summaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorSerey Kong <serey.kong@intel.com>2016-05-16 19:26:39 +0200
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2016-06-28 00:51:54 +0200
commit6536227d1dd60dcd4a4a4a32825842c1456fa78c (patch)
treee9477fa063069db28faf0a8b1df615cfb58ae2d6 /drivers/net
parenti40e: Save PCI state before suspend (diff)
downloadlinux-6536227d1dd60dcd4a4a4a32825842c1456fa78c.tar.xz
linux-6536227d1dd60dcd4a4a4a32825842c1456fa78c.zip
i40e: fix missing DA cable check
When a Direct Attach (DA) cable is used, if the i40e_set_settings function is called it would return an error. Add the DA type so the function won't fail. Change-ID: I2b802f27a5d91cfefa72fd1f852acb4d74647a8e Signed-off-by: Serey Kong <serey.kong@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/ethernet/intel/i40e/i40e_ethtool.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
index 5e8d84ff7d5f..8381dabf0524 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
@@ -663,6 +663,7 @@ static int i40e_set_settings(struct net_device *netdev,
if (hw->phy.media_type != I40E_MEDIA_TYPE_BASET &&
hw->phy.media_type != I40E_MEDIA_TYPE_FIBER &&
hw->phy.media_type != I40E_MEDIA_TYPE_BACKPLANE &&
+ hw->phy.media_type != I40E_MEDIA_TYPE_DA &&
hw->phy.link_info.link_info & I40E_AQ_LINK_UP)
return -EOPNOTSUPP;