summaryrefslogtreecommitdiffstats
path: root/arch/avr32/kernel/time.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-09-30 10:40:20 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2013-09-30 10:40:20 -0700
commit5c282e858f87651e97b31b99e7446aeb449f987e (patch)
treed54d80f5e19989485c97ab16d898387d21d3e6f7 /arch/avr32/kernel/time.c
parent8945546d90a748d1484872c48823f8c8ab302577 (diff)
parent395e73a278cfa3b1560b414ab93674711574ddc6 (diff)
downloadlinux-5c282e858f87651e97b31b99e7446aeb449f987e.tar.gz
linux-5c282e858f87651e97b31b99e7446aeb449f987e.tar.bz2
linux-5c282e858f87651e97b31b99e7446aeb449f987e.zip
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32
Pull AVR32 fixes from Hans-Christian Egtvedt. Fix build warnings and use the Kbuild infrastructure for generic headers rather than doing it by hand. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32: avr32: cast syscall_return to silence compiler warning avr32: fix clockevents kernel warning avr32: use Kbuild infrastructure to handle the asm-generic headers
Diffstat (limited to 'arch/avr32/kernel/time.c')
-rw-r--r--arch/avr32/kernel/time.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/arch/avr32/kernel/time.c b/arch/avr32/kernel/time.c
index 869a1c6ffeee..12f828ad5058 100644
--- a/arch/avr32/kernel/time.c
+++ b/arch/avr32/kernel/time.c
@@ -98,7 +98,14 @@ static void comparator_mode(enum clock_event_mode mode,
case CLOCK_EVT_MODE_SHUTDOWN:
sysreg_write(COMPARE, 0);
pr_debug("%s: stop\n", evdev->name);
- cpu_idle_poll_ctrl(false);
+ if (evdev->mode == CLOCK_EVT_MODE_ONESHOT ||
+ evdev->mode == CLOCK_EVT_MODE_RESUME) {
+ /*
+ * Only disable idle poll if we have forced that
+ * in a previous call.
+ */
+ cpu_idle_poll_ctrl(false);
+ }
break;
default:
BUG();