x86/shadow: shadow_table[] needs only one entry for PV-only configs
authorJan Beulich <jbeulich@suse.com>
Tue, 21 Jul 2020 11:58:15 +0000 (13:58 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 21 Jul 2020 11:58:15 +0000 (13:58 +0200)
commitef3b0d8d2c3975c5cdd6a521896d85e97b74e924
treed4cd9c8f241c6835373e0663cabf0eec731dece2
parentded576ce07e9328f66842bef67d8cfc14c3088b7
x86/shadow: shadow_table[] needs only one entry for PV-only configs

Furthermore the field isn't needed at all with shadow support disabled -
move it into struct shadow_vcpu.

Introduce for_each_shadow_table(), shortening loops for the 4-level case
at the same time.

Adjust loop variables and a function parameter to be "unsigned int"
where applicable at the same time. Also move a comment that ended up
misplaced due to incremental additions.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Tim Deegan <tim@xen.org>
xen/arch/x86/mm/shadow/common.c
xen/arch/x86/mm/shadow/multi.c
xen/include/asm-x86/domain.h