[U-Boot] [PATCH v3 8/8] am335x_evm: enable networking in SPL
Ilya Yanok
ilya.yanok at cogentembedded.com
Wed Jul 25 00:22:23 CEST 2012
This patch adds support for networking in SPL on TI AM335x based
boards. Vendor Class Identifier used by SPL during BOOTP is
"AM335x U-Boot SPL".
Signed-off-by: Ilya Yanok <ilya.yanok at cogentembedded.com>
---
Changes in v3:
- set Vendor Class Identifier for SPL
board/ti/am335x/evm.c | 12 ++++++++++++
include/configs/am335x_evm.h | 6 +++++-
2 files changed, 17 insertions(+), 1 deletion(-)
diff --git a/board/ti/am335x/evm.c b/board/ti/am335x/evm.c
index b7eee80..597fced 100644
--- a/board/ti/am335x/evm.c
+++ b/board/ti/am335x/evm.c
@@ -120,6 +120,18 @@ int board_init(void)
return 0;
}
+#ifdef CONFIG_SPL_BUILD
+int spl_board_init(void)
+{
+ enable_i2c0_pin_mux();
+ i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);
+ if (read_eeprom() < 0)
+ printf("Could not get board ID.\n");
+
+ return 0;
+}
+#endif
+
#ifdef CONFIG_DRIVER_TI_CPSW
static void cpsw_control(int enabled)
{
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
index 2a3251b..22eefa4 100644
--- a/include/configs/am335x_evm.h
+++ b/include/configs/am335x_evm.h
@@ -128,8 +128,9 @@
/* Defines for SPL */
#define CONFIG_SPL
+#define CONFIG_SPL_BOARD_INIT
#define CONFIG_SPL_TEXT_BASE 0x402F0400
-#define CONFIG_SPL_MAX_SIZE (46 * 1024)
+#define CONFIG_SPL_MAX_SIZE (101 * 1024)
#define CONFIG_SPL_STACK LOW_LEVEL_SRAM_STACK
#define CONFIG_SPL_BSS_START_ADDR 0x80000000
@@ -148,6 +149,9 @@
#define CONFIG_SPL_LIBGENERIC_SUPPORT
#define CONFIG_SPL_SERIAL_SUPPORT
#define CONFIG_SPL_YMODEM_SUPPORT
+#define CONFIG_SPL_NET_SUPPORT
+#define CONFIG_SPL_NET_VCI_STRING "AM335x U-Boot SPL"
+#define CONFIG_SPL_ETH_SUPPORT
#define CONFIG_SPL_LDSCRIPT "$(CPUDIR)/omap-common/u-boot-spl.lds"
/*
--
1.7.9.5
More information about the U-Boot
mailing list