linux/kernel/time
Viresh Kumar a9d20988ac clockevents: Check state instead of mode in suspend/resume path
CLOCK_EVT_MODE_* macros are present for backward compatibility (as most
of the drivers are still using old ->set_mode() interface).

These macro's shouldn't be used anymore in code, that is common to both
driver interfaces, i.e. ->set_mode() and ->set_state_*().

Drivers implementing ->set_state_*() interface, which have their
clkevt->mode set to 0 (clkevt device structures are normally globally
defined), will not participate in suspend/resume as they will always be
marked as UNUSED.

Fix this by checking state of the clockevent device instead of mode,
which is updated for both the interfaces.

Fixes: ac34ad27fc ("clockevents: Do not suspend/resume if unused")
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Cc: linaro-kernel@lists.linaro.org
Cc: alexandre.belloni@free-electrons.com
Cc: sylvain.rochet@finsecur.com
Link: http://lkml.kernel.org/r/a1964eef6e8a47d02b1ff9083c6c91f73f0ff643.1434537215.git.viresh.kumar@linaro.org
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2015-06-18 09:27:02 +02:00
..
alarmtimer.c alarmtimer: Get rid of unused return value 2015-04-22 17:06:52 +02:00
clockevents.c clockevents: Check state instead of mode in suspend/resume path 2015-06-18 09:27:02 +02:00
clocksource.c clocksource: Use current logging style 2015-06-10 11:31:14 +02:00
hrtimer.c clockevents: Stop unused clockevent devices 2015-05-19 16:18:11 +02:00
itimer.c time/timers: Move all time(r) related files into kernel/time 2014-06-23 11:22:35 +02:00
jiffies.c tick: Move clocksource related stuff to timekeeping.h 2015-04-01 14:22:58 +02:00
Kconfig clockevents: Remove CONFIG_GENERIC_CLOCKEVENTS_BUILD 2015-04-01 14:22:57 +02:00
Makefile time: Move timeconst.h into include/generated 2015-05-19 15:13:45 +02:00
ntp.c ntp: Do leapsecond adjustment in adjtimex read path 2015-06-12 11:15:49 +02:00
ntp_internal.h time: Prevent early expiry of hrtimers[CLOCK_REALTIME] at the leap second edge 2015-06-12 11:15:49 +02:00
posix-clock.c kernel: Fix files explicitly needing EXPORT_SYMBOL infrastructure 2011-10-31 19:30:05 -04:00
posix-cpu-timers.c all arches, signal: move restart_block to struct task_struct 2015-02-12 18:54:12 -08:00
posix-timers.c hrtimer: Get rid of hrtimer_get_res() 2015-04-22 17:06:49 +02:00
sched_clock.c timers, sched/clock: Clean up the code a bit 2015-03-27 08:34:01 +01:00
test_udelay.c time: Rename udelay_test.c to test_udelay.c 2014-11-21 11:59:55 -08:00
tick-broadcast-hrtimer.c tick: hrtimer-broadcast: Prevent endless restarting when broadcast device is unused 2015-05-05 15:34:21 +02:00
tick-broadcast.c clockevents: Provide functions to set and get the state 2015-06-02 14:40:47 +02:00
tick-common.c clockevents: Use set/get state helper functions 2015-06-02 14:40:48 +02:00
tick-internal.h clockevents: Rename state to state_use_accessors 2015-06-02 16:56:42 +02:00
tick-oneshot.c clockevents: Provide functions to set and get the state 2015-06-02 14:40:47 +02:00
tick-sched.c nohz: Fix !HIGH_RES_TIMERS hang 2015-05-07 16:15:50 +02:00
tick-sched.h tick: Nohz: Rework next timer evaluation 2015-04-22 17:06:50 +02:00
time.c time: Refactor usecs_to_jiffies 2015-06-10 11:31:13 +02:00
timeconst.bc time: Move timeconst.h into include/generated 2015-05-19 15:13:45 +02:00
timeconv.c time: add function to convert between calendar time and broken-down time for universal use 2009-09-24 07:20:56 -07:00
timecounter.c timecounter: keep track of accumulated fractional nanoseconds 2014-12-30 18:29:27 -05:00
timekeeping.c time: Prevent early expiry of hrtimers[CLOCK_REALTIME] at the leap second edge 2015-06-12 11:15:49 +02:00
timekeeping.h hrtimer: Make offset update smarter 2015-04-22 17:06:49 +02:00
timekeeping_debug.c timekeeping: Convert timekeeping core to use timespec64s 2014-07-23 10:17:54 -07:00
timekeeping_internal.h clocksource: Move cycle_last validation to core code 2014-07-23 15:01:51 -07:00
timer.c tracing: timer: Add deferrable flag to timer_start 2015-05-22 10:36:06 -07:00
timer_list.c clockevents: Introduce CLOCK_EVT_STATE_ONESHOT_STOPPED state 2015-05-19 16:18:02 +02:00
timer_stats.c timer stats: Add a 'Collection: active/inactive' line to timer usage statistics 2013-10-10 09:59:25 +02:00