]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Merge remote-tracking branch 'rcu/rcu/next'
authorStephen Rothwell <sfr@canb.auug.org.au>
Tue, 27 Sep 2011 05:20:33 +0000 (15:20 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 27 Sep 2011 05:20:33 +0000 (15:20 +1000)
Conflicts:
arch/x86/kernel/cpu/mcheck/mce.c
arch/x86/kernel/process_64.c

22 files changed:
1  2 
arch/arm/kernel/process.c
arch/blackfin/kernel/process.c
arch/microblaze/kernel/process.c
arch/mips/kernel/process.c
arch/s390/kernel/process.c
arch/sh/kernel/idle.c
arch/um/kernel/process.c
arch/x86/kernel/apic/apic.c
arch/x86/kernel/apic/io_apic.c
arch/x86/kernel/process_32.c
arch/x86/kernel/process_64.c
include/linux/rcupdate.h
include/linux/sched.h
init/Kconfig
kernel/lockdep.c
kernel/pid.c
kernel/rcupdate.c
kernel/rcutorture.c
kernel/rcutree_trace.c
kernel/rtmutex.c
kernel/sched.c
kernel/time/tick-sched.c

Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index 2196c703c5e2e0700bb3f354890b35a6ef99221a,8c2faa9d2c4ec2e563312b5b616dc1a37854773e..fed222fef37a70b43fe9e01cf50107d004b7484b
@@@ -110,11 -109,10 +110,11 @@@ void cpu_idle(void
                        local_irq_disable();
                        /* Don't trace irqs off for idle */
                        stop_critical_timings();
 -                      pm_idle();
 +                      if (cpuidle_idle_call())
 +                              pm_idle();
                        start_critical_timings();
                }
-               tick_nohz_restart_sched_tick();
+               tick_nohz_idle_exit();
                preempt_enable_no_resched();
                schedule();
                preempt_disable();
index f693e44e1bf63a303a3e53a00d927721e6602e86,dee2e6ccbe66794211205cba409945d9f0e26c44..0a15dec5f3fd31a82ecb147a19e1526e1d28559b
@@@ -137,8 -136,12 +137,14 @@@ void cpu_idle(void
                        enter_idle();
                        /* Don't trace irqs off for idle */
                        stop_critical_timings();
-                       if (cpuidle_idle_call())
 -                      /* enter_idle() needs rcu for notifiers */
 -                      rcu_enter_nohz();
 -                      pm_idle();
 -                      rcu_exit_nohz();
++                      if (cpuidle_idle_call()) {
++                              /* enter_idle() needs rcu for notifiers */
++                              rcu_enter_nohz();
 +                              pm_idle();
++                              rcu_exit_nohz();
++                      }
                        start_critical_timings();
  
                        /* In many cases the interrupt that ended idle
index 8f4f881a0ad8153dd82150745aee03881448a3b0,9d40e425d46c8206019d57566bcb49c7b2406d97..ea9bc708ccef2a6e5448c52cb372a56f4f7160f2
@@@ -238,8 -313,18 +313,18 @@@ extern int rcu_read_lock_bh_held(void)
   *
   * Check debug_lockdep_rcu_enabled() to prevent false positives during boot
   * and while lockdep is disabled.
+  *
+  * Note that if the CPU is in an extended quiescent state, for example,
+  * if the CPU is in dyntick-idle mode, then rcu_read_lock_held() returns
+  * false even if the CPU did an rcu_read_lock().  The reason for this is
+  * that RCU ignores CPUs that are in extended quiescent states, so such
+  * a CPU is effectively never in an RCU read-side critical section
+  * regardless of what RCU primitives it invokes.  This state of affairs
+  * is required -- RCU would otherwise need to periodically wake up
+  * dyntick-idle CPUs, which would defeat the whole purpose of dyntick-idle
+  * mode.
   */
 -#ifdef CONFIG_PREEMPT
 +#ifdef CONFIG_PREEMPT_COUNT
  static inline int rcu_read_lock_sched_held(void)
  {
        int lockdep_opinion = 0;
Simple merge
diff --cc init/Kconfig
Simple merge
Simple merge
diff --cc kernel/pid.c
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc kernel/sched.c
index 3d82a55d6654c7f0e98fa33b9342ad7277fe2eef,313c0f63e29a9b36b47b11e7f284f8482fd3580f..29d686d77dee8672604b3c5c4ddaaa4aec0a6338
@@@ -8372,8 -8185,10 +8362,9 @@@ static inline int preempt_count_equals(
  
  void __might_sleep(const char *file, int line, int preempt_offset)
  {
 -#ifdef in_atomic
        static unsigned long prev_jiffy;        /* ratelimiting */
  
+       rcu_sleep_check(); /* WARN_ON_ONCE() by default, no rate limit reqd. */
        if ((preempt_count_equals(preempt_offset) && !irqs_disabled()) ||
            system_state != SYSTEM_RUNNING || oops_in_progress)
                return;
Simple merge