Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-28 Thread Thomas Gleixner
Len,

On Tue, 2007-03-27 at 23:28 -0400, Len Brown wrote:
> Is this failure specific to NO_HZ, and that is why the "nolapic_timer" fix is 
> i386 only?
> I'm running 2.6.21-rc5 an nx6325 here in 64-bit mode and I don't see the 
> dramatic
> boot failure described earlier in this thread.

The difference between x86_64 and i386 is that on i386 we now switch off
the PIT and do the jiffies increment in the local apic timer interrupt.
This is necessary for NO_HZ and HIGH_RES_TIMERS. We just fall back to
the PIT in C3 (enforced to C2 now due to massive breakage).

You can see the same problem on x86_64 by adding "apicmaintimer" to the
kernel command line. This should make your box really slow.

> However, I have observed that when running on battery,
> the LOC falls behind the irq0 timer to the tune of about
> 2 interrupt/minute.  eg. when i booted my machine, LOC was
> behind irq0 by 50, and now about a 20 minutes later it is behind
> irq0 by 99.  However, the LOC for each processor remain at
> a constant offset with respect to each other.
> 
> I do not see these this drift when running on AC.
> Yes, the system exports just C1 in both cases.

Right, but it does bad magic when running on battery. The offsets you
observe are due to the LAPIC stops. The delta is rather small, because
you wake up via the PIT periodically, so the APICs start to run as well.
And they do it on both cores.

Someone should apply a huge clue stick to BIOS developers.

I have some experimental code to detect the LAPIC breakage during run
time, but this needs more thought and is definitely not 2.6.21 material.

> Other oddities is the IRQ name on irq0 is garbled:
> 
> [EMAIL PROTECTED]:~> uname -a; cat /proc/interrupts; sleep 100; cat 
> /proc/interrupts
> Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
> x86_64 GNU/Linux
>CPU0   CPU1
>   0: 723812  0-edge  timer

Hrmpf. Ingo ???

tglx


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-28 Thread Thomas Gleixner
Len,

On Tue, 2007-03-27 at 23:28 -0400, Len Brown wrote:
 Is this failure specific to NO_HZ, and that is why the nolapic_timer fix is 
 i386 only?
 I'm running 2.6.21-rc5 an nx6325 here in 64-bit mode and I don't see the 
 dramatic
 boot failure described earlier in this thread.

The difference between x86_64 and i386 is that on i386 we now switch off
the PIT and do the jiffies increment in the local apic timer interrupt.
This is necessary for NO_HZ and HIGH_RES_TIMERS. We just fall back to
the PIT in C3 (enforced to C2 now due to massive breakage).

You can see the same problem on x86_64 by adding apicmaintimer to the
kernel command line. This should make your box really slow.

 However, I have observed that when running on battery,
 the LOC falls behind the irq0 timer to the tune of about
 2 interrupt/minute.  eg. when i booted my machine, LOC was
 behind irq0 by 50, and now about a 20 minutes later it is behind
 irq0 by 99.  However, the LOC for each processor remain at
 a constant offset with respect to each other.
 
 I do not see these this drift when running on AC.
 Yes, the system exports just C1 in both cases.

Right, but it does bad magic when running on battery. The offsets you
observe are due to the LAPIC stops. The delta is rather small, because
you wake up via the PIT periodically, so the APICs start to run as well.
And they do it on both cores.

Someone should apply a huge clue stick to BIOS developers.

I have some experimental code to detect the LAPIC breakage during run
time, but this needs more thought and is definitely not 2.6.21 material.

 Other oddities is the IRQ name on irq0 is garbled:
 
 [EMAIL PROTECTED]:~ uname -a; cat /proc/interrupts; sleep 100; cat 
 /proc/interrupts
 Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
 x86_64 GNU/Linux
CPU0   CPU1
   0: 723812  0NULL-edge  timer

Hrmpf. Ingo ???

tglx


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-27 Thread Len Brown
On Tuesday 27 March 2007 23:28, Len Brown wrote:
> Thomas,
> 
> Is this failure specific to NO_HZ, and that is why the "nolapic_timer" fix is 
> i386 only?
> I'm running 2.6.21-rc5 an nx6325 here in 64-bit mode and I don't see the 
> dramatic
> boot failure described earlier in this thread.
> 
> However, I have observed that when running on battery,
> the LOC falls behind the irq0 timer to the tune of about
> 2 interrupt/minute.  eg. when i booted my machine, LOC was
> behind irq0 by 50, and now about a 20 minutes later it is behind
> irq0 by 99.  However, the LOC for each processor remain at
> a constant offset with respect to each other.
> 
> I do not see these this drift when running on AC.

Correction.
I double-checked and the same drift is present between irq0
and LOC when on AC:

[EMAIL PROTECTED]:/tmp/sut> uname -a; cat /proc/interrupts; sleep 100; cat 
/proc/interrupts
Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
x86_64 GNU/Linux
   CPU0   CPU1
  0:1000442  0-edge  timer
  1:724  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  36299  0   IO-APIC-edge  i8042
 14:  33661  0   IO-APIC-edge  ide0
 16:  20676  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   9388  0   IO-APIC-fasteoi   acpi
 23:  43794  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC:10002711000247
ERR:  0
   CPU0   CPU1
  0:1025442  0-edge  timer
  1:724  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  39539  0   IO-APIC-edge  i8042
 14:  34506  0   IO-APIC-edge  ide0
 16:  22172  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   9630  0   IO-APIC-fasteoi   acpi
 23:  44826  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC:10252691025245
ERR:  0
[EMAIL PROTECTED]:/tmp/sut> bc -l
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
1025442-1000442
25000
1025269-1000271
24998
[EMAIL PROTECTED]:/tmp/sut> cat /proc/acpi/ac_adapter/C1BD/state
state:   on-line

-Len

> Yes, the system exports just C1 in both cases.
> 
> Other oddities is the IRQ name on irq0 is garbled:
> 
> [EMAIL PROTECTED]:~> uname -a; cat /proc/interrupts; sleep 100; cat 
> /proc/interrupts
> Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
> x86_64 GNU/Linux
>CPU0   CPU1
>   0: 723812  0-edge  timer
>   1:716  0   IO-APIC-edge  i8042
>   8:  0  0   IO-APIC-edge  rtc
>  12:  30719  0   IO-APIC-edge  i8042
>  14:  24318  0   IO-APIC-edge  ide0
>  16:  18316  0   IO-APIC-fasteoi   libata
>  19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
> ohci_hcd:usb3
>  20:  1  0   IO-APIC-fasteoi   ohci1394
>  21:   6736  0   IO-APIC-fasteoi   acpi
>  23:  30358  0   IO-APIC-fasteoi   eth0
> NMI:  0  0
> LOC: 723675 723651
> ERR:  0
>CPU0   CPU1
>   0: 748812  0-edge  timer
>   1:716  0   IO-APIC-edge  i8042
>   8:  0  0   IO-APIC-edge  rtc
>  12:  30719  0   IO-APIC-edge  i8042
>  14:  25164  0   IO-APIC-edge  ide0
>  16:  18361  0   IO-APIC-fasteoi   libata
>  19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
> ohci_hcd:usb3
>  20:  1  0   IO-APIC-fasteoi   ohci1394
>  21:   6960  0   IO-APIC-fasteoi   acpi
>  23:  31385  0   IO-APIC-fasteoi   eth0
> NMI:  0  0
> LOC: 748673 748649
> ERR:  0
> [EMAIL PROTECTED]:~> bc -l
> bc 1.06
> Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
> This is free software with ABSOLUTELY NO WARRANTY.
> For details type `warranty'.
> 748812-723812
> 25000
> 748673-723675
> 24998
> 723812-723675
> 137
> 748812-748673
> 139
> [EMAIL PROTECTED]:~> 
> 
> Further, in dmesg:
> ATI board detected. Disabling timer routing over 8254.
> 
> ..MP-BIOS bug: 8254 timer not connected to IO-APIC
> 
> -Len
> 
> 
> 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  

Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-27 Thread Len Brown
Thomas,

Is this failure specific to NO_HZ, and that is why the "nolapic_timer" fix is 
i386 only?
I'm running 2.6.21-rc5 an nx6325 here in 64-bit mode and I don't see the 
dramatic
boot failure described earlier in this thread.

However, I have observed that when running on battery,
the LOC falls behind the irq0 timer to the tune of about
2 interrupt/minute.  eg. when i booted my machine, LOC was
behind irq0 by 50, and now about a 20 minutes later it is behind
irq0 by 99.  However, the LOC for each processor remain at
a constant offset with respect to each other.

I do not see these this drift when running on AC.
Yes, the system exports just C1 in both cases.

Other oddities is the IRQ name on irq0 is garbled:

[EMAIL PROTECTED]:~> uname -a; cat /proc/interrupts; sleep 100; cat 
/proc/interrupts
Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
x86_64 GNU/Linux
   CPU0   CPU1
  0: 723812  0-edge  timer
  1:716  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  30719  0   IO-APIC-edge  i8042
 14:  24318  0   IO-APIC-edge  ide0
 16:  18316  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   6736  0   IO-APIC-fasteoi   acpi
 23:  30358  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC: 723675 723651
ERR:  0
   CPU0   CPU1
  0: 748812  0-edge  timer
  1:716  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  30719  0   IO-APIC-edge  i8042
 14:  25164  0   IO-APIC-edge  ide0
 16:  18361  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   6960  0   IO-APIC-fasteoi   acpi
 23:  31385  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC: 748673 748649
ERR:  0
[EMAIL PROTECTED]:~> bc -l
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
748812-723812
25000
748673-723675
24998
723812-723675
137
748812-748673
139
[EMAIL PROTECTED]:~> 

Further, in dmesg:
ATI board detected. Disabling timer routing over 8254.

..MP-BIOS bug: 8254 timer not connected to IO-APIC

-Len


Linux version 2.6.21-rc5 ([EMAIL PROTECTED]) (gcc version 4.1.2 20061115 
(prerelease) (SUSE Linux)) #37 SMP Tue Mar 27 22:26:00 EDT 2007
Command line: root=/dev/sda2 debug
BIOS-provided physical RAM map:
 BIOS-e820:  - 0009fc00 (usable)
 BIOS-e820: 0009fc00 - 000a (reserved)
 BIOS-e820: 000e - 0010 (reserved)
 BIOS-e820: 0010 - 1bfd (usable)
 BIOS-e820: 1bfd - 1bfe5600 (reserved)
 BIOS-e820: 1bfe5600 - 1bff8000 (ACPI NVS)
 BIOS-e820: 1bff8000 - 2000 (reserved)
 BIOS-e820: e000 - f000 (reserved)
 BIOS-e820: fec0 - fec02000 (reserved)
 BIOS-e820: ffbc - ffcc (reserved)
 BIOS-e820: fff0 - 0001 (reserved)
Entering add_active_range(0, 0, 159) 0 entries of 3200 used
Entering add_active_range(0, 256, 114640) 1 entries of 3200 used
end_pfn_map = 1048576
DMI 2.4 present.
ACPI: RSDP 000F7D30, 0024 (r2 HP)
ACPI: XSDT 1BFE57B4, 0054 (r1 HP 0944  6070620 HP  1)
ACPI: FACP 1BFE5684, 00F4 (r4 HP 09443 HP  1)
ACPI: DSDT 1BFE58DC, EE7A (r1 HPSB4001 MSFT  10E)
ACPI: FACS 1BFF7E80, 0040
ACPI: APIC 1BFE5808, 0062 (r1 HP 09441 HP  1)
ACPI: MCFG 1BFE586C, 003C (r1 HP 09441 HP  1)
ACPI: TCPA 1BFE58A8, 0032 (r2 HP 09441 HP  1)
ACPI: SSDT 1BFF4756, 0059 (r1 HP   HPQNLP1 MSFT  10E)
ACPI: SSDT 1BFF47AF, 0182 (r1 HP PSSTBLID1 HP  1)
Scanning NUMA topology in Northbridge 24
Number of nodes 1
Node 0 MemBase  Limit 1bfd
Entering add_active_range(0, 0, 159) 0 entries of 3200 used
Entering add_active_range(0, 256, 114640) 1 entries of 3200 used
NUMA: Using 63 for the hash shift.
Using node hash shift of 63
Bootmem setup node 0 -1bfd
No mptable found.
Zone PFN ranges:
  DMA 0 -> 4096
  DMA324096 ->  1048576
  Normal1048576 ->  1048576
early_node_map[2] active PFN ranges
0:0 ->  159
0:  256 ->   114640
On node 0 totalpages: 114543
  DMA zone: 56 pages used for memmap
  DMA zone: 1593 pages reserved
  DMA zone: 2350 pages, LIFO batch:0
  DMA32 

Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-27 Thread Len Brown
Thomas,

Is this failure specific to NO_HZ, and that is why the nolapic_timer fix is 
i386 only?
I'm running 2.6.21-rc5 an nx6325 here in 64-bit mode and I don't see the 
dramatic
boot failure described earlier in this thread.

However, I have observed that when running on battery,
the LOC falls behind the irq0 timer to the tune of about
2 interrupt/minute.  eg. when i booted my machine, LOC was
behind irq0 by 50, and now about a 20 minutes later it is behind
irq0 by 99.  However, the LOC for each processor remain at
a constant offset with respect to each other.

I do not see these this drift when running on AC.
Yes, the system exports just C1 in both cases.

Other oddities is the IRQ name on irq0 is garbled:

[EMAIL PROTECTED]:~ uname -a; cat /proc/interrupts; sleep 100; cat 
/proc/interrupts
Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
x86_64 GNU/Linux
   CPU0   CPU1
  0: 723812  0NULL-edge  timer
  1:716  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  30719  0   IO-APIC-edge  i8042
 14:  24318  0   IO-APIC-edge  ide0
 16:  18316  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   6736  0   IO-APIC-fasteoi   acpi
 23:  30358  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC: 723675 723651
ERR:  0
   CPU0   CPU1
  0: 748812  0NULL-edge  timer
  1:716  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  30719  0   IO-APIC-edge  i8042
 14:  25164  0   IO-APIC-edge  ide0
 16:  18361  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   6960  0   IO-APIC-fasteoi   acpi
 23:  31385  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC: 748673 748649
ERR:  0
[EMAIL PROTECTED]:~ bc -l
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
748812-723812
25000
748673-723675
24998
723812-723675
137
748812-748673
139
[EMAIL PROTECTED]:~ 

Further, in dmesg:
ATI board detected. Disabling timer routing over 8254.

..MP-BIOS bug: 8254 timer not connected to IO-APIC

-Len


Linux version 2.6.21-rc5 ([EMAIL PROTECTED]) (gcc version 4.1.2 20061115 
(prerelease) (SUSE Linux)) #37 SMP Tue Mar 27 22:26:00 EDT 2007
Command line: root=/dev/sda2 debug
BIOS-provided physical RAM map:
 BIOS-e820:  - 0009fc00 (usable)
 BIOS-e820: 0009fc00 - 000a (reserved)
 BIOS-e820: 000e - 0010 (reserved)
 BIOS-e820: 0010 - 1bfd (usable)
 BIOS-e820: 1bfd - 1bfe5600 (reserved)
 BIOS-e820: 1bfe5600 - 1bff8000 (ACPI NVS)
 BIOS-e820: 1bff8000 - 2000 (reserved)
 BIOS-e820: e000 - f000 (reserved)
 BIOS-e820: fec0 - fec02000 (reserved)
 BIOS-e820: ffbc - ffcc (reserved)
 BIOS-e820: fff0 - 0001 (reserved)
Entering add_active_range(0, 0, 159) 0 entries of 3200 used
Entering add_active_range(0, 256, 114640) 1 entries of 3200 used
end_pfn_map = 1048576
DMI 2.4 present.
ACPI: RSDP 000F7D30, 0024 (r2 HP)
ACPI: XSDT 1BFE57B4, 0054 (r1 HP 0944  6070620 HP  1)
ACPI: FACP 1BFE5684, 00F4 (r4 HP 09443 HP  1)
ACPI: DSDT 1BFE58DC, EE7A (r1 HPSB4001 MSFT  10E)
ACPI: FACS 1BFF7E80, 0040
ACPI: APIC 1BFE5808, 0062 (r1 HP 09441 HP  1)
ACPI: MCFG 1BFE586C, 003C (r1 HP 09441 HP  1)
ACPI: TCPA 1BFE58A8, 0032 (r2 HP 09441 HP  1)
ACPI: SSDT 1BFF4756, 0059 (r1 HP   HPQNLP1 MSFT  10E)
ACPI: SSDT 1BFF47AF, 0182 (r1 HP PSSTBLID1 HP  1)
Scanning NUMA topology in Northbridge 24
Number of nodes 1
Node 0 MemBase  Limit 1bfd
Entering add_active_range(0, 0, 159) 0 entries of 3200 used
Entering add_active_range(0, 256, 114640) 1 entries of 3200 used
NUMA: Using 63 for the hash shift.
Using node hash shift of 63
Bootmem setup node 0 -1bfd
No mptable found.
Zone PFN ranges:
  DMA 0 - 4096
  DMA324096 -  1048576
  Normal1048576 -  1048576
early_node_map[2] active PFN ranges
0:0 -  159
0:  256 -   114640
On node 0 totalpages: 114543
  DMA zone: 56 pages used for memmap
  DMA zone: 1593 pages reserved
  DMA zone: 2350 pages, LIFO batch:0
  DMA32 

Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-27 Thread Len Brown
On Tuesday 27 March 2007 23:28, Len Brown wrote:
 Thomas,
 
 Is this failure specific to NO_HZ, and that is why the nolapic_timer fix is 
 i386 only?
 I'm running 2.6.21-rc5 an nx6325 here in 64-bit mode and I don't see the 
 dramatic
 boot failure described earlier in this thread.
 
 However, I have observed that when running on battery,
 the LOC falls behind the irq0 timer to the tune of about
 2 interrupt/minute.  eg. when i booted my machine, LOC was
 behind irq0 by 50, and now about a 20 minutes later it is behind
 irq0 by 99.  However, the LOC for each processor remain at
 a constant offset with respect to each other.
 
 I do not see these this drift when running on AC.

Correction.
I double-checked and the same drift is present between irq0
and LOC when on AC:

[EMAIL PROTECTED]:/tmp/sut uname -a; cat /proc/interrupts; sleep 100; cat 
/proc/interrupts
Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
x86_64 GNU/Linux
   CPU0   CPU1
  0:1000442  0NULL-edge  timer
  1:724  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  36299  0   IO-APIC-edge  i8042
 14:  33661  0   IO-APIC-edge  ide0
 16:  20676  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   9388  0   IO-APIC-fasteoi   acpi
 23:  43794  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC:10002711000247
ERR:  0
   CPU0   CPU1
  0:1025442  0NULL-edge  timer
  1:724  0   IO-APIC-edge  i8042
  8:  0  0   IO-APIC-edge  rtc
 12:  39539  0   IO-APIC-edge  i8042
 14:  34506  0   IO-APIC-edge  ide0
 16:  22172  0   IO-APIC-fasteoi   libata
 19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
ohci_hcd:usb3
 20:  1  0   IO-APIC-fasteoi   ohci1394
 21:   9630  0   IO-APIC-fasteoi   acpi
 23:  44826  0   IO-APIC-fasteoi   eth0
NMI:  0  0
LOC:10252691025245
ERR:  0
[EMAIL PROTECTED]:/tmp/sut bc -l
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
1025442-1000442
25000
1025269-1000271
24998
[EMAIL PROTECTED]:/tmp/sut cat /proc/acpi/ac_adapter/C1BD/state
state:   on-line

-Len

 Yes, the system exports just C1 in both cases.
 
 Other oddities is the IRQ name on irq0 is garbled:
 
 [EMAIL PROTECTED]:~ uname -a; cat /proc/interrupts; sleep 100; cat 
 /proc/interrupts
 Linux nx6325 2.6.21-rc5 #37 SMP Tue Mar 27 22:26:00 EDT 2007 x86_64 x86_64 
 x86_64 GNU/Linux
CPU0   CPU1
   0: 723812  0NULL-edge  timer
   1:716  0   IO-APIC-edge  i8042
   8:  0  0   IO-APIC-edge  rtc
  12:  30719  0   IO-APIC-edge  i8042
  14:  24318  0   IO-APIC-edge  ide0
  16:  18316  0   IO-APIC-fasteoi   libata
  19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
 ohci_hcd:usb3
  20:  1  0   IO-APIC-fasteoi   ohci1394
  21:   6736  0   IO-APIC-fasteoi   acpi
  23:  30358  0   IO-APIC-fasteoi   eth0
 NMI:  0  0
 LOC: 723675 723651
 ERR:  0
CPU0   CPU1
   0: 748812  0NULL-edge  timer
   1:716  0   IO-APIC-edge  i8042
   8:  0  0   IO-APIC-edge  rtc
  12:  30719  0   IO-APIC-edge  i8042
  14:  25164  0   IO-APIC-edge  ide0
  16:  18361  0   IO-APIC-fasteoi   libata
  19: 21  0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, 
 ohci_hcd:usb3
  20:  1  0   IO-APIC-fasteoi   ohci1394
  21:   6960  0   IO-APIC-fasteoi   acpi
  23:  31385  0   IO-APIC-fasteoi   eth0
 NMI:  0  0
 LOC: 748673 748649
 ERR:  0
 [EMAIL PROTECTED]:~ bc -l
 bc 1.06
 Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
 This is free software with ABSOLUTELY NO WARRANTY.
 For details type `warranty'.
 748812-723812
 25000
 748673-723675
 24998
 723812-723675
 137
 748812-748673
 139
 [EMAIL PROTECTED]:~ 
 
 Further, in dmesg:
 ATI board detected. Disabling timer routing over 8254.
 
 ..MP-BIOS bug: 8254 timer not connected to IO-APIC
 
 -Len
 
 
 
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-22 Thread Stefan Prechtel

2007/3/21, Grzegorz Chwesewicz <[EMAIL PROTECTED]>:

On Wed, 21 Mar 2007 15:09:30 +0100, Ingo Molnar wrote
> * Thomas Gleixner <[EMAIL PROTECTED]> wrote:
>
> > The local APIC timer stops to work in deeper C-States. This is handled
> > by the ACPI code and a broadcast mechanism in the clockevents / tick
> > managment code.
> >
> > Some systems do not expose the deeper C-States to the kernel, but
> > switch into deeper C-States behind the kernels back. This delays the
> > local apic timer interrupts for ever and makes the systems unusable.
> >
> > Add a command line option to disable the local apic timer and a dmi
> > quirk for known broken systems.

Confirming that my machine on 2.6-git with this patch works just like on
2.6.20. Great work.

--
Greetings - Grzegorz Chwesewicz


Works here too, thx ;)

Kind regards,
Stefan Prechtel
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-22 Thread Stefan Prechtel

2007/3/21, Grzegorz Chwesewicz [EMAIL PROTECTED]:

On Wed, 21 Mar 2007 15:09:30 +0100, Ingo Molnar wrote
 * Thomas Gleixner [EMAIL PROTECTED] wrote:

  The local APIC timer stops to work in deeper C-States. This is handled
  by the ACPI code and a broadcast mechanism in the clockevents / tick
  managment code.
 
  Some systems do not expose the deeper C-States to the kernel, but
  switch into deeper C-States behind the kernels back. This delays the
  local apic timer interrupts for ever and makes the systems unusable.
 
  Add a command line option to disable the local apic timer and a dmi
  quirk for known broken systems.

Confirming that my machine on 2.6-git with this patch works just like on
2.6.20. Great work.

--
Greetings - Grzegorz Chwesewicz


Works here too, thx ;)

Kind regards,
Stefan Prechtel
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-21 Thread Grzegorz Chwesewicz
On Wed, 21 Mar 2007 15:09:30 +0100, Ingo Molnar wrote
> * Thomas Gleixner <[EMAIL PROTECTED]> wrote:
> 
> > The local APIC timer stops to work in deeper C-States. This is handled 
> > by the ACPI code and a broadcast mechanism in the clockevents / tick 
> > managment code.
> > 
> > Some systems do not expose the deeper C-States to the kernel, but 
> > switch into deeper C-States behind the kernels back. This delays the 
> > local apic timer interrupts for ever and makes the systems unusable.
> > 
> > Add a command line option to disable the local apic timer and a dmi 
> > quirk for known broken systems.

Confirming that my machine on 2.6-git with this patch works just like on
2.6.20. Great work.

--
Greetings - Grzegorz Chwesewicz

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-21 Thread Ingo Molnar

* Thomas Gleixner <[EMAIL PROTECTED]> wrote:

> The local APIC timer stops to work in deeper C-States. This is handled 
> by the ACPI code and a broadcast mechanism in the clockevents / tick 
> managment code.
> 
> Some systems do not expose the deeper C-States to the kernel, but 
> switch into deeper C-States behind the kernels back. This delays the 
> local apic timer interrupts for ever and makes the systems unusable.
> 
> Add a command line option to disable the local apic timer and a dmi 
> quirk for known broken systems.
> 
> Signed-off-by: Thomas Gleixner <[EMAIL PROTECTED]>

Acked-by: Ingo Molnar <[EMAIL PROTECTED]>

nice work!

Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-21 Thread Thomas Gleixner
The local APIC timer stops to work in deeper C-States. This is handled
by the ACPI code and a broadcast mechanism in the clockevents / tick
managment code.

Some systems do not expose the deeper C-States to the kernel, but switch
into deeper C-States behind the kernels back. This delays the local apic
timer interrupts for ever and makes the systems unusable.

Add a command line option to disable the local apic timer and a dmi
quirk for known broken systems.

Signed-off-by: Thomas Gleixner <[EMAIL PROTECTED]>

diff --git a/Documentation/kernel-parameters.txt 
b/Documentation/kernel-parameters.txt
index 856c8b1..06377c7 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -1117,6 +1117,8 @@ and is between 256 and 4096 characters. It is defined in 
the file
 
nolapic [IA-32,APIC] Do not enable or use the local APIC.
 
+   nolapic_timer   [IA-32,APIC] Do not use the local APIC timer.
+
noltlbs [PPC] Do not use large page/tlb entries for kernel
lowmem mapping on PPC40x.
 
diff --git a/arch/i386/kernel/apic.c b/arch/i386/kernel/apic.c
index 5cff797..3682511 100644
--- a/arch/i386/kernel/apic.c
+++ b/arch/i386/kernel/apic.c
@@ -28,6 +28,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -61,6 +62,8 @@ static int enable_local_apic __initdata = 0;
 
 /* Local APIC timer verification ok */
 static int local_apic_timer_verify_ok;
+/* Disable local APIC timer from the kernel commandline or via dmi quirk */
+static int local_apic_timer_disabled;
 
 /*
  * Debug level, exported for io_apic.c
@@ -266,6 +269,32 @@ static void __devinit setup_APIC_timer(void)
 }
 
 /*
+ * Detect systems with known broken BIOS implementations
+ */
+static int __init lapic_check_broken_bios(struct dmi_system_id *d)
+{
+   printk(KERN_NOTICE "%s detected: disabling lapic timer.\n",
+  d->ident);
+   local_apic_timer_disabled = 1;
+   return 0;
+}
+
+static struct dmi_system_id __initdata broken_bios_dmi_table[] = {
+   {
+   /*
+* BIOS exports only C1 state, but uses deeper power
+* modes behind the kernels back.
+*/
+ .callback = lapic_check_broken_bios,
+ .ident = "HP nx6325",
+ .matches = {
+   DMI_MATCH(DMI_PRODUCT_NAME, "HP Compaq nx6325"),
+ },
+},
+{}
+};
+
+/*
  * In this functions we calibrate APIC bus clocks to the external timer.
  *
  * We want to do the calibration only once since we want to have local timer
@@ -340,6 +369,22 @@ void __init setup_boot_APIC_clock(void)
long delta, deltapm;
int pm_referenced = 0;
 
+   /* Detect know broken systems */
+   dmi_check_system(broken_bios_dmi_table);
+
+   /*
+* The local apic timer can be disabled via the kernel
+* commandline or from the dmi quirk above. Register the lapic
+* timer as a dummy clock event source on SMP systems, so the
+* broadcast mechanism is used. On UP systems simply ignore it.
+*/
+   if (local_apic_timer_disabled) {
+   /* No broadcast on UP ! */
+   if (num_possible_cpus() > 1)
+   setup_APIC_timer();
+   return;
+   }
+
apic_printk(APIC_VERBOSE, "Using local APIC timer interrupts.\n"
"calibrating APIC timer ...\n");
 
@@ -1179,6 +1224,13 @@ static int __init parse_nolapic(char *arg)
 }
 early_param("nolapic", parse_nolapic);
 
+static int __init parse_disable_lapic_timer(char *arg)
+{
+   local_apic_timer_disabled = 1;
+   return 0;
+}
+early_param("nolapic_timer", parse_disable_lapic_timer);
+
 static int __init apic_set_verbosity(char *str)
 {
if (strcmp("debug", str) == 0)


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-21 Thread Thomas Gleixner
The local APIC timer stops to work in deeper C-States. This is handled
by the ACPI code and a broadcast mechanism in the clockevents / tick
managment code.

Some systems do not expose the deeper C-States to the kernel, but switch
into deeper C-States behind the kernels back. This delays the local apic
timer interrupts for ever and makes the systems unusable.

Add a command line option to disable the local apic timer and a dmi
quirk for known broken systems.

Signed-off-by: Thomas Gleixner [EMAIL PROTECTED]

diff --git a/Documentation/kernel-parameters.txt 
b/Documentation/kernel-parameters.txt
index 856c8b1..06377c7 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -1117,6 +1117,8 @@ and is between 256 and 4096 characters. It is defined in 
the file
 
nolapic [IA-32,APIC] Do not enable or use the local APIC.
 
+   nolapic_timer   [IA-32,APIC] Do not use the local APIC timer.
+
noltlbs [PPC] Do not use large page/tlb entries for kernel
lowmem mapping on PPC40x.
 
diff --git a/arch/i386/kernel/apic.c b/arch/i386/kernel/apic.c
index 5cff797..3682511 100644
--- a/arch/i386/kernel/apic.c
+++ b/arch/i386/kernel/apic.c
@@ -28,6 +28,7 @@
 #include linux/clockchips.h
 #include linux/acpi_pmtmr.h
 #include linux/module.h
+#include linux/dmi.h
 
 #include asm/atomic.h
 #include asm/smp.h
@@ -61,6 +62,8 @@ static int enable_local_apic __initdata = 0;
 
 /* Local APIC timer verification ok */
 static int local_apic_timer_verify_ok;
+/* Disable local APIC timer from the kernel commandline or via dmi quirk */
+static int local_apic_timer_disabled;
 
 /*
  * Debug level, exported for io_apic.c
@@ -266,6 +269,32 @@ static void __devinit setup_APIC_timer(void)
 }
 
 /*
+ * Detect systems with known broken BIOS implementations
+ */
+static int __init lapic_check_broken_bios(struct dmi_system_id *d)
+{
+   printk(KERN_NOTICE %s detected: disabling lapic timer.\n,
+  d-ident);
+   local_apic_timer_disabled = 1;
+   return 0;
+}
+
+static struct dmi_system_id __initdata broken_bios_dmi_table[] = {
+   {
+   /*
+* BIOS exports only C1 state, but uses deeper power
+* modes behind the kernels back.
+*/
+ .callback = lapic_check_broken_bios,
+ .ident = HP nx6325,
+ .matches = {
+   DMI_MATCH(DMI_PRODUCT_NAME, HP Compaq nx6325),
+ },
+},
+{}
+};
+
+/*
  * In this functions we calibrate APIC bus clocks to the external timer.
  *
  * We want to do the calibration only once since we want to have local timer
@@ -340,6 +369,22 @@ void __init setup_boot_APIC_clock(void)
long delta, deltapm;
int pm_referenced = 0;
 
+   /* Detect know broken systems */
+   dmi_check_system(broken_bios_dmi_table);
+
+   /*
+* The local apic timer can be disabled via the kernel
+* commandline or from the dmi quirk above. Register the lapic
+* timer as a dummy clock event source on SMP systems, so the
+* broadcast mechanism is used. On UP systems simply ignore it.
+*/
+   if (local_apic_timer_disabled) {
+   /* No broadcast on UP ! */
+   if (num_possible_cpus()  1)
+   setup_APIC_timer();
+   return;
+   }
+
apic_printk(APIC_VERBOSE, Using local APIC timer interrupts.\n
calibrating APIC timer ...\n);
 
@@ -1179,6 +1224,13 @@ static int __init parse_nolapic(char *arg)
 }
 early_param(nolapic, parse_nolapic);
 
+static int __init parse_disable_lapic_timer(char *arg)
+{
+   local_apic_timer_disabled = 1;
+   return 0;
+}
+early_param(nolapic_timer, parse_disable_lapic_timer);
+
 static int __init apic_set_verbosity(char *str)
 {
if (strcmp(debug, str) == 0)


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-21 Thread Ingo Molnar

* Thomas Gleixner [EMAIL PROTECTED] wrote:

 The local APIC timer stops to work in deeper C-States. This is handled 
 by the ACPI code and a broadcast mechanism in the clockevents / tick 
 managment code.
 
 Some systems do not expose the deeper C-States to the kernel, but 
 switch into deeper C-States behind the kernels back. This delays the 
 local apic timer interrupts for ever and makes the systems unusable.
 
 Add a command line option to disable the local apic timer and a dmi 
 quirk for known broken systems.
 
 Signed-off-by: Thomas Gleixner [EMAIL PROTECTED]

Acked-by: Ingo Molnar [EMAIL PROTECTED]

nice work!

Ingo
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] i386: disable local apic timer via command line or dmi quirk

2007-03-21 Thread Grzegorz Chwesewicz
On Wed, 21 Mar 2007 15:09:30 +0100, Ingo Molnar wrote
 * Thomas Gleixner [EMAIL PROTECTED] wrote:
 
  The local APIC timer stops to work in deeper C-States. This is handled 
  by the ACPI code and a broadcast mechanism in the clockevents / tick 
  managment code.
  
  Some systems do not expose the deeper C-States to the kernel, but 
  switch into deeper C-States behind the kernels back. This delays the 
  local apic timer interrupts for ever and makes the systems unusable.
  
  Add a command line option to disable the local apic timer and a dmi 
  quirk for known broken systems.

Confirming that my machine on 2.6-git with this patch works just like on
2.6.20. Great work.

--
Greetings - Grzegorz Chwesewicz

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/