Set the effective priority of idleprio tasks to that of nice 19 tasks when modifying vm reclaim behaviour. -ck --- --- include/linux/sched.h | 2 +- mm/vmscan.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) Index: linux-3.1-ck2/include/linux/sched.h =================================================================== --- linux-3.1-ck2.orig/include/linux/sched.h 2011-11-11 13:28:21.025507698 +1100 +++ linux-3.1-ck2/include/linux/sched.h 2011-11-11 13:28:22.121507624 +1100 @@ -39,9 +39,9 @@ #define SCHED_BATCH 3 /* SCHED_ISO: Implemented on BFS only */ #define SCHED_IDLE 5 +#define SCHED_IDLEPRIO SCHED_IDLE #ifdef CONFIG_SCHED_BFS #define SCHED_ISO 4 -#define SCHED_IDLEPRIO SCHED_IDLE #define SCHED_MAX (SCHED_IDLEPRIO) #define SCHED_RANGE(policy) ((policy) <= SCHED_MAX) #endif Index: linux-3.1-ck2/mm/vmscan.c =================================================================== --- linux-3.1-ck2.orig/mm/vmscan.c 2011-11-11 13:28:21.940507635 +1100 +++ linux-3.1-ck2/mm/vmscan.c 2011-11-11 13:28:22.121507624 +1100 @@ -2044,6 +2044,8 @@ static inline int effective_sc_prio(stru if (likely(p->mm)) { if (rt_task(p)) return -20; + if (p->policy == SCHED_IDLEPRIO) + return 19; return task_nice(p); } return 0;