[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 22/26] hw/arm/imx25_pdk: Fix error message for invalid RAM size
From: |
Peter Maydell |
Subject: |
[PULL 22/26] hw/arm/imx25_pdk: Fix error message for invalid RAM size |
Date: |
Mon, 10 May 2021 13:25:44 +0100 |
From: Philippe Mathieu-Daudé <f4bug@amsat.org>
The i.MX25 PDK board has 2 banks for SDRAM, each can
address up to 256 MiB. So the total RAM usable for this
board is 512M. When we ask for more we get a misleading
error message:
$ qemu-system-arm -M imx25-pdk -m 513M
qemu-system-arm: Invalid RAM size, should be 128 MiB
Update the error message to better match the reality:
$ qemu-system-arm -M imx25-pdk -m 513M
qemu-system-arm: RAM size more than 512 MiB is not supported
Fixes: bf350daae02 ("arm/imx25_pdk: drop RAM size fixup")
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Message-id: 20210407225608.1882855-1-f4bug@amsat.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
hw/arm/imx25_pdk.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/hw/arm/imx25_pdk.c b/hw/arm/imx25_pdk.c
index 11426e5ec0c..bd16acd4d9f 100644
--- a/hw/arm/imx25_pdk.c
+++ b/hw/arm/imx25_pdk.c
@@ -65,7 +65,6 @@ static struct arm_boot_info imx25_pdk_binfo;
static void imx25_pdk_init(MachineState *machine)
{
- MachineClass *mc = MACHINE_GET_CLASS(machine);
IMX25PDK *s = g_new0(IMX25PDK, 1);
unsigned int ram_size;
unsigned int alias_offset;
@@ -77,8 +76,8 @@ static void imx25_pdk_init(MachineState *machine)
/* We need to initialize our memory */
if (machine->ram_size > (FSL_IMX25_SDRAM0_SIZE + FSL_IMX25_SDRAM1_SIZE)) {
- char *sz = size_to_str(mc->default_ram_size);
- error_report("Invalid RAM size, should be %s", sz);
+ char *sz = size_to_str(FSL_IMX25_SDRAM0_SIZE + FSL_IMX25_SDRAM1_SIZE);
+ error_report("RAM size more than %s is not supported", sz);
g_free(sz);
exit(EXIT_FAILURE);
}
--
2.20.1
- [PULL 12/26] target/arm: Move vfp_reg_ptr() to translate-neon.c.inc, (continued)
- [PULL 12/26] target/arm: Move vfp_reg_ptr() to translate-neon.c.inc, Peter Maydell, 2021/05/10
- [PULL 10/26] target/arm: Make functions used by translate-vfp global, Peter Maydell, 2021/05/10
- [PULL 09/26] target/arm: Move vfp_{load, store}_reg{32, 64} to translate-vfp.c.inc, Peter Maydell, 2021/05/10
- [PULL 11/26] target/arm: Make translate-vfp.c.inc its own compilation unit, Peter Maydell, 2021/05/10
- [PULL 14/26] target/arm: Move NeonGenThreeOpEnvFn typedef to translate.h, Peter Maydell, 2021/05/10
- [PULL 15/26] target/arm: Make functions used by translate-neon global, Peter Maydell, 2021/05/10
- [PULL 13/26] target/arm: Delete unused typedef, Peter Maydell, 2021/05/10
- [PULL 16/26] target/arm: Make translate-neon.c.inc its own compilation unit, Peter Maydell, 2021/05/10
- [PULL 18/26] hw/sd/omap_mmc: Use device_cold_reset() instead of device_legacy_reset(), Peter Maydell, 2021/05/10
- [PULL 17/26] target/arm: Make WFI a NOP for userspace emulators, Peter Maydell, 2021/05/10
- [PULL 22/26] hw/arm/imx25_pdk: Fix error message for invalid RAM size,
Peter Maydell <=
- [PULL 20/26] include/qemu/bswap.h: Handle being included outside extern "C" block, Peter Maydell, 2021/05/10
- [PULL 19/26] osdep: Make os-win32.h and os-posix.h handle 'extern "C"' themselves, Peter Maydell, 2021/05/10
- [PULL 21/26] include/disas/dis-asm.h: Handle being included outside 'extern "C"', Peter Maydell, 2021/05/10
- [PULL 23/26] hw/misc/mps2-scc: Add "QEMU interface" comment, Peter Maydell, 2021/05/10
- [PULL 25/26] hw/arm/mps2-tz: Implement AN524 memory remapping via machine property, Peter Maydell, 2021/05/10
- [PULL 24/26] hw/misc/mps2-scc: Support using CFG0 bit 0 for remapping, Peter Maydell, 2021/05/10
- [PULL 26/26] hw/arm/xlnx: Fix PHY address for xilinx-zynq-a9, Peter Maydell, 2021/05/10