linux-mips
[Top] [All Lists]

[PATCH] MSP71xx: request_irq() failure ignored in msp_pcibios_config_acc

To: Ralf Baechle <ralf@linux-mips.org>, linux-mips@linux-mips.org, Andrew Morton <akpm@linux-foundation.org>
Subject: [PATCH] MSP71xx: request_irq() failure ignored in msp_pcibios_config_access()
From: Roel Kluin <roel.kluin@gmail.com>
Date: Tue, 01 Sep 2009 20:32:07 +0200
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:subject:content-type :content-transfer-encoding; bh=TLtbBscmrNt5Kj+Q8MTHiMcYuBMg3m84JPERBIhSPxY=; b=k6bAl9QZoRKK4y3Kc9qOe1AvXgldSgxXhXN25Q/iU4hj5bmTRqR3TGFoobtsMsATrr GHg5OYWRyCU0QdXyOtHY/kUwcaS454roqzZwU5UU1CFWxRk2DBJFbIlMtOoQ+1bp1MxQ A3splH1HYbOB5a1FnsQHJ1GtzLnm+3OqERVFE=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject :content-type:content-transfer-encoding; b=GUG2Zt/dE1Rqcer8s79fS016eIYjYDHSuU4om5v4JYDu39tKMhtvffPhY0S9nHFPoq 5nzFH0vkZ0Gy4hEtnWN5zkdo1CRRFHQPRYXM06LwWTq2ekwf/m35hWmQYzS/kP35VUyR nqlRyUKlvaMMwejnHaI84LRGWpGgnOOQnfkj8=
Original-recipient: rfc822;linux-mips@linux-mips.org
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.1) Gecko/20090814 Fedora/3.0-2.6.b3.fc11 Thunderbird/3.0b3
Produce an error if request_irq() fails.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
diff --git a/arch/mips/pci/ops-pmcmsp.c b/arch/mips/pci/ops-pmcmsp.c
index 109c95c..223d822 100644
--- a/arch/mips/pci/ops-pmcmsp.c
+++ b/arch/mips/pci/ops-pmcmsp.c
@@ -402,11 +402,12 @@ int msp_pcibios_config_access(unsigned char access_type,
         * allocation assigns an interrupt handler to the interrupt.
         */
        if (pciirqflag == 0) {
-               request_irq(MSP_INT_PCI,/* Hardcoded internal MSP7120 wiring */
+               if ((request_irq(MSP_INT_PCI,/* Hardcoded internal MSP7120 
wiring */
                                bpci_interrupt,
                                IRQF_SHARED | IRQF_DISABLED,
                                "PMC MSP PCI Host",
-                               preg);
+                               preg)) != 0)
+                       return -1;
                pciirqflag = ~0;
        }
 

<Prev in Thread] Current Thread [Next in Thread>