mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-20 06:08:08 +00:00
b4cee3b63f
Deleted (upstreamed): bcm53xx/patches-5.10/181-Revert-USB-bcma-Add-a-check-for-devm_gpiod_get.patch Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
41 lines
1.1 KiB
Diff
41 lines
1.1 KiB
Diff
--- a/drivers/net/phy/phylink.c
|
|
+++ b/drivers/net/phy/phylink.c
|
|
@@ -1425,6 +1425,11 @@ int phylink_ethtool_ksettings_set(struct
|
|
* the presence of a PHY, this should not be changed as that
|
|
* should be determined from the media side advertisement.
|
|
*/
|
|
+ if (pl->phydev->drv->get_port && pl->phydev->drv->set_port) {
|
|
+ if(pl->phydev->drv->get_port(pl->phydev) != kset->base.port) {
|
|
+ pl->phydev->drv->set_port(pl->phydev, kset->base.port);
|
|
+ }
|
|
+ }
|
|
return phy_ethtool_ksettings_set(pl->phydev, kset);
|
|
}
|
|
|
|
@@ -1726,8 +1731,11 @@ int phylink_ethtool_get_eee(struct phyli
|
|
|
|
ASSERT_RTNL();
|
|
|
|
- if (pl->phydev)
|
|
+ if (pl->phydev) {
|
|
+ if (pl->phydev->drv->get_eee)
|
|
+ return pl->phydev->drv->get_eee(pl->phydev, eee);
|
|
ret = phy_ethtool_get_eee(pl->phydev, eee);
|
|
+ }
|
|
|
|
return ret;
|
|
}
|
|
@@ -1744,8 +1752,11 @@ int phylink_ethtool_set_eee(struct phyli
|
|
|
|
ASSERT_RTNL();
|
|
|
|
- if (pl->phydev)
|
|
+ if (pl->phydev) {
|
|
+ if (pl->phydev->drv->set_eee)
|
|
+ return pl->phydev->drv->set_eee(pl->phydev, eee);
|
|
ret = phy_ethtool_set_eee(pl->phydev, eee);
|
|
+ }
|
|
|
|
return ret;
|
|
}
|