USB: remove incorrect __exit markups
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Sun, 24 Feb 2013 08:55:07 +0000 (00:55 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 Mar 2013 18:45:16 +0000 (11:45 -0700)
Even if bus is not hot-pluggable, the devices can be unbound from the
driver via sysfs, so we should not be using __exit annotations on
remove() methods. The only exception is drivers registered with
platform_driver_probe() which specifically disables sysfs bind/unbind
attributes.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/ehci-mxc.c
drivers/usb/host/ehci-orion.c
drivers/usb/host/ehci-sh.c
drivers/usb/otg/isp1301_omap.c
drivers/usb/otg/twl4030-usb.c
drivers/usb/otg/twl6030-usb.c
drivers/usb/phy/mv_u3d_phy.c

index b5b7be45e3010f2bb6d3237caf400d973e150f5b..a38c8c8e5b0d9fdc6d25c61f4f79322bddfdf02d 100644 (file)
@@ -172,7 +172,7 @@ err_alloc:
        return ret;
 }
 
-static int __exit ehci_mxc_drv_remove(struct platform_device *pdev)
+static int ehci_mxc_drv_remove(struct platform_device *pdev)
 {
        struct mxc_usbh_platform_data *pdata = pdev->dev.platform_data;
        struct usb_hcd *hcd = platform_get_drvdata(pdev);
index 914a3ecfb5d361501a9a9e939d82388e34b795bc..38c45fb3357eed576e195905768d6316d16d6dce 100644 (file)
@@ -305,7 +305,7 @@ err1:
        return err;
 }
 
-static int __exit ehci_orion_drv_remove(struct platform_device *pdev)
+static int ehci_orion_drv_remove(struct platform_device *pdev)
 {
        struct usb_hcd *hcd = platform_get_drvdata(pdev);
        struct clk *clk;
@@ -333,7 +333,7 @@ MODULE_DEVICE_TABLE(of, ehci_orion_dt_ids);
 
 static struct platform_driver ehci_orion_driver = {
        .probe          = ehci_orion_drv_probe,
-       .remove         = __exit_p(ehci_orion_drv_remove),
+       .remove         = ehci_orion_drv_remove,
        .shutdown       = usb_hcd_platform_shutdown,
        .driver = {
                .name   = "orion-ehci",
index 3565a300f401347315b968b0c09131df294e317f..e30e39672027416496bcf2bd8fd2daddfa480bb0 100644 (file)
@@ -170,7 +170,7 @@ fail_create_hcd:
        return ret;
 }
 
-static int __exit ehci_hcd_sh_remove(struct platform_device *pdev)
+static int ehci_hcd_sh_remove(struct platform_device *pdev)
 {
        struct ehci_sh_priv *priv = platform_get_drvdata(pdev);
        struct usb_hcd *hcd = priv->hcd;
@@ -196,7 +196,7 @@ static void ehci_hcd_sh_shutdown(struct platform_device *pdev)
 
 static struct platform_driver ehci_hcd_sh_driver = {
        .probe          = ehci_hcd_sh_probe,
-       .remove         = __exit_p(ehci_hcd_sh_remove),
+       .remove         = ehci_hcd_sh_remove
        .shutdown       = ehci_hcd_sh_shutdown,
        .driver         = {
                .name   = "sh_ehci",
index af9cb11626b229a417b49189ff932c40f3587c13..8b9de95813197cc8edd254b7c260ed10a73c72df 100644 (file)
@@ -1212,7 +1212,7 @@ static void isp1301_release(struct device *dev)
 
 static struct isp1301 *the_transceiver;
 
-static int __exit isp1301_remove(struct i2c_client *i2c)
+static int isp1301_remove(struct i2c_client *i2c)
 {
        struct isp1301  *isp;
 
@@ -1634,7 +1634,7 @@ static struct i2c_driver isp1301_driver = {
                .name   = "isp1301_omap",
        },
        .probe          = isp1301_probe,
-       .remove         = __exit_p(isp1301_remove),
+       .remove         = isp1301_remove,
        .id_table       = isp1301_id,
 };
 
index a994715a3101978a916bea3f4d3d1e1c38d72f7d..24d573a134b1ceccbd5af25fdff74595bd8fe09c 100644 (file)
@@ -658,7 +658,7 @@ static int twl4030_usb_probe(struct platform_device *pdev)
        return 0;
 }
 
-static int __exit twl4030_usb_remove(struct platform_device *pdev)
+static int twl4030_usb_remove(struct platform_device *pdev)
 {
        struct twl4030_usb *twl = platform_get_drvdata(pdev);
        int val;
@@ -702,7 +702,7 @@ MODULE_DEVICE_TABLE(of, twl4030_usb_id_table);
 
 static struct platform_driver twl4030_usb_driver = {
        .probe          = twl4030_usb_probe,
-       .remove         = __exit_p(twl4030_usb_remove),
+       .remove         = twl4030_usb_remove,
        .driver         = {
                .name   = "twl4030_usb",
                .owner  = THIS_MODULE,
index 8cd6cf49bdbd12c987f871193e58be3f3df77853..7f3c5b0e3f66a3a24014bf56e0b8774735fc753b 100644 (file)
@@ -393,7 +393,7 @@ static int twl6030_usb_probe(struct platform_device *pdev)
        return 0;
 }
 
-static int __exit twl6030_usb_remove(struct platform_device *pdev)
+static int twl6030_usb_remove(struct platform_device *pdev)
 {
        struct twl6030_usb *twl = platform_get_drvdata(pdev);
 
@@ -420,7 +420,7 @@ MODULE_DEVICE_TABLE(of, twl6030_usb_id_table);
 
 static struct platform_driver twl6030_usb_driver = {
        .probe          = twl6030_usb_probe,
-       .remove         = __exit_p(twl6030_usb_remove),
+       .remove         = twl6030_usb_remove,
        .driver         = {
                .name   = "twl6030_usb",
                .owner  = THIS_MODULE,
index 9d8599122aa9abb424d469747fb50c28d9893dbd..bafd67f1f13491dee8c12cc2be2b8da48377d169 100644 (file)
@@ -313,7 +313,7 @@ err:
        return ret;
 }
 
-static int __exit mv_u3d_phy_remove(struct platform_device *pdev)
+static int mv_u3d_phy_remove(struct platform_device *pdev)
 {
        struct mv_u3d_phy *mv_u3d_phy = platform_get_drvdata(pdev);