]> err.no Git - linux-2.6/commitdiff
[PATCH] PCI: Add pci_device_shutdown to pci_bus_type
authorBrian Gerst <bgerst@didntduck.org>
Sun, 19 Feb 2006 21:05:52 +0000 (16:05 -0500)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 23 Mar 2006 22:35:13 +0000 (14:35 -0800)
The extra compatability code is not necessary.  Any code still using
the old shutdown method will trigger the warning in driver_register()
instead.

Signed-off-by: Brian Gerst <bgerst@didntduck.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/pci/pci-driver.c

index 0aa14c92b5700eca800e937de7ed17e2024e83b2..eb5b50c8770c863c1c12e77dd8241ec09520885d 100644 (file)
@@ -380,14 +380,6 @@ int __pci_register_driver(struct pci_driver *drv, struct module *owner)
        /* initialize common driver fields */
        drv->driver.name = drv->name;
        drv->driver.bus = &pci_bus_type;
-       /* FIXME, once all of the existing PCI drivers have been fixed to set
-        * the pci shutdown function, this test can go away. */
-       if (!drv->driver.shutdown)
-               drv->driver.shutdown = pci_device_shutdown;
-       else
-               printk(KERN_WARNING "Warning: PCI driver %s has a struct "
-                       "device_driver shutdown method, please update!\n",
-                       drv->name);
        drv->driver.owner = owner;
        drv->driver.kobj.ktype = &pci_driver_kobj_type;
 
@@ -514,6 +506,7 @@ struct bus_type pci_bus_type = {
        .probe          = pci_device_probe,
        .remove         = pci_device_remove,
        .suspend        = pci_device_suspend,
+       .shutdown       = pci_device_shutdown,
        .resume         = pci_device_resume,
        .dev_attrs      = pci_dev_attrs,
 };