From: Rosen Penev <rosenp@gmail.com>
To: linux-samsung-soc@vger.kernel.org
Cc: Krzysztof Kozlowski <krzk@kernel.org>,
Sylwester Nawrocki <s.nawrocki@samsung.com>,
Peter Griffin <peter.griffin@linaro.org>,
Alim Akhtar <alim.akhtar@samsung.com>,
Linus Walleij <linusw@kernel.org>,
linux-arm-kernel@lists.infradead.org (moderated list:PIN
CONTROLLER - SAMSUNG),
linux-gpio@vger.kernel.org (open list:PIN CONTROL SUBSYSTEM),
linux-kernel@vger.kernel.org (open list)
Subject: [PATCH] pinctrl: samsung: exynos: replace irq_of_parse_and_map with modern APIs
Date: Mon, 27 Jul 2026 12:48:35 -0700 [thread overview]
Message-ID: <20260727194836.11689-1-rosenp@gmail.com> (raw)
Replace irq_of_parse_and_map() with fwnode_irq_get() for per-pin IRQ
lookup and of_irq_get() for the muxed EINT IRQ. The fwnode-based API
works with both OF and ACPI fwnodes and follows modern conventions.
For the muxed EINT path, change the error handling to propagate the
error code rather than silently returning 0.
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
drivers/pinctrl/samsung/pinctrl-exynos.c | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/drivers/pinctrl/samsung/pinctrl-exynos.c b/drivers/pinctrl/samsung/pinctrl-exynos.c
index 81fe0b08a9af..5bef230f5bed 100644
--- a/drivers/pinctrl/samsung/pinctrl-exynos.c
+++ b/drivers/pinctrl/samsung/pinctrl-exynos.c
@@ -824,8 +824,8 @@ __init int exynos_eint_wkup_init(struct samsung_pinctrl_drv_data *d)
return -ENOMEM;
for (idx = 0; idx < bank->nr_pins; ++idx) {
- irq = irq_of_parse_and_map(to_of_node(bank->fwnode), idx);
- if (!irq) {
+ irq = fwnode_irq_get(bank->fwnode, idx);
+ if (irq < 0) {
dev_err(dev, "irq number for eint-%s-%d not found\n",
bank->name, idx);
continue;
@@ -841,11 +841,9 @@ __init int exynos_eint_wkup_init(struct samsung_pinctrl_drv_data *d)
if (!muxed_banks)
return 0;
- irq = irq_of_parse_and_map(wkup_np, 0);
- if (!irq) {
- dev_err(dev, "irq number for muxed EINTs not found\n");
- return 0;
- }
+ irq = of_irq_get(wkup_np, 0);
+ if (irq < 0)
+ return irq;
muxed_data = devm_kzalloc(dev, sizeof(*muxed_data)
+ muxed_banks*sizeof(struct samsung_pin_bank *), GFP_KERNEL);
--
2.55.0
reply other threads:[~2026-07-27 19:48 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20260727194836.11689-1-rosenp@gmail.com \
--to=rosenp@gmail.com \
--cc=alim.akhtar@samsung.com \
--cc=krzk@kernel.org \
--cc=linusw@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=peter.griffin@linaro.org \
--cc=s.nawrocki@samsung.com \
/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