Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull scheduler fix from Thomas Gleixner:
"A single bug fix to prevent a subtle deadlock in the scheduler core
code vs cpu hotplug"

* 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
sched/core: Fix cpu.max vs. cpuhotplug deadlock

+18 -5
+7
include/linux/jump_label.h
··· 160 160 extern int jump_label_text_reserved(void *start, void *end); 161 161 extern void static_key_slow_inc(struct static_key *key); 162 162 extern void static_key_slow_dec(struct static_key *key); 163 + extern void static_key_slow_inc_cpuslocked(struct static_key *key); 164 + extern void static_key_slow_dec_cpuslocked(struct static_key *key); 163 165 extern void jump_label_apply_nops(struct module *mod); 164 166 extern int static_key_count(struct static_key *key); 165 167 extern void static_key_enable(struct static_key *key); ··· 223 221 STATIC_KEY_CHECK_USE(key); 224 222 atomic_dec(&key->enabled); 225 223 } 224 + 225 + #define static_key_slow_inc_cpuslocked(key) static_key_slow_inc(key) 226 + #define static_key_slow_dec_cpuslocked(key) static_key_slow_dec(key) 226 227 227 228 static inline int jump_label_text_reserved(void *start, void *end) 228 229 { ··· 421 416 422 417 #define static_branch_inc(x) static_key_slow_inc(&(x)->key) 423 418 #define static_branch_dec(x) static_key_slow_dec(&(x)->key) 419 + #define static_branch_inc_cpuslocked(x) static_key_slow_inc_cpuslocked(&(x)->key) 420 + #define static_branch_dec_cpuslocked(x) static_key_slow_dec_cpuslocked(&(x)->key) 424 421 425 422 /* 426 423 * Normal usage; boolean enable/disable.
+9 -3
kernel/jump_label.c
··· 79 79 } 80 80 EXPORT_SYMBOL_GPL(static_key_count); 81 81 82 - static void static_key_slow_inc_cpuslocked(struct static_key *key) 82 + void static_key_slow_inc_cpuslocked(struct static_key *key) 83 83 { 84 84 int v, v1; 85 85 ··· 180 180 } 181 181 EXPORT_SYMBOL_GPL(static_key_disable); 182 182 183 - static void static_key_slow_dec_cpuslocked(struct static_key *key, 183 + static void __static_key_slow_dec_cpuslocked(struct static_key *key, 184 184 unsigned long rate_limit, 185 185 struct delayed_work *work) 186 186 { ··· 211 211 struct delayed_work *work) 212 212 { 213 213 cpus_read_lock(); 214 - static_key_slow_dec_cpuslocked(key, rate_limit, work); 214 + __static_key_slow_dec_cpuslocked(key, rate_limit, work); 215 215 cpus_read_unlock(); 216 216 } 217 217 ··· 228 228 __static_key_slow_dec(key, 0, NULL); 229 229 } 230 230 EXPORT_SYMBOL_GPL(static_key_slow_dec); 231 + 232 + void static_key_slow_dec_cpuslocked(struct static_key *key) 233 + { 234 + STATIC_KEY_CHECK_USE(key); 235 + __static_key_slow_dec_cpuslocked(key, 0, NULL); 236 + } 231 237 232 238 void static_key_slow_dec_deferred(struct static_key_deferred *key) 233 239 {
+2 -2
kernel/sched/fair.c
··· 4365 4365 4366 4366 void cfs_bandwidth_usage_inc(void) 4367 4367 { 4368 - static_key_slow_inc(&__cfs_bandwidth_used); 4368 + static_key_slow_inc_cpuslocked(&__cfs_bandwidth_used); 4369 4369 } 4370 4370 4371 4371 void cfs_bandwidth_usage_dec(void) 4372 4372 { 4373 - static_key_slow_dec(&__cfs_bandwidth_used); 4373 + static_key_slow_dec_cpuslocked(&__cfs_bandwidth_used); 4374 4374 } 4375 4375 #else /* HAVE_JUMP_LABEL */ 4376 4376 static bool cfs_bandwidth_used(void)