pre-2.1.116-1 breaks Cyrix 6x86 support

Rafael Reilova (rreilova@ececs.uc.edu)
Mon, 10 Aug 1998 03:37:32 -0400 (EDT)


Hi Linus,

Even with the patch I previously posted the 6x86(L) breaks.
GCC is reordering the inb()-outb() macros around the Cyrix code.

The line in bugs.h, check_cx686_cpuid_slop()

setCx86(CX86_CCR4, getCx86(CX86_CCR4) | 0x80); /* enable cpuid */

becomes (under 2.7.2.3 & 2.8.1),

#NO_APP
movb $232,%al /* 232 == CX86_CCR4 */
#APP
outb %al,$34
outb %al,$34 <-- this is wrong, after an access to 0x22, we
inb $35,%al must access 0x23 or an external cycle is
#NO_APP generated.
orb $128,%al
#APP
outb %al,$35 <-- same problem here, 0x23 requires a previous
#NO_APP access to 0x22. This is going outside.

Worst of all, this is the part of the code which enables cpuid, after this
we use it, and will receive an illegal instruction fault.

If there is no way to force gcc to keep the order right (in all cases),
could we keep the fixed inline asm functions for setC6x86() and getC6x86()
I sent you and leave this alone, (please!).

Cheers,

Rafael

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html