]> git.baikalelectronics.ru Git - kernel.git/commit
genirq/affinity: Consider that CPUs on nodes can be unbalanced
authorRei Yamamoto <yamamoto.rei@jp.fujitsu.com>
Thu, 31 Mar 2022 00:33:09 +0000 (09:33 +0900)
committerThomas Gleixner <tglx@linutronix.de>
Mon, 11 Apr 2022 07:58:03 +0000 (09:58 +0200)
commitc1837918595ad4a81b58e9b030a47544c88ed41f
tree29cf5d4162a45129b60b1205d81b846ee72902d1
parent8b8765f1f3e1435193f170a638b37faace2e05b5
genirq/affinity: Consider that CPUs on nodes can be unbalanced

If CPUs on a node are offline at boot time, the number of nodes is
different when building affinity masks for present cpus and when building
affinity masks for possible cpus. This causes the following problem:

In the case that the number of vectors is less than the number of nodes
there are cases where bits of masks for present cpus are overwritten when
building masks for possible cpus.

Fix this by excluding CPUs, which are not part of the current build mask
(present/possible).

[ tglx: Massaged changelog and added comment ]

Fixes: 0a0bb829f4be ("genirq/affinity: Spread IRQs to all available NUMA nodes")
Signed-off-by: Rei Yamamoto <yamamoto.rei@jp.fujitsu.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Ming Lei <ming.lei@redhat.com>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20220331003309.10891-1-yamamoto.rei@jp.fujitsu.com
kernel/irq/affinity.c