public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: Ashok Raj <ashok.raj@intel.com>
To: linux-ia64@vger.kernel.org
Subject: Re: [PATCH] fix interrupt rerouting for Altix
Date: Fri, 18 Jun 2004 22:30:23 +0000	[thread overview]
Message-ID: <20040618153023.A15940@unix-os.sc.intel.com> (raw)
In-Reply-To: <200406171546.i5HFk3wF407364@fsgi900.americas.sgi.com>

On Fri, Jun 18, 2004 at 01:17:37PM -0400, Jesse Barnes wrote:
> This looks like a duplicate of what's in iosapic.c.  Maybe we should just have 
> one version of it in irq.c?  Ashok?

Yep.. i think it will be nice to integrate them into irq.c. I have
the patch to do that attached below.

Pat, could you go ahead and submit the patch to work with this attached
patch? i was not able to apply yours clean, patch reported
garbled patch, and i didnt take time to fix it manually...

-
Cheers,
Ashok Raj
- Linux OS Technologies Team


Signed-off-by: Ashok Raj <ashok.raj@intel.com>

D: This patch makes move_irq() function from iospic.c to irq.c to make this common for
D: ia64 archs. Both that use iosapic, and the SN2 versions. 


---

 linux-2.6.7-root/arch/ia64/kernel/iosapic.c |   16 ----------------
 linux-2.6.7-root/arch/ia64/kernel/irq.c     |   16 ++++++++++++++++
 linux-2.6.7-root/include/asm-ia64/irq.h     |    6 ++++++
 3 files changed, 22 insertions(+), 16 deletions(-)

diff -puN arch/ia64/kernel/irq.c~make_moveirq_common arch/ia64/kernel/irq.c
--- linux-2.6.7/arch/ia64/kernel/irq.c~make_moveirq_common	2004-06-18 15:22:57.297836562 -0700
+++ linux-2.6.7-root/arch/ia64/kernel/irq.c	2004-06-18 15:22:57.303695940 -0700
@@ -1018,6 +1018,22 @@ static int irq_affinity_write_proc (stru
 	return full_count;
 }
 
+void move_irq(int irq)
+{
+	/* note - we hold desc->lock */
+	cpumask_t tmp;
+	irq_desc_t *desc = irq_descp(irq);
+
+	if (!cpus_empty(pending_irq_cpumask[irq])) {
+		cpus_and(tmp, pending_irq_cpumask[irq], cpu_online_map);
+		if (unlikely(!cpus_empty(tmp))) {
+			desc->handler->set_affinity(irq, pending_irq_cpumask[irq]);
+		}
+		cpus_clear(pending_irq_cpumask[irq]);
+	}
+}
+
+
 #endif /* CONFIG_SMP */
 
 #ifdef CONFIG_HOTPLUG_CPU
diff -puN arch/ia64/kernel/iosapic.c~make_moveirq_common arch/ia64/kernel/iosapic.c
--- linux-2.6.7/arch/ia64/kernel/iosapic.c~make_moveirq_common	2004-06-18 15:22:57.298813125 -0700
+++ linux-2.6.7-root/arch/ia64/kernel/iosapic.c	2004-06-18 15:22:57.303695940 -0700
@@ -100,7 +100,6 @@
 #endif
 
 static spinlock_t iosapic_lock = SPIN_LOCK_UNLOCKED;
-extern cpumask_t	__cacheline_aligned pending_irq_cpumask[NR_IRQS];
 
 /* These tables map IA-64 vectors to the IOSAPIC pin that generates this vector. */
 
@@ -335,21 +334,6 @@ iosapic_set_affinity (unsigned int irq, 
 #endif
 }
 
-static inline void move_irq(int irq)
-{
-	/* note - we hold desc->lock */
-	cpumask_t tmp;
-	irq_desc_t *desc = irq_descp(irq);
-
-	if (!cpus_empty(pending_irq_cpumask[irq])) {
-		cpus_and(tmp, pending_irq_cpumask[irq], cpu_online_map);
-		if (unlikely(!cpus_empty(tmp))) {
-			desc->handler->set_affinity(irq, pending_irq_cpumask[irq]);
-		}
-		cpus_clear(pending_irq_cpumask[irq]);
-	}
-}
-
 /*
  * Handlers for level-triggered interrupts.
  */
diff -puN include/asm-ia64/irq.h~make_moveirq_common include/asm-ia64/irq.h
--- linux-2.6.7/include/asm-ia64/irq.h~make_moveirq_common	2004-06-18 15:22:57.300766251 -0700
+++ linux-2.6.7-root/include/asm-ia64/irq.h	2004-06-18 15:22:57.303695940 -0700
@@ -30,6 +30,12 @@ extern void disable_irq_nosync (unsigned
 extern void enable_irq (unsigned int);
 extern void set_irq_affinity_info (unsigned int irq, int dest, int redir);
 
+#ifdef CONFIG_SMP
+extern void move_irq(int irq);
+#else
+#define move_irq(irq)
+#endif
+
 struct irqaction;
 struct pt_regs;
 int handle_IRQ_event(unsigned int, struct pt_regs *, struct irqaction *);

_

  parent reply	other threads:[~2004-06-18 22:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-17 15:46 [PATCH] fix interrupt rerouting for Altix Pat Gefre
2004-06-18 17:17 ` Jesse Barnes
2004-06-18 22:30 ` Ashok Raj [this message]
2004-06-22 17:58 ` Pat Gefre

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040618153023.A15940@unix-os.sc.intel.com \
    --to=ashok.raj@intel.com \
    --cc=linux-ia64@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox