From: Hariprasad Shenai Date: Wed, 21 Oct 2015 09:09:51 +0000 (+0530) Subject: cxgb4: Don't disallow turning off auto-negotiation X-Git-Tag: MMI-PSA29.97-13-9~9125^2~87^2~6 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9bfdad5ef555d92639a8b2a9e75e1f51ea3235d6;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git cxgb4: Don't disallow turning off auto-negotiation For {1, 10, 40} Gb/s. Prohibiting turning off autonegotiation isn't anywhere in the standard. Signed-off-by: Hariprasad Shenai Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c index 1127642a2327..1487c57ffa70 100644 --- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c +++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c @@ -629,10 +629,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd) if (cmd->autoneg == AUTONEG_DISABLE) { cap = speed_to_caps(speed); - if (!(lc->supported & cap) || - (speed == 1000) || - (speed == 10000) || - (speed == 40000)) + if (!(lc->supported & cap)) return -EINVAL; lc->requested_speed = cap; lc->advertising = 0;