diff options
author | BALATON Zoltan <balaton@eik.bme.hu> | 2022-09-24 14:27:52 +0200 |
---|---|---|
committer | Daniel Henrique Barboza <danielhb413@gmail.com> | 2022-10-17 16:15:09 -0300 |
commit | 68b9a2e38d7183f64dddc5faec9a16c70a4f095c (patch) | |
tree | d172ca8d0ca763b634b3ede5ccb1d164c65e3cec /hw/ppc/ppc440_bamboo.c | |
parent | 8626982301dc8dbbe49e0fb1730461955df879c8 (diff) | |
download | qemu-68b9a2e38d7183f64dddc5faec9a16c70a4f095c.zip qemu-68b9a2e38d7183f64dddc5faec9a16c70a4f095c.tar.gz qemu-68b9a2e38d7183f64dddc5faec9a16c70a4f095c.tar.bz2 |
ppc4xx_sdram: Get rid of the init RAM hack
The do_init parameter of ppc4xx_sdram_init() is used to map memory
regions that is normally done by the firmware by programming the SDRAM
controller. Do this from board code emulating what firmware would do
when booting a kernel directly from -kernel without a firmware so we
can get rid of this do_init hack.
Signed-off-by: BALATON Zoltan <balaton@eik.bme.hu>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Message-Id: <d6c44c870befa1a075e21f1a59926dcdaff63f6b.1664021647.git.balaton@eik.bme.hu>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Diffstat (limited to 'hw/ppc/ppc440_bamboo.c')
-rw-r--r-- | hw/ppc/ppc440_bamboo.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c index 5ec82fa..409a884 100644 --- a/hw/ppc/ppc440_bamboo.c +++ b/hw/ppc/ppc440_bamboo.c @@ -211,7 +211,9 @@ static void bamboo_init(MachineState *machine) ppc4xx_sdram_init(env, qdev_get_gpio_in(uicdev, 14), PPC440EP_SDRAM_NR_BANKS, ram_memories, - ram_bases, ram_sizes, 1); + ram_bases, ram_sizes); + /* Enable SDRAM memory regions, this should be done by the firmware */ + ppc4xx_sdram_enable(env); /* PCI */ dev = sysbus_create_varargs(TYPE_PPC4xx_PCI_HOST_BRIDGE, |