diff options
| author | Hui Su <sh_def@163.com> | 2026-10-21 13:38:34 +0900 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2026-11-06 10:04:57 +0100 |
| commit | 5ebdfe12ab96368d0339593129d4ce0bc2bd06f5 (patch) | |
| tree | 8dd4d8df49917d611663ebcf99a8186dd5cd0bac /tools/lib/python | |
| parent | a0c755e574e37fddb59edf175f27dc3877e7fe23 (diff) | |
sched/topology: Balance cluster static-key updates
build_sched_domains() increments sched_cluster_active once per newly
built partition that contains an SD_CLUSTER domain.
detach_destroy_domains() instead tested the global static key before
decrementing it, so destroying a cluster-less partition could drop a
reference owned by another partition and disable cluster-aware
scheduling while SD_CLUSTER domains remained installed.
Check the installed domains before detaching them, only while the key is
enabled, and decrement only when the removed partition contains an
SD_CLUSTER domain.
With two cluster-bearing partitions installed, removing a singleton
partition left the baseline count at 1 where 2 partitions still
carried SD_CLUSTER; the fixed kernel correctly reports 2. On an
asymmetric cluster topology where the parent partition gains no
cluster domain, the baseline count drops to 0 while a cluster
partition remains installed; the fixed kernel keeps it at 1.
Fixes: 8881e1639f1f ("sched/fair: Scan cluster before scanning LLC in wake-up path")
Signed-off-by: Hui Su <sh_def@163.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Reviewed-by: K Prateek Nayak <kprateek.nayak@amd.com>
Reviewed-by: Kayra Cizmeci <kayracizmeci@gmail.com>
Link: https://patch.msgid.link/20261021043834.1140951-1-sh_def@163.com
Diffstat (limited to 'tools/lib/python')
0 files changed, 0 insertions, 0 deletions
