summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl/stm32
diff options
context:
space:
mode:
authorAlexandre TORGUE <alexandre.torgue@st.com>2016-10-20 15:26:51 +0200
committerLinus Walleij <linus.walleij@linaro.org>2016-10-31 21:25:15 +0100
commit1064a2b41579d77af16164f5dd7bc6948ba1d5be (patch)
tree1a232c1b71b3f5a0376158bae65c08522a00c2f5 /drivers/pinctrl/stm32
parentc35e7790dcbe74b0c85f4c26bbe7e15510422684 (diff)
downloadlinux-stable-1064a2b41579d77af16164f5dd7bc6948ba1d5be.tar.gz
linux-stable-1064a2b41579d77af16164f5dd7bc6948ba1d5be.tar.bz2
linux-stable-1064a2b41579d77af16164f5dd7bc6948ba1d5be.zip
pinctrl: stm32: remove dependency with interrupt controller
This patch allows to probe stm32 pinctrl driver even if no interrupt controller is defined to manage gpio irqs. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/stm32')
-rw-r--r--drivers/pinctrl/stm32/pinctrl-stm32.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/pinctrl-stm32.c
index 200667f08c37..efc43711ff5c 100644
--- a/drivers/pinctrl/stm32/pinctrl-stm32.c
+++ b/drivers/pinctrl/stm32/pinctrl-stm32.c
@@ -1092,9 +1092,11 @@ int stm32_pctl_probe(struct platform_device *pdev)
return -EINVAL;
}
- ret = stm32_pctrl_dt_setup_irq(pdev, pctl);
- if (ret)
- return ret;
+ if (of_find_property(np, "interrupt-parent", NULL)) {
+ ret = stm32_pctrl_dt_setup_irq(pdev, pctl);
+ if (ret)
+ return ret;
+ }
for_each_child_of_node(np, child)
if (of_property_read_bool(child, "gpio-controller"))