hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/kernel/time/tick-internal.h
....@@ -62,9 +62,8 @@
6262 /* Broadcasting support */
6363 # ifdef CONFIG_GENERIC_CLOCKEVENTS_BROADCAST
6464 extern int tick_device_uses_broadcast(struct clock_event_device *dev, int cpu);
65
-extern void tick_install_broadcast_device(struct clock_event_device *dev);
65
+extern void tick_install_broadcast_device(struct clock_event_device *dev, int cpu);
6666 extern int tick_is_broadcast_device(struct clock_event_device *dev);
67
-extern void tick_shutdown_broadcast(unsigned int cpu);
6867 extern void tick_suspend_broadcast(void);
6968 extern void tick_resume_broadcast(void);
7069 extern bool tick_resume_check_broadcast(void);
....@@ -73,12 +72,12 @@
7372 extern int tick_broadcast_update_freq(struct clock_event_device *dev, u32 freq);
7473 extern struct tick_device *tick_get_broadcast_device(void);
7574 extern struct cpumask *tick_get_broadcast_mask(void);
75
+extern const struct clock_event_device *tick_get_wakeup_device(int cpu);
7676 # else /* !CONFIG_GENERIC_CLOCKEVENTS_BROADCAST: */
77
-static inline void tick_install_broadcast_device(struct clock_event_device *dev) { }
77
+static inline void tick_install_broadcast_device(struct clock_event_device *dev, int cpu) { }
7878 static inline int tick_is_broadcast_device(struct clock_event_device *dev) { return 0; }
7979 static inline int tick_device_uses_broadcast(struct clock_event_device *dev, int cpu) { return 0; }
8080 static inline void tick_do_periodic_broadcast(struct clock_event_device *d) { }
81
-static inline void tick_shutdown_broadcast(unsigned int cpu) { }
8281 static inline void tick_suspend_broadcast(void) { }
8382 static inline void tick_resume_broadcast(void) { }
8483 static inline bool tick_resume_check_broadcast(void) { return false; }
....@@ -128,18 +127,22 @@
128127 /* Functions related to oneshot broadcasting */
129128 #if defined(CONFIG_GENERIC_CLOCKEVENTS_BROADCAST) && defined(CONFIG_TICK_ONESHOT)
130129 extern void tick_broadcast_switch_to_oneshot(void);
131
-extern void tick_shutdown_broadcast_oneshot(unsigned int cpu);
132130 extern int tick_broadcast_oneshot_active(void);
133131 extern void tick_check_oneshot_broadcast_this_cpu(void);
134132 bool tick_broadcast_oneshot_available(void);
135133 extern struct cpumask *tick_get_broadcast_oneshot_mask(void);
136134 #else /* !(BROADCAST && ONESHOT): */
137135 static inline void tick_broadcast_switch_to_oneshot(void) { }
138
-static inline void tick_shutdown_broadcast_oneshot(unsigned int cpu) { }
139136 static inline int tick_broadcast_oneshot_active(void) { return 0; }
140137 static inline void tick_check_oneshot_broadcast_this_cpu(void) { }
141138 static inline bool tick_broadcast_oneshot_available(void) { return tick_oneshot_possible(); }
142139 #endif /* !(BROADCAST && ONESHOT) */
140
+
141
+#if defined(CONFIG_GENERIC_CLOCKEVENTS_BROADCAST) && defined(CONFIG_HOTPLUG_CPU)
142
+extern void tick_broadcast_offline(unsigned int cpu);
143
+#else
144
+static inline void tick_broadcast_offline(unsigned int cpu) { }
145
+#endif
143146
144147 /* NO_HZ_FULL internal */
145148 #ifdef CONFIG_NO_HZ_FULL
....@@ -163,3 +166,6 @@
163166
164167 extern u64 get_next_timer_interrupt(unsigned long basej, u64 basem);
165168 void timer_clear_idle(void);
169
+
170
+void clock_was_set(void);
171
+void clock_was_set_delayed(void);