2002-11-15 11:54:15

by Kammerloher, Josef

[permalink] [raw]
Subject: Every semaphore call results in "uninterruptable sleep"

I use SuSE 8.1 ( kernel 2.4.19-4GB) and a program with semaphores.
It runs okay on many PCs and laptops except one laptop (with Pentium
Mobile).

Every semaphore function (semget(),..) , "ipcs -s" ... results in
"uninterruptable sleep".
The processes cannot be killed by kill -9.

cat /proc/sys/kernel/sem returns 250 256000 32 1024

I always use the default kernel without special configurations.

What can I do ??
Thanks for your help,
Josef


2002-11-15 17:56:58

by Manfred Spraul

[permalink] [raw]
Subject: Re: Every semaphore call results in "uninterruptable sleep"

>
>
>Every semaphore function (semget(),..) , "ipcs -s" ... results in
>"uninterruptable sleep".
>The processes cannot be killed by kill -9.
>
>
Enable sysrequest, then press Alt+SysRQ+T.
It will dump the kernel stack of all processes.
Run in through ksymoops and send the results to the list.

--
Manfred

2002-11-16 13:17:59

by Steffen Persvold

[permalink] [raw]
Subject: Xeon with HyperThreading and linux-2.4.20-rc2

Hi all,

I've two boxes with Dual Xeons 1.8 GHz and HT option enabled in BIOS. When
I boot 2.4.20-rc2 with default arguments the kernel detects 4 processors and
also reports 4 processors in /proc/cpuinfo wiht the "ht" feature.

However, if I boot with the "noht" option (wich I believed turned off HT
and therefore only two processors should be available), the kernel still
detects 4 processors, _but_ now the "ht" feature in /proc/cpuinfo is not
there. Is this the intention of the "noht" option ? If so, are there any
options available to turn off HT support in the kernel completely, so that
I don't have to go into the BIOS to turn it off ?

If you want to I can provide the dmesg output and .config.

I think this issue is not just related to 2.4.20-rc2, but earlier kernels
aswell.

Regards,
--
Steffen Persvold | Scali AS
mailto:[email protected] | http://www.scali.com
Tel: (+47) 2262 8950 | Olaf Helsets vei 6
Fax: (+47) 2262 8951 | N0621 Oslo, NORWAY

2002-11-19 21:00:24

by Steffen Persvold

[permalink] [raw]
Subject: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

Hi all,

I've two boxes with Dual Xeons 1.8 GHz and HT option enabled in BIOS. When
I boot 2.4.20-rc2 with default arguments the kernel detects 4 processors and
also reports 4 processors in /proc/cpuinfo wiht the "ht" feature.

However, if I boot with the "noht" option (wich I believed turned off HT
and therefore only two processors should be available), the kernel still
detects 4 processors, _but_ now the "ht" feature in /proc/cpuinfo is not
there. Is this the intention of the "noht" option ? If so, are there any
options available to turn off HT support in the kernel completely, so that
I don't have to go into the BIOS to turn it off ?

If you want to I can provide the dmesg output and .config.

I think this issue is not just related to 2.4.20-rc2, but earlier kernels
aswell.

Regards,
--
Steffen Persvold | Scali AS
mailto:[email protected] | http://www.scali.com
Tel: (+47) 2262 8950 | Olaf Helsets vei 6
Fax: (+47) 2262 8951 | N0621 Oslo, NORWAY

2002-11-19 21:34:36

by Hugh Dickins

[permalink] [raw]
Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Tue, 19 Nov 2002, Steffen Persvold wrote:
>
> I've two boxes with Dual Xeons 1.8 GHz and HT option enabled in BIOS. When
> I boot 2.4.20-rc2 with default arguments the kernel detects 4 processors and
> also reports 4 processors in /proc/cpuinfo wiht the "ht" feature.
>
> However, if I boot with the "noht" option (wich I believed turned off HT
> and therefore only two processors should be available), the kernel still
> detects 4 processors, _but_ now the "ht" feature in /proc/cpuinfo is not
> there. Is this the intention of the "noht" option ?

No, the intention of the "noht" option is as you believed, and it used to
work that way. I looked at latest sourcec, didn't see anything obviously
wrong. Sorry, but I don't have a suitable HT machine to check at present.

> If so, are there any
> options available to turn off HT support in the kernel completely, so that
> I don't have to go into the BIOS to turn it off ?
>
> If you want to I can provide the dmesg output and .config.
>
> I think this issue is not just related to 2.4.20-rc2, but earlier kernels
> aswell.

Could others check and report if 2.4.20-rc2 "noht" works for them or not?

Thanks,
Hugh

2002-11-20 09:47:13

by Steffen Persvold

[permalink] [raw]
Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Tue, 19 Nov 2002, Hugh Dickins wrote:

> On Tue, 19 Nov 2002, Steffen Persvold wrote:
> >
> > I've two boxes with Dual Xeons 1.8 GHz and HT option enabled in BIOS. When
> > I boot 2.4.20-rc2 with default arguments the kernel detects 4 processors and
> > also reports 4 processors in /proc/cpuinfo wiht the "ht" feature.
> >
> > However, if I boot with the "noht" option (wich I believed turned off HT
> > and therefore only two processors should be available), the kernel still
> > detects 4 processors, _but_ now the "ht" feature in /proc/cpuinfo is not
> > there. Is this the intention of the "noht" option ?
>
> No, the intention of the "noht" option is as you believed, and it used to
> work that way. I looked at latest sourcec, didn't see anything obviously
> wrong. Sorry, but I don't have a suitable HT machine to check at present.
>
> > If so, are there any
> > options available to turn off HT support in the kernel completely, so that
> > I don't have to go into the BIOS to turn it off ?
> >
> > If you want to I can provide the dmesg output and .config.
> >
> > I think this issue is not just related to 2.4.20-rc2, but earlier kernels
> > aswell.
>
> Could others check and report if 2.4.20-rc2 "noht" works for them or not?
>

Thanks for your reply Hugh,

After digging into it a bit, I _think_ I know what happens. When the
machine is bootet with default parameters, the processors are detected in
the ACPI table, and the MP table search is skipped :

Linux version 2.4.20-rc2 ([email protected]) (gcc version 3.2 20020903 (Red Hat Linux 8.0 3.2-7)) #4 SMP Sat Nov 16 14:06:13 CET 2002
BIOS-provided physical RAM map:
BIOS-e820: 0000000000000000 - 000000000009f400 (usable)
BIOS-e820: 000000000009f400 - 00000000000a0000 (reserved)
BIOS-e820: 00000000000d8000 - 00000000000e0000 (reserved)
BIOS-e820: 00000000000e4000 - 0000000000100000 (reserved)
BIOS-e820: 0000000000100000 - 000000003fef0000 (usable)
BIOS-e820: 000000003fef0000 - 000000003fefc000 (ACPI data)
BIOS-e820: 000000003fefc000 - 000000003ff00000 (ACPI NVS)
BIOS-e820: 000000003ff00000 - 000000003ff80000 (usable)
BIOS-e820: 000000003ff80000 - 0000000040000000 (reserved)
BIOS-e820: 00000000fec00000 - 00000000fec10000 (reserved)
BIOS-e820: 00000000fee00000 - 00000000fee01000 (reserved)
BIOS-e820: 00000000ff800000 - 00000000ffc00000 (reserved)
BIOS-e820: 00000000fff00000 - 0000000100000000 (reserved)
127MB HIGHMEM available.
896MB LOWMEM available.
found SMP MP-table at 000f7030
hm, page 000f7000 reserved twice.
hm, page 000f8000 reserved twice.
hm, page 0009f000 reserved twice.
hm, page 000a0000 reserved twice.
On node 0 totalpages: 262016
zone(0): 4096 pages.
zone(1): 225280 pages.
zone(2): 32640 pages.
ACPI: Searched entire block, no RSDP was found.
ACPI: RSDP located at physical address c00f7090
RSD PTR v0 [PTLTD ]
__va_range(0x3fef84e0, 0x68): idx=8 mapped at ffff6000
ACPI table found: RSDT v1 [PTLTD RSDT 1540.0]
__va_range(0x3fefbe78, 0x24): idx=8 mapped at ffff6000
__va_range(0x3fefbe78, 0x74): idx=8 mapped at ffff6000
ACPI table found: FACP v1 [INTEL K_CANYON 1540.0]
__va_range(0x3fefbeec, 0x24): idx=8 mapped at ffff6000
__va_range(0x3fefbeec, 0x9c): idx=8 mapped at ffff6000
ACPI table found: APIC v1 [PTLTD APIC 1540.0]
__va_range(0x3fefbeec, 0x9c): idx=8 mapped at ffff6000
LAPIC (acpi_id[0x0000] id[0x0] enabled[1])
CPU 0 (0x0000) enabledProcessor #0 Pentium 4(tm) XEON(tm) APIC version 16

LAPIC (acpi_id[0x0001] id[0x6] enabled[1])
CPU 1 (0x0600) enabledProcessor #6 Pentium 4(tm) XEON(tm) APIC version 16

LAPIC (acpi_id[0x0002] id[0x1] enabled[1])
CPU 2 (0x0100) enabledProcessor #1 Pentium 4(tm) XEON(tm) APIC version 16

LAPIC (acpi_id[0x0003] id[0x7] enabled[1])
CPU 3 (0x0700) enabledProcessor #7 Pentium 4(tm) XEON(tm) APIC version 16

IOAPIC (id[0x2] address[0xfec00000] global_irq_base[0x0])
IOAPIC (id[0x3] address[0xfec80000] global_irq_base[0x18])
IOAPIC (id[0x4] address[0xfec80400] global_irq_base[0x30])
INT_SRC_OVR (bus[0] irq[0x0] global_irq[0x2] polarity[0x1] trigger[0x1])
INT_SRC_OVR (bus[0] irq[0x9] global_irq[0x9] polarity[0x1] trigger[0x3])
LAPIC_NMI (acpi_id[0x0000] polarity[0x1] trigger[0x1] lint[0x1])
LAPIC_NMI (acpi_id[0x0001] polarity[0x1] trigger[0x1] lint[0x1])
LAPIC_NMI (acpi_id[0x0002] polarity[0x1] trigger[0x1] lint[0x1])
LAPIC_NMI (acpi_id[0x0003] polarity[0x1] trigger[0x1] lint[0x1])
4 CPUs total
Local APIC address fee00000
__va_range(0x3fefbf88, 0x24): idx=8 mapped at ffff6000
__va_range(0x3fefbf88, 0x28): idx=8 mapped at ffff6000
ACPI table found: BOOT v1 [PTLTD $SBFTBL$ 1540.0]
__va_range(0x3fefbfb0, 0x24): idx=8 mapped at ffff6000
__va_range(0x3fefbfb0, 0x50): idx=8 mapped at ffff6000
ACPI table found: SPCR v1 [PTLTD $UCRTBL$ 1540.0]
Enabling the CPU's according to the ACPI table
Intel MultiProcessor Specification v1.4
Virtual Wire compatibility mode.
OEM ID: Product ID: Kings Canyon APIC at: 0xFEE00000
I/O APIC #2 Version 32 at 0xFEC00000.
I/O APIC #3 Version 32 at 0xFEC80000.
I/O APIC #4 Version 32 at 0xFEC80400.
Processors: 4
Kernel command line: ro root=LABEL=/ console=ttyS0,9600n8 nmi_watchdog=1
[snip]


However, when I boot the machine with the "noht" option the ACPI table
search is skipped, _but_ it still finds 4 processors in the MP table :

Linux version 2.4.20-rc2 ([email protected]) (gcc version 3.2 20020903 (Red Hat Linux 8.0 3.2-7)) #4 SMP Sat Nov 16 14:06:13 CET 2002
BIOS-provided physical RAM map:
BIOS-e820: 0000000000000000 - 000000000009f400 (usable)
BIOS-e820: 000000000009f400 - 00000000000a0000 (reserved)
BIOS-e820: 00000000000d8000 - 00000000000e0000 (reserved)
BIOS-e820: 00000000000e4000 - 0000000000100000 (reserved)
BIOS-e820: 0000000000100000 - 000000003fef0000 (usable)
BIOS-e820: 000000003fef0000 - 000000003fefc000 (ACPI data)
BIOS-e820: 000000003fefc000 - 000000003ff00000 (ACPI NVS)
BIOS-e820: 000000003ff00000 - 000000003ff80000 (usable)
BIOS-e820: 000000003ff80000 - 0000000040000000 (reserved)
BIOS-e820: 00000000fec00000 - 00000000fec10000 (reserved)
BIOS-e820: 00000000fee00000 - 00000000fee01000 (reserved)
BIOS-e820: 00000000ff800000 - 00000000ffc00000 (reserved)
BIOS-e820: 00000000fff00000 - 0000000100000000 (reserved)
127MB HIGHMEM available.
896MB LOWMEM available.
found SMP MP-table at 000f7030
hm, page 000f7000 reserved twice.
hm, page 000f8000 reserved twice.
hm, page 0009f000 reserved twice.
hm, page 000a0000 reserved twice.
On node 0 totalpages: 262016
zone(0): 4096 pages.
zone(1): 225280 pages.
zone(2): 32640 pages.
Intel MultiProcessor Specification v1.4
Virtual Wire compatibility mode.
OEM ID: Product ID: Kings Canyon APIC at: 0xFEE00000
Processor #0 Pentium 4(tm) XEON(tm) APIC version 20
Processor #6 Pentium 4(tm) XEON(tm) APIC version 20
Processor #1 Pentium 4(tm) XEON(tm) APIC version 20
Processor #7 Pentium 4(tm) XEON(tm) APIC version 20
I/O APIC #2 Version 32 at 0xFEC00000.
I/O APIC #3 Version 32 at 0xFEC80000.
I/O APIC #4 Version 32 at 0xFEC80400.
Processors: 4
Kernel command line: ro root=LABEL=/ console=ttyS0,9600n8 nmi_watchdog=1 noht

Since the HT feature is enabled in the BIOS it seems normal to me that 4
processors are reported both in the MP table and in the ACPI table.
Shouldn't the 'noht' option handle this ?

I have two of these machines and can assist in testing out patches etc.

Regards,
--
Steffen Persvold | Scali AS
mailto:[email protected] | http://www.scali.com
Tel: (+47) 2262 8950 | Olaf Helsets vei 6
Fax: (+47) 2262 8951 | N0621 Oslo, NORWAY

2002-11-20 12:45:00

by Hugh Dickins

[permalink] [raw]
Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Wed, 20 Nov 2002, Steffen Persvold wrote:
> On Tue, 19 Nov 2002, Hugh Dickins wrote:
> > On Tue, 19 Nov 2002, Steffen Persvold wrote:
> > >
> > > I've two boxes with Dual Xeons 1.8 GHz and HT option enabled in BIOS. When
> > > I boot 2.4.20-rc2 with default arguments the kernel detects 4 processors and
> > > also reports 4 processors in /proc/cpuinfo wiht the "ht" feature.
> > >
> > > However, if I boot with the "noht" option (wich I believed turned off HT
> > > and therefore only two processors should be available), the kernel still
> > > detects 4 processors, _but_ now the "ht" feature in /proc/cpuinfo is not
> > > there. Is this the intention of the "noht" option ?
> >
> > No, the intention of the "noht" option is as you believed, and it used to
> > work that way. I looked at latest sourcec, didn't see anything obviously
> > wrong. Sorry, but I don't have a suitable HT machine to check at present.
> >
> > > If so, are there any
> > > options available to turn off HT support in the kernel completely, so that
> > > I don't have to go into the BIOS to turn it off ?
> > >
> > > If you want to I can provide the dmesg output and .config.
> > >
> > > I think this issue is not just related to 2.4.20-rc2, but earlier kernels
> > > aswell.
> >
> > Could others check and report if 2.4.20-rc2 "noht" works for them or not?
> >
>
> Thanks for your reply Hugh,
>
> After digging into it a bit, I _think_ I know what happens. When the
> machine is bootet with default parameters, the processors are detected in
> the ACPI table, and the MP table search is skipped :
>
> Linux version 2.4.20-rc2 ([email protected]) (gcc version 3.2 20020903 (Red Hat Linux 8.0 3.2-7)) #4 SMP Sat Nov 16 14:06:13 CET 2002
> BIOS-provided physical RAM map:
> BIOS-e820: 0000000000000000 - 000000000009f400 (usable)
> BIOS-e820: 000000000009f400 - 00000000000a0000 (reserved)
> BIOS-e820: 00000000000d8000 - 00000000000e0000 (reserved)
> BIOS-e820: 00000000000e4000 - 0000000000100000 (reserved)
> BIOS-e820: 0000000000100000 - 000000003fef0000 (usable)
> BIOS-e820: 000000003fef0000 - 000000003fefc000 (ACPI data)
> BIOS-e820: 000000003fefc000 - 000000003ff00000 (ACPI NVS)
> BIOS-e820: 000000003ff00000 - 000000003ff80000 (usable)
> BIOS-e820: 000000003ff80000 - 0000000040000000 (reserved)
> BIOS-e820: 00000000fec00000 - 00000000fec10000 (reserved)
> BIOS-e820: 00000000fee00000 - 00000000fee01000 (reserved)
> BIOS-e820: 00000000ff800000 - 00000000ffc00000 (reserved)
> BIOS-e820: 00000000fff00000 - 0000000100000000 (reserved)
> 127MB HIGHMEM available.
> 896MB LOWMEM available.
> found SMP MP-table at 000f7030
> hm, page 000f7000 reserved twice.
> hm, page 000f8000 reserved twice.
> hm, page 0009f000 reserved twice.
> hm, page 000a0000 reserved twice.
> On node 0 totalpages: 262016
> zone(0): 4096 pages.
> zone(1): 225280 pages.
> zone(2): 32640 pages.
> ACPI: Searched entire block, no RSDP was found.
> ACPI: RSDP located at physical address c00f7090
> RSD PTR v0 [PTLTD ]
> __va_range(0x3fef84e0, 0x68): idx=8 mapped at ffff6000
> ACPI table found: RSDT v1 [PTLTD RSDT 1540.0]
> __va_range(0x3fefbe78, 0x24): idx=8 mapped at ffff6000
> __va_range(0x3fefbe78, 0x74): idx=8 mapped at ffff6000
> ACPI table found: FACP v1 [INTEL K_CANYON 1540.0]
> __va_range(0x3fefbeec, 0x24): idx=8 mapped at ffff6000
> __va_range(0x3fefbeec, 0x9c): idx=8 mapped at ffff6000
> ACPI table found: APIC v1 [PTLTD APIC 1540.0]
> __va_range(0x3fefbeec, 0x9c): idx=8 mapped at ffff6000
> LAPIC (acpi_id[0x0000] id[0x0] enabled[1])
> CPU 0 (0x0000) enabledProcessor #0 Pentium 4(tm) XEON(tm) APIC version 16
>
> LAPIC (acpi_id[0x0001] id[0x6] enabled[1])
> CPU 1 (0x0600) enabledProcessor #6 Pentium 4(tm) XEON(tm) APIC version 16
>
> LAPIC (acpi_id[0x0002] id[0x1] enabled[1])
> CPU 2 (0x0100) enabledProcessor #1 Pentium 4(tm) XEON(tm) APIC version 16
>
> LAPIC (acpi_id[0x0003] id[0x7] enabled[1])
> CPU 3 (0x0700) enabledProcessor #7 Pentium 4(tm) XEON(tm) APIC version 16
>
> IOAPIC (id[0x2] address[0xfec00000] global_irq_base[0x0])
> IOAPIC (id[0x3] address[0xfec80000] global_irq_base[0x18])
> IOAPIC (id[0x4] address[0xfec80400] global_irq_base[0x30])
> INT_SRC_OVR (bus[0] irq[0x0] global_irq[0x2] polarity[0x1] trigger[0x1])
> INT_SRC_OVR (bus[0] irq[0x9] global_irq[0x9] polarity[0x1] trigger[0x3])
> LAPIC_NMI (acpi_id[0x0000] polarity[0x1] trigger[0x1] lint[0x1])
> LAPIC_NMI (acpi_id[0x0001] polarity[0x1] trigger[0x1] lint[0x1])
> LAPIC_NMI (acpi_id[0x0002] polarity[0x1] trigger[0x1] lint[0x1])
> LAPIC_NMI (acpi_id[0x0003] polarity[0x1] trigger[0x1] lint[0x1])
> 4 CPUs total
> Local APIC address fee00000
> __va_range(0x3fefbf88, 0x24): idx=8 mapped at ffff6000
> __va_range(0x3fefbf88, 0x28): idx=8 mapped at ffff6000
> ACPI table found: BOOT v1 [PTLTD $SBFTBL$ 1540.0]
> __va_range(0x3fefbfb0, 0x24): idx=8 mapped at ffff6000
> __va_range(0x3fefbfb0, 0x50): idx=8 mapped at ffff6000
> ACPI table found: SPCR v1 [PTLTD $UCRTBL$ 1540.0]
> Enabling the CPU's according to the ACPI table
> Intel MultiProcessor Specification v1.4
> Virtual Wire compatibility mode.
> OEM ID: Product ID: Kings Canyon APIC at: 0xFEE00000
> I/O APIC #2 Version 32 at 0xFEC00000.
> I/O APIC #3 Version 32 at 0xFEC80000.
> I/O APIC #4 Version 32 at 0xFEC80400.
> Processors: 4
> Kernel command line: ro root=LABEL=/ console=ttyS0,9600n8 nmi_watchdog=1
> [snip]
>
>
> However, when I boot the machine with the "noht" option the ACPI table
> search is skipped, _but_ it still finds 4 processors in the MP table :
>
> Linux version 2.4.20-rc2 ([email protected]) (gcc version 3.2 20020903 (Red Hat Linux 8.0 3.2-7)) #4 SMP Sat Nov 16 14:06:13 CET 2002
> BIOS-provided physical RAM map:
> BIOS-e820: 0000000000000000 - 000000000009f400 (usable)
> BIOS-e820: 000000000009f400 - 00000000000a0000 (reserved)
> BIOS-e820: 00000000000d8000 - 00000000000e0000 (reserved)
> BIOS-e820: 00000000000e4000 - 0000000000100000 (reserved)
> BIOS-e820: 0000000000100000 - 000000003fef0000 (usable)
> BIOS-e820: 000000003fef0000 - 000000003fefc000 (ACPI data)
> BIOS-e820: 000000003fefc000 - 000000003ff00000 (ACPI NVS)
> BIOS-e820: 000000003ff00000 - 000000003ff80000 (usable)
> BIOS-e820: 000000003ff80000 - 0000000040000000 (reserved)
> BIOS-e820: 00000000fec00000 - 00000000fec10000 (reserved)
> BIOS-e820: 00000000fee00000 - 00000000fee01000 (reserved)
> BIOS-e820: 00000000ff800000 - 00000000ffc00000 (reserved)
> BIOS-e820: 00000000fff00000 - 0000000100000000 (reserved)
> 127MB HIGHMEM available.
> 896MB LOWMEM available.
> found SMP MP-table at 000f7030
> hm, page 000f7000 reserved twice.
> hm, page 000f8000 reserved twice.
> hm, page 0009f000 reserved twice.
> hm, page 000a0000 reserved twice.
> On node 0 totalpages: 262016
> zone(0): 4096 pages.
> zone(1): 225280 pages.
> zone(2): 32640 pages.
> Intel MultiProcessor Specification v1.4
> Virtual Wire compatibility mode.
> OEM ID: Product ID: Kings Canyon APIC at: 0xFEE00000
> Processor #0 Pentium 4(tm) XEON(tm) APIC version 20
> Processor #6 Pentium 4(tm) XEON(tm) APIC version 20
> Processor #1 Pentium 4(tm) XEON(tm) APIC version 20
> Processor #7 Pentium 4(tm) XEON(tm) APIC version 20
> I/O APIC #2 Version 32 at 0xFEC00000.
> I/O APIC #3 Version 32 at 0xFEC80000.
> I/O APIC #4 Version 32 at 0xFEC80400.
> Processors: 4
> Kernel command line: ro root=LABEL=/ console=ttyS0,9600n8 nmi_watchdog=1 noht
>
> Since the HT feature is enabled in the BIOS it seems normal to me that 4
> processors are reported both in the MP table and in the ACPI table.
> Shouldn't the 'noht' option handle this ?
>
> I have two of these machines and can assist in testing out patches etc.

I know too little to comment definitively, but it's my understanding
that a dual HT machine should only show 2 processors in its MP table,
their siblings only appearing through analysis of the ACPI tables.

Whether it's that your MP table has been wrongly set up, or that
you've really been given 4 processors when you only asked for 2
(sue your supplier!), I cannot say. I've copied Jun at Intel
and Arjan at RedHat, and hope they can shed more light on this.

Hugh

2002-11-20 12:57:33

by Arjan van de Ven

[permalink] [raw]
Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Wed, Nov 20, 2002 at 12:53:04PM +0000, Hugh Dickins wrote:
>
> I know too little to comment definitively, but it's my understanding
> that a dual HT machine should only show 2 processors in its MP table,
> their siblings only appearing through analysis of the ACPI tables.
>
> Whether it's that your MP table has been wrongly set up, or that
> you've really been given 4 processors when you only asked for 2
> (sue your supplier!), I cannot say. I've copied Jun at Intel
> and Arjan at RedHat, and hope they can shed more light on this.

Linux has zero problem with a sane MP table that lists all
CPU's. Intel normally seems to recommend against it (maybe N3.51 doesn't
like it or so) but it's all fair as far as I'm concerned.
The bios is supposed to offer you a choice
to disable hyperthreading, use that ;)

Greetings,
Arjan van de Ven


--
But when you distribute the same sections as part of a whole which is a work
based on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the entire whole,
and thus to each and every part regardless of who wrote it. [sect.2 GPL]

2002-11-20 13:19:44

by Arjan van de Ven

[permalink] [raw]
Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2


On Wed, Nov 20, 2002 at 02:27:20PM +0100, Steffen Persvold wrote:
>
> Sure, the bios has this option (and it works). I just believed the 'noht'
> option would disable it from a kernel perspective. I understand that if
> the MP table lists 4 processors, the kernel must think it is 4 processors
> and enable them. But what is the purpose of the 'noht' option ? If it is
> to avoid scanning the ACPI table for CPUs, wouldn't it be less confusing
> to call it something like 'acpismp=disable', since you apparently can't
> disable the siblings anyway (when they are also listed in the MP table) ?

in theory we can, at least with the O(1) scheduling infrastructure
it's easy. it's just that nobody cared enough so far to do it

2002-11-20 13:17:59

by Steffen Persvold

[permalink] [raw]
Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Wed, 20 Nov 2002, Arjan van de Ven wrote:

> On Wed, Nov 20, 2002 at 12:53:04PM +0000, Hugh Dickins wrote:
> >
> > I know too little to comment definitively, but it's my understanding
> > that a dual HT machine should only show 2 processors in its MP table,
> > their siblings only appearing through analysis of the ACPI tables.
> >
> > Whether it's that your MP table has been wrongly set up, or that
> > you've really been given 4 processors when you only asked for 2
> > (sue your supplier!), I cannot say. I've copied Jun at Intel
> > and Arjan at RedHat, and hope they can shed more light on this.
>
> Linux has zero problem with a sane MP table that lists all
> CPU's. Intel normally seems to recommend against it (maybe N3.51 doesn't
> like it or so) but it's all fair as far as I'm concerned.
> The bios is supposed to offer you a choice
> to disable hyperthreading, use that ;)
>

Sure, the bios has this option (and it works). I just believed the 'noht'
option would disable it from a kernel perspective. I understand that if
the MP table lists 4 processors, the kernel must think it is 4 processors
and enable them. But what is the purpose of the 'noht' option ? If it is
to avoid scanning the ACPI table for CPUs, wouldn't it be less confusing
to call it something like 'acpismp=disable', since you apparently can't
disable the siblings anyway (when they are also listed in the MP table) ?

Regards,
--
Steffen Persvold | Scali AS
mailto:[email protected] | http://www.scali.com
Tel: (+47) 2262 8950 | Olaf Helsets vei 6
Fax: (+47) 2262 8951 | N0621 Oslo, NORWAY

2002-11-20 15:43:36

by Nakajima, Jun

[permalink] [raw]
Subject: RE: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

As Hugh pointed out, the MPS table should report the physical processors
only even if HT is enabled. The major reason is to support legacy OSes that
don't support HT well. If the BIOS has an option for you to enable/disable
HT, then please use it.

Jun

> -----Original Message-----
> From: Arjan van de Ven [mailto:[email protected]]
> Sent: Wednesday, November 20, 2002 5:04 AM
> To: Hugh Dickins
> Cc: Steffen Persvold; Jun Nakajima; Arjan van de Ven; linux-
> [email protected]
> Subject: Re: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2
>
> On Wed, Nov 20, 2002 at 12:53:04PM +0000, Hugh Dickins wrote:
> >
> > I know too little to comment definitively, but it's my understanding
> > that a dual HT machine should only show 2 processors in its MP table,
> > their siblings only appearing through analysis of the ACPI tables.
> >
> > Whether it's that your MP table has been wrongly set up, or that
> > you've really been given 4 processors when you only asked for 2
> > (sue your supplier!), I cannot say. I've copied Jun at Intel
> > and Arjan at RedHat, and hope they can shed more light on this.
>
> Linux has zero problem with a sane MP table that lists all
> CPU's. Intel normally seems to recommend against it (maybe N3.51 doesn't
> like it or so) but it's all fair as far as I'm concerned.
> The bios is supposed to offer you a choice
> to disable hyperthreading, use that ;)
>
> Greetings,
> Arjan van de Ven
>
>
> --
> But when you distribute the same sections as part of a whole which is a
> work
> based on the Program, the distribution of the whole must be on the terms
> of
> this License, whose permissions for other licensees extend to the entire
> whole,
> and thus to each and every part regardless of who wrote it. [sect.2 GPL]

2002-11-20 15:51:42

by Steffen Persvold

[permalink] [raw]
Subject: RE: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Wed, 20 Nov 2002, Nakajima, Jun wrote:

> As Hugh pointed out, the MPS table should report the physical processors
> only even if HT is enabled. The major reason is to support legacy OSes that
> don't support HT well. If the BIOS has an option for you to enable/disable
> HT, then please use it.

But since my BIOS reports 4 CPU's in the MPS table (with HT enabled), I
guess the BIOS is doing something wrong ? Should I report this to the
vendor ?

Regards,
--
Steffen Persvold | Scali AS
mailto:[email protected] | http://www.scali.com
Tel: (+47) 2262 8950 | Olaf Helsets vei 6
Fax: (+47) 2262 8951 | N0621 Oslo, NORWAY

2002-11-20 16:19:59

by Alan

[permalink] [raw]
Subject: RE: [BUG?] Xeon with HyperThreading and linux-2.4.20-rc2

On Wed, 2002-11-20 at 16:00, Steffen Persvold wrote:
> On Wed, 20 Nov 2002, Nakajima, Jun wrote:
>
> > As Hugh pointed out, the MPS table should report the physical processors
> > only even if HT is enabled. The major reason is to support legacy OSes that
> > don't support HT well. If the BIOS has an option for you to enable/disable
> > HT, then please use it.
>
> But since my BIOS reports 4 CPU's in the MPS table (with HT enabled), I
> guess the BIOS is doing something wrong ? Should I report this to the
> vendor ?

Im not sure about "wrong". Unusual perhaps. Nothing in the MPS spec
prohibits this that I can see