Skip to content

Commit

Permalink
mb/emulation: Drop cbmem_recovery(0) call in ramstage
Browse files Browse the repository at this point in the history
Calling cbmem_recovery(0) late in ramstage would appear
to remove all CBMEM entries created so far.

Change-Id: I2abb079844c4b41be09354d603ad36e4a56ea2e1
Signed-off-by: Kyösti Mälkki <[email protected]>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/50841
Reviewed-by: Angel Pons <[email protected]>
Tested-by: build bot (Jenkins) <[email protected]>
  • Loading branch information
kmalkki authored and pgeorgi committed Feb 22, 2021
1 parent 70243cd commit c79fc47
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 10 deletions.
2 changes: 0 additions & 2 deletions src/mainboard/emulation/qemu-armv7/mainboard.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

#include <console/console.h>
#include <device/device.h>
#include <cbmem.h>
#include <halt.h>
#include <device/mmio.h>
#include <ramdetect.h>
Expand Down Expand Up @@ -41,7 +40,6 @@ static void mainboard_enable(struct device *dev)
discovered = probe_ramsize((uintptr_t)_dram, CONFIG_DRAM_SIZE_MB);
printk(BIOS_DEBUG, "%d MiB of RAM discovered\n", discovered);
ram_resource(dev, 0, 0x60000000 >> 10, discovered << 10);
cbmem_recovery(0);
init_gfx();
}

Expand Down
2 changes: 0 additions & 2 deletions src/mainboard/emulation/qemu-power8/mainboard.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

#include <console/console.h>
#include <device/device.h>
#include <cbmem.h>

static void mainboard_enable(struct device *dev)
{
Expand All @@ -13,7 +12,6 @@ static void mainboard_enable(struct device *dev)

/* Where does RAM live? */
ram_resource(dev, 0, 2048, 32768);
cbmem_recovery(0);
}

struct chip_operations mainboard_ops = {
Expand Down
3 changes: 0 additions & 3 deletions src/mainboard/emulation/qemu-riscv/mainboard.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

#include <console/console.h>
#include <device/device.h>
#include <cbmem.h>
#include <symbols.h>
#include <ramdetect.h>

Expand All @@ -16,8 +15,6 @@ static void mainboard_enable(struct device *dev)

dram_mb_detected = probe_ramsize((uintptr_t)_dram, CONFIG_DRAM_SIZE_MB);
ram_resource(dev, 0, (uintptr_t)_dram / KiB, dram_mb_detected * MiB / KiB);

cbmem_recovery(0);
}

struct chip_operations mainboard_ops = {
Expand Down
3 changes: 0 additions & 3 deletions src/mainboard/emulation/spike-riscv/mainboard.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

#include <console/console.h>
#include <device/device.h>
#include <cbmem.h>

static void mainboard_enable(struct device *dev)
{
Expand All @@ -19,8 +18,6 @@ static void mainboard_enable(struct device *dev)
}

ram_resource(dev, 0, 0x80000000/KiB, ram_size/KiB);

cbmem_recovery(0);
}

struct chip_operations mainboard_ops = {
Expand Down

0 comments on commit c79fc47

Please sign in to comment.