diff mbox

libxc/arm: align to page size the base address of the device tree

Message ID 1384887144-7229-1-git-send-email-julien.grall@linaro.org
State Rejected, archived
Headers show

Commit Message

Julien Grall Nov. 19, 2013, 6:52 p.m. UTC
xc_dom_alloc_segment requires start address to be page align.

Signed-off-by: Julien Grall <julien.grall@linaro.org>
---
 tools/libxc/xc_dom_arm.c |    2 ++
 1 file changed, 2 insertions(+)
diff mbox

Patch

diff --git a/tools/libxc/xc_dom_arm.c b/tools/libxc/xc_dom_arm.c
index ffe575b..366061d 100644
--- a/tools/libxc/xc_dom_arm.c
+++ b/tools/libxc/xc_dom_arm.c
@@ -290,6 +290,8 @@  int arch_setup_meminit(struct xc_dom_image *dom)
         else /* otherwise at top of RAM */
             dom->devicetree_seg.vstart = ramend - dtbsize;
 
+        dom->devicetree_seg.vstart &= XC_PAGE_MASK;
+
         dom->devicetree_seg.vend =
             dom->devicetree_seg.vstart + dom->devicetree_size;
         DOMPRINTF("%s: devicetree: 0x%" PRIx64 " -> 0x%" PRIx64 "",