With the introduction of per-cpu wakeup devices that can be used in preference to the broadcast timer, print the name of such devices when they are available.
Showing the changes to kernel (3 of 3 files). Show all
Unified · Split
| @@ -63,6 +63,13 @@ struct cpumask *tick_get_broadcast_mask(void) · 62 unmodified lines | |||
| 63 | return tick_broadcast_mask; | 63 | return tick_broadcast_mask; |
| 64 | } | 64 | } |
| 65 | 65 | ||
| 66 | static struct clock_event_device *tick_get_oneshot_wakeup_device(int cpu); | ||
| 67 | |||
| 68 | const struct clock_event_device *tick_get_wakeup_device(int cpu) | ||
| 69 | { | ||
| 70 | return tick_get_oneshot_wakeup_device(cpu); | ||
| 71 | } | ||
| 72 | |||
| 66 | /* | 73 | /* |
| 67 | * Start the device in periodic mode | 74 | * Start the device in periodic mode |
| 68 | */ | 75 | */ |
| @@ -71,6 +71,7 @@ extern void tick_set_periodic_handler(struct clock_event_device *dev, int broadc · 70 unmodified lines | |||
| 71 | extern int tick_broadcast_update_freq(struct clock_event_device *dev, u32 freq); | 71 | extern int tick_broadcast_update_freq(struct clock_event_device *dev, u32 freq); |
| 72 | extern struct tick_device *tick_get_broadcast_device(void); | 72 | extern struct tick_device *tick_get_broadcast_device(void); |
| 73 | extern struct cpumask *tick_get_broadcast_mask(void); | 73 | extern struct cpumask *tick_get_broadcast_mask(void); |
| 74 | extern const struct clock_event_device *tick_get_wakeup_device(int cpu); | ||
| 74 | # else /* !CONFIG_GENERIC_CLOCKEVENTS_BROADCAST: */ | 75 | # else /* !CONFIG_GENERIC_CLOCKEVENTS_BROADCAST: */ |
| 75 | static inline void tick_install_broadcast_device(struct clock_event_device *dev, int cpu) { } | 76 | static inline void tick_install_broadcast_device(struct clock_event_device *dev, int cpu) { } |
| 76 | static inline int tick_is_broadcast_device(struct clock_event_device *dev) { return 0; } | 77 | static inline int tick_is_broadcast_device(struct clock_event_device *dev) { return 0; } |
| @@ -228,6 +228,14 @@ print_tickdevice(struct seq_file *m, struct tick_device *td, int cpu) · 227 unmodified lines | |||
| 228 | SEQ_printf(m, " event_handler: %ps\n", dev->event_handler); | 228 | SEQ_printf(m, " event_handler: %ps\n", dev->event_handler); |
| 229 | SEQ_printf(m, "\n"); | 229 | SEQ_printf(m, "\n"); |
| 230 | SEQ_printf(m, " retries: %lu\n", dev->retries); | 230 | SEQ_printf(m, " retries: %lu\n", dev->retries); |
| 231 | |||
| 232 | #ifdef CONFIG_GENERIC_CLOCKEVENTS_BROADCAST | ||
| 233 | if (cpu >= 0) { | ||
| 234 | const struct clock_event_device *wd = tick_get_wakeup_device(cpu); | ||
| 235 | |||
| 236 | SEQ_printf(m, "Wakeup Device: %s\n", wd ? wd->name : "<NULL>"); | ||
| 237 | } | ||
| 238 | #endif | ||
| 231 | SEQ_printf(m, "\n"); | 239 | SEQ_printf(m, "\n"); |
| 232 | } | 240 | } |
| 233 | 241 | ||
| @@ -248,7 +256,7 @@ static void timer_list_show_tickdevices_header(struct seq_file *m) · 14 unmodified lines | |||
| 248 | 256 | ||
| 249 | static inline void timer_list_header(struct seq_file *m, u64 now) | 257 | static inline void timer_list_header(struct seq_file *m, u64 now) |
| 250 | { | 258 | { |
| 251 | SEQ_printf(m, "Timer List Version: v0.8\n"); | 259 | SEQ_printf(m, "Timer List Version: v0.9\n"); |
| 252 | SEQ_printf(m, "HRTIMER_MAX_CLOCK_BASES: %d\n", HRTIMER_MAX_CLOCK_BASES); | 260 | SEQ_printf(m, "HRTIMER_MAX_CLOCK_BASES: %d\n", HRTIMER_MAX_CLOCK_BASES); |
| 253 | SEQ_printf(m, "now at %Ld nsecs\n", (unsigned long long)now); | 261 | SEQ_printf(m, "now at %Ld nsecs\n", (unsigned long long)now); |
| 254 | SEQ_printf(m, "\n"); | 262 | SEQ_printf(m, "\n"); |