@@ -28,27 +28,6 @@ enum clock_event_mode {
};
/*
- * Possible states of a clock event device.
- *
- * DETACHED: Device is not used by clockevents core. Initial state or can be
- * reached from SHUTDOWN.
- * SHUTDOWN: Device is powered-off. Can be reached from PERIODIC or ONESHOT.
- * PERIODIC: Device is programmed to generate events periodically. Can be
- * reached from DETACHED or SHUTDOWN.
- * ONESHOT: Device is programmed to generate event only once. Can be reached
- * from DETACHED or SHUTDOWN.
- * ONESHOT_STOPPED: Device was programmed in ONESHOT mode and is temporarily
- * stopped.
- */
-enum clock_event_state {
- CLOCK_EVT_STATE_DETACHED,
- CLOCK_EVT_STATE_SHUTDOWN,
- CLOCK_EVT_STATE_PERIODIC,
- CLOCK_EVT_STATE_ONESHOT,
- CLOCK_EVT_STATE_ONESHOT_STOPPED,
-};
-
-/*
* Clock event features
*/
# define CLOCK_EVT_FEAT_PERIODIC 0x000001
@@ -117,7 +96,7 @@ struct clock_event_device {
u32 mult;
u32 shift;
enum clock_event_mode mode;
- enum clock_event_state state;
+ unsigned int state;
unsigned int features;
unsigned long retries;
@@ -12,6 +12,27 @@
# define TICK_DO_TIMER_NONE -1
# define TICK_DO_TIMER_BOOT -2
+/*
+ * Possible states of a clock event device.
+ *
+ * DETACHED: Device is not used by clockevents core. Initial state or can be
+ * reached from SHUTDOWN.
+ * SHUTDOWN: Device is powered-off. Can be reached from PERIODIC or ONESHOT.
+ * PERIODIC: Device is programmed to generate events periodically. Can be
+ * reached from DETACHED or SHUTDOWN.
+ * ONESHOT: Device is programmed to generate event only once. Can be reached
+ * from DETACHED or SHUTDOWN.
+ * ONESHOT_STOPPED: Device was programmed in ONESHOT mode and is temporarily
+ * stopped.
+ */
+enum clock_event_state {
+ CLOCK_EVT_STATE_DETACHED,
+ CLOCK_EVT_STATE_SHUTDOWN,
+ CLOCK_EVT_STATE_PERIODIC,
+ CLOCK_EVT_STATE_ONESHOT,
+ CLOCK_EVT_STATE_ONESHOT_STOPPED,
+};
+
DECLARE_PER_CPU(struct tick_device, tick_cpu_device);
extern ktime_t tick_next_period;
extern ktime_t tick_period;
CLOCK_EVT_STATE_* symbols are local to the kernel/time and shouldn't be exposed to other parts of the kernel. They were added to clockchips.h as there was one external user (arch/arm/common/bL_switcher.c). That is modified now to not use these symbols directly: 7270d11c56f5 ("arm/bL_switcher: Kill tick suspend hackery") We can now move them to a file local to kernel/time. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> --- include/linux/clockchips.h | 23 +---------------------- kernel/time/tick-internal.h | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+), 22 deletions(-)