diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/clockchips.h | 7 | ||||
| -rw-r--r-- | include/linux/clocksource.h | 10 |
2 files changed, 17 insertions, 0 deletions
diff --git a/include/linux/clockchips.h b/include/linux/clockchips.h index 3b5841016276..4d438b0bc10a 100644 --- a/include/linux/clockchips.h +++ b/include/linux/clockchips.h | |||
| @@ -130,6 +130,13 @@ extern int clockevents_program_event(struct clock_event_device *dev, | |||
| 130 | 130 | ||
| 131 | extern void clockevents_handle_noop(struct clock_event_device *dev); | 131 | extern void clockevents_handle_noop(struct clock_event_device *dev); |
| 132 | 132 | ||
| 133 | static inline void | ||
| 134 | clockevents_calc_mult_shift(struct clock_event_device *ce, u32 freq, u32 minsec) | ||
| 135 | { | ||
| 136 | return clocks_calc_mult_shift(&ce->mult, &ce->shift, NSEC_PER_SEC, | ||
| 137 | freq, minsec); | ||
| 138 | } | ||
| 139 | |||
| 133 | #ifdef CONFIG_GENERIC_CLOCKEVENTS | 140 | #ifdef CONFIG_GENERIC_CLOCKEVENTS |
| 134 | extern void clockevents_notify(unsigned long reason, void *arg); | 141 | extern void clockevents_notify(unsigned long reason, void *arg); |
| 135 | #else | 142 | #else |
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h index 83d2fbd81b93..f57f88250526 100644 --- a/include/linux/clocksource.h +++ b/include/linux/clocksource.h | |||
| @@ -279,6 +279,16 @@ extern void clocksource_resume(void); | |||
| 279 | extern struct clocksource * __init __weak clocksource_default_clock(void); | 279 | extern struct clocksource * __init __weak clocksource_default_clock(void); |
| 280 | extern void clocksource_mark_unstable(struct clocksource *cs); | 280 | extern void clocksource_mark_unstable(struct clocksource *cs); |
| 281 | 281 | ||
| 282 | extern void | ||
| 283 | clocks_calc_mult_shift(u32 *mult, u32 *shift, u32 from, u32 to, u32 minsec); | ||
| 284 | |||
| 285 | static inline void | ||
| 286 | clocksource_calc_mult_shift(struct clocksource *cs, u32 freq, u32 minsec) | ||
| 287 | { | ||
| 288 | return clocks_calc_mult_shift(&cs->mult, &cs->shift, freq, | ||
| 289 | NSEC_PER_SEC, minsec); | ||
| 290 | } | ||
| 291 | |||
| 282 | #ifdef CONFIG_GENERIC_TIME_VSYSCALL | 292 | #ifdef CONFIG_GENERIC_TIME_VSYSCALL |
| 283 | extern void update_vsyscall(struct timespec *ts, struct clocksource *c); | 293 | extern void update_vsyscall(struct timespec *ts, struct clocksource *c); |
| 284 | extern void update_vsyscall_tz(void); | 294 | extern void update_vsyscall_tz(void); |
