Skip to content

Commit

Permalink
rcu: increment quiescent state counter in ksoftirqd()
Browse files Browse the repository at this point in the history
If a machine is flooded by network frames, a cpu can loop
100% of its time inside ksoftirqd() without calling schedule().
This can delay RCU grace period to insane values.

Adding rcu_qsctr_inc() call in ksoftirqd() solves this problem.

Paul: "This regression was a result of the recent change from
"schedule()" to "cond_resched()", which got rid of that quiescent
state in the common case where a reschedule is not needed".

Signed-off-by: Eric Dumazet <[email protected]>
Reviewed-by: Paul E. McKenney <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>
  • Loading branch information
Eric Dumazet authored and Ingo Molnar committed Mar 4, 2009
1 parent 559595a commit 64ca5ab
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions kernel/softirq.c
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,7 @@ static int ksoftirqd(void * __bind_cpu)
preempt_enable_no_resched();
cond_resched();
preempt_disable();
rcu_qsctr_inc((long)__bind_cpu);
}
preempt_enable();
set_current_state(TASK_INTERRUPTIBLE);
Expand Down

0 comments on commit 64ca5ab

Please sign in to comment.