aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/phy
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2022-03-18 08:38:26 -0400
committerTom Rini <trini@konsulko.com>2022-03-25 12:01:15 +0000
commit16199a8b961fab60587011e9da5a592b94d3eaf4 (patch)
treee05a720eb15bd9af882725de6dea0ee4bb937d28 /drivers/net/phy
parent0b956e3987bf856add12023e1835bfa9662d13ee (diff)
downloadu-boot-16199a8b961fab60587011e9da5a592b94d3eaf4.zip
u-boot-16199a8b961fab60587011e9da5a592b94d3eaf4.tar.gz
u-boot-16199a8b961fab60587011e9da5a592b94d3eaf4.tar.bz2
Convert CONFIG_PHY_RESET_DELAY to Kconfig
This converts the following to Kconfig: CONFIG_PHY_RESET_DELAY Cc: Ramon Fried <rfried.dev@gmail.com> Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'drivers/net/phy')
-rw-r--r--drivers/net/phy/Kconfig8
-rw-r--r--drivers/net/phy/phy.c2
2 files changed, 9 insertions, 1 deletions
diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
index 74339a2..eed6eb1 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
@@ -330,3 +330,11 @@ config PHY_NCSI
depends on DM_ETH
endif #PHYLIB
+
+config PHY_RESET_DELAY
+ int "Extra delay after reset before MII register access"
+ default 0
+ help
+ Some PHYs need extra delay after reset before any MII register access
+ is possible. For such PHY, set this option to the usec delay
+ required.
diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
index fffa10f..92fff5b 100644
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -872,7 +872,7 @@ int phy_reset(struct phy_device *phydev)
return -1;
}
-#ifdef CONFIG_PHY_RESET_DELAY
+#if CONFIG_PHY_RESET_DELAY > 0
udelay(CONFIG_PHY_RESET_DELAY); /* Intel LXT971A needs this */
#endif
/*