summaryrefslogtreecommitdiff
path: root/src/mainboard/kontron/986lcd-m
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/kontron/986lcd-m')
-rw-r--r--src/mainboard/kontron/986lcd-m/Kconfig1
-rw-r--r--src/mainboard/kontron/986lcd-m/romstage.c8
2 files changed, 6 insertions, 3 deletions
diff --git a/src/mainboard/kontron/986lcd-m/Kconfig b/src/mainboard/kontron/986lcd-m/Kconfig
index e8b722523d..29d4da46a5 100644
--- a/src/mainboard/kontron/986lcd-m/Kconfig
+++ b/src/mainboard/kontron/986lcd-m/Kconfig
@@ -9,6 +9,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select CHECK_SLFRCS_ON_RESUME
select SOUTHBRIDGE_INTEL_I82801GX
select SUPERIO_WINBOND_W83627THG
+ select EARLY_CBMEM_INIT
select HAVE_ACPI_TABLES
select HAVE_PIRQ_TABLE
select HAVE_MP_TABLE
diff --git a/src/mainboard/kontron/986lcd-m/romstage.c b/src/mainboard/kontron/986lcd-m/romstage.c
index 324f442f44..1875a10ad4 100644
--- a/src/mainboard/kontron/986lcd-m/romstage.c
+++ b/src/mainboard/kontron/986lcd-m/romstage.c
@@ -22,6 +22,7 @@
#include <stdint.h>
#include <string.h>
#include <lib.h>
+#include <cbmem.h>
#include <arch/io.h>
#include <device/pci_def.h>
#include <device/pnp_def.h>
@@ -314,12 +315,11 @@ static void early_ich7_init(void)
RCBA32(0x2034) = reg32;
}
-#include <cbmem.h>
-
void main(unsigned long bist)
{
u32 reg32;
int boot_mode = 0;
+ int cbmem_was_initted;
if (bist == 0)
enable_lapic();
@@ -410,11 +410,13 @@ void main(unsigned long bist)
MCHBAR16(SSKPD) = 0xCAFE;
+ cbmem_was_initted = !cbmem_initialize();
+
#if CONFIG_HAVE_ACPI_RESUME
/* If there is no high memory area, we didn't boot before, so
* this is not a resume. In that case we just create the cbmem toc.
*/
- if ((boot_mode == 2) && cbmem_reinit()) {
+ if ((boot_mode == 2) && cbmem_was_initted) {
void *resume_backup_memory = cbmem_find(CBMEM_ID_RESUME);
/* copy 1MB - 64K to high tables ram_base to prevent memory corruption