ppc/pnv: change initrd address
authorCédric Le Goater <clg@kaod.org>
Mon, 15 Jan 2018 18:04:05 +0000 (19:04 +0100)
committerDavid Gibson <david@gibson.dropbear.id.au>
Tue, 16 Jan 2018 22:35:24 +0000 (09:35 +1100)
When skiboot starts, it first clears the CPU structs for all possible
CPUs on a system :

for (i = 0; i <= cpu_max_pir; i++)
memset(&cpu_stacks[i].cpu, 0, sizeof(struct cpu_thread));

On POWER9, cpu_max_pir is quite big, 0x7fff, and the skiboot cpu_stacks
array overlaps with the memory region in which QEMU maps the initramfs
file. Move it upwards in memory to keep it safe.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
hw/ppc/pnv.c

index 80245f57f1aea1440593c27e9aab18b353e23a46..98ee3c607ae7b02c6abce9e83d6a9702abf66ddb 100644 (file)
@@ -53,7 +53,7 @@
 #define FW_MAX_SIZE             0x00400000
 
 #define KERNEL_LOAD_ADDR        0x20000000
-#define INITRD_LOAD_ADDR        0x40000000
+#define INITRD_LOAD_ADDR        0x60000000
 
 static const char *pnv_chip_core_typename(const PnvChip *o)
 {