]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - drivers/regulator/wm831x-ldo.c
include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit...
[net-next-2.6.git] / drivers / regulator / wm831x-ldo.c
index 61e02ac2fda334f9e17dd145cf65d938f816548e..e686cdb61b97cd8a54ab7fbecb1312a41e333595 100644 (file)
@@ -19,6 +19,7 @@
 #include <linux/i2c.h>
 #include <linux/platform_device.h>
 #include <linux/regulator/driver.h>
+#include <linux/slab.h>
 
 #include <linux/mfd/wm831x/core.h>
 #include <linux/mfd/wm831x/regulator.h>
@@ -371,6 +372,8 @@ static __devexit int wm831x_gp_ldo_remove(struct platform_device *pdev)
        struct wm831x_ldo *ldo = platform_get_drvdata(pdev);
        struct wm831x *wm831x = ldo->wm831x;
 
+       platform_set_drvdata(pdev, NULL);
+
        wm831x_free_irq(wm831x, platform_get_irq_byname(pdev, "UV"), ldo);
        regulator_unregister(ldo->regulator);
        kfree(ldo);
@@ -383,6 +386,7 @@ static struct platform_driver wm831x_gp_ldo_driver = {
        .remove = __devexit_p(wm831x_gp_ldo_remove),
        .driver         = {
                .name   = "wm831x-ldo",
+               .owner  = THIS_MODULE,
        },
 };
 
@@ -640,6 +644,7 @@ static struct platform_driver wm831x_aldo_driver = {
        .remove = __devexit_p(wm831x_aldo_remove),
        .driver         = {
                .name   = "wm831x-aldo",
+               .owner  = THIS_MODULE,
        },
 };
 
@@ -811,6 +816,7 @@ static struct platform_driver wm831x_alive_ldo_driver = {
        .remove = __devexit_p(wm831x_alive_ldo_remove),
        .driver         = {
                .name   = "wm831x-alive-ldo",
+               .owner  = THIS_MODULE,
        },
 };