kernel: Only set one CPU in the default IRQ affinity mask

On ARM, IRQs are executed on the first CPU inside the affinity mask, so
setting an affinity mask with more than one CPU set is deceptive and
causes issues with pm_qos. To fix this, only set the CPU0 bit inside the
affinity mask, since that's where IRQs will run by default.

This is a follow-up to "kernel: Don't allow IRQ affinity masks to have
more than one CPU".

Signed-off-by: Sultan Alsawaf <sultan@kerneltoast.com>
This commit is contained in:
Sultan Alsawaf 2020-08-14 20:11:38 -07:00 committed by spakkkk
parent 6e31237cf3
commit 0f86af590b

View File

@ -43,7 +43,7 @@ static void __init init_irq_default_affinity(void)
if (!cpumask_available(irq_default_affinity))
zalloc_cpumask_var(&irq_default_affinity, GFP_NOWAIT);
if (cpumask_empty(irq_default_affinity))
cpumask_setall(irq_default_affinity);
cpumask_set_cpu(0, irq_default_affinity);
}
#else
static void __init init_irq_default_affinity(void)