From: Narasimharao Vadlamudi <ahmisaranrao@gmail.com>
To: kuninori.morimoto.gx@renesas.com, broonie@kernel.org
Cc: linux-sound@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
linux-kernel@vger.kernel.org,
Narasimharao Vadlamudi <ahmisaranrao@gmail.com>
Subject: [PATCH] ASoC: renesas: fsi: Propagate platform_get_irq() errors
Date: Mon, 29 Jun 2026 15:23:26 +0530 [thread overview]
Message-ID: <20260629095326.37302-1-ahmisaranrao@gmail.com> (raw)
platform_get_irq() returns a negative error code on failure. The
driver currently stores the return value in an unsigned int and returns
-ENODEV for all failures, which loses useful errors such as
-EPROBE_DEFER.
Store the IRQ in an int and return the error from platform_get_irq()
directly.
Signed-off-by: Narasimharao Vadlamudi <ahmisaranrao@gmail.com>
---
sound/soc/renesas/fsi.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/sound/soc/renesas/fsi.c b/sound/soc/renesas/fsi.c
index ae86014c3819..6be6587e1095 100644
--- a/sound/soc/renesas/fsi.c
+++ b/sound/soc/renesas/fsi.c
@@ -1992,7 +1992,7 @@ static int fsi_probe(struct platform_device *pdev)
const struct fsi_core *core;
struct fsi_priv *fsi;
struct resource *res;
- unsigned int irq;
+ int irq;
int ret;
memset(&info, 0, sizeof(info));
@@ -2007,12 +2007,15 @@ static int fsi_probe(struct platform_device *pdev)
}
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- irq = platform_get_irq(pdev, 0);
- if (!res || (int)irq <= 0) {
+ if (!res) {
dev_err(&pdev->dev, "Not enough FSI platform resources.\n");
return -ENODEV;
}
+ irq = platform_get_irq(pdev, 0);
+ if (irq < 0)
+ return irq;
+
master = devm_kzalloc(&pdev->dev, sizeof(*master), GFP_KERNEL);
if (!master)
return -ENOMEM;
--
2.43.0
next reply other threads:[~2026-06-29 9:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-29 9:53 Narasimharao Vadlamudi [this message]
2026-06-29 23:33 ` Kuninori Morimoto
2026-06-30 15:44 ` Geert Uytterhoeven
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=20260629095326.37302-1-ahmisaranrao@gmail.com \
--to=ahmisaranrao@gmail.com \
--cc=broonie@kernel.org \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=linux-sound@vger.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
Powered by JetHome