guest/pvh: fix handling of multiboot module list
authorRoger Pau Monné <roger.pau@citrix.com>
Mon, 12 Nov 2018 16:13:57 +0000 (17:13 +0100)
committerJan Beulich <jbeulich@suse.com>
Mon, 12 Nov 2018 16:13:57 +0000 (17:13 +0100)
commitc6aae55786e138951daf25e14709895d8c166948
tree58911c0910c72e4f580deb571acd440a063de75a
parent94bd9df0f7efad8038d99ec52ba56ecec4191248
guest/pvh: fix handling of multiboot module list

When booting Xen as a PVH guest the data in the PVH start info
structure is copied over to a multiboot structure and a module list
array that resides in the .init section of the Xen image. The
resulting multiboot module list is then handed to the generic boot
process using the physical address in mbi->mods_addr.

This works fine as long as the Xen image doesn't relocate itself, if
there's such a relocation the physical addresses of multiboot module
list is no longer valid.

Fix this by handing the virtual address of the module list to the
generic boot process instead of it's physical address.

Reported-by: Sergey Dyasli <sergey.dyasli@citrix.com>
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/guest/pvh-boot.c
xen/arch/x86/setup.c
xen/include/asm-x86/guest/pvh-boot.h