projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
694d0d0
)
iio: pressure: bmp280: fix wrong pointer passed to PTR_ERR()
author
Wei Yongjun
<
[email protected]
>
Thu, 14 Jul 2016 11:06:11 +0000
(11:06 +0000)
committer
Jonathan Cameron
<
[email protected]
>
Mon, 15 Aug 2016 14:38:59 +0000
(15:38 +0100)
PTR_ERR should access the value just tested by IS_ERR, otherwise
the wrong error code will be returned.
Signed-off-by: Wei Yongjun <
[email protected]
>
Reviewed-by: Linus Walleij <
[email protected]
>
Signed-off-by: Jonathan Cameron <
[email protected]
>
drivers/iio/pressure/bmp280-core.c
patch
|
blob
|
history
diff --git
a/drivers/iio/pressure/bmp280-core.c
b/drivers/iio/pressure/bmp280-core.c
index 6943688e66dfbebc5edae2959f4f43e558786c0a..94e27b2600f347b8cf6136e5157c91a24a93143a 100644
(file)
--- a/
drivers/iio/pressure/bmp280-core.c
+++ b/
drivers/iio/pressure/bmp280-core.c
@@
-970,7
+970,7
@@
int bmp280_common_probe(struct device *dev,
data->vdda = devm_regulator_get(dev, "vdda");
if (IS_ERR(data->vdda)) {
dev_err(dev, "failed to get VDDA regulator\n");
- ret = PTR_ERR(data->vdd
d
);
+ ret = PTR_ERR(data->vdd
a
);
goto out_disable_vddd;
}
ret = regulator_enable(data->vdda);