summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ice/ice_lib.c
diff options
context:
space:
mode:
authorDave Ertman2018-10-26 19:40:57 +0200
committerJeff Kirsher2018-11-06 21:46:47 +0100
commit25525b69bb44a628841492f44a5a8e74f34724f4 (patch)
tree16a637f6ad2598d3a381577a68a7bdf26a777689 /drivers/net/ethernet/intel/ice/ice_lib.c
parentice: Fix typo in error message (diff)
downloadkernel-qcow2-linux-25525b69bb44a628841492f44a5a8e74f34724f4.tar.gz
kernel-qcow2-linux-25525b69bb44a628841492f44a5a8e74f34724f4.tar.xz
kernel-qcow2-linux-25525b69bb44a628841492f44a5a8e74f34724f4.zip
ice: Fix napi delete calls for remove
In the remove path, the vsi->netdev is being set to NULL before the call to free vectors. This is causing the netif_napi_del call to never be made. Add a call to ice_napi_del to the same location as the calls to unregister_netdev and just prior to them. This will use the reverse flow as the register and netif_napi_add calls. Signed-off-by: Dave Ertman <david.m.ertman@intel.com> Signed-off-by: Anirudh Venkataramanan <anirudh.venkataramanan@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/ethernet/intel/ice/ice_lib.c')
-rw-r--r--drivers/net/ethernet/intel/ice/ice_lib.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_lib.c b/drivers/net/ethernet/intel/ice/ice_lib.c
index c604a44c8cfb..1041fa2a7767 100644
--- a/drivers/net/ethernet/intel/ice/ice_lib.c
+++ b/drivers/net/ethernet/intel/ice/ice_lib.c
@@ -2458,6 +2458,7 @@ int ice_vsi_release(struct ice_vsi *vsi)
* on this wq
*/
if (vsi->netdev && !ice_is_reset_in_progress(pf->state)) {
+ ice_napi_del(vsi);
unregister_netdev(vsi->netdev);
free_netdev(vsi->netdev);
vsi->netdev = NULL;