From: David S. Miller Date: Wed, 4 May 2005 05:04:36 +0000 (-0700) Subject: [SPARC64]: Fix goal_cpu tracking in retarget_one_irq(). X-Git-Tag: v2.6.12-rc4~117^2~22 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cee2824f85414c98fff4004e335a6bc4072c8809;p=linux-2.6 [SPARC64]: Fix goal_cpu tracking in retarget_one_irq(). We would never advance the goal_cpu counter like we should, so all IRQs would go to a single processor. Signed-off-by: David S. Miller --- diff --git a/arch/sparc64/kernel/irq.c b/arch/sparc64/kernel/irq.c index a38cb5036d..ab2f36863f 100644 --- a/arch/sparc64/kernel/irq.c +++ b/arch/sparc64/kernel/irq.c @@ -1007,10 +1007,10 @@ static int retarget_one_irq(struct irqaction *p, int goal_cpu) } upa_writel(tid | IMAP_VALID, imap); - while (!cpu_online(goal_cpu)) { + do { if (++goal_cpu >= NR_CPUS) goal_cpu = 0; - } + } while (!cpu_online(goal_cpu)); return goal_cpu; }