[Cbe-oss-dev] [PATCH 3/6] spufs: fix starvation case with terminated spes
Luke Browning
lukebr at linux.vnet.ibm.com
Sat Feb 16 00:39:07 EST 2008
On Fri, 2008-02-15 at 10:41 -0200, Luke Browning wrote:
> On Fri, 2008-02-15 at 12:55 +0100, Arnd Bergmann wrote:
> >
> > Wouldn't it be sufficient to lower the priority of a nonrunning context
> > to the minimum? We set it in __spu_update_sched_info() when entering
> > spu_run, so it would be logical to reset the priority when leaving there.
> >
> > Arnd <><
>
> That is worth prototyping. I will try it out.
Its ugly. We would have to add a priority level, since the scheduler
doesn't preempt contexts at the same level. We also have the issue of
what to do with the context once it is preempted. The scheduler is
currently coded to put preempted contexts back on the runqueue, but this
breaks things as the context cannot be on the runqueue when it is in
user mode. Not only do we hit the assert when we re-enter spu_run(),
but more importantly it could be scheduled as it is on the runqueue.
Luke
More information about the cbe-oss-dev
mailing list