summaryrefslogtreecommitdiff
path: root/drivers/net/hyperv
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/hyperv')
-rw-r--r--drivers/net/hyperv/netvsc_drv.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
index 81c5c70b616a..4a25886e2346 100644
--- a/drivers/net/hyperv/netvsc_drv.c
+++ b/drivers/net/hyperv/netvsc_drv.c
@@ -2619,7 +2619,6 @@ static int netvsc_resume(struct hv_device *dev)
struct net_device *net = hv_get_drvdata(dev);
struct net_device_context *net_device_ctx;
struct netvsc_device_info *device_info;
- struct net_device *vf_netdev;
int ret;
rtnl_lock();
@@ -2632,15 +2631,6 @@ static int netvsc_resume(struct hv_device *dev)
netvsc_devinfo_put(device_info);
net_device_ctx->saved_netvsc_dev_info = NULL;
- /* A NIC driver (e.g. mlx5) may keep the VF network interface across
- * hibernation, but here the data path is implicitly switched to the
- * netvsc NIC since the vmbus channel is closed and re-opened, so
- * netvsc_vf_changed() must be used to switch the data path to the VF.
- */
- vf_netdev = rtnl_dereference(net_device_ctx->vf_netdev);
- if (vf_netdev && netvsc_vf_changed(vf_netdev) != NOTIFY_OK)
- ret = -EINVAL;
-
rtnl_unlock();
return ret;
@@ -2701,6 +2691,7 @@ static int netvsc_netdev_event(struct notifier_block *this,
return netvsc_unregister_vf(event_dev);
case NETDEV_UP:
case NETDEV_DOWN:
+ case NETDEV_CHANGE:
return netvsc_vf_changed(event_dev);
default:
return NOTIFY_DONE;