Wang ShaoBo
4cc4cc28ec
arch_topology: Fix missing clear cluster_cpumask in remove_cpu_topology()
...
When testing cpu online and offline, warning happened like this:
[ 146.746743] WARNING: CPU: 92 PID: 974 at kernel/sched/topology.c:2215 build_sched_domains+0x81c/0x11b0
[ 146.749988] CPU: 92 PID: 974 Comm: kworker/92:2 Not tainted 5.15.0 #9
[ 146.750402] Hardware name: Huawei TaiShan 2280 V2/BC82AMDDA, BIOS 1.79 08/21/2021
[ 146.751213] Workqueue: events cpuset_hotplug_workfn
[ 146.751629] pstate: 00400009 (nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[ 146.752048] pc : build_sched_domains+0x81c/0x11b0
[ 146.752461] lr : build_sched_domains+0x414/0x11b0
[ 146.752860] sp : ffff800040a83a80
[ 146.753247] x29: ffff800040a83a80 x28: ffff20801f13a980 x27: ffff20800448ae00
[ 146.753644] x26: ffff800012a858e8 x25: ffff800012ea48c0 x24: 0000000000000000
[ 146.754039] x23: ffff800010ab7d60 x22: ffff800012f03758 x21: 000000000000005f
[ 146.754427] x20: 000000000000005c x19: ffff004080012840 x18: ffffffffffffffff
[ 146.754814] x17: 3661613030303230 x16: 30303078303a3239 x15: ffff800011f92b48
[ 146.755197] x14: ffff20be3f95cef6 x13: 2e6e69616d6f642d x12: 6465686373204c4c
[ 146.755578] x11: ffff20bf7fc83a00 x10: 0000000000000040 x9 : 0000000000000000
[ 146.755957] x8 : 0000000000000002 x7 : ffffffffe0000000 x6 : 0000000000000002
[ 146.756334] x5 : 0000000090000000 x4 : 00000000f0000000 x3 : 0000000000000001
[ 146.756705] x2 : 0000000000000080 x1 : ffff800012f03860 x0 : 0000000000000001
[ 146.757070] Call trace:
[ 146.757421] build_sched_domains+0x81c/0x11b0
[ 146.757771] partition_sched_domains_locked+0x57c/0x978
[ 146.758118] rebuild_sched_domains_locked+0x44c/0x7f0
[ 146.758460] rebuild_sched_domains+0x2c/0x48
[ 146.758791] cpuset_hotplug_workfn+0x3fc/0x888
[ 146.759114] process_one_work+0x1f4/0x480
[ 146.759429] worker_thread+0x48/0x460
[ 146.759734] kthread+0x158/0x168
[ 146.760030] ret_from_fork+0x10/0x20
[ 146.760318] ---[ end trace 82c44aad6900e81a ]---
For some architectures like risc-v and arm64 which use common code
clear_cpu_topology() in shutting down CPUx, When CONFIG_SCHED_CLUSTER
is set, cluster_sibling in cpu_topology of each sibling adjacent
to CPUx is missed clearing, this causes checking failed in
topology_span_sane() and rebuilding topology failure at end when CPU online.
Different sibling's cluster_sibling in cpu_topology[] when CPU92 offline
(CPU 92, 93, 94, 95 are in one cluster):
Before revision:
CPU [92] [93] [94] [95]
cluster_sibling [92] [92-95] [92-95] [92-95]
After revision:
CPU [92] [93] [94] [95]
cluster_sibling [92] [93-95] [93-95] [93-95]
Signed-off-by: Wang ShaoBo <bobo.shaobowang@huawei.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Dietmar Eggemann <dietmar.eggemann@arm.com>
Acked-by: Barry Song <song.bao.hua@hisilicon.com>
Tested-by: Dietmar Eggemann <dietmar.eggemann@arm.com>
Link: https://lore.kernel.org/r/20211110095856.469360-1-bobo.shaobowang@huawei.com
2021-11-11 13:09:33 +01:00
..
2021-10-22 14:13:53 +02:00
2021-11-05 16:10:11 +01:00
2021-11-02 06:20:58 -07:00
2021-10-06 17:53:42 -06:00
2021-11-06 13:30:41 -07:00
2021-11-11 13:09:33 +01:00
2021-05-14 13:37:10 +02:00
2021-07-27 09:22:08 +02:00
2021-07-16 19:17:05 +02:00
2021-07-21 14:56:00 +02:00
2021-07-21 17:29:40 +02:00
2020-11-09 18:56:49 +01:00
2021-10-21 13:01:56 +02:00
2021-10-20 19:38:29 +02:00
2021-07-21 17:30:09 +02:00
2021-08-09 09:03:47 +02:00
2021-06-04 15:05:44 +02:00
2021-06-15 17:14:36 +02:00
2021-03-23 14:57:35 +01:00
2020-07-10 14:16:44 +02:00
2021-02-11 08:43:03 +01:00
2021-07-21 11:53:42 +02:00
2021-02-26 10:28:35 -08:00
2021-11-06 13:30:42 -07:00
2021-07-21 17:30:09 +02:00
2021-09-08 12:55:35 -07:00
2021-11-06 13:30:42 -07:00
2021-08-24 09:16:20 +02:00
2021-09-14 16:52:41 +02:00
2021-10-07 13:39:51 +01:00
2020-12-09 19:46:31 +01:00
2021-10-26 19:14:01 +02:00
2020-09-08 13:32:06 +02:00
2021-10-15 11:25:15 +02:00
2021-06-15 17:14:36 +02:00
2021-06-15 17:14:36 +02:00
2020-01-15 22:55:37 -05:00