Skip to contentSkip to conversation

ppc/pnv: Set default ram size to 1.75GB

PATCH Applied Joel Stanley 2 participants 2 messages Aug 21, 2019 – Aug 22, 2019

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 ppc/pnv: Set default ram size to 1.75GB

This makes the powernv machine easier for end users as the default initrd address (1.5GB) is now within RAM.

This uses less than 2GB of RAM to ensure 32 bit Qemu still works.

--
v2: Use INITRD defines, whcih come out to 1.75, instead of 2GB

---
 hw/ppc/pnv.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
hw/ppc/pnv.c +3 -1
index d95086fbbd1e..5000db5faab5 100644
@@ -1361,7 +1361,9 @@ static void pnv_machine_class_init(ObjectClass *oc, void *data)
                                       * storage */
     mc->no_parallel = 1;
     mc->default_boot_order = NULL;
-    mc->default_ram_size = 1 * GiB;
+    /* RAM defaults to less than 2048 for 32-bit hosts, and large
+     * enough to fit the maximum initrd size at it's load address */
+    mc->default_ram_size = INITRD_LOAD_ADDR + INITRD_MAX_SIZE;
     xic->icp_get = pnv_icp_get;
     xic->ics_get = pnv_ics_get;
     xic->ics_resend = pnv_ics_resend;
Signature · 1 line
2.23.0.rc1
Applied
#1 lore raw
Quoted 6 lines · Joel Stanley

This makes the powernv machine easier for end users as the default initrd address (1.5GB) is now within RAM.

This uses less than 2GB of RAM to ensure 32 bit Qemu still works.

Applied to ppc-for-4.2, in place of the earlier version.

Signature · 4 lines
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson