]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
x86: fix setup code crashes on my old 486 box
authorJoerg Roedel <joro@8bytes.org>
Sun, 17 Aug 2008 00:25:07 +0000 (00:25 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 20 Aug 2008 18:05:13 +0000 (11:05 -0700)
commit66b53f4d3bf219053afa58c88c80a388131fd6df
treebefb9dfb01bece7ac492cb8527412ae87b24b949
parenta6582aa43703213e727161911938db89c511aa57
x86: fix setup code crashes on my old 486 box

commit 7b27718bdb1b70166383dec91391df5534d449ee upstream

yesterday I tried to reactivate my old 486 box and wanted to install a
current Linux with latest kernel on it. But it turned out that the
latest kernel does not boot because the machine crashes early in the
setup code.

After some debugging it turned out that the problem is the query_ist()
function. If this interrupt with that function is called the machine
simply locks up. It looks like a BIOS bug. Looking for a workaround for
this problem I wrote the attached patch. It checks for the CPUID
instruction and if it is not implemented it does not call the speedstep
BIOS function. As far as I know speedstep should be available since some
Pentium earliest.

Alan Cox observed that it's available since the Pentium II, so cpuid
levels 4 and 5 can be excluded altogether.

H. Peter Anvin cleaned up the code some more:

> Right in concept, but I dislike the implementation (duplication of the
> CPU detect code we already have).  Could you try this patch and see if
> it works for you?

which, with a small modification to fix a build error with it the
resulting kernel boots on my machine.

Signed-off-by: Joerg Roedel <joro@8bytes.org>
Signed-off-by: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
arch/x86/boot/boot.h
arch/x86/boot/cpucheck.c
arch/x86/boot/main.c