Lines Matching +full:cs +full:- +full:1
1 /* SPDX-License-Identifier: GPL-2.0 */
34 * struct clocksource - hardware abstraction for a free running counter
35 * Provides mostly state-free accessors to the underlying hardware.
45 * @archdata: Optional arch-specific data
54 * 1-99: Unfit for real use
56 * 100-199: Base level usability.
58 * 200-299: Good.
60 * 300-399: Desired.
62 * 400-499: Perfect
63 * The ideal clocksource. A must-use where
90 u64 (*read)(struct clocksource *cs);
106 int (*enable)(struct clocksource *cs);
107 void (*disable)(struct clocksource *cs);
108 void (*suspend)(struct clocksource *cs);
109 void (*resume)(struct clocksource *cs);
110 void (*mark_unstable)(struct clocksource *cs);
111 void (*tick_stable)(struct clocksource *cs);
136 #define CLOCKSOURCE_MASK(bits) GENMASK_ULL((bits) - 1, 0)
156 * clocksource_khz2mult - calculates mult from khz and shift
169 * clocksource_hz2mult - calculates mult from hz and shift
183 * clocksource_cyc2ns - converts clocksource cycles to nanoseconds
193 * XXX - This could use some mult_lxl_ll() asm optimization
203 extern void clocksource_change_rating(struct clocksource *cs, int rating);
207 extern void clocksource_mark_unstable(struct clocksource *cs);
209 clocksource_start_suspend_timing(struct clocksource *cs, u64 start_cycles);
210 extern u64 clocksource_stop_suspend_timing(struct clocksource *cs, u64 now);
222 __clocksource_register_scale(struct clocksource *cs, u32 scale, u32 freq);
224 __clocksource_update_freq_scale(struct clocksource *cs, u32 scale, u32 freq);
230 static inline int __clocksource_register(struct clocksource *cs) in __clocksource_register() argument
232 return __clocksource_register_scale(cs, 1, 0); in __clocksource_register()
235 static inline int clocksource_register_hz(struct clocksource *cs, u32 hz) in clocksource_register_hz() argument
237 return __clocksource_register_scale(cs, 1, hz); in clocksource_register_hz()
240 static inline int clocksource_register_khz(struct clocksource *cs, u32 khz) in clocksource_register_khz() argument
242 return __clocksource_register_scale(cs, 1000, khz); in clocksource_register_khz()
245 static inline void __clocksource_update_freq_hz(struct clocksource *cs, u32 hz) in __clocksource_update_freq_hz() argument
247 __clocksource_update_freq_scale(cs, 1, hz); in __clocksource_update_freq_hz()
250 static inline void __clocksource_update_freq_khz(struct clocksource *cs, u32 khz) in __clocksource_update_freq_khz() argument
252 __clocksource_update_freq_scale(cs, 1000, khz); in __clocksource_update_freq_khz()
256 extern void clocksource_arch_init(struct clocksource *cs);
258 static inline void clocksource_arch_init(struct clocksource *cs) { } in clocksource_arch_init() argument