]> 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>
Wed, 16 Nov 2011 23:41:11 +0000 (10:41 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 17 Nov 2011 02:53:23 +0000 (13:53 +1100)
commitc2d9cce7c161a1f08ce57e6b3a8b594dc171b9fe
tree3b504a142812e1cbcfd6a608b29b377076f32239
parent181984b8f18ddebb1e0d00288b580f02004dd074
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.

[sboyd@codeaurora.org: remove WARN, intialize timer function]
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>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
kernel/timer.c