From: Alexandre TORGUE <alexandre.torgue@st.com>
To: Linus Walleij <linus.walleij@linaro.org>,
Maxime Coquelin <mcoquelin.stm32@gmail.com>,
Patrice Chotard <patrice.chotard@st.com>,
Paul Gortmaker <paul.gortmaker@windriver.com>,
Rob Herring <robh+dt@kernel.org>
Cc: <linux-kernel@vger.kernel.org>, <linux-gpio@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<devicetree@vger.kernel.org>
Subject: [PATCH 1/2] pinctrl: stm32: remove dependency with interrupt controller
Date: Thu, 20 Oct 2016 15:26:51 +0200 [thread overview]
Message-ID: <1476970012-7838-2-git-send-email-alexandre.torgue@st.com> (raw)
In-Reply-To: <1476970012-7838-1-git-send-email-alexandre.torgue@st.com>
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>
diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/pinctrl-stm32.c
index 200667f..efc4371 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"))
--
1.9.1
next prev parent reply other threads:[~2016-10-20 13:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-20 13:26 [PATCH 0/2] STM32 pinctrl: remove dependency between pinctrl driver and device tree Alexandre TORGUE
2016-10-20 13:26 ` Alexandre TORGUE [this message]
2016-10-23 23:55 ` [PATCH 1/2] pinctrl: stm32: remove dependency with interrupt controller Linus Walleij
2016-10-20 13:26 ` [PATCH 2/2] pinctrl: stm32: move gpio irqs binding to optional Alexandre TORGUE
2016-10-23 23:56 ` Linus Walleij
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1476970012-7838-2-git-send-email-alexandre.torgue@st.com \
--to=alexandre.torgue@st.com \
--cc=devicetree@vger.kernel.org \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mcoquelin.stm32@gmail.com \
--cc=patrice.chotard@st.com \
--cc=paul.gortmaker@windriver.com \
--cc=robh+dt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®