Skip to content

Commit

Permalink
ntb_netdev: remove from list on exit
Browse files Browse the repository at this point in the history
The ntb_netdev device is not removed from the global list of devices
upon device removal.  If the device is re-added, the removal code would
find the first instance and try to remove an already removed device.

Signed-off-by: Jon Mason <jon.mason@intel.com>
  • Loading branch information
Jon Mason committed May 15, 2013
1 parent c336acd commit 904435c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/ntb_netdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -375,6 +375,8 @@ static void ntb_netdev_remove(struct pci_dev *pdev)
if (dev == NULL)
return;

list_del(&dev->list);

ndev = dev->ndev;

unregister_netdev(ndev);
Expand Down

0 comments on commit 904435c

Please sign in to comment.