OSDN Git Service

rcu: Initialize tiny RCU stall-warning timeouts at boot
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Wed, 24 Dec 2014 05:33:14 +0000 (21:33 -0800)
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Fri, 16 Jan 2015 07:33:17 +0000 (23:33 -0800)
The current tiny RCU stall-warning code assumes that the jiffies counter
starts at zero, however, it is sometimes initialized to other values,
for example, -30,000.  This commit therefore changes rcu_init() to
invoke reset_cpu_stall_ticks() for both flavors of RCU to initialize
the stall-warning times properly at boot.

Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
kernel/rcu/tiny.c

index 0db5649..fc0f2c0 100644 (file)
@@ -383,6 +383,8 @@ EXPORT_SYMBOL_GPL(call_rcu_bh);
 void __init rcu_init(void)
 {
        open_softirq(RCU_SOFTIRQ, rcu_process_callbacks);
+       RCU_TRACE(reset_cpu_stall_ticks(&rcu_sched_ctrlblk));
+       RCU_TRACE(reset_cpu_stall_ticks(&rcu_bh_ctrlblk));
 
        rcu_early_boot_tests();
 }