]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
kernel/timer.c: use debugobjects to catch deletion of uninitialized timers
authorChristine Chan <cschan@codeaurora.org>
Tue, 8 Nov 2011 00:20:02 +0000 (11:20 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 8 Nov 2011 03:15:51 +0000 (14:15 +1100)
commit3f30af1f4d96c6e46c4302160584a28f92d2eee2
treeb1270b04df9e909b44cb5dfdc95c3159838b2446
parentd3959eb353e63766f68fa75b228e4c9cc068a34b
kernel/timer.c: use debugobjects to catch deletion of uninitialized timers

del_timer_sync() calls debug_object_assert_init() to assert that a timer
has been initialized before calling lock_timer_base().  lock_timer_base()
would spin forever on a NULL(uninit-ed) base.  The check is added to
del_timer() to prevent silent failure, even though it would not get stuck
in an infinite loop.

Signed-off-by: Christine Chan <cschan@codeaurora.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: John Stultz <john.stultz@linaro.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
kernel/timer.c