lkml.org 
[lkml]   [2006]   [Mar]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[patch] hrtimer remove replace state check by BUG_ON
From
Date
The rework of the hrtimer code showed a hard to track sporadic problem
on a testers machine. The !hrtimer_active check in the return path of
the timer callback function prevents requeueing of an enqueued timer.
Replace the check by a BUG_ON to get more info about this not yet
verified problem instead of hiding it away.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>

Index: linux-2.6.16-updates/kernel/hrtimer.c
===================================================================
--- linux-2.6.16-updates.orig/kernel/hrtimer.c
+++ linux-2.6.16-updates/kernel/hrtimer.c
@@ -631,9 +631,10 @@ static inline void run_hrtimer_queue(str

spin_lock_irq(&base->lock);

- if (restart != HRTIMER_NORESTART &&
- !hrtimer_active(timer))
+ if (restart != HRTIMER_NORESTART) {
+ BUG_ON(hrtimer_active(timer));
enqueue_hrtimer(timer, base);
+ }
}
set_curr_timer(base, NULL);
spin_unlock_irq(&base->lock);



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-03-12 18:00    [W:0.081 / U:23.796 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site