| To: | "Ithamar R. Adema" <ithamar.adema@team-embedded.nl> |
|---|---|
| Subject: | Re: [PATCH] MSP71xx: request_irq() failure ignored in msp_pcibios_config_access() |
| From: | Roel Kluin <roel.kluin@gmail.com> |
| Date: | Tue, 01 Sep 2009 22:23:28 +0200 |
| Cc: | Ralf Baechle <ralf@linux-mips.org>, linux-mips@linux-mips.org, Andrew Morton <akpm@linux-foundation.org> |
| 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:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=6gAZe4DCuHdeHhPTuE1u511ES02hQXs5ODPcmSauaFg=; b=Uq56xg4N9y+6BTt5GMNhsIhH9khZ4bTw+iDh+sO+blfAQr3L5rS0KEWtaFAUv3a0Z2 +v210lMMo/jhxjQKIEVmm36lTKUYaLbrjTMW+pQFofHPoJcfuATGxDLKv5ryU9cC0waH 4jHRbvp4P/2YmlYCXfWXe0P35HSOEEsDxRGC8= |
| Domainkey-signature: | a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=cz7QEOa8E4GiMAAfWXetEO+KdAxeSIpLQSoSquM98TAJxuSmGvZ9zgWq6eCnj/miEB fToB8rV4in5jBCumRGET7808+rmqJWvJHbVrOMC8YIGlGWQw4e1GHIIBEPej5p3IVYSg czfh9ii2UcVTfXw7xu6RRWAs2R5yZJ1CD6dIw= |
| In-reply-to: | <4A9D6E37.1030704@team-embedded.nl> |
| Original-recipient: | rfc822;linux-mips@linux-mips.org |
| References: | <4A9D68A7.9000902@gmail.com> <4A9D6E37.1030704@team-embedded.nl> |
| 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>
---
>> + return -1;
> I'd personally suggest to return the actual value returned by
> request_irq, instead of returning -EPERM..... ;)
>
> Ithamar.
The comments at the header states that it returns -1 on failure,
and so do the callers as well, but if preferred, below is as you
suggest.
Thanks,
diff --git a/arch/mips/pci/ops-pmcmsp.c b/arch/mips/pci/ops-pmcmsp.c
index 109c95c..32548b5 100644
--- a/arch/mips/pci/ops-pmcmsp.c
+++ b/arch/mips/pci/ops-pmcmsp.c
@@ -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;
}
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH] MSP71xx: request_irq() failure ignored in msp_pcibios_config_access(), Roel Kluin |
|---|---|
| Next by Date: | [PATCH] MIPS: Don't corrupt page tables on vmalloc fault., David Daney |
| Previous by Thread: | [PATCH] MSP71xx: request_irq() failure ignored in msp_pcibios_config_access(), Roel Kluin |
| Next by Thread: | [PATCH] MIPS: Don't corrupt page tables on vmalloc fault., David Daney |
| Indexes: | [Date] [Thread] [Top] [All Lists] |