diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2013-04-03 06:27:29 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2013-04-03 06:27:29 -0400 |
commit | 0ed2aef9b3bffe598045b62a31a50d912eee92d8 (patch) | |
tree | d7dda12955c838f531727d2775d09c4e04bdf066 /include | |
parent | cfea7d7e452f57682a0bb55a55e9f79c569558c2 (diff) | |
parent | 8011657b9e63cb2e914b9a0f75233b910c1854cb (diff) |
Merge branch 'fortglx/3.10/time' of git://git.linaro.org/people/jstultz/linux into timers/core
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/clocksource.h | 1 | ||||
-rw-r--r-- | include/linux/hrtimer.h | 5 | ||||
-rw-r--r-- | include/linux/jiffies.h | 1 | ||||
-rw-r--r-- | include/linux/time.h | 3 | ||||
-rw-r--r-- | include/linux/timekeeper_internal.h | 7 | ||||
-rw-r--r-- | include/uapi/linux/time.h | 6 |
6 files changed, 15 insertions, 8 deletions
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h index 27cfda427dd9..aa7032c7238f 100644 --- a/include/linux/clocksource.h +++ b/include/linux/clocksource.h | |||
@@ -206,6 +206,7 @@ struct clocksource { | |||
206 | #define CLOCK_SOURCE_WATCHDOG 0x10 | 206 | #define CLOCK_SOURCE_WATCHDOG 0x10 |
207 | #define CLOCK_SOURCE_VALID_FOR_HRES 0x20 | 207 | #define CLOCK_SOURCE_VALID_FOR_HRES 0x20 |
208 | #define CLOCK_SOURCE_UNSTABLE 0x40 | 208 | #define CLOCK_SOURCE_UNSTABLE 0x40 |
209 | #define CLOCK_SOURCE_SUSPEND_NONSTOP 0x80 | ||
209 | 210 | ||
210 | /* simplify initialization of mask field */ | 211 | /* simplify initialization of mask field */ |
211 | #define CLOCKSOURCE_MASK(bits) (cycle_t)((bits) < 64 ? ((1ULL<<(bits))-1) : -1) | 212 | #define CLOCKSOURCE_MASK(bits) (cycle_t)((bits) < 64 ? ((1ULL<<(bits))-1) : -1) |
diff --git a/include/linux/hrtimer.h b/include/linux/hrtimer.h index cc07d2777bbe..d19a5c2d2270 100644 --- a/include/linux/hrtimer.h +++ b/include/linux/hrtimer.h | |||
@@ -157,6 +157,7 @@ enum hrtimer_base_type { | |||
157 | HRTIMER_BASE_MONOTONIC, | 157 | HRTIMER_BASE_MONOTONIC, |
158 | HRTIMER_BASE_REALTIME, | 158 | HRTIMER_BASE_REALTIME, |
159 | HRTIMER_BASE_BOOTTIME, | 159 | HRTIMER_BASE_BOOTTIME, |
160 | HRTIMER_BASE_TAI, | ||
160 | HRTIMER_MAX_CLOCK_BASES, | 161 | HRTIMER_MAX_CLOCK_BASES, |
161 | }; | 162 | }; |
162 | 163 | ||
@@ -327,7 +328,9 @@ extern ktime_t ktime_get(void); | |||
327 | extern ktime_t ktime_get_real(void); | 328 | extern ktime_t ktime_get_real(void); |
328 | extern ktime_t ktime_get_boottime(void); | 329 | extern ktime_t ktime_get_boottime(void); |
329 | extern ktime_t ktime_get_monotonic_offset(void); | 330 | extern ktime_t ktime_get_monotonic_offset(void); |
330 | extern ktime_t ktime_get_update_offsets(ktime_t *offs_real, ktime_t *offs_boot); | 331 | extern ktime_t ktime_get_clocktai(void); |
332 | extern ktime_t ktime_get_update_offsets(ktime_t *offs_real, ktime_t *offs_boot, | ||
333 | ktime_t *offs_tai); | ||
331 | 334 | ||
332 | DECLARE_PER_CPU(struct tick_device, tick_cpu_device); | 335 | DECLARE_PER_CPU(struct tick_device, tick_cpu_device); |
333 | 336 | ||
diff --git a/include/linux/jiffies.h b/include/linux/jiffies.h index 82ed068b1ebe..8fb8edf12417 100644 --- a/include/linux/jiffies.h +++ b/include/linux/jiffies.h | |||
@@ -75,7 +75,6 @@ extern int register_refined_jiffies(long clock_tick_rate); | |||
75 | */ | 75 | */ |
76 | extern u64 __jiffy_data jiffies_64; | 76 | extern u64 __jiffy_data jiffies_64; |
77 | extern unsigned long volatile __jiffy_data jiffies; | 77 | extern unsigned long volatile __jiffy_data jiffies; |
78 | extern seqlock_t jiffies_lock; | ||
79 | 78 | ||
80 | #if (BITS_PER_LONG < 64) | 79 | #if (BITS_PER_LONG < 64) |
81 | u64 get_jiffies_64(void); | 80 | u64 get_jiffies_64(void); |
diff --git a/include/linux/time.h b/include/linux/time.h index d4835dfdf25e..22d81b3c955b 100644 --- a/include/linux/time.h +++ b/include/linux/time.h | |||
@@ -181,6 +181,9 @@ extern struct timespec timespec_trunc(struct timespec t, unsigned gran); | |||
181 | extern int timekeeping_valid_for_hres(void); | 181 | extern int timekeeping_valid_for_hres(void); |
182 | extern u64 timekeeping_max_deferment(void); | 182 | extern u64 timekeeping_max_deferment(void); |
183 | extern int timekeeping_inject_offset(struct timespec *ts); | 183 | extern int timekeeping_inject_offset(struct timespec *ts); |
184 | extern s32 timekeeping_get_tai_offset(void); | ||
185 | extern void timekeeping_set_tai_offset(s32 tai_offset); | ||
186 | extern void timekeeping_clocktai(struct timespec *ts); | ||
184 | 187 | ||
185 | struct tms; | 188 | struct tms; |
186 | extern void do_sys_times(struct tms *); | 189 | extern void do_sys_times(struct tms *); |
diff --git a/include/linux/timekeeper_internal.h b/include/linux/timekeeper_internal.h index e1d558e237ec..a151bd70e52b 100644 --- a/include/linux/timekeeper_internal.h +++ b/include/linux/timekeeper_internal.h | |||
@@ -62,8 +62,11 @@ struct timekeeper { | |||
62 | ktime_t offs_boot; | 62 | ktime_t offs_boot; |
63 | /* The raw monotonic time for the CLOCK_MONOTONIC_RAW posix clock. */ | 63 | /* The raw monotonic time for the CLOCK_MONOTONIC_RAW posix clock. */ |
64 | struct timespec raw_time; | 64 | struct timespec raw_time; |
65 | /* Seqlock for all timekeeper values */ | 65 | /* The current UTC to TAI offset in seconds */ |
66 | seqlock_t lock; | 66 | s32 tai_offset; |
67 | /* Offset clock monotonic -> clock tai */ | ||
68 | ktime_t offs_tai; | ||
69 | |||
67 | }; | 70 | }; |
68 | 71 | ||
69 | static inline struct timespec tk_xtime(struct timekeeper *tk) | 72 | static inline struct timespec tk_xtime(struct timekeeper *tk) |
diff --git a/include/uapi/linux/time.h b/include/uapi/linux/time.h index 0d3c0edc3eda..e75e1b6ff27f 100644 --- a/include/uapi/linux/time.h +++ b/include/uapi/linux/time.h | |||
@@ -54,11 +54,9 @@ struct itimerval { | |||
54 | #define CLOCK_BOOTTIME 7 | 54 | #define CLOCK_BOOTTIME 7 |
55 | #define CLOCK_REALTIME_ALARM 8 | 55 | #define CLOCK_REALTIME_ALARM 8 |
56 | #define CLOCK_BOOTTIME_ALARM 9 | 56 | #define CLOCK_BOOTTIME_ALARM 9 |
57 | #define CLOCK_SGI_CYCLE 10 /* Hardware specific */ | ||
58 | #define CLOCK_TAI 11 | ||
57 | 59 | ||
58 | /* | ||
59 | * The IDs of various hardware clocks: | ||
60 | */ | ||
61 | #define CLOCK_SGI_CYCLE 10 | ||
62 | #define MAX_CLOCKS 16 | 60 | #define MAX_CLOCKS 16 |
63 | #define CLOCKS_MASK (CLOCK_REALTIME | CLOCK_MONOTONIC) | 61 | #define CLOCKS_MASK (CLOCK_REALTIME | CLOCK_MONOTONIC) |
64 | #define CLOCKS_MONO CLOCK_MONOTONIC | 62 | #define CLOCKS_MONO CLOCK_MONOTONIC |