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.2-ck1/include/linux/sched.h =================================================================== --- linux-3.2-ck1.orig/include/linux/sched.h 2012-01-16 10:07:31.338097029 +1100 +++ linux-3.2-ck1/include/linux/sched.h 2012-01-16 10:07:32.577096941 +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.2-ck1/mm/vmscan.c =================================================================== --- linux-3.2-ck1.orig/mm/vmscan.c 2012-01-16 10:07:32.406096951 +1100 +++ linux-3.2-ck1/mm/vmscan.c 2012-01-16 10:07:32.578096942 +1100 @@ -2103,6 +2103,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;