* [PATCH net-next] net: phy: remove dead code from phy_sanitize_settings
@ 2019-04-16 22:13 Heiner Kallweit
2019-04-18 23:31 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Heiner Kallweit @ 2019-04-16 22:13 UTC (permalink / raw)
To: Andrew Lunn, Florian Fainelli, David Miller; +Cc: netdev
phy_sanitize_settings() is called from phy_start_aneg() only, and only
if phydev->autoneg isn't set. Therefore the removed code does nothing.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
drivers/net/phy/phy.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
index 5938c5acf..984de9872 100644
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -214,10 +214,6 @@ static void phy_sanitize_settings(struct phy_device *phydev)
{
const struct phy_setting *setting;
- /* Sanitize settings based on PHY capabilities */
- if (linkmode_test_bit(ETHTOOL_LINK_MODE_Autoneg_BIT, phydev->supported))
- phydev->autoneg = AUTONEG_DISABLE;
-
setting = phy_find_valid(phydev->speed, phydev->duplex,
phydev->supported);
if (setting) {
--
2.21.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] net: phy: remove dead code from phy_sanitize_settings
2019-04-16 22:13 [PATCH net-next] net: phy: remove dead code from phy_sanitize_settings Heiner Kallweit
@ 2019-04-18 23:31 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2019-04-18 23:31 UTC (permalink / raw)
To: hkallweit1; +Cc: andrew, f.fainelli, netdev
From: Heiner Kallweit <hkallweit1@gmail.com>
Date: Wed, 17 Apr 2019 00:13:09 +0200
> phy_sanitize_settings() is called from phy_start_aneg() only, and only
> if phydev->autoneg isn't set. Therefore the removed code does nothing.
>
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-04-18 23:31 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-16 22:13 [PATCH net-next] net: phy: remove dead code from phy_sanitize_settings Heiner Kallweit
2019-04-18 23:31 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).