Commit 58d11a39 authored by Jeff Garzik's avatar Jeff Garzik Committed by Linus Torvalds

[PATCH] remove manual driver poisoning of net_device

From: Al Viro <viro@parcelfarce.linux.theplanet.co.uk>
   
   Such poisoning can cause oopses either because the refcount is not
   zero when the poisoning occurs, or due to kernel debugging options
   being enabled.
parent e627eccb
......@@ -864,13 +864,6 @@ static void __devexit netdrv_remove_one (struct pci_dev *pdev)
pci_release_regions (pdev);
#ifndef NETDRV_NDEBUG
/* poison memory before freeing */
memset (dev, 0xBC,
sizeof (struct net_device) +
sizeof (struct netdrv_private));
#endif /* NETDRV_NDEBUG */
free_netdev (dev);
pci_set_drvdata (pdev, NULL);
......
......@@ -642,10 +642,6 @@ rtl8169_remove_one(struct pci_dev *pdev)
iounmap(tp->mmio_addr);
pci_release_regions(pdev);
// poison memory before freeing
memset(dev, 0xBC,
sizeof (struct net_device) + sizeof (struct rtl8169_private));
pci_disable_device(pdev);
free_netdev(dev);
pci_set_drvdata(pdev, NULL);
......
......@@ -703,10 +703,6 @@ SiS190_remove_one(struct pci_dev *pdev)
iounmap(tp->mmio_addr);
pci_release_regions(pdev);
// poison memory before freeing
memset(dev, 0xBC,
sizeof (struct net_device) + sizeof (struct sis190_private));
free_netdev(dev);
pci_set_drvdata(pdev, NULL);
}
......
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