]> git.karo-electronics.de Git - karo-tx-linux.git/commit
hrtimer: catch expired CLOCK_REALTIME timers early
authorThomas Gleixner <tglx@linutronix.de>
Wed, 20 Feb 2008 00:04:56 +0000 (01:04 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 26 Feb 2008 00:18:57 +0000 (16:18 -0800)
commit4813a83f2665f7276f1e4eee9cffe45116cf3824
treec90ab757087895606343902813d0c563a9df88bf
parent85d1617924607c1311962546bb55367b9edb4ca6
hrtimer: catch expired CLOCK_REALTIME timers early

commit 63070a79ba482c274bad10ac8c4b587a3e011f2c

A CLOCK_REALTIME timer, which has an absolute expiry time less than
the clock realtime offset calls with a negative delta into the clock
events code and triggers the WARN_ON() there.

This is a false positive and needs to be prevented. Check the result
of timer->expires - timer->base->offset right away and return -ETIME
right away.

Thanks to Frans Pop, who reported the problem and tested the fixes.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Frans Pop <elendil@planet.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
kernel/hrtimer.c