domctl: introduce a macro to set the grant table max version
authorRoger Pau Monné <roger.pau@citrix.com>
Wed, 17 Nov 2021 07:12:00 +0000 (08:12 +0100)
committerJan Beulich <jbeulich@suse.com>
Wed, 17 Nov 2021 07:12:00 +0000 (08:12 +0100)
commit2abeaf319c59d3446e03264e25987200eb4217ca
treec08bdcfa102d7298711ffab5638aee99ad9d5090
parent2d72d2784eb71d8532bfbd6462d261739c9e82e4
domctl: introduce a macro to set the grant table max version

Such macro just clamps the passed version to fit in the designated
bits of the domctl field. The main purpose is to make it clearer in
the code when max grant version is being set in the grant_opts field.

Existing users that where setting the version in the grant_opts field
are switched to use the macro.

No functional change intended.

Requested-by: Jan Beulich <jbeulich@suse.com>
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Bertrand Marquis <bertrand.marquis@arm.com>
Acked-by: Julien Grall <jgrall@amazon.com>
Reviewed-by: Ian Jackson <iwj@xenproject.org>
Release-Acked-by: Ian Jackson <iwj@xenproject.org>
tools/helpers/init-xenstore-domain.c
tools/libs/light/libxl_create.c
tools/ocaml/libs/xc/xenctrl_stubs.c
xen/arch/arm/domain_build.c
xen/arch/x86/setup.c
xen/include/public/domctl.h