Skip to contentSkip to conversation

omap mailbox: platform_get_irq() error ignored

PATCH In review Hiroshi DOYU 2 participants 3 messages Jun 15, 2009 – Jun 17, 2009

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 omap mailbox: platform_get_irq() error ignored

From: ext Roel Kluin <[email protected]>

platform_get_irq may return -ENXIO. but struct omap_mbox mbox_dsp_info.irq is unsigned, so the error was not noticed.

---
 arch/arm/mach-omap2/mailbox.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
arch/arm/mach-omap2/mailbox.c +3 -3
index fd5b8a5..6f71f37 100644
@@ -282,12 +282,12 @@ static int __devinit omap2_mbox_probe(struct platform_device *pdev)
 		return -ENOMEM;
 
 	/* DSP or IVA2 IRQ */
-	mbox_dsp_info.irq = platform_get_irq(pdev, 0);
-	if (mbox_dsp_info.irq < 0) {
+	ret = platform_get_irq(pdev, 0);
+	if (ret < 0) {
 		dev_err(&pdev->dev, "invalid irq resource\n");
-		ret = -ENODEV;
 		goto err_dsp;
 	}
+	mbox_dsp_info.irq = ret;
 
 	ret = omap_mbox_register(&pdev->dev, &mbox_dsp_info);
 	if (ret)
Signature · 1 line
1.6.0.4
#1 lore raw

From: "Doyu Hiroshi (Nokia-D/Helsinki)" <[email protected]>
Subject: [PATCH 1/1] omap mailbox: platform_get_irq() error ignored
Date: Mon, 15 Jun 2009 11:25:33 +0200

Quoted 1 line

From: ext Roel Kluin <[email protected]>

Messed up with our mail server...use the following line instead...

From: Roel Kluin <[email protected]>

Quoted 37 lines

platform_get_irq may return -ENXIO. but struct omap_mbox mbox_dsp_info.irq is unsigned, so the error was not noticed.

---
 arch/arm/mach-omap2/mailbox.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
arch/arm/mach-omap2/mailbox.c +3 -3
index fd5b8a5..6f71f37 100644
@@ -282,12 +282,12 @@ static int __devinit omap2_mbox_probe(struct platform_device *pdev)
 		return -ENOMEM;
 
 	/* DSP or IVA2 IRQ */
-	mbox_dsp_info.irq = platform_get_irq(pdev, 0);
-	if (mbox_dsp_info.irq < 0) {
+	ret = platform_get_irq(pdev, 0);
+	if (ret < 0) {
 		dev_err(&pdev->dev, "invalid irq resource\n");
-		ret = -ENODEV;
 		goto err_dsp;
 	}
+	mbox_dsp_info.irq = ret;
 
 	ret = omap_mbox_register(&pdev->dev, &mbox_dsp_info);
 	if (ret)
Signature · 6 lines
1.6.0.4

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
maintainer
#2 lore raw

PATCH 1/1 omap mailbox: platform_get_irq() error ignored

In reply to Hiroshi DOYU

This patch has been applied to the linux-omap
by youw fwiendly patch wobot.

Branch in linux-omap: omap-fixes

Initial commit ID (Likely to change): 20514e5b5c3e86d58fb1825c8f89e18c3bcc61a7

PatchWorks
http://patchwork.kernel.org/patch/30287/

Git (Likely to change, and takes a while to get mirrored)
http://git.kernel.org/?p=linux/kernel/git/tmlind/linux-omap-2.6.git;a=commit;h=20514e5b5c3e86d58fb1825c8f89e18c3bcc61a7