This adds necessary config options to enable usb booting and
fixes board_eth_init() function to take into account that we may have
USB ether support in SPL now.
Signed-off-by: Ilya Yanok ilya.ya...@cogentembedded.com
---
board/ti/am335x/board.c | 3 ++-
include/configs/am335x_evm.h | 8
2 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c
index f0eca54..5728c9a 100644
--- a/board/ti/am335x/board.c
+++ b/board/ti/am335x/board.c
@@ -425,7 +425,8 @@ int board_eth_init(bd_t *bis)
n += rv;
#endif
try_usbether:
-#if defined(CONFIG_USB_ETHER) !defined(CONFIG_SPL_BUILD)
+#if defined(CONFIG_USB_ETHER) \
+ (!defined(CONFIG_SPL_BUILD) || defined(CONFIG_SPL_USBETH_SUPPORT))
rv = usb_eth_initialize(bis);
if (rv 0)
printf(Error %d registering USB_ETHER\n, rv);
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
index ab9549b..2da863d 100644
--- a/include/configs/am335x_evm.h
+++ b/include/configs/am335x_evm.h
@@ -238,6 +238,8 @@
#define CONFIG_SPL_SPI_CS 0
#define CONFIG_SYS_SPI_U_BOOT_OFFS 0x2
#define CONFIG_SYS_SPI_U_BOOT_SIZE 0x4
+#define CONFIG_SPL_MUSB_NEW_SUPPORT
+#define CONFIG_SPL_USBETH_SUPPORT
#define CONFIG_SPL_LDSCRIPT$(CPUDIR)/omap-common/u-boot-spl.lds
/*
@@ -279,6 +281,8 @@
#ifdef CONFIG_MUSB_GADGET
#define CONFIG_USB_ETHER
#define CONFIG_USB_ETH_RNDIS
+#define CONFIG_USBNET_HOST_ADDRde:ad:be:af:00:00
+#define CONFIG_USBNET_DEV_ADDR de:ad:be:af:00:01
#endif /* CONFIG_MUSB_GADGET */
/* Unsupported features */
@@ -301,4 +305,8 @@
#define CONFIG_PHYLIB
#define CONFIG_PHY_SMSC
+#ifdef CONFIG_SPL_BUILD
+/* disable host part of MUSB in SPL */
+#undef CONFIG_MUSB_HOST
+#endif
#endif /* ! __CONFIG_AM335X_EVM_H */
--
1.8.0.2
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot