Bug 1219 - pci=noacpi ineffective
Summary: pci=noacpi ineffective
Status: CLOSED CODE_FIX
Alias: None
Product: ACPI
Classification: Unclassified
Component: Config-Interrupts (show other bugs)
Hardware: i386 Linux
: P2 normal
Assignee: Len Brown
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-12 07:46 UTC by Len Brown
Modified: 2004-03-04 11:54 UTC (History)
2 users (show)

See Also:
Kernel Version: 2.4.22
Subsystem:
Regression: ---
Bisected commit-id:


Attachments
pci=noacpi console output before patch (12.42 KB, text/plain)
2003-09-13 22:38 UTC, Len Brown
Details
patch above ported to 2.4.22 (1.11 KB, patch)
2003-09-13 22:39 UTC, Len Brown
Details | Diff
pci=noacpi console output after patch (17.21 KB, text/plain)
2003-09-13 22:39 UTC, Len Brown
Details
Soyo UltraDragon P4X400-8235 dmesg with pci=noacpi (12.65 KB, text/plain)
2003-10-21 21:06 UTC, Len Brown
Details

Description Len Brown 2003-09-12 07:46:40 UTC
From: Thomas Schlichter

Hi Andrew,

the attached patch fixes interrupt routing probems for (at least 3) people 
with broken ACPI BIOSes. If only the ACPI interrupt routing part is broken, 
'pci=noacpi' should help as the documantation states:

pci=option[,option...]
	[...]
	noacpi	[IA-32] Do not use ACPI for IRQ routing.

The problem was that ACPI interrupt routing was not correctly disabled.
The patch applies cleanly to 2.6.0-test4...

   Thomas

--- linux-2.6.0-test4/arch/i386/kernel/acpi/boot.c.orig	Sat Aug 23 01:59:02 
2003
+++ linux-2.6.0-test4/arch/i386/kernel/acpi/boot.c	Sat Aug 23 16:39:57 
2003
@@ -41,6 +41,7 @@
 #define PREFIX			"ACPI: "
 
 extern int acpi_disabled;
+extern int acpi_irq;
 extern int acpi_ht;
 
 int acpi_lapic = 0;
@@ -407,7 +408,7 @@
 	 * If MPS is present, it will handle them,
 	 * otherwise the system will stay in PIC mode
 	 */
-	if (acpi_disabled) {
+	if (acpi_disabled || !acpi_irq) {
 		return 1;
         }
 
--- linux-2.6.0-test4/arch/i386/kernel/setup.c.orig	Sat Aug 23 01:55:38 
2003
+++ linux-2.6.0-test4/arch/i386/kernel/setup.c	Sat Aug 23 16:34:21 2003
@@ -71,6 +71,7 @@
 EXPORT_SYMBOL(acpi_disabled);
 
 #ifdef	CONFIG_ACPI_BOOT
+	int acpi_irq __initdata = 1;	/* enable IRQ */
 	int acpi_ht __initdata = 1;	/* enable HT */
 #endif
 
@@ -542,6 +543,11 @@
 		else if (!memcmp(from, "acpi=ht", 7)) {
 			acpi_ht = 1;
 			if (!acpi_force) acpi_disabled = 1;
+		}
+
+		/* "pci=noacpi" disables ACPI interrupt routing */
+		else if (!memcmp(from, "pci=noacpi", 10)) {
+			acpi_irq = 0;
 		}
 
 #ifdef CONFIG_X86_LOCAL_APIC

On Monday 25 August 2003 03:13, Peter Lieverdink wrote:
> Hi Thomas,
>
> Your patch works beautifully. 'acpi=nopci' previously caused IDE to work
> fine, but made the kernel not detect USB and network devices. With your
> patch it sees all peripherals AND acpi is available for the cpu. I wonder
> if it would be accepted into the kernel as a patch to workaround buggy acpi
> bioses.
>
> Thanks heaps!
>
> - Peter.
> --
>
> At 23:44 24/08/2003 +0200, you wrote:
> >Am Sunday 24 August 2003 22:54 schrieb David van Hoose:
> > > Kevin P. Fleming wrote:
> > > > Peter Lieverdink wrote:
> > > >> When I enable ACPI on 2.6.0-test4 (also on 2.6.0-test3-*), the
> > > >> kernel no longer recognises my IDE controller and drops down to PIO
> > > >> mode for harddisk access. Additionally, USB devices don't get
> > > >> detected.
> > > >
> > > > I'm running -test4 here with ACPI and have no trouble with USB
> > > > devices.
> > >
> > > I'm running test4 here with ACPI and have no USB following a call trace
> > > with "IRQ 20: nobody cared". ACPI seems to make odd reports. I've been
> > > having this problem since 2.5.70'ish. Posted numerous times, but nobody
> > > seems to care about it. I also have a PS/2 mouse detection when I have
> > > no mice attached to my system.
> > >
> > > >> The system is an Athlon 2400+ on a Gibabyte GA-7VAXP mainboard.
> > > >> (KT400)
> > > >
> > > > My system is an Athlon 1000 on an MSI KT266-based board.
> > >
> > > I have a Pentium 4 2.53 GHz on a Asus P4S8X mainboard.
> > >
> > > -David
> > >
> > > PS. dmesg is attached with ACPI debug and USB debug enabled.
> >
> >I had similar problems with my Epox 8K9A (KT400) Board.
> >
> >If I wanted to use my USB ports I had to boot wiht 'acpi=off'. But with
> > the patch attached it is possible for me to boot with 'pci=noacpi'. It
> > has the advantage that ACPI stays enabled...
> >
> >You are free to give it a try...
> >
> >   Thomas

On Sunday 10 August 2003 01:24, Joonas Koivunen:
> On Saturday 09 August 2003 19:02, Thomas Schlichter wrote:
> > It's not a problem with ACPI, it's more a problem with the interrupt
> > routing based on the ACPI tables. These tables seem to be not correctly
> > implemented in the BIOS and, as the german EPOX support admits, are not
> > really tested. To change this you may contact the EPOX support and
> > describe your problems, too....
>
> Thanks for letting me know.. I had a image of EPOX being pretty good with
> motherboards.. Guess not then.
>
> > If you want to use ACPI while this BIOS bug is not fixed you may use the
> > attached patch and boot with pci=noacpi. Without the patch this doesn't
> > work for me here...
>
> Why isn't this patch in the mainstream kernel? There are many other
> chipset/bios fixes in the kernel.. This would save many
> reboot/recompilings/worries until or if ever epox does something with the
> bios.
>
> The patch works nicely. Though I did apply it manually to -test3 :) But it
> works.
>
> > Best regards
> >   Thomas Schlichter
>
> Thanks again
> -rzei
Comment 1 Len Brown 2003-09-13 22:36:57 UTC
SE7505VB2 boots 2.4.22 with ACPI enabled and no cmdline 
but "pci=noacpi" does not boot -- the boot drive on a SiI3112 starves for interrupts 
 
hde: dma_timer_expiry: dma status == 0x24 
hde: DMA interrupt recovery 
hde: lost interrupt 
 
With the patch above, the system does boot, as the MP tables are parsed 
to get the APIC IRQ info.  However, ACPI lies about its intent: 
"ACPI: Using PIC for interrupt routing" 
 
 
 
 
 
Comment 2 Len Brown 2003-09-13 22:38:00 UTC
Created attachment 885 [details]
pci=noacpi console output before patch
Comment 3 Len Brown 2003-09-13 22:39:09 UTC
Created attachment 886 [details]
patch above ported to 2.4.22
Comment 4 Len Brown 2003-09-13 22:39:40 UTC
Created attachment 887 [details]
pci=noacpi console output after patch
Comment 5 Len Brown 2003-10-21 21:06:23 UTC
Created attachment 1127 [details]
Soyo UltraDragon P4X400-8235 dmesg with pci=noacpi

This Soyo P4X400-8235 doesn't bring up its ethernet when 2.6.0-test8
is booted with pci=noacpi.  It works without pci=noacpi.

	  CPU0
  0:	 122055    IO-APIC-edge  timer
  1:	      9    IO-APIC-edge  i8042
  2:	      0 	 XT-PIC  cascade
  4:	    334    IO-APIC-edge  serial
  9:	      0    IO-APIC-edge  acpi
 12:	     61    IO-APIC-edge  i8042
 14:	   5102    IO-APIC-edge  ide0
 15:	     33    IO-APIC-edge  ide1
 21:	      0   IO-APIC-level  uhci_hcd, uhci_hcd, uhci_hcd
NMI:	      0
LOC:	 124663
ERR:	      0
MIS:	      0
Comment 6 Len Brown 2003-11-30 20:54:02 UTC
the attached patch is in 2.4.23 -- marking RESOLVED. 
will close this bug when the change is updated to fix the rough edges mentioned. 
 
Comment 7 Len Brown 2003-12-02 12:54:13 UTC
shipped in 2.4.23. 
will fix the remaining rough edges as part of another bug. 
 

Note You need to log in before you can comment on or make changes to this bug.