i40e: Fix autoneg disabling for non-10GBaseT links
Subsystems (2)
PATCH 1/1 i40e: Fix autoneg disabling for non-10GBaseT links
Disabling autonegotiation was allowed only for 10GBaseT PHY. The condition was changed to check if link media type is BaseT.
Fixes 3ce12ee9d8f9("i40e: Fix order of checks when enabling/disabling autoneg in ethtool")
Reviewed-by Aleksandr Loktionov <[email protected]>
Reviewed-by Karen Sornek <[email protected]>
Signed-off-by Dawid Lukwinski <[email protected]>
Signed-off-by Mateusz Palczewski <[email protected]>
--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +1 -2
@@ -1253,8 +1253,7 @@ static int i40e_set_link_ksettings(struct net_device *netdev,if (ethtool_link_ksettings_test_link_mode (&safe_ks, supported, Autoneg) && - hw->phy.link_info.phy_type != -I40E_PHY_TYPE_10GBASE_T ) { + hw->phy.media_type !=I40E_MEDIA_TYPE_BASET ) {netdev_info (netdev,"Autoneg cannot be disabled on this phy\n" ); err = -EINVAL ; goto done;
Signature · 1 line
2.17.1
Nguyen
PATCH 1/1 i40e: Fix autoneg disabling for non-10GBaseT links
Quoted 5 lines · Mateusz Palczewski
Disabling autonegotiation was allowed only for 10GBaseT PHY. The condition was changed to check if link media type is BaseT.
Fixes 3ce12ee9d8f9("i40e: Fix order of checks whenenabling/disabling autoneg in ethtool")
This is missing a space after the hash
Quoted 4 lines
Reviewed-by Aleksandr Loktionov <[email protected]>Reviewed-by Karen Sornek <[email protected]>Signed-off-by Dawid Lukwinski <[email protected]>Signed-off-by Mateusz Palczewski <[email protected]>