MIPS: MSP71xx: request_irq() failure ignored in msp_pcibios_config_access()
authorRoel Kluin <roel.kluin@gmail.com>
Fri, 18 Sep 2009 19:50:11 +0000 (12:50 -0700)
committerRalf Baechle <ralf@linux-mips.org>
Wed, 30 Sep 2009 19:47:01 +0000 (21:47 +0200)
Produce an error if request_irq() fails.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Cc: "Ithamar R. Adema" <ithamar.adema@team-embedded.nl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/pci/ops-pmcmsp.c

index 109c95ca698bb9cb3aefde8b584d4f1bfa7d834d..32548b5d68d6738ec7bf5709cf0a26f6055da3f4 100644 (file)
@@ -385,6 +385,7 @@ int msp_pcibios_config_access(unsigned char access_type,
        unsigned long intr;
        unsigned long value;
        static char pciirqflag;
+       int ret;
 #if defined(CONFIG_PMC_MSP7120_GW) || defined(CONFIG_PMC_MSP7120_EVAL)
        unsigned int    vpe_status;
 #endif
@@ -402,11 +403,13 @@ 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 */
+               ret = request_irq(MSP_INT_PCI,/* Hardcoded internal MSP7120 wiring */
                                bpci_interrupt,
                                IRQF_SHARED | IRQF_DISABLED,
                                "PMC MSP PCI Host",
                                preg);
+               if (ret != 0)
+                       return ret;
                pciirqflag = ~0;
        }