[PoC 213/241] global: Migrate CONFIG_TSEC2 to CFG

Tom Rini
2022-11-20T14:25:27Z

board/freescale/common/pixis.c | 2 +-
board/freescale/mpc8548cds/mpc8548cds.c | 2 +-
board/freescale/p1010rdb/p1010rdb.c | 2 +-
board/freescale/p1_p2_rdb_pc/p1_p2_rdb_pc.c | 2 +-
drivers/net/tsec.c | 2 +-
include/configs/MPC837XERDB.h | 6 +++---
include/configs/MPC8548CDS.h | 4 ++--
include/configs/P1010RDB.h | 4 ++--
include/configs/ls1021aiot.h | 4 ++--
include/configs/ls1021aqds.h | 4 ++--
include/configs/p1_p2_rdb_pc.h | 4 ++--
scripts/config_whitelist.txt | 4 ++--
12 files changed, 20 insertions(+), 20 deletions(-)

diff --git a/board/freescale/common/pixis.c b/board/freescale/common/pixis.c
index 37d502f7ff4b..87deb4538a22 100644
--- a/board/freescale/common/pixis.c
+++ b/board/freescale/common/pixis.c
@@ -302,7 +302,7 @@ static int pixis_set_sgmii(struct cmd_tbl *cmdtp, int flag, int argc,
switch_mask = PIXIS_VCFGEN1_TSEC1SER;
break;
#endif
-#ifdef CONFIG_TSEC2
+#ifdef CFG_TSEC2
case 2:
mask = PIXIS_VSPEED2_TSEC2SER;
switch_mask = PIXIS_VCFGEN1_TSEC2SER;
diff --git a/board/freescale/mpc8548cds/mpc8548cds.c b/board/freescale/mpc8548cds/mpc8548cds.c
index 4c10b1075e53..7ef204763eaa 100644
--- a/board/freescale/mpc8548cds/mpc8548cds.c
+++ b/board/freescale/mpc8548cds/mpc8548cds.c
@@ -212,7 +212,7 @@ int board_eth_init(struct bd_info *bis)
SET_STD_TSEC_INFO(tsec_info[num], 1);
num++;
#endif
-#ifdef CONFIG_TSEC2
+#ifdef CFG_TSEC2
SET_STD_TSEC_INFO(tsec_info[num], 2);
num++;
#endif
diff --git a/board/freescale/p1010rdb/p1010rdb.c b/board/freescale/p1010rdb/p1010rdb.c
index a527d44d6865..e7ba90a8d1a3 100644
--- a/board/freescale/p1010rdb/p1010rdb.c
+++ b/board/freescale/p1010rdb/p1010rdb.c
@@ -493,7 +493,7 @@ int board_eth_init(struct bd_info *bis)
SET_STD_TSEC_INFO(tsec_info[num], 1);
num++;
#endif
-#ifdef CONFIG_TSEC2
+#ifdef CFG_TSEC2
SET_STD_TSEC_INFO(tsec_info[num], 2);
num++;
#endif
diff --git a/board/freescale/p1_p2_rdb_pc/p1_p2_rdb_pc.c b/board/freescale/p1_p2_rdb_pc/p1_p2_rdb_pc.c
index 7d2b8ec12d9f..5dac8fcce2cb 100644
--- a/board/freescale/p1_p2_rdb_pc/p1_p2_rdb_pc.c
+++ b/board/freescale/p1_p2_rdb_pc/p1_p2_rdb_pc.c
@@ -377,7 +377,7 @@ int board_eth_init(struct bd_info *bis)
SET_STD_TSEC_INFO(tsec_info[num], 1);
num++;
#endif
-#ifdef CONFIG_TSEC2
+#ifdef CFG_TSEC2
SET_STD_TSEC_INFO(tsec_info[num], 2);
if (is_serdes_configured(SGMII_TSEC2)) {
printf("eTSEC2 is in sgmii mode.\n");
diff --git a/drivers/net/tsec.c b/drivers/net/tsec.c
index ad2c68e2a73d..7287c6ad4cbb 100644
--- a/drivers/net/tsec.c
+++ b/drivers/net/tsec.c
@@ -29,7 +29,7 @@ static struct tsec_info_struct tsec_info[] = {
#ifdef CFG_TSEC1
STD_TSEC_INFO(1), /* TSEC1 */
#endif
-#ifdef CONFIG_TSEC2
+#ifdef CFG_TSEC2
STD_TSEC_INFO(2), /* TSEC2 */
#endif
#ifdef CONFIG_MPC85XX_FEC
diff --git a/include/configs/MPC837XERDB.h b/include/configs/MPC837XERDB.h
index 82101ced5323..b9ac67fae0be 100644
--- a/include/configs/MPC837XERDB.h
+++ b/include/configs/MPC837XERDB.h
@@ -41,7 +41,7 @@

#ifdef CONFIG_VSC7385_ENET

-#define CONFIG_TSEC2
+#define CFG_TSEC2

/* The flash address and size of the VSC7385 firmware image */
#define CONFIG_VSC7385_IMAGE 0xFE7FE000
@@ -195,8 +195,8 @@
#define TSEC1_PHYIDX 0
#endif

-#ifdef CONFIG_TSEC2
-#define CONFIG_TSEC2_NAME "TSEC1"
+#ifdef CFG_TSEC2
+#define CFG_TSEC2_NAME "TSEC1"
#define TSEC2_PHY_ADDR 0x1c
#define TSEC2_FLAGS (TSEC_GIGABIT | TSEC_REDUCED)
#define TSEC2_PHYIDX 0
diff --git a/include/configs/MPC8548CDS.h b/include/configs/MPC8548CDS.h
index 53639db0b9dd..35154630add0 100644
--- a/include/configs/MPC8548CDS.h
+++ b/include/configs/MPC8548CDS.h
@@ -287,8 +287,8 @@

#define CFG_TSEC1 1
#define CFG_TSEC1_NAME "eTSEC0"
-#define CONFIG_TSEC2 1
-#define CONFIG_TSEC2_NAME "eTSEC1"
+#define CFG_TSEC2 1
+#define CFG_TSEC2_NAME "eTSEC1"
#define CONFIG_TSEC3 1
#define CONFIG_TSEC3_NAME "eTSEC2"
#define CONFIG_TSEC4
diff --git a/include/configs/P1010RDB.h b/include/configs/P1010RDB.h
index 88865aac01eb..b01b3b019662 100644
--- a/include/configs/P1010RDB.h
+++ b/include/configs/P1010RDB.h
@@ -353,8 +353,8 @@ extern unsigned long get_sdram_size(void);
#define CFG_MII_DEFAULT_TSEC 1 /* Allow unregistered phys */
#define CFG_TSEC1 1
#define CFG_TSEC1_NAME "eTSEC1"
-#define CONFIG_TSEC2 1
-#define CONFIG_TSEC2_NAME "eTSEC2"
+#define CFG_TSEC2 1
+#define CFG_TSEC2_NAME "eTSEC2"
#define CONFIG_TSEC3 1
#define CONFIG_TSEC3_NAME "eTSEC3"

diff --git a/include/configs/ls1021aiot.h b/include/configs/ls1021aiot.h
index fff4e816ecc1..f7063ca2a1a8 100644
--- a/include/configs/ls1021aiot.h
+++ b/include/configs/ls1021aiot.h
@@ -74,8 +74,8 @@
#define CFG_MII_DEFAULT_TSEC 1
#define CFG_TSEC1 1
#define CFG_TSEC1_NAME "eTSEC1"
-#define CONFIG_TSEC2 1
-#define CONFIG_TSEC2_NAME "eTSEC2"
+#define CFG_TSEC2 1
+#define CFG_TSEC2_NAME "eTSEC2"

#define TSEC1_PHY_ADDR 1
#define TSEC2_PHY_ADDR 3
diff --git a/include/configs/ls1021aqds.h b/include/configs/ls1021aqds.h
index eab8ade5c9ef..8747ef260b89 100644
--- a/include/configs/ls1021aqds.h
+++ b/include/configs/ls1021aqds.h
@@ -255,8 +255,8 @@
#define CFG_MII_DEFAULT_TSEC 3
#define CFG_TSEC1 1
#define CFG_TSEC1_NAME "eTSEC1"
-#define CONFIG_TSEC2 1
-#define CONFIG_TSEC2_NAME "eTSEC2"
+#define CFG_TSEC2 1
+#define CFG_TSEC2_NAME "eTSEC2"
#define CONFIG_TSEC3 1
#define CONFIG_TSEC3_NAME "eTSEC3"

diff --git a/include/configs/p1_p2_rdb_pc.h b/include/configs/p1_p2_rdb_pc.h
index fa446c725c88..dfb2679883a9 100644
--- a/include/configs/p1_p2_rdb_pc.h
+++ b/include/configs/p1_p2_rdb_pc.h
@@ -369,8 +369,8 @@
#if defined(CONFIG_TSEC_ENET)
#define CFG_TSEC1
#define CFG_TSEC1_NAME "eTSEC1"
-#define CONFIG_TSEC2
-#define CONFIG_TSEC2_NAME "eTSEC2"
+#define CFG_TSEC2
+#define CFG_TSEC2_NAME "eTSEC2"
#define CONFIG_TSEC3
#define CONFIG_TSEC3_NAME "eTSEC3"

diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt
index 310ac53d91a1..c4e7fdfa27fe 100644
--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -223,8 +223,8 @@ CFG_THOR_RESET_OFF
CFG_TPM_TIS_BASE_ADDRESS
CFG_TSEC1
CFG_TSEC1_NAME
-CONFIG_TSEC2
-CONFIG_TSEC2_NAME
+CFG_TSEC2
+CFG_TSEC2_NAME
CONFIG_TSEC3
CONFIG_TSEC3_NAME
CONFIG_TSEC4
--
2.25.1