lkml.org 
[lkml]   [2003]   [Aug]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] O13.1int
Date
A heck of a lot fairer on disk only tasks; lets them earn sleep avg up to just 
interactive state so they stay on the active array.

Con

--- linux-2.6.0-test2-mm4-O13/kernel/sched.c 2003-08-05 10:08:15.000000000 +1000
+++ linux-2.6.0-test2-mm4-O13.1/kernel/sched.c 2003-08-05 09:58:55.000000000 +1000
@@ -584,13 +584,16 @@ repeat_lock_task:
goto repeat_lock_task;
}
if (old_state == TASK_UNINTERRUPTIBLE){
+ rq->nr_uninterruptible--;
/*
* Tasks on involuntary sleep don't earn
- * sleep_avg
+ * sleep_avg beyond just interactive state.
*/
- rq->nr_uninterruptible--;
- p->timestamp = sched_clock();
- p->activated = -1;
+ if (NS_TO_JIFFIES(p->sleep_avg) >=
+ JUST_INTERACTIVE_SLEEP(p)){
+ p->timestamp = sched_clock();
+ p->activated = -1;
+ }
}
if (sync)
__activate_task(p, rq);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

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