projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0b354dc
)
pinctrl: use ERR_CAST instead of ERR_PTR/PTR_ERR
author
Fabian Frederick
<fabf@skynet.be>
Mon, 27 Apr 2015 16:04:05 +0000
(18:04 +0200)
committer
Linus Walleij
<linus.walleij@linaro.org>
Wed, 6 May 2015 13:34:51 +0000
(15:34 +0200)
Inspired by scripts/coccinelle/api/err_cast.cocci
Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
include/linux/pinctrl/consumer.h
patch
|
blob
|
history
diff --git
a/include/linux/pinctrl/consumer.h
b/include/linux/pinctrl/consumer.h
index
18eccef
..
d7e5d60
100644
(file)
--- a/
include/linux/pinctrl/consumer.h
+++ b/
include/linux/pinctrl/consumer.h
@@
-142,7
+142,7
@@
static inline struct pinctrl * __must_check pinctrl_get_select(
s = pinctrl_lookup_state(p, name);
if (IS_ERR(s)) {
pinctrl_put(p);
- return ERR_
PTR(PTR_ERR(s)
);
+ return ERR_
CAST(s
);
}
ret = pinctrl_select_state(p, s);