From: Patryk Małek <[email protected]>

Setting link settings on backplane devices shouldn't be allowed.
This patch adds one more device id to the list which we check
that against.

Signed-off-by: Patryk Małek <[email protected]>
Tested-by: Andrew Bowers <[email protected]>
Signed-off-by: Jeff Kirsher <[email protected]>
---
 drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c 
b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
index 0ce68e8a45cc..d3d299ab9de3 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
@@ -859,7 +859,8 @@ static int i40e_set_link_ksettings(struct net_device 
*netdev,
        if (hw->device_id == I40E_DEV_ID_KX_B ||
            hw->device_id == I40E_DEV_ID_KX_C ||
            hw->device_id == I40E_DEV_ID_20G_KR2 ||
-           hw->device_id == I40E_DEV_ID_20G_KR2_A) {
+           hw->device_id == I40E_DEV_ID_20G_KR2_A ||
+           hw->device_id == I40E_DEV_ID_KX_X722) {
                netdev_info(netdev, "Changing settings is not supported on 
backplane.\n");
                return -EOPNOTSUPP;
        }
-- 
2.14.3

Reply via email to