Skip to contentSkip to conversation

Convert CONFIG_SMC911X et al to Kconfig

PATCH In review Adam Ford 2 participants 2 messages Oct 16, 2017 – Oct 21, 2017

lore
Share & tools
lore

Adam Ford

author
#0 lore raw

PATCH 1/1 Convert CONFIG_SMC911X et al to Kconfig

This converts the following to Kconfig:
CONFIG_SMC911X
CONFIG_SMC911X_BASE
CONFIG_SMC911X_32_BIT

There are a variety of boards that need some cleanup in their respective include/configs file, but here is a foundation for them to begin their transisiton.

V2: Merge into 1 patch and rebase

---
 configs/cm_t3517_defconfig       | 4 ++++
 configs/cm_t35_defconfig         | 4 ++++
 configs/duovero_defconfig        | 4 ++++
 configs/igep0032_defconfig       | 4 ++++
 configs/igep00x0_defconfig       | 4 ++++
 configs/omap3_evm_defconfig      | 4 ++++
 configs/omap3_logic_defconfig    | 4 ++++
 configs/omap3_overo_defconfig    | 4 ++++
 configs/omap3_zoom1_defconfig    | 3 +++
 configs/twister_defconfig        | 3 +++
 include/configs/cm_t35.h         | 3 +--
 include/configs/cm_t3517.h       | 3 ---
 include/configs/duovero.h        | 4 ----
 include/configs/omap3_evm.h      | 7 -------
 include/configs/omap3_igep00x0.h | 9 ---------
 include/configs/omap3_logic.h    | 7 -------
 include/configs/omap3_zoom1.h    | 4 ----
 include/configs/twister.h        | 4 +---
 18 files changed, 40 insertions(+), 39 deletions(-)
configs/cm_t3517_defconfig +4 -0
index 8e7c072..3ed0b37 100644
@@ -38,6 +38,10 @@ CONFIG_LED_STATUS_BOOT_ENABLE=y
 CONFIG_LED_STATUS_BOOT=0
 CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C100000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_USB=y
configs/cm_t35_defconfig +4 -0
index 1515c92..bf11722 100644
@@ -40,6 +40,10 @@ CONFIG_LED_STATUS_BOOT=0
 CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
 CONFIG_SPL_NAND_SIMPLE=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_USB=y
configs/duovero_defconfig +4 -0
index feec2cf..b76da3e 100644
@@ -23,6 +23,10 @@ CONFIG_CMD_EXT4_WRITE=y
 # CONFIG_SPL_EFI_PARTITION is not set
 CONFIG_SPL_PARTITION_UUIDS=y
 CONFIG_MMC_OMAP_HS=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_USB=y
configs/igep0032_defconfig +4 -0
index 3138e96..0ea9e92 100644
@@ -31,6 +31,10 @@ CONFIG_NET_RANDOM_ETHADDR=y
 CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
 CONFIG_SPL_NAND_SIMPLE=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_FAT_WRITE=y
configs/igep00x0_defconfig +4 -0
index 4f13b14..3294194 100644
@@ -32,6 +32,10 @@ CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
 CONFIG_SPL_NAND_SIMPLE=y
 CONFIG_MTD_UBI_FASTMAP=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_FAT_WRITE=y
configs/omap3_evm_defconfig +4 -0
index 14348ee..7173b5d 100644
@@ -43,6 +43,10 @@ CONFIG_MMC_OMAP_HS=y
 CONFIG_MTD=y
 CONFIG_NAND=y
 CONFIG_SPL_NAND_SIMPLE=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_DM_SERIAL=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
configs/omap3_logic_defconfig +4 -0
index aacd24a..3352933 100644
@@ -36,6 +36,10 @@ CONFIG_NAND=y
 CONFIG_SYS_NAND_U_BOOT_LOCATIONS=y
 CONFIG_SYS_NAND_U_BOOT_OFFS=0x80000
 CONFIG_SPL_NAND_SIMPLE=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x08000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_USB=y
configs/omap3_overo_defconfig +4 -0
index 6f94fe6..ea01cd1 100644
@@ -42,6 +42,10 @@ CONFIG_ENV_IS_IN_NAND=y
 CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
 CONFIG_SPL_NAND_SIMPLE=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_USB=y
configs/omap3_zoom1_defconfig +3 -0
index e50de33..b1a8b5e 100644
@@ -32,6 +32,9 @@ CONFIG_EFI_PARTITION=y
 CONFIG_ENV_IS_IN_NAND=y
 CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_32_BIT=y
 CONFIG_SYS_NS16550=y
 CONFIG_OMAP3_SPI=y
 CONFIG_FAT_WRITE=y
configs/twister_defconfig +3 -0
index 98fc376..0eefddd 100644
@@ -33,6 +33,9 @@ CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
 CONFIG_NAND_OMAP_GPMC_PREFETCH=y
 CONFIG_SPL_NAND_SIMPLE=y
+CONFIG_NETDEVICES=y
+CONFIG_SMC911X=y
+CONFIG_SMC911X_BASE=0x2C000000
 CONFIG_SYS_NS16550=y
 CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
include/configs/cm_t35.h +1 -2
index 985237c..4e1cc9f 100644
@@ -208,8 +208,7 @@
 #define CONFIG_ENV_ADDR			0x260000
 
 #if defined(CONFIG_CMD_NET)
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
+
 #define CM_T3X_SMC911X_BASE	0x2C000000
 #define SB_T35_SMC911X_BASE	(CM_T3X_SMC911X_BASE + (16 << 20))
 #define CONFIG_SMC911X_BASE	CM_T3X_SMC911X_BASE
include/configs/cm_t3517.h +0 -3
index 4a31944..fbb1135 100644
@@ -213,9 +213,6 @@
 #define CONFIG_DRIVER_TI_EMAC
 #define CONFIG_DRIVER_TI_EMAC_USE_RMII
 #define CONFIG_MII
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
-#define CONFIG_SMC911X_BASE	(0x2C000000 + (16 << 20))
 #define CONFIG_ARP_TIMEOUT		200UL
 #define CONFIG_NET_RETRY_COUNT		5
 #endif /* CONFIG_CMD_NET */
include/configs/duovero.h +0 -4
index c4496a7..96644b1 100644
@@ -30,10 +30,6 @@
 
 #define CONFIG_SYS_ENABLE_PADS_ALL
 
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
-#define CONFIG_SMC911X_BASE		0x2C000000
-
 /* GPIO */
 
 /* ENV related config options */
include/configs/omap3_evm.h +0 -7
index f12e26c..7354558 100644
@@ -84,13 +84,6 @@
 /* USB EHCI */
 #define CONFIG_SYS_USB_FAT_BOOT_PARTITION  1
 
-/* SMSC911x Ethernet */
-#if defined(CONFIG_CMD_NET)
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
-#define CONFIG_SMC911X_BASE             0x2C000000
-#endif /* CONFIG_CMD_NET */
-
 /* Environment */
 #define CONFIG_PREBOOT                  "usb start"
 
include/configs/omap3_igep00x0.h +0 -9
index aa7188b..51f2e22 100644
@@ -101,15 +101,6 @@
 
 #endif
 
-/*
- * SMSC911x Ethernet
- */
-#if defined(CONFIG_CMD_NET)
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
-#define CONFIG_SMC911X_BASE		0x2C000000
-#endif /* (CONFIG_CMD_NET) */
-
 #define CONFIG_MTD_PARTITIONS
 #define CONFIG_SYS_MTDPARTS_RUNTIME
 
include/configs/omap3_logic.h +0 -7
index 1e3de43..1bb6878 100644
@@ -237,13 +237,6 @@
 #define CONFIG_ENV_OFFSET		0x260000
 #define CONFIG_ENV_ADDR			0x260000
 
-/* SMSC922x Ethernet */
-#if defined(CONFIG_CMD_NET)
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
-#define CONFIG_SMC911X_BASE	0x08000000
-#endif /* (CONFIG_CMD_NET) */
-
 /* Defines for SPL */
 
 /* NAND: SPL falcon mode configs */
include/configs/omap3_zoom1.h +0 -4
index cbbe7d4..53923f1 100644
@@ -155,11 +155,7 @@
 #define CONFIG_ENV_ADDR			0x260000
 
 #ifdef CONFIG_CMD_NET
-/* Ethernet (LAN9211 from SMSC9118 family) */
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_32_BIT
 #define CONFIG_SMC911X_BASE		DEBUG_BASE
-
 #endif
 
 #endif				/* __CONFIG_H */
include/configs/twister.h +1 -3
index bec402e..777504b 100644
@@ -27,9 +27,7 @@
 /*
  * Miscellaneous configurable options
  */
-#define CONFIG_SMC911X
-#define CONFIG_SMC911X_16_BIT
-#define CONFIG_SMC911X_BASE		0x2C000000
+
 #define CONFIG_SMC911X_NO_EEPROM
 
 #define	CONFIG_EXTRA_ENV_SETTINGS	CONFIG_TAM3517_SETTINGS \
Signature · 1 line
2.7.4
#1 lore raw
Quoted 11 lines · Adam Ford

This converts the following to Kconfig:

   CONFIG_SMC911X
   CONFIG_SMC911X_BASE
   CONFIG_SMC911X_32_BIT

There are a variety of boards that need some cleanup in their respective include/configs file, but here is a foundation for them to begin their transisiton.

V2: Merge into 1 patch and rebase

Note that this was missing the drivers/net/Kconfig part, so I grabbed that again and really merged it in. I've also migrated all users and that meant migrating CONFIG_SMC911X_16_BIT, and it's now applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171020/875cf0ec/attachment.sig>