]> git.karo-electronics.de Git - karo-tx-linux.git/commit
kernel/timer.c: use debugobjects to catch deletion of uninitialized timers
authorChristine Chan <cschan@codeaurora.org>
Wed, 5 Oct 2011 00:42:35 +0000 (11:42 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 6 Oct 2011 05:48:54 +0000 (16:48 +1100)
commit7548df9671e5011751bec38ba8bebb194d91b435
treeb622c7b5cc15bd4475b41b10f4bbc2cfb8199b64
parent1583d8a5f54b1b2eda3b8d49b03e7cd96079260e
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