Skip to content

Commit fed71f7

Browse files
committed
x86/apic/x2apic: Initialize cluster ID properly
Rick bisected a regression on large systems which use the x2apic cluster mode for interrupt delivery to the commit wich reworked the cluster management. The problem is caused by a missing initialization of the clusterid field in the shared cluster data structures. So all structures end up with cluster ID 0 which only allows sharing between all CPUs which belong to cluster 0. All other CPUs with a cluster ID > 0 cannot share the data structure because they cannot find existing data with their cluster ID. This causes malfunction with IPIs because IPIs are sent to the wrong cluster and the caller waits for ever that the target CPU handles the IPI. Add the missing initialization when a upcoming CPU is the first in a cluster so that the later booting CPUs can find the data and share it for proper operation. Fixes: 023a611 ("x86/apic/x2apic: Simplify cluster management") Reported-by: Rick Warner <[email protected]> Bisected-by: Rick Warner <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Tested-by: Rick Warner <[email protected]> Cc: [email protected] Link: https://lkml.kernel.org/r/[email protected]
1 parent 589bb62 commit fed71f7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

arch/x86/kernel/apic/x2apic_cluster.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ static void init_x2apic_ldr(void)
116116
goto update;
117117
}
118118
cmsk = cluster_hotplug_mask;
119+
cmsk->clusterid = cluster;
119120
cluster_hotplug_mask = NULL;
120121
update:
121122
this_cpu_write(cluster_masks, cmsk);

0 commit comments

Comments
 (0)