x86/shadow: ditch dangerous declarations
authorJan Beulich <jbeulich@suse.com>
Mon, 22 Jul 2019 09:30:10 +0000 (11:30 +0200)
committerJan Beulich <jbeulich@suse.com>
Mon, 22 Jul 2019 09:30:10 +0000 (11:30 +0200)
commit93a8877544c3df39124eea6e1f12a319aa3ce54a
treefba04011b6a3e2fd7d8573a0374da7768c1aeb37
parent66d11b9c1281ac133b92b3e6dd5b5e1c2abea7bf
x86/shadow: ditch dangerous declarations

This started out with me noticing the latent bug of there being HVM
related declarations in common.c that their producer doesn't see, and
that hence could go out of sync at any time. However, go farther than
fixing just that and move the functions actually using these into hvm.c.
This way the items in question can simply become static, and no separate
declarations are needed at all.

Within the moved code constify and rename or outright delete the struct
vcpu * local variables and re-format a comment.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/mm/shadow/common.c
xen/arch/x86/mm/shadow/hvm.c
xen/arch/x86/mm/shadow/private.h