diff options
Diffstat (limited to 'include/linux/clockchips.h')
-rw-r--r-- | include/linux/clockchips.h | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/include/linux/clockchips.h b/include/linux/clockchips.h index 3a1dbba4d3ae..0cf725bdd2a1 100644 --- a/include/linux/clockchips.h +++ b/include/linux/clockchips.h | |||
@@ -77,10 +77,10 @@ enum clock_event_nofitiers { | |||
77 | struct clock_event_device { | 77 | struct clock_event_device { |
78 | const char *name; | 78 | const char *name; |
79 | unsigned int features; | 79 | unsigned int features; |
80 | unsigned long max_delta_ns; | 80 | u64 max_delta_ns; |
81 | unsigned long min_delta_ns; | 81 | u64 min_delta_ns; |
82 | unsigned long mult; | 82 | u32 mult; |
83 | int shift; | 83 | u32 shift; |
84 | int rating; | 84 | int rating; |
85 | int irq; | 85 | int irq; |
86 | const struct cpumask *cpumask; | 86 | const struct cpumask *cpumask; |
@@ -116,8 +116,8 @@ static inline unsigned long div_sc(unsigned long ticks, unsigned long nsec, | |||
116 | } | 116 | } |
117 | 117 | ||
118 | /* Clock event layer functions */ | 118 | /* Clock event layer functions */ |
119 | extern unsigned long clockevent_delta2ns(unsigned long latch, | 119 | extern u64 clockevent_delta2ns(unsigned long latch, |
120 | struct clock_event_device *evt); | 120 | struct clock_event_device *evt); |
121 | extern void clockevents_register_device(struct clock_event_device *dev); | 121 | extern void clockevents_register_device(struct clock_event_device *dev); |
122 | 122 | ||
123 | extern void clockevents_exchange_device(struct clock_event_device *old, | 123 | extern void clockevents_exchange_device(struct clock_event_device *old, |
@@ -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 |