pinctrl: remove unnecessary error check
The file drivers/pinctrl/pinctrl.c is compiled only when CONFIG_PINCTRL is defined. "IS_ENABLED(CONFIG_PINCTRL)" is always evaluated as 1 in this function. (Although the compiler would optimize it, the source file does not look nice.) Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
8ed32ae81b
commit
f5cb522743
|
@ -62,9 +62,6 @@ int of_pinctrl_select_state(struct device_node *np, const char *name)
|
|||
struct device_node *np_config;
|
||||
const char *statename;
|
||||
|
||||
if (!IS_ENABLED(CONFIG_PINCTRL))
|
||||
return -ENOSYS;
|
||||
|
||||
if (!of_find_property(np, "pinctrl-0", NULL))
|
||||
return 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue