summaryrefslogtreecommitdiff
path: root/board/ti/am64x
diff options
context:
space:
mode:
authorDave Gerlach <d-gerlach@ti.com>2021-04-23 11:27:42 -0500
committerLokesh Vutla <lokeshvutla@ti.com>2021-05-12 16:27:57 +0530
commit33b7258947f4a15a048f7c31c3f5d72221152ba2 (patch)
treeafb3489b58b63968daeadc70ab37f58637888d73 /board/ti/am64x
parentf721502e3f772e4dd818e1e40a9485177356e9f9 (diff)
downloadu-boot-33b7258947f4a15a048f7c31c3f5d72221152ba2.tar.gz
u-boot-33b7258947f4a15a048f7c31c3f5d72221152ba2.tar.bz2
u-boot-33b7258947f4a15a048f7c31c3f5d72221152ba2.zip
board: ti: am64x: Add board support for am64x evm
Add board specific initialization for am64x based boards. Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
Diffstat (limited to 'board/ti/am64x')
-rw-r--r--board/ti/am64x/Kconfig53
-rw-r--r--board/ti/am64x/Makefile8
-rw-r--r--board/ti/am64x/evm.c48
3 files changed, 109 insertions, 0 deletions
diff --git a/board/ti/am64x/Kconfig b/board/ti/am64x/Kconfig
new file mode 100644
index 0000000000..57527be1df
--- /dev/null
+++ b/board/ti/am64x/Kconfig
@@ -0,0 +1,53 @@
+# SPDX-License-Identifier: GPL-2.0+
+#
+# Copyright (C) 2020-2021 Texas Instruments Incorporated - https://www.ti.com/
+
+choice
+ prompt "K3 AM64 based boards"
+ optional
+
+config TARGET_AM642_A53_EVM
+ bool "TI K3 based AM642 EVM running on A53"
+ select ARM64
+ select SOC_K3_AM642
+ imply BOARD
+ imply SPL_BOARD
+
+config TARGET_AM642_R5_EVM
+ bool "TI K3 based AM642 EVM running on R5"
+ select CPU_V7R
+ select SYS_THUMB_BUILD
+ select K3_LOAD_SYSFW
+ select SOC_K3_AM642
+ imply SYS_K3_SPL_ATF
+
+endchoice
+
+if TARGET_AM642_A53_EVM
+
+config SYS_BOARD
+ default "am64x"
+
+config SYS_VENDOR
+ default "ti"
+
+config SYS_CONFIG_NAME
+ default "am64x_evm"
+
+endif
+
+if TARGET_AM642_R5_EVM
+
+config SYS_BOARD
+ default "am64x"
+
+config SYS_VENDOR
+ default "ti"
+
+config SYS_CONFIG_NAME
+ default "am64x_evm"
+
+config SPL_LDSCRIPT
+ default "arch/arm/mach-omap2/u-boot-spl.lds"
+
+endif
diff --git a/board/ti/am64x/Makefile b/board/ti/am64x/Makefile
new file mode 100644
index 0000000000..8b98e6f5fd
--- /dev/null
+++ b/board/ti/am64x/Makefile
@@ -0,0 +1,8 @@
+#
+# Copyright (C) 2020-2021 Texas Instruments Incorporated - https://www.ti.com/
+# Keerthy <j-keerthy@ti.com>
+#
+# SPDX-License-Identifier: GPL-2.0+
+#
+
+obj-y += evm.o
diff --git a/board/ti/am64x/evm.c b/board/ti/am64x/evm.c
new file mode 100644
index 0000000000..bbb81dddb3
--- /dev/null
+++ b/board/ti/am64x/evm.c
@@ -0,0 +1,48 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Board specific initialization for AM642 EVM
+ *
+ * Copyright (C) 2020-2021 Texas Instruments Incorporated - https://www.ti.com/
+ * Keerthy <j-keerthy@ti.com>
+ *
+ */
+
+#include <common.h>
+#include <asm/io.h>
+#include <spl.h>
+
+DECLARE_GLOBAL_DATA_PTR;
+
+int board_init(void)
+{
+ return 0;
+}
+
+int dram_init(void)
+{
+ gd->ram_size = 0x80000000;
+
+ return 0;
+}
+
+int dram_init_banksize(void)
+{
+ /* Bank 0 declares the memory available in the DDR low region */
+ gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE;
+ gd->bd->bi_dram[0].size = 0x80000000;
+ gd->ram_size = 0x80000000;
+
+ return 0;
+}
+
+#if defined(CONFIG_SPL_LOAD_FIT)
+int board_fit_config_name_match(const char *name)
+{
+#if defined(CONFIG_TARGET_AM642_A53_EVM)
+ if (!strcmp(name, "k3-am642-evm"))
+ return 0;
+#endif
+
+ return -1;
+}
+#endif