]> Git Repo - qemu.git/commitdiff
sam460ex: Suppress useless warning on -m 32 and -m 64
authorMarkus Armbruster <[email protected]>
Wed, 22 Apr 2020 13:48:12 +0000 (15:48 +0200)
committerMarkus Armbruster <[email protected]>
Wed, 29 Apr 2020 06:01:52 +0000 (08:01 +0200)
Requesting 32 or 64 MiB of RAM with the sam460ex machine type produces
a useless warning:

    qemu-system-ppc: warning: Memory size is too small for SDRAM type, adjusting type

This is because sam460ex_init() asks spd_data_generate() for DDR2,
which is impossible, so spd_data_generate() corrects it to DDR.

The warning goes back to commit 08fd99179a "sam460ex: Clean up SPD
EEPROM creation".

Make sam460ex_init() pass the correct SDRAM type to get rid of the
warning.

Signed-off-by: Markus Armbruster <[email protected]>
Message-Id: <20200422134815[email protected]>
Reviewed-by: Philippe Mathieu-Daudé <[email protected]>
hw/ppc/sam460ex.c

index 898453cf30d2aec5ce4425fc197e4faf6bbb9e3e..1e3eaac0dbcd04d59bd419dff8de5cbef184aed5 100644 (file)
@@ -335,7 +335,8 @@ static void sam460ex_init(MachineState *machine)
     dev = sysbus_create_simple(TYPE_PPC4xx_I2C, 0x4ef600700, uic[0][2]);
     i2c = PPC4xx_I2C(dev)->bus;
     /* SPD EEPROM on RAM module */
-    spd_data = spd_data_generate(DDR2, ram_sizes[0], &err);
+    spd_data = spd_data_generate(ram_sizes[0] < 128 * MiB ? DDR : DDR2,
+                                 ram_sizes[0], &err);
     if (err) {
         warn_report_err(err);
     }
This page took 0.026777 seconds and 4 git commands to generate.