]> git.baikalelectronics.ru Git - kernel.git/commit
[ARM] pxa: fix one-shot timer mode
authorRussell King <rmk@dyn-67.arm.linux.org.uk>
Thu, 8 Nov 2007 23:35:46 +0000 (23:35 +0000)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Thu, 8 Nov 2007 23:35:46 +0000 (23:35 +0000)
commit2d2d315fd358eebbadd845e9d663f9058e0728ec
tree35acc012af09a987364f39d0a5ccda7c4be35a3e
parent63d4961443f292bb3d3c4a273f8bcd1ecc306947
[ARM] pxa: fix one-shot timer mode

One-shot timer mode on PXA has various bugs which prevent kernels
build with NO_HZ enabled booting.  They end up spinning on a
permanently asserted timer interrupt because we don't properly
clear it down - clearing the OIER bit does not stop the pending
interrupt status.  Fix this in the set_mode handler as well.

Moreover, the code which sets the next expiry point may race with
the hardware, and we might not set the match register sufficiently
in the future.  If we encounter that situation, return -ETIME so
the generic time code retries.

Acked-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/mach-pxa/time.c