Commit 77e9b2ab authored by Andrew Lunn's avatar Andrew Lunn Committed by David S. Miller

net: ethtool: self_test: Mark interface in testing operative status

When an interface is executing a self test, put the interface into
operative status testing.
Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent db30a577
......@@ -1746,7 +1746,9 @@ static int ethtool_self_test(struct net_device *dev, char __user *useraddr)
if (!data)
return -ENOMEM;
netif_testing_on(dev);
ops->self_test(dev, &test, data);
netif_testing_off(dev);
ret = -EFAULT;
if (copy_to_user(useraddr, &test, sizeof(test)))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment