tick/sched: Prevent false positive softirq pending warnings on RT
[sfrench/cifs-2.6.git] / kernel / time / tick-sched.c
index e10a4af887373bc8a693b750fd27ff1e2460df3f..0cc55791b2b615979f0376386ffb5133a2e6ea71 100644 (file)
@@ -973,7 +973,7 @@ static bool can_stop_idle_tick(int cpu, struct tick_sched *ts)
        if (unlikely(local_softirq_pending())) {
                static int ratelimit;
 
-               if (ratelimit < 10 &&
+               if (ratelimit < 10 && !local_bh_blocked() &&
                    (local_softirq_pending() & SOFTIRQ_STOP_IDLE_MASK)) {
                        pr_warn("NOHZ tick-stop error: Non-RCU local softirq work is pending, handler #%02x!!!\n",
                                (unsigned int) local_softirq_pending());