Magellan Linux

Annotation of /trunk/kernel26-magellan/patches-2.6.20-r5/0009-2.6.20-sched-make_softirqd_batch.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 133 - (hide annotations) (download)
Fri Apr 27 15:25:13 2007 UTC (17 years, 1 month ago) by niro
File size: 1040 byte(s)
files for 2.6.20-r5

1 niro 133 Instead of 'nice'ing ksoftirqd we can use the policy hint of SCHED_BATCH which
2     specifies it as not requiring low latency. This increases the cpu use possible
3     under very heavy softirq traffic (such as network loads) and decreases the
4     latency that might otherwise be seen (such as keyboard input under heavy cpu
5     load on slow machines).
6    
7     Signed-off-by: Con Kolivas <kernel@kolivas.org>
8    
9     ---
10     kernel/softirq.c | 4 +++-
11     1 file changed, 3 insertions(+), 1 deletion(-)
12    
13     Index: linux-2.6.20-ck1/kernel/softirq.c
14     ===================================================================
15     --- linux-2.6.20-ck1.orig/kernel/softirq.c 2007-02-05 22:52:04.000000000 +1100
16     +++ linux-2.6.20-ck1/kernel/softirq.c 2007-02-16 19:01:31.000000000 +1100
17     @@ -469,7 +469,9 @@ void __init softirq_init(void)
18    
19     static int ksoftirqd(void * __bind_cpu)
20     {
21     - set_user_nice(current, 19);
22     + struct sched_param param = { .sched_priority = 0 };
23     +
24     + sched_setscheduler(current, SCHED_BATCH, &param);
25     current->flags |= PF_NOFREEZE;
26    
27     set_current_state(TASK_INTERRUPTIBLE);