aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>2007-08-13 13:31:26 -0400
committerTony Luck <tony.luck@intel.com>2007-08-13 13:31:26 -0400
commit1115200a3df64d6925bc94b404039e7082409af4 (patch)
tree057db5767e57d08dc45efbc3cf5f8a207382ffb2 /arch
parent6cba986298105a87a09d65baa2658fb5111459c6 (diff)
[IA64] SN2 needs platform specific irq_to_vector() function.
Add base support for implementing platform_irq_to_vector(), and then use it on SN2. Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Acked-by: John Keller <jpk@sgi.com> Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/ia64/kernel/irq.c5
-rw-r--r--arch/ia64/sn/kernel/irq.c7
2 files changed, 12 insertions, 0 deletions
diff --git a/arch/ia64/kernel/irq.c b/arch/ia64/kernel/irq.c
index cc3ee4ef37af..44be1c952b7c 100644
--- a/arch/ia64/kernel/irq.c
+++ b/arch/ia64/kernel/irq.c
@@ -33,6 +33,11 @@ void ack_bad_irq(unsigned int irq)
33} 33}
34 34
35#ifdef CONFIG_IA64_GENERIC 35#ifdef CONFIG_IA64_GENERIC
36ia64_vector __ia64_irq_to_vector(int irq)
37{
38 return irq_cfg[irq].vector;
39}
40
36unsigned int __ia64_local_vector_to_irq (ia64_vector vec) 41unsigned int __ia64_local_vector_to_irq (ia64_vector vec)
37{ 42{
38 return __get_cpu_var(vector_irq)[vec]; 43 return __get_cpu_var(vector_irq)[vec];
diff --git a/arch/ia64/sn/kernel/irq.c b/arch/ia64/sn/kernel/irq.c
index 7f6d2360a262..bfa43e4c7ef7 100644
--- a/arch/ia64/sn/kernel/irq.c
+++ b/arch/ia64/sn/kernel/irq.c
@@ -256,6 +256,13 @@ struct irq_chip irq_type_sn = {
256 .set_affinity = sn_set_affinity_irq 256 .set_affinity = sn_set_affinity_irq
257}; 257};
258 258
259ia64_vector sn_irq_to_vector(int irq)
260{
261 if (irq >= IA64_NUM_VECTORS)
262 return 0;
263 return (ia64_vector)irq;
264}
265
259unsigned int sn_local_vector_to_irq(u8 vector) 266unsigned int sn_local_vector_to_irq(u8 vector)
260{ 267{
261 return (CPU_VECTOR_TO_IRQ(smp_processor_id(), vector)); 268 return (CPU_VECTOR_TO_IRQ(smp_processor_id(), vector));