local apic timer ints not working with vmware: nolocalapic arg?

From: Brian J. Murrell (brian@interlinx.bc.ca)
Date: Tue May 27 2003 - 20:06:16 EST


Hi,

Using a distribution (Mandrake's Cooker) patched kernel, I am unable to
successfully boot at 2.4.20ish kernel on VMware 2.0.4 build 1142. The
problem seems to be with using local apic timer interrupts. The last few
lines of the boot sequence before the kernel hangs are (copied by hand, so
please excuse typos):

Using local APIC timer interrupts.
calibrating APIC timer ...
..... CPU clock speed is 1658.7651 MHz.
..... host bus clock speed is 0.0000 MHz.
cpu: 0, clocks: 0, slice: 0

So, to successfully boot this kernel after hunting around, I changed:

int dont_use_local_apic_timer __initdata = 0;

to

int dont_use_local_apic_timer __initdata = 1;

in arch/i386/kernel/apic.c and it booted successfully. I noticed a
comment right at the start of setup_APIC_clocks() to short-circuit out:

/* Disabled by DMI scan or kernel option? */
if (dont_use_local_apic_timer)
return;

so I went to see if I could use the DMI scan to blacklist the VMware host
from trying to use local APIC timer interrupts. Unfortunately,
dmi_iterate() does not find the _DMI_ signature anywhere between 0xF0000
and 0xFFFFF.

So on to the other aspect of the comment "...or kernel option", but there
is no option to disable the local APIC timer. The "noapic" option appears
to disable the IO-APIC.

So is it wrong to have a kernel option to disable the local APIC timer
interrupts? Or is there a better way than a kernel option? I thought using the DMI
scan would have been great, if it worked so I am wondering if there is any
other way to get a signature on the host system and disable the local APIC
timer without the operator having to pass a command line option.

I do know that I could simply build a kernel with the CONFIG_X86_UP_APIC
to work around this problem, but that means a "special" kernel just for
VMware and also means not being able to use vendor supplied kernels, or
vendor supplied boot media (i.e. CD-ROMs).

It would be nicer to be able to disable this feature at run-time than
build-time.

Thots?

b.



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