It worked like a charm by puttng a "sleep(2)" between the
prctl call and the call to sched_setscheduler().
I have a fe more features I'd like to add, but I hope
to have something concrete out by the end of the weekend.
john.c
---------- Original Message -------------------
From: Dimitris Michailidis <dimitris@xxxxxxxxxxxxxxxxxxxx>
Date: Mon, 14 Aug 2000 21:50:39 -0700 (PDT)
>
>Heh. I think I know what's doing this. There's a bug in the
current
>scheduler that allows a runnable process to be considered for
scheduling by
>its current CPU even if it can no longer run on this CPU.
Basically this
>means that if you try to pin a process to a CPU other than its
current this
>will not take effect until the CPU is taken away from the
process somehow
>(sleeping, preemption). With a SCHED_FIFO it won't get
preempted and I
>suppose it doesn't sleep either so you're out of luck. Try
having the
>process sleep for a moment and see if it behaves.
>
>--
>Dimitris Michailidis dimitris@xxxxxxxxxxxx
>
|