summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEric Lai <eric_lai@quanta.corp-partner.google.com>2022-05-23 15:47:20 +0800
committerSubrata Banik <subratabanik@google.com>2022-07-01 07:23:19 +0000
commitf6c52f46846b4d6157bc1cddbadbbece8a872afc (patch)
treecb76e1c8c85ae35d8ee777905ae5753bf5838d1f /src
parent03b392355c84a5c868a96470e1b96e3d422fb85a (diff)
mb/google/rex: Add entry stubs of each stage
Add entry point stubs of each stage for Rex. More functionalities will be added later. BUG=b:224325352 TEST=util/abuild/abuild -p none -t google/rex -a -c max Signed-off-by: Eric Lai <eric_lai@quanta.corp-partner.google.com> Change-Id: I2310e58ab92bdb0ce86a9f7284cc0b3e04a2889f Reviewed-on: https://review.coreboot.org/c/coreboot/+/64591 Reviewed-by: Tarun Tuli <taruntuli@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src')
-rw-r--r--src/mainboard/google/rex/Makefile.inc10
-rw-r--r--src/mainboard/google/rex/bootblock.c8
-rw-r--r--src/mainboard/google/rex/mainboard.c18
-rw-r--r--src/mainboard/google/rex/romstage.c9
-rw-r--r--src/mainboard/google/rex/variants/baseboard/include/baseboard/variants.h9
-rw-r--r--src/mainboard/google/rex/variants/baseboard/rex/include/baseboard/gpio.h9
6 files changed, 63 insertions, 0 deletions
diff --git a/src/mainboard/google/rex/Makefile.inc b/src/mainboard/google/rex/Makefile.inc
new file mode 100644
index 0000000000..e0c4003b5a
--- /dev/null
+++ b/src/mainboard/google/rex/Makefile.inc
@@ -0,0 +1,10 @@
+bootblock-y += bootblock.c
+
+romstage-y += romstage.c
+
+ramstage-y += mainboard.c
+
+subdirs-y += variants/baseboard/$(BASEBOARD_DIR)
+
+CPPFLAGS_common += -I$(src)/mainboard/$(MAINBOARDDIR)/variants/baseboard/include
+CPPFLAGS_common += -I$(src)/mainboard/$(MAINBOARDDIR)/variants/baseboard/$(BASEBOARD_DIR)/include
diff --git a/src/mainboard/google/rex/bootblock.c b/src/mainboard/google/rex/bootblock.c
new file mode 100644
index 0000000000..8a7b93a968
--- /dev/null
+++ b/src/mainboard/google/rex/bootblock.c
@@ -0,0 +1,8 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#include <bootblock_common.h>
+
+void bootblock_mainboard_init(void)
+{
+ /* TODO: Perform mainboard initialization */
+}
diff --git a/src/mainboard/google/rex/mainboard.c b/src/mainboard/google/rex/mainboard.c
new file mode 100644
index 0000000000..3dc2c41d69
--- /dev/null
+++ b/src/mainboard/google/rex/mainboard.c
@@ -0,0 +1,18 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#include <device/device.h>
+
+static void mainboard_init(void *chip_info)
+{
+ /* TODO: Perform mainboard initialization */
+}
+
+static void mainboard_enable(struct device *dev)
+{
+ /* TODO: Enable mainboard */
+}
+
+struct chip_operations mainboard_ops = {
+ .init = mainboard_init,
+ .enable_dev = mainboard_enable,
+};
diff --git a/src/mainboard/google/rex/romstage.c b/src/mainboard/google/rex/romstage.c
new file mode 100644
index 0000000000..b8ad127cef
--- /dev/null
+++ b/src/mainboard/google/rex/romstage.c
@@ -0,0 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#include <fsp/api.h>
+#include <soc/romstage.h>
+
+void mainboard_memory_init_params(FSPM_UPD *memupd)
+{
+ /* TODO : Fill FSP-M memory params */
+}
diff --git a/src/mainboard/google/rex/variants/baseboard/include/baseboard/variants.h b/src/mainboard/google/rex/variants/baseboard/include/baseboard/variants.h
new file mode 100644
index 0000000000..d16d3dad53
--- /dev/null
+++ b/src/mainboard/google/rex/variants/baseboard/include/baseboard/variants.h
@@ -0,0 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#ifndef __BASEBOARD_VARIANTS_H__
+#define __BASEBOARD_VARIANTS_H__
+
+#include <soc/gpio.h>
+#include <stdint.h>
+
+#endif /*__BASEBOARD_VARIANTS_H__ */
diff --git a/src/mainboard/google/rex/variants/baseboard/rex/include/baseboard/gpio.h b/src/mainboard/google/rex/variants/baseboard/rex/include/baseboard/gpio.h
new file mode 100644
index 0000000000..a708db11ad
--- /dev/null
+++ b/src/mainboard/google/rex/variants/baseboard/rex/include/baseboard/gpio.h
@@ -0,0 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#ifndef __BASEBOARD_GPIO_H__
+#define __BASEBOARD_GPIO_H__
+
+#include <soc/gpe.h>
+#include <soc/gpio.h>
+
+#endif /* __BASEBOARD_GPIO_H__ */