lkml.org 
[lkml]   [1997]   [Jul]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: question re: scheduling policies
Adam Mckee wrote:
>
> Hello all. I am new to the wacky world of kernel hacking, so this
> question may be silly, but...
>
> In kernel/sched.c:goodness(), I am puzzled by the following:
>
> /*
> * Realtime process, select the first one on the
> * runqueue (taking priorities within processes
> * into account).
> */
> if (p->policy != SCHED_OTHER)
> return 1000 + p->rt_priority;
>
> I thought SCHED_OTHER *was* real-time... this snippet implies that
> SCHED_RR and SCHED_FIFO are real-time. Is this true?
>

SCHED_RR is Round Robin and SCHED_FIFO is First In, First Out: both
are real time scheduling policies. The give away is that the 'rt_'
fields are only used by the "real time" processes. Basically they
add weight so that they get selected before other, non-real time,
processes by the scheduler.


> Thanks for your help!
>
> -- Adam

--
----------------------------------------------------------------------
David A Rusling Principal Engineer
European Semiconductor Applications Digital Equipment Co Ltd.,
Engineering PO Box 121,
Imperial Way,
Worton Grange
Reading RG2 0TU
Linux, Alpha, StrongArm, PCI Tel: UK-(0)1734-204380
Fax: UK-(0)1734-203133
----------------------------------------------------------------------

\
 
 \ /
  Last update: 2005-03-22 13:39    [W:0.061 / U:0.580 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site