]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
Fix very high interrupt rate for IRQ8 (rtc) unless pnpacpi=off
authorKrzysztof Oledzki <olel@ans.pl>
Wed, 17 Oct 2007 06:31:08 +0000 (23:31 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Wed, 17 Oct 2007 15:43:04 +0000 (08:43 -0700)
Workaround for broken systems with BIOS that makes RTC interrupt level
triggered and/or active low.

See http://bugzilla.kernel.org/show_bug.cgi?id=5243

Based on the patch from Shaohua Li <shaohua.li@intel.com>

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>
Cc: "Li, Shaohua" <shaohua.li@intel.com>
Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Andi Kleen <ak@suse.de>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/pnp/pnpacpi/rsparser.c

index 0e3b8d0ff06b78a3432d9846a904e2c29a1f2e75..cd0a204d96d14e9ffdc7d19e5597f47e89fe6b8a 100644 (file)
@@ -85,6 +85,16 @@ static void pnpacpi_parse_allocated_irqresource(struct pnp_resource_table *res,
        if (i >= PNP_MAX_IRQ)
                return;
 
+#ifdef CONFIG_X86
+       if (gsi < 16 && (triggering != ACPI_EDGE_SENSITIVE ||
+                               polarity != ACPI_ACTIVE_HIGH)) {
+               pnp_warn("BIOS BUG: legacy PNP IRQ %d should be edge trigger, "
+                               "active high", gsi);
+               triggering = ACPI_EDGE_SENSITIVE;
+               polarity = ACPI_ACTIVE_HIGH;
+       }
+#endif
+
        res->irq_resource[i].flags = IORESOURCE_IRQ;    // Also clears _UNSET flag
        res->irq_resource[i].flags |= irq_flags(triggering, polarity);
        irq = acpi_register_gsi(gsi, triggering, polarity);