diff options
author | Jeff Garzik <jgarzik@pobox.com> | 2006-02-09 00:59:34 -0500 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2006-02-09 00:59:34 -0500 |
commit | 725b2805fd5d729b0db59fe8fc992e97523782c7 (patch) | |
tree | 04ca7c7ed6e918029898a6c5301488e60d0564d4 /arch/ia64/sn/kernel/irq.c | |
parent | 9ac341ae799413708e674bc65c8a72c90dae8d34 (diff) | |
parent | cac0e8e8bb2e7a086643bdd00c41d900a79bb4fa (diff) |
Merge branch 'upstream-fixes'
Diffstat (limited to 'arch/ia64/sn/kernel/irq.c')
-rw-r--r-- | arch/ia64/sn/kernel/irq.c | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/arch/ia64/sn/kernel/irq.c b/arch/ia64/sn/kernel/irq.c index ec37084bdc17..74d87d903d5d 100644 --- a/arch/ia64/sn/kernel/irq.c +++ b/arch/ia64/sn/kernel/irq.c | |||
@@ -5,11 +5,12 @@ | |||
5 | * License. See the file "COPYING" in the main directory of this archive | 5 | * License. See the file "COPYING" in the main directory of this archive |
6 | * for more details. | 6 | * for more details. |
7 | * | 7 | * |
8 | * Copyright (c) 2000-2005 Silicon Graphics, Inc. All Rights Reserved. | 8 | * Copyright (c) 2000-2006 Silicon Graphics, Inc. All Rights Reserved. |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #include <linux/irq.h> | 11 | #include <linux/irq.h> |
12 | #include <linux/spinlock.h> | 12 | #include <linux/spinlock.h> |
13 | #include <linux/init.h> | ||
13 | #include <asm/sn/addrs.h> | 14 | #include <asm/sn/addrs.h> |
14 | #include <asm/sn/arch.h> | 15 | #include <asm/sn/arch.h> |
15 | #include <asm/sn/intr.h> | 16 | #include <asm/sn/intr.h> |
@@ -76,17 +77,15 @@ static void sn_enable_irq(unsigned int irq) | |||
76 | 77 | ||
77 | static void sn_ack_irq(unsigned int irq) | 78 | static void sn_ack_irq(unsigned int irq) |
78 | { | 79 | { |
79 | u64 event_occurred, mask = 0; | 80 | u64 event_occurred, mask; |
80 | 81 | ||
81 | irq = irq & 0xff; | 82 | irq = irq & 0xff; |
82 | event_occurred = | 83 | event_occurred = HUB_L((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED)); |
83 | HUB_L((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED)); | ||
84 | mask = event_occurred & SH_ALL_INT_MASK; | 84 | mask = event_occurred & SH_ALL_INT_MASK; |
85 | HUB_S((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED_ALIAS), | 85 | HUB_S((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED_ALIAS), mask); |
86 | mask); | ||
87 | __set_bit(irq, (volatile void *)pda->sn_in_service_ivecs); | 86 | __set_bit(irq, (volatile void *)pda->sn_in_service_ivecs); |
88 | 87 | ||
89 | move_irq(irq); | 88 | move_native_irq(irq); |
90 | } | 89 | } |
91 | 90 | ||
92 | static void sn_end_irq(unsigned int irq) | 91 | static void sn_end_irq(unsigned int irq) |
@@ -219,9 +218,8 @@ static void register_intr_pda(struct sn_irq_info *sn_irq_info) | |||
219 | pdacpu(cpu)->sn_last_irq = irq; | 218 | pdacpu(cpu)->sn_last_irq = irq; |
220 | } | 219 | } |
221 | 220 | ||
222 | if (pdacpu(cpu)->sn_first_irq == 0 || pdacpu(cpu)->sn_first_irq > irq) { | 221 | if (pdacpu(cpu)->sn_first_irq == 0 || pdacpu(cpu)->sn_first_irq > irq) |
223 | pdacpu(cpu)->sn_first_irq = irq; | 222 | pdacpu(cpu)->sn_first_irq = irq; |
224 | } | ||
225 | } | 223 | } |
226 | 224 | ||
227 | static void unregister_intr_pda(struct sn_irq_info *sn_irq_info) | 225 | static void unregister_intr_pda(struct sn_irq_info *sn_irq_info) |
@@ -289,7 +287,7 @@ void sn_irq_fixup(struct pci_dev *pci_dev, struct sn_irq_info *sn_irq_info) | |||
289 | list_add_rcu(&sn_irq_info->list, sn_irq_lh[sn_irq_info->irq_irq]); | 287 | list_add_rcu(&sn_irq_info->list, sn_irq_lh[sn_irq_info->irq_irq]); |
290 | spin_unlock(&sn_irq_info_lock); | 288 | spin_unlock(&sn_irq_info_lock); |
291 | 289 | ||
292 | (void)register_intr_pda(sn_irq_info); | 290 | register_intr_pda(sn_irq_info); |
293 | } | 291 | } |
294 | 292 | ||
295 | void sn_irq_unfixup(struct pci_dev *pci_dev) | 293 | void sn_irq_unfixup(struct pci_dev *pci_dev) |
@@ -419,7 +417,7 @@ void sn_lb_int_war_check(void) | |||
419 | rcu_read_unlock(); | 417 | rcu_read_unlock(); |
420 | } | 418 | } |
421 | 419 | ||
422 | void sn_irq_lh_init(void) | 420 | void __init sn_irq_lh_init(void) |
423 | { | 421 | { |
424 | int i; | 422 | int i; |
425 | 423 | ||
@@ -434,5 +432,4 @@ void sn_irq_lh_init(void) | |||
434 | 432 | ||
435 | INIT_LIST_HEAD(sn_irq_lh[i]); | 433 | INIT_LIST_HEAD(sn_irq_lh[i]); |
436 | } | 434 | } |
437 | |||
438 | } | 435 | } |