Re: [V2 02/11] KVM: selftests: sparsebit: add const where appropriate

From: Andrew Jones
Date: Tue Aug 02 2022 - 06:00:54 EST


On Mon, Aug 01, 2022 at 01:11:00PM -0700, Peter Gonda wrote:
> From: Michael Roth <michael.roth@xxxxxxx>
>
> Subsequent patches will introduce an encryption bitmap in kvm_util that
> would be useful to allow tests to access in read-only fashion. This
> will be done via a const sparsebit*. To avoid warnings or the need to
> add casts everywhere, add const to the various sparsebit functions that
> are applicable for read-only usage of sparsebit.
>
> Signed-off-by: Michael Roth <michael.roth@xxxxxxx>
> Signed-off-by: Peter Gonda <pgonda@xxxxxxxxxx>
> ---
> .../testing/selftests/kvm/include/sparsebit.h | 36 +++++++-------
> tools/testing/selftests/kvm/lib/sparsebit.c | 48 +++++++++----------
> 2 files changed, 42 insertions(+), 42 deletions(-)
>

Reviewed-by: Andrew Jones <andrew.jones@xxxxxxxxx>