summaryrefslogtreecommitdiff
path: root/src/mainboard/aopen
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2019-01-06 10:44:49 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2019-01-13 08:38:13 +0000
commit0377a369b9c34dd9e5e1002845e99d29dea55ca3 (patch)
treed85345dc447b2db608039b0b3c39d3d1e7619ac6 /src/mainboard/aopen
parent34856579f8e9349104cfdd0245a2b966bc59a7ea (diff)
downloadcoreboot-0377a369b9c34dd9e5e1002845e99d29dea55ca3.tar.xz
aopen/dxplplusu: Switch to C_ENVIRONMENT_BOOTBLOCK
This board is the only user of these ancient chipsets, so we'll do all in one go. Also wipe out some extra headers. Change-Id: I22c172d577e6072562d8fcfa58145ec62473823e Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/30688 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/mainboard/aopen')
-rw-r--r--src/mainboard/aopen/dxplplusu/Kconfig4
-rw-r--r--src/mainboard/aopen/dxplplusu/Makefile.inc14
-rw-r--r--src/mainboard/aopen/dxplplusu/bootblock.c26
-rw-r--r--src/mainboard/aopen/dxplplusu/romstage.c15
4 files changed, 44 insertions, 15 deletions
diff --git a/src/mainboard/aopen/dxplplusu/Kconfig b/src/mainboard/aopen/dxplplusu/Kconfig
index 85c45d51f3..3a729ce17a 100644
--- a/src/mainboard/aopen/dxplplusu/Kconfig
+++ b/src/mainboard/aopen/dxplplusu/Kconfig
@@ -29,6 +29,10 @@ config MAX_CPUS
int
default 4
+config C_ENV_BOOTBLOCK_SIZE
+ hex
+ default 0x4000
+
config MAINBOARD_PCI_SUBSYSTEM_VENDOR_ID
hex
default 0x0
diff --git a/src/mainboard/aopen/dxplplusu/Makefile.inc b/src/mainboard/aopen/dxplplusu/Makefile.inc
new file mode 100644
index 0000000000..0fedf5ce8c
--- /dev/null
+++ b/src/mainboard/aopen/dxplplusu/Makefile.inc
@@ -0,0 +1,14 @@
+##
+## This file is part of the coreboot project.
+##
+## This program is free software; you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation; version 2 of the License.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+##
+
+bootblock-y += bootblock.c
diff --git a/src/mainboard/aopen/dxplplusu/bootblock.c b/src/mainboard/aopen/dxplplusu/bootblock.c
new file mode 100644
index 0000000000..f06f76e0ad
--- /dev/null
+++ b/src/mainboard/aopen/dxplplusu/bootblock.c
@@ -0,0 +1,26 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2019 Kyösti Mälkki <kyosti.malkki@gmail.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <bootblock_common.h>
+#include <device/pnp_def.h>
+#include <superio/smsc/lpc47m10x/lpc47m10x.h>
+
+#define SERIAL_DEV PNP_DEV(0x2e, LPC47M10X2_SP1)
+
+void bootblock_mainboard_early_init(void)
+{
+ /* Get the serial port configured. */
+ lpc47m10x_enable_serial(SERIAL_DEV, CONFIG_TTYS0_BASE);
+}
diff --git a/src/mainboard/aopen/dxplplusu/romstage.c b/src/mainboard/aopen/dxplplusu/romstage.c
index f95c7f91e2..57538d6f80 100644
--- a/src/mainboard/aopen/dxplplusu/romstage.c
+++ b/src/mainboard/aopen/dxplplusu/romstage.c
@@ -14,22 +14,14 @@
*/
#include <stdint.h>
-#include <device/pci_def.h>
#include <arch/io.h>
-#include <stdlib.h>
#include <cbmem.h>
#include <console/console.h>
-#include <cpu/x86/bist.h>
#include <cpu/intel/romstage.h>
#include <southbridge/intel/i82801dx/i82801dx.h>
#include <northbridge/intel/e7505/raminit.h>
-#include <device/pnp_def.h>
-#include <superio/smsc/lpc47m10x/lpc47m10x.h>
-
-#define SERIAL_DEV PNP_DEV(0x2e, LPC47M10X2_SP1)
-
int spd_read_byte(unsigned int device, unsigned int address)
{
return smbus_read_byte(device, address);
@@ -46,13 +38,6 @@ void mainboard_romstage_entry(unsigned long bist)
},
};
- /* Get the serial port running and print a welcome banner */
- lpc47m10x_enable_serial(SERIAL_DEV, CONFIG_TTYS0_BASE);
- console_init();
-
- /* Halt if there was a built in self test failure */
- report_bist_failure(bist);
-
/* If this is a warm boot, some initialization can be skipped */
if (!e7505_mch_is_ready()) {
enable_smbus();