projects
/
profile
/
common
/
kernel-common.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0bf7481
)
pinctrl: pinctrl-mxs: set platform driver data to NULL at errpath and at unregister
author
Devendra Naga
<devendra.aaru@gmail.com>
Sat, 9 Jun 2012 12:02:31 +0000
(17:32 +0530)
committer
Linus Walleij
<linus.walleij@linaro.org>
Tue, 12 Jun 2012 14:26:08 +0000
(16:26 +0200)
clear the platform data pointer when mxs_pinctrl_probe_dt fails,
and also before the unregistering with pinctrl subsystem.
Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinctrl-mxs.c
patch
|
blob
|
history
diff --git
a/drivers/pinctrl/pinctrl-mxs.c
b/drivers/pinctrl/pinctrl-mxs.c
index
9d46303
..
afb50ee
100644
(file)
--- a/
drivers/pinctrl/pinctrl-mxs.c
+++ b/
drivers/pinctrl/pinctrl-mxs.c
@@
-516,6
+516,7
@@
int __devinit mxs_pinctrl_probe(struct platform_device *pdev,
return 0;
err:
+ platform_set_drvdata(pdev, NULL);
iounmap(d->base);
return ret;
}
@@
-525,6
+526,7
@@
int __devexit mxs_pinctrl_remove(struct platform_device *pdev)
{
struct mxs_pinctrl_data *d = platform_get_drvdata(pdev);
+ platform_set_drvdata(pdev, NULL);
pinctrl_unregister(d->pctl);
iounmap(d->base);