aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/lockdep.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-01-06 11:02:40 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2012-01-06 11:02:40 -0500
commit423d091dfe58d3109d84c408810a7cfa82f6f184 (patch)
tree43c4385d1dc7219582f924d42db1f3e203a577bd /kernel/lockdep.c
parent1483b3823542c9721eddf09a077af1e02ac96b50 (diff)
parent919b83452b2e7c1dbced0456015508b4b9585db3 (diff)
Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
* 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (64 commits) cpu: Export cpu_up() rcu: Apply ACCESS_ONCE() to rcu_boost() return value Revert "rcu: Permit rt_mutex_unlock() with irqs disabled" docs: Additional LWN links to RCU API rcu: Augment rcu_batch_end tracing for idle and callback state rcu: Add rcutorture tests for srcu_read_lock_raw() rcu: Make rcutorture test for hotpluggability before offlining CPUs driver-core/cpu: Expose hotpluggability to the rest of the kernel rcu: Remove redundant rcu_cpu_stall_suppress declaration rcu: Adaptive dyntick-idle preparation rcu: Keep invoking callbacks if CPU otherwise idle rcu: Irq nesting is always 0 on rcu_enter_idle_common rcu: Don't check irq nesting from rcu idle entry/exit rcu: Permit dyntick-idle with callbacks pending rcu: Document same-context read-side constraints rcu: Identify dyntick-idle CPUs on first force_quiescent_state() pass rcu: Remove dynticks false positives and RCU failures rcu: Reduce latency of rcu_prepare_for_idle() rcu: Eliminate RCU_FAST_NO_HZ grace-period hang rcu: Avoid needlessly IPIing CPUs at GP end ...
Diffstat (limited to 'kernel/lockdep.c')
-rw-r--r--kernel/lockdep.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/kernel/lockdep.c b/kernel/lockdep.c
index e69d633d6aa..8fb75513232 100644
--- a/kernel/lockdep.c
+++ b/kernel/lockdep.c
@@ -4181,6 +4181,28 @@ void lockdep_rcu_suspicious(const char *file, const int line, const char *s)
4181 printk("%s:%d %s!\n", file, line, s); 4181 printk("%s:%d %s!\n", file, line, s);
4182 printk("\nother info that might help us debug this:\n\n"); 4182 printk("\nother info that might help us debug this:\n\n");
4183 printk("\nrcu_scheduler_active = %d, debug_locks = %d\n", rcu_scheduler_active, debug_locks); 4183 printk("\nrcu_scheduler_active = %d, debug_locks = %d\n", rcu_scheduler_active, debug_locks);
4184
4185 /*
4186 * If a CPU is in the RCU-free window in idle (ie: in the section
4187 * between rcu_idle_enter() and rcu_idle_exit(), then RCU
4188 * considers that CPU to be in an "extended quiescent state",
4189 * which means that RCU will be completely ignoring that CPU.
4190 * Therefore, rcu_read_lock() and friends have absolutely no
4191 * effect on a CPU running in that state. In other words, even if
4192 * such an RCU-idle CPU has called rcu_read_lock(), RCU might well
4193 * delete data structures out from under it. RCU really has no
4194 * choice here: we need to keep an RCU-free window in idle where
4195 * the CPU may possibly enter into low power mode. This way we can
4196 * notice an extended quiescent state to other CPUs that started a grace
4197 * period. Otherwise we would delay any grace period as long as we run
4198 * in the idle task.
4199 *
4200 * So complain bitterly if someone does call rcu_read_lock(),
4201 * rcu_read_lock_bh() and so on from extended quiescent states.
4202 */
4203 if (rcu_is_cpu_idle())
4204 printk("RCU used illegally from extended quiescent state!\n");
4205
4184 lockdep_print_held_locks(curr); 4206 lockdep_print_held_locks(curr);
4185 printk("\nstack backtrace:\n"); 4207 printk("\nstack backtrace:\n");
4186 dump_stack(); 4208 dump_stack();