linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/2] Fix IRQ round-robing w/o irqbalance on pseries
@ 2010-09-27 23:17 Nishanth Aravamudan
  2010-09-27 23:17 ` [RFC PATCH 2/2] pseries/xics: use cpu_possible_mask rather than cpu_all_mask Nishanth Aravamudan
  0 siblings, 1 reply; 2+ messages in thread
From: Nishanth Aravamudan @ 2010-09-27 23:17 UTC (permalink / raw)
  To: nacc; +Cc: linuxppc-dev, linux-kernel, miltonm

We have received reports on power systems not running irqbalance where
all interrupts are being routed to CPU0 rather than being interleaved by
default across the system. Current firmware only allows either sending
interrupts to all CPUs or sending them to one CPU. The following two
patches address this issue by fixing the mask used in generic code and
by fixing the check for the "all" setting in the pseries code.

Nishanth Aravamudan (2):
  IRQ: use cpu_possible_mask rather than online_mask in setup_affinity
  pseries/xics: use cpu_possible_mask rather than cpu_all_mask

 arch/powerpc/platforms/pseries/xics.c |    2 +-
 kernel/irq/manage.c                   |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Cc: linuxppc-dev@lists.ozlabs.org
Cc: linux-kernel@vger.kernel.org

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [RFC PATCH 2/2] pseries/xics: use cpu_possible_mask rather than cpu_all_mask
  2010-09-27 23:17 [RFC PATCH 0/2] Fix IRQ round-robing w/o irqbalance on pseries Nishanth Aravamudan
@ 2010-09-27 23:17 ` Nishanth Aravamudan
  0 siblings, 0 replies; 2+ messages in thread
From: Nishanth Aravamudan @ 2010-09-27 23:17 UTC (permalink / raw)
  To: nacc
  Cc: Mark Nelson, linux-kernel, miltonm, Paul Mackerras,
	Anton Blanchard, Thomas Gleixner, linuxppc-dev

Current firmware only allows us to send IRQs to the first processor or
all processors. We currently check to see if the passed in mask is equal
to the all_mask, but the firmware is only considering whether the
request is for the equivalent of the possible_mask. Thus, we think the
request is for some subset of CPUs and only assign IRQs to the first CPU
(on systems without irqbalance running) as evidenced by
/proc/interrupts. By using possible_mask instead, we account for this
and proper interleaving of interrupts occurs. Without this change and
"pseries/xics: use cpu_possible_mask rather than cpu_all_mask", IRQs are
all routed to CPU0 on power machines not running irqbalance.

Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
---
 arch/powerpc/platforms/pseries/xics.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/powerpc/platforms/pseries/xics.c b/arch/powerpc/platforms/pseries/xics.c
index 93834b0..7c1e342 100644
--- a/arch/powerpc/platforms/pseries/xics.c
+++ b/arch/powerpc/platforms/pseries/xics.c
@@ -178,7 +178,7 @@ static int get_irq_server(unsigned int virq, const struct cpumask *cpumask,
 	if (!distribute_irqs)
 		return default_server;
 
-	if (!cpumask_equal(cpumask, cpu_all_mask)) {
+	if (!cpumask_subset(cpu_possible_mask, cpumask)) {
 		int server = cpumask_first_and(cpu_online_mask, cpumask);
 
 		if (server < nr_cpu_ids)
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-09-27 23:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-09-27 23:17 [RFC PATCH 0/2] Fix IRQ round-robing w/o irqbalance on pseries Nishanth Aravamudan
2010-09-27 23:17 ` [RFC PATCH 2/2] pseries/xics: use cpu_possible_mask rather than cpu_all_mask Nishanth Aravamudan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).