[PATCH u-boot 10/12] aspeed: remove CONFIG_PHY_MAX_ADDR

Cédric Le Goater clg at kaod.org
Fri Oct 7 08:26:43 AEDT 2016


PHY_MAX_ADDR has the same value

Signed-off-by: Cédric Le Goater <clg at kaod.org>
---
 drivers/net/ftgmac100.c      | 3 ++-
 include/configs/ast-g4-phy.h | 2 --
 include/configs/ast-g5-phy.h | 1 -
 3 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ftgmac100.c b/drivers/net/ftgmac100.c
index b690e6c2330c..f82ea5f35e89 100644
--- a/drivers/net/ftgmac100.c
+++ b/drivers/net/ftgmac100.c
@@ -16,6 +16,7 @@
 #include <net.h>
 #include <asm/io.h>
 #include <linux/mii.h>
+#include <phy.h>
 
 #include <i2c.h>
 
@@ -306,7 +307,7 @@ static int ftgmac100_phy_init(struct eth_device *dev)
 	int i;
 
 	/* Check if the PHY is up to snuff... */
-	for (phy_addr = 0; phy_addr < CONFIG_PHY_MAX_ADDR; phy_addr++) {
+	for (phy_addr = 0; phy_addr < PHY_MAX_ADDR; phy_addr++) {
 
 		ftgmac100_phy_read(dev, phy_addr, MII_PHYSID1, &phy_id1);
 		ftgmac100_phy_read(dev, phy_addr, MII_PHYSID2, &phy_id2);
diff --git a/include/configs/ast-g4-phy.h b/include/configs/ast-g4-phy.h
index 66881f6cb8be..8e1ce2bfd10b 100644
--- a/include/configs/ast-g4-phy.h
+++ b/include/configs/ast-g4-phy.h
@@ -21,7 +21,5 @@
 /* Ethernet */
 #define CONFIG_HAS_ETH0
 #define CONFIG_HAS_ETH1
-#define CONFIG_PHY_MAX_ADDR		32
-
 
 #endif	/* __AST_G4_NCSI_CONFIG_H */
diff --git a/include/configs/ast-g5-phy.h b/include/configs/ast-g5-phy.h
index 469ef01e31f2..c10767467bb9 100644
--- a/include/configs/ast-g5-phy.h
+++ b/include/configs/ast-g5-phy.h
@@ -22,6 +22,5 @@
 /* Ethernet */
 #define CONFIG_HAS_ETH0
 #define CONFIG_HAS_ETH1
-#define CONFIG_PHY_MAX_ADDR		32
 
 #endif	/* __AST_G5_PHY_CONFIG_H */
-- 
2.7.4



More information about the openbmc mailing list