diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2010-02-23 23:38:39 -0800 |
---|---|---|
committer | Liam Girdwood <lrg@slimlogic.co.uk> | 2010-03-03 14:49:29 +0000 |
commit | eb66d565e8eb73ab0c471fd3dac822dc663fe8ea (patch) | |
tree | 91ffe5e5ad07017f90c52ef579348ef4d050a58a /drivers/regulator/wm831x-isink.c | |
parent | 6a74857d1b75e4f58f1a09472b972058499258a4 (diff) | |
download | linux-stable-eb66d565e8eb73ab0c471fd3dac822dc663fe8ea.tar.gz linux-stable-eb66d565e8eb73ab0c471fd3dac822dc663fe8ea.tar.bz2 linux-stable-eb66d565e8eb73ab0c471fd3dac822dc663fe8ea.zip |
Regulators: wm831x-xxx - clean up driver data after removal
It is a good tone to reset driver data after unbinding the device.
Also set up drivers owner.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Diffstat (limited to 'drivers/regulator/wm831x-isink.c')
-rw-r--r-- | drivers/regulator/wm831x-isink.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/regulator/wm831x-isink.c b/drivers/regulator/wm831x-isink.c index 48857008758c..ca0f6b6c384b 100644 --- a/drivers/regulator/wm831x-isink.c +++ b/drivers/regulator/wm831x-isink.c @@ -222,6 +222,8 @@ static __devexit int wm831x_isink_remove(struct platform_device *pdev) struct wm831x_isink *isink = platform_get_drvdata(pdev); struct wm831x *wm831x = isink->wm831x; + platform_set_drvdata(pdev, NULL); + wm831x_free_irq(wm831x, platform_get_irq(pdev, 0), isink); regulator_unregister(isink->regulator); @@ -235,6 +237,7 @@ static struct platform_driver wm831x_isink_driver = { .remove = __devexit_p(wm831x_isink_remove), .driver = { .name = "wm831x-isink", + .owner = THIS_MODULE, }, }; |