aboutsummaryrefslogtreecommitdiffstats
path: root/rust/helpers/helpers.c
diff options
context:
space:
mode:
authorBrian Norris <[email protected]>2025-06-12 18:32:52 +0000
committerThomas Gleixner <[email protected]>2025-06-13 13:13:35 +0000
commit72218d74c9c57b8ea36c2a58875dff406fc10462 (patch)
tree982e97296adcd1d83f85a535ade024dd2df965ec /rust/helpers/helpers.c
parentgenirq/cpuhotplug: Rebalance managed interrupts across multi-CPU hotplug (diff)
downloadkernel-72218d74c9c57b8ea36c2a58875dff406fc10462.tar.gz
kernel-72218d74c9c57b8ea36c2a58875dff406fc10462.zip
genirq/cpuhotplug: Restore affinity even for suspended IRQ
Commit 788019eb559f ("genirq: Retain disable depth for managed interrupts across CPU hotplug") tried to make managed shutdown/startup properly reference counted, but it missed the fact that the unplug and hotplug code has an intentional imbalance by skipping IRQS_SUSPENDED interrupts on the "restore" path. This means that if a managed-affinity interrupt was both suspended and managed-shutdown (such as may happen during system suspend / S3), resume skips calling irq_startup_managed(), and would again have an unbalanced depth this time, with a positive value (i.e., remaining unexpectedly masked). This IRQS_SUSPENDED check was introduced in commit a60dd06af674 ("genirq/cpuhotplug: Skip suspended interrupts when restoring affinity") for essentially the same reason as commit 788019eb559f, to prevent that irq_startup() would unconditionally re-enable an interrupt too early. Because irq_startup_managed() now respsects the disable-depth count, the IRQS_SUSPENDED check is not longer needed, and instead, it causes harm. Thus, drop the IRQS_SUSPENDED check, and restore balance. This effectively reverts commit a60dd06af674 ("genirq/cpuhotplug: Skip suspended interrupts when restoring affinity"), because it is replaced by commit 788019eb559f ("genirq: Retain disable depth for managed interrupts across CPU hotplug"). Fixes: 788019eb559f ("genirq: Retain disable depth for managed interrupts across CPU hotplug") Reported-by: Aleksandrs Vinarskis <[email protected]> Signed-off-by: Brian Norris <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Tested-by: Aleksandrs Vinarskis <[email protected]> Link: https://lore.kernel.org/all/[email protected] Closes: https://lore.kernel.org/lkml/[email protected]/
Diffstat (limited to 'rust/helpers/helpers.c')
0 files changed, 0 insertions, 0 deletions