public inbox for linux-rt-users@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH RT] timer: Run irq_work() even if there are no active timers
@ 2014-01-24 19:51 Steven Rostedt
  2014-01-24 20:09 ` [PATCH RT v2] timer: Raise softirq if there's irq_work Steven Rostedt
  0 siblings, 1 reply; 7+ messages in thread
From: Steven Rostedt @ 2014-01-24 19:51 UTC (permalink / raw)
  To: LKML, linux-rt-users
  Cc: Thomas Gleixner, Sebastian Andrzej Siewior, Clark Williams,
	Luis Claudio R. Goncalves, John Kacur, Mike Galbraith,
	Joakim Hernberg, Joe Korty, Muli Baron

After trying hard to figure out why my i7 box was locking up with the
new active_timers code, that does not run the timer softirq if there
are no active timers, I took an extra look at the softirq handler and
noticed that it doesn't just run timer softirqs, it also runs irq work.

This was the bug that was locking up the system. It wasn't missing a
timer, it was missing irq work. By always doing the irq work callbacks,
the system boots fine.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

diff --git a/kernel/timer.c b/kernel/timer.c
index 46467be..7c5026e 100644
--- a/kernel/timer.c
+++ b/kernel/timer.c
@@ -1464,8 +1464,12 @@ void run_local_timers(void)
 		raise_softirq(TIMER_SOFTIRQ);
 		return;
 	}
-	if (!base->active_timers)
+	if (!base->active_timers) {
+#if defined(CONFIG_IRQ_WORK) && defined(CONFIG_PREEMPT_RT_FULL)
+		irq_work_run();
+#endif
 		goto out;
+	}
 
 	/* Check whether the next pending timer has expired */
 	if (time_before_eq(base->next_timer, jiffies))

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-01-25  2:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-24 19:51 [PATCH RT] timer: Run irq_work() even if there are no active timers Steven Rostedt
2014-01-24 20:09 ` [PATCH RT v2] timer: Raise softirq if there's irq_work Steven Rostedt
2014-01-24 20:20   ` Sebastian Andrzej Siewior
2014-01-24 20:35     ` Steven Rostedt
2014-01-24 20:42       ` Sebastian Andrzej Siewior
2014-01-25  0:19       ` Paul E. McKenney
2014-01-25  2:16         ` Steven Rostedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox