xen/arm: Allocate memory for dom0 from the bottom with the 1:1 Workaround
authorJulien Grall <julien.grall@linaro.org>
Tue, 22 Oct 2013 10:51:48 +0000 (11:51 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Thu, 24 Oct 2013 13:04:42 +0000 (14:04 +0100)
commit6c21cb36e263de2db8716b477157a5b6cd531e1e
tree9acb41cf6149541edc08310b1d8a33718026c5da
parent466abd6b3866cda0866c03a9d7673f299d6f6754
xen/arm: Allocate memory for dom0 from the bottom with the 1:1 Workaround

On Linux, the option CONFIG_ARM_PATCH_PHYS_VIRT (by default enabled) allows
the Kernel to be loaded anywhere (or nearly) by patching the translation
pv<->virt at boot time.

The current solution in Linux assuming that the delta physical address -
virtual address is always negative. A positive delta will destroy all the
optimisation to modify only a part of the translation instruction (add/sub).

By default, Xen is allocating memory from the top of memory and then
goes down. To avoid booting issue with Linux, we must allocate memory
from the bottom (ie starting from 0).

Signed-off-by: Julien Grall <julien.grall@linaro.org>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
xen/arch/arm/domain_build.c