aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/remove.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pci/remove.c')
-rw-r--r--drivers/pci/remove.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/remove.c b/drivers/pci/remove.c
index 84954a726a94..cc875e6ed159 100644
--- a/drivers/pci/remove.c
+++ b/drivers/pci/remove.c
@@ -24,7 +24,7 @@ static void pci_stop_dev(struct pci_dev *dev)
24 if (dev->is_added) { 24 if (dev->is_added) {
25 pci_proc_detach_device(dev); 25 pci_proc_detach_device(dev);
26 pci_remove_sysfs_dev_files(dev); 26 pci_remove_sysfs_dev_files(dev);
27 device_unregister(&dev->dev); 27 device_del(&dev->dev);
28 dev->is_added = 0; 28 dev->is_added = 0;
29 } 29 }
30 30
@@ -39,7 +39,7 @@ static void pci_destroy_dev(struct pci_dev *dev)
39 up_write(&pci_bus_sem); 39 up_write(&pci_bus_sem);
40 40
41 pci_free_resources(dev); 41 pci_free_resources(dev);
42 pci_dev_put(dev); 42 put_device(&dev->dev);
43} 43}
44 44
45void pci_remove_bus(struct pci_bus *bus) 45void pci_remove_bus(struct pci_bus *bus)