diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-07-21 15:07:56 +0100 |
---|---|---|
committer | Xinyu Chen <xinyu.chen@freescale.com> | 2012-05-24 09:18:59 +0800 |
commit | 6008da0b559e9a46ea1e65520db73e86c51c5805 (patch) | |
tree | bc1637d3da35a441538acda59661fa9f8235826e /arch | |
parent | 2a4673720ce9c008b11bd2639a933b8d488c8ba2 (diff) |
ARM: CPU hotplug: pass in proper affinity mask on IRQ migration
Now that the GIC takes care of selecting a target interrupt from the
affinity mask, we don't need all this complexity in the core code
anymore. Just detect when we need to break affinity.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/kernel/irq.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/arch/arm/kernel/irq.c b/arch/arm/kernel/irq.c index 3e34b1f0586b..30d680620281 100644 --- a/arch/arm/kernel/irq.c +++ b/arch/arm/kernel/irq.c @@ -142,17 +142,15 @@ int __init arch_probe_nr_irqs(void) static bool migrate_one_irq(struct irq_data *d) { - unsigned int cpu = cpumask_any_and(d->affinity, cpu_online_mask); + const struct cpumask *affinity = d->affinity; bool ret = false; - if (cpu >= nr_cpu_ids) { - cpu = cpumask_any(cpu_online_mask); + if (cpumask_any_and(affinity, cpu_online_mask) >= nr_cpu_ids) { + affinity cpu_online_mask; ret = true; } - pr_debug("IRQ%u: moving from cpu%u to cpu%u\n", d->irq, d->node, cpu); - - d->chip->irq_set_affinity(d, cpumask_of(cpu), true); + d->chip->irq_set_affinity(d, affinity, true); return ret; } |