minor Suggested cleanup: RT / sched : Have RT tasks use PF_LESS_THROTTLE flag

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Group, Ingo Molnar, and Dmitry, et al,

task mm/page-writeback.c : get_dirty_limits()

Shouldn't the PF_LESS_THROTTLE flag be
scheduling class independent?

The below is a suggestion is to use the flag for
RT tasks.

-- to drop the rt_task() call within the function

if (tsk->flags & PF_LESS_THROTTLE || rt_task(tsk)) {

1) becomes
if (tsk->flags & PF_LESS_THROTTLE)

Then 
2) in kernel/sched.c set:
   p->flags |= PF_LESS_THROTTLE before the break;

case SCHED_FIFO:
case SCHED_RR:
              p->sched_class = &rt_sched_class;
              p->flags |= PF_LESS_THROTTLE;
            break;

3) Unset it in case sched class changed; before the break
case SCHED_NORMAL:
case SCHED_BATCH:
case SCHED_IDLE:
           p->sched_class = &fair_sched_class;
           p->flags &= ~PF_LESS_THROTTLE;
           break;

4) set the flag rt_mutex_setprio with braces
if (rt_prio(prio)) {
                 p->sched_class = &rt_sched_class;
                 p->flags |= PF_LESS_THROTTLE;

                 
 }      else


5) Am I missing anything?

Mitchell Erblich

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux