projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fc20467
)
i2c: mux: pinctrl: potential NULL dereference on error
author
Dan Carpenter
<dan.carpenter@oracle.com>
Thu, 17 Aug 2017 11:53:55 +0000
(14:53 +0300)
committer
Peter Rosin
<peda@axentia.se>
Thu, 17 Aug 2017 12:19:56 +0000
(14:19 +0200)
If i2c_mux_alloc() fails then we'd have a NULL dereference here.
Fixes:
c4aee3e1b0de
("i2c: mux: pinctrl: remove platform_data")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Peter Rosin <peda@axentia.se>
drivers/i2c/muxes/i2c-mux-pinctrl.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/i2c/muxes/i2c-mux-pinctrl.c
b/drivers/i2c/muxes/i2c-mux-pinctrl.c
index 20b90a7a1e61f94197f70d4f515b425fc3955bcc..cc6818aabab515ba2b68badc030c2b6417cc6b94 100644
(file)
--- a/
drivers/i2c/muxes/i2c-mux-pinctrl.c
+++ b/
drivers/i2c/muxes/i2c-mux-pinctrl.c
@@
-173,7
+173,7
@@
static int i2c_mux_pinctrl_probe(struct platform_device *pdev)
err_del_adapter:
i2c_mux_del_adapters(muxc);
err_put_parent:
- i2c_put_adapter(
muxc->
parent);
+ i2c_put_adapter(parent);
return ret;
}