From: Jiaxun Yang <[email protected]>

Higher bits for memory nodes were omitted at qemu_fdt_setprop_cells.

Cc: [email protected]
Signed-off-by: Jiaxun Yang <[email protected]>
Reviewed-by: Song Gao <[email protected]>
Message-Id: <[email protected]>
Signed-off-by: Song Gao <[email protected]>
(cherry picked from commit 6204af704a071ea68d3af55c0502b112a7af9546)
Signed-off-by: Michael Tokarev <[email protected]>

diff --git a/hw/loongarch/virt.c b/hw/loongarch/virt.c
index 8f39254880..83d3d7522f 100644
--- a/hw/loongarch/virt.c
+++ b/hw/loongarch/virt.c
@@ -333,7 +333,8 @@ static void fdt_add_memory_node(MachineState *ms,
     char *nodename = g_strdup_printf("/memory@%" PRIx64, base);
 
     qemu_fdt_add_subnode(ms->fdt, nodename);
-    qemu_fdt_setprop_cells(ms->fdt, nodename, "reg", 0, base, 0, size);
+    qemu_fdt_setprop_cells(ms->fdt, nodename, "reg", base >> 32, base,
+                           size >> 32, size);
     qemu_fdt_setprop_string(ms->fdt, nodename, "device_type", "memory");
 
     if (ms->numa_state && ms->numa_state->num_nodes) {
-- 
2.39.2


Reply via email to