diff options
author | Rik van Riel <riel@redhat.com> | 2014-04-27 02:15:35 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-05-19 13:52:04 -0400 |
commit | 61f38db3e3c0e4c3be0858750e2cabeadaecac0c (patch) | |
tree | 5ded19f41e8ceb49a55b2942fb0a5774a95126d1 /kernel/rcu | |
parent | e534165bbf6a04d001748c573c7d6a7bae3713a5 (diff) |
rcu: Provide API to suppress stall warnings while sysrc runs
Some sysrq handlers can run for a long time, because they dump a lot
of data onto a serial console. Having RCU stall warnings pop up in
the middle of them only makes the problem worse.
This commit provides rcu_sysrq_start() and rcu_sysrq_end() APIs to
temporarily suppress RCU CPU stall warnings while a sysrq request is
handled.
Signed-off-by: Rik van Riel <riel@redhat.com>
[ paulmck: Fix TINY_RCU build error. ]
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Diffstat (limited to 'kernel/rcu')
-rw-r--r-- | kernel/rcu/update.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/kernel/rcu/update.c b/kernel/rcu/update.c index ed7a0d72562c..a2aeb4df0f60 100644 --- a/kernel/rcu/update.c +++ b/kernel/rcu/update.c | |||
@@ -320,6 +320,18 @@ int rcu_jiffies_till_stall_check(void) | |||
320 | return till_stall_check * HZ + RCU_STALL_DELAY_DELTA; | 320 | return till_stall_check * HZ + RCU_STALL_DELAY_DELTA; |
321 | } | 321 | } |
322 | 322 | ||
323 | void rcu_sysrq_start(void) | ||
324 | { | ||
325 | if (!rcu_cpu_stall_suppress) | ||
326 | rcu_cpu_stall_suppress = 2; | ||
327 | } | ||
328 | |||
329 | void rcu_sysrq_end(void) | ||
330 | { | ||
331 | if (rcu_cpu_stall_suppress == 2) | ||
332 | rcu_cpu_stall_suppress = 0; | ||
333 | } | ||
334 | |||
323 | static int rcu_panic(struct notifier_block *this, unsigned long ev, void *ptr) | 335 | static int rcu_panic(struct notifier_block *this, unsigned long ev, void *ptr) |
324 | { | 336 | { |
325 | rcu_cpu_stall_suppress = 1; | 337 | rcu_cpu_stall_suppress = 1; |