From: Veola Nazareth Date: Sun, 21 Aug 2016 02:35:37 +0000 (-0700) Subject: ixgbe: report correct media type for KR, KX and KX4 interfaces X-Git-Tag: v4.1.12-92~2^2~148 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=27555e209315ef01708dafc14bb3555012e97a28;p=users%2Fjedix%2Flinux-maple.git ixgbe: report correct media type for KR, KX and KX4 interfaces Orabug: 24568240 ethtool reports backplane type interfaces as 1000/10000baseT link modes. This has been corrected to report the media as KR, KX or KX4 based on the backplane interface present. Signed-off-by: Veola Nazareth Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher (cherry picked from commit 27b23f96f3cf6ffd680e28bf569d8ddd71842590) Signed-off-by: Brian Maly --- diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c index 2f5da8d0ab23f..734e47fcb43da 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c @@ -193,7 +193,9 @@ static int ixgbe_get_settings(struct net_device *netdev, if (supported_link & IXGBE_LINK_SPEED_10GB_FULL) ecmd->supported |= ixgbe_get_supported_10gtypes(hw); if (supported_link & IXGBE_LINK_SPEED_1GB_FULL) - ecmd->supported |= SUPPORTED_1000baseT_Full; + ecmd->supported |= (ixgbe_isbackplane(hw->phy.media_type)) ? + SUPPORTED_1000baseKX_Full : + SUPPORTED_1000baseT_Full; if (supported_link & IXGBE_LINK_SPEED_100_FULL) ecmd->supported |= ixgbe_isbackplane(hw->phy.media_type) ? SUPPORTED_1000baseKX_Full :