Comment 12 for bug 316187

Revision history for this message
Colin Ian King (colin-king) wrote :

It appears that this kind of soft lockup kernel message easily reproduced with the following code on a 2.6.24-xxx hardy server kernel inside vmware server:

#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sched.h>

void setsched(void)
{
        struct sched_param mysched;
        mysched.sched_priority = 99;

        if( sched_setscheduler( 0, SCHED_FIFO, &mysched ) == -1 ) {
                fprintf(stderr,"Cannot set sched()\n");
                exit(0);
        }
}

int main(void)
{
        setsched();

        for (;;) {
        }
        return (0);
}

Basically we get the program to hog a CPU and the kernel reports that we have a CPU hogging task with a soft lockup message.

I'm now investigating this for any fixes upstream.