diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2009-11-17 10:46:45 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2009-12-14 17:55:33 -0500 |
commit | 239007b8440abff689632f50cdf0f2b9e895b534 (patch) | |
tree | 569cab843af4a999d6d868ec9a824530d2bfa733 | |
parent | 9f5a5621e78cf48d86682a71ceb3fcdbde38b222 (diff) |
genirq: Convert irq_desc.lock to raw_spinlock
Convert locks which cannot be sleeping locks in preempt-rt to
raw_spinlocks.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Peter Zijlstra <peterz@infradead.org>
Acked-by: Ingo Molnar <mingo@elte.hu>
43 files changed, 240 insertions, 240 deletions
diff --git a/arch/alpha/kernel/irq.c b/arch/alpha/kernel/irq.c index c0de072b8305..5f2cf23c4648 100644 --- a/arch/alpha/kernel/irq.c +++ b/arch/alpha/kernel/irq.c | |||
@@ -81,7 +81,7 @@ show_interrupts(struct seq_file *p, void *v) | |||
81 | #endif | 81 | #endif |
82 | 82 | ||
83 | if (irq < ACTUAL_NR_IRQS) { | 83 | if (irq < ACTUAL_NR_IRQS) { |
84 | spin_lock_irqsave(&irq_desc[irq].lock, flags); | 84 | raw_spin_lock_irqsave(&irq_desc[irq].lock, flags); |
85 | action = irq_desc[irq].action; | 85 | action = irq_desc[irq].action; |
86 | if (!action) | 86 | if (!action) |
87 | goto unlock; | 87 | goto unlock; |
@@ -105,7 +105,7 @@ show_interrupts(struct seq_file *p, void *v) | |||
105 | 105 | ||
106 | seq_putc(p, '\n'); | 106 | seq_putc(p, '\n'); |
107 | unlock: | 107 | unlock: |
108 | spin_unlock_irqrestore(&irq_desc[irq].lock, flags); | 108 | raw_spin_unlock_irqrestore(&irq_desc[irq].lock, flags); |
109 | } else if (irq == ACTUAL_NR_IRQS) { | 109 | } else if (irq == ACTUAL_NR_IRQS) { |
110 | #ifdef CONFIG_SMP | 110 | #ifdef CONFIG_SMP |
111 | seq_puts(p, "IPI: "); | 111 | seq_puts(p, "IPI: "); |
diff --git a/arch/arm/include/asm/mach/irq.h b/arch/arm/include/asm/mach/irq.h index acac5302e4ea..8920b2d6e3b8 100644 --- a/arch/arm/include/asm/mach/irq.h +++ b/arch/arm/include/asm/mach/irq.h | |||
@@ -26,9 +26,9 @@ extern int show_fiq_list(struct seq_file *, void *); | |||
26 | */ | 26 | */ |
27 | #define do_bad_IRQ(irq,desc) \ | 27 | #define do_bad_IRQ(irq,desc) \ |
28 | do { \ | 28 | do { \ |
29 | spin_lock(&desc->lock); \ | 29 | raw_spin_lock(&desc->lock); \ |
30 | handle_bad_irq(irq, desc); \ | 30 | handle_bad_irq(irq, desc); \ |
31 | spin_unlock(&desc->lock); \ | 31 | raw_spin_unlock(&desc->lock); \ |
32 | } while(0) | 32 | } while(0) |
33 | 33 | ||
34 | #endif | 34 | #endif |
diff --git a/arch/arm/kernel/irq.c b/arch/arm/kernel/irq.c index c9a8619f3856..b7cb45bb91e8 100644 --- a/arch/arm/kernel/irq.c +++ b/arch/arm/kernel/irq.c | |||
@@ -69,7 +69,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
69 | } | 69 | } |
70 | 70 | ||
71 | if (i < NR_IRQS) { | 71 | if (i < NR_IRQS) { |
72 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 72 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
73 | action = irq_desc[i].action; | 73 | action = irq_desc[i].action; |
74 | if (!action) | 74 | if (!action) |
75 | goto unlock; | 75 | goto unlock; |
@@ -84,7 +84,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
84 | 84 | ||
85 | seq_putc(p, '\n'); | 85 | seq_putc(p, '\n'); |
86 | unlock: | 86 | unlock: |
87 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 87 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
88 | } else if (i == NR_IRQS) { | 88 | } else if (i == NR_IRQS) { |
89 | #ifdef CONFIG_FIQ | 89 | #ifdef CONFIG_FIQ |
90 | show_fiq_list(p, v); | 90 | show_fiq_list(p, v); |
@@ -139,7 +139,7 @@ void set_irq_flags(unsigned int irq, unsigned int iflags) | |||
139 | } | 139 | } |
140 | 140 | ||
141 | desc = irq_desc + irq; | 141 | desc = irq_desc + irq; |
142 | spin_lock_irqsave(&desc->lock, flags); | 142 | raw_spin_lock_irqsave(&desc->lock, flags); |
143 | desc->status |= IRQ_NOREQUEST | IRQ_NOPROBE | IRQ_NOAUTOEN; | 143 | desc->status |= IRQ_NOREQUEST | IRQ_NOPROBE | IRQ_NOAUTOEN; |
144 | if (iflags & IRQF_VALID) | 144 | if (iflags & IRQF_VALID) |
145 | desc->status &= ~IRQ_NOREQUEST; | 145 | desc->status &= ~IRQ_NOREQUEST; |
@@ -147,7 +147,7 @@ void set_irq_flags(unsigned int irq, unsigned int iflags) | |||
147 | desc->status &= ~IRQ_NOPROBE; | 147 | desc->status &= ~IRQ_NOPROBE; |
148 | if (!(iflags & IRQF_NOAUTOEN)) | 148 | if (!(iflags & IRQF_NOAUTOEN)) |
149 | desc->status &= ~IRQ_NOAUTOEN; | 149 | desc->status &= ~IRQ_NOAUTOEN; |
150 | spin_unlock_irqrestore(&desc->lock, flags); | 150 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
151 | } | 151 | } |
152 | 152 | ||
153 | void __init init_IRQ(void) | 153 | void __init init_IRQ(void) |
@@ -166,9 +166,9 @@ static void route_irq(struct irq_desc *desc, unsigned int irq, unsigned int cpu) | |||
166 | { | 166 | { |
167 | pr_debug("IRQ%u: moving from cpu%u to cpu%u\n", irq, desc->node, cpu); | 167 | pr_debug("IRQ%u: moving from cpu%u to cpu%u\n", irq, desc->node, cpu); |
168 | 168 | ||
169 | spin_lock_irq(&desc->lock); | 169 | raw_spin_lock_irq(&desc->lock); |
170 | desc->chip->set_affinity(irq, cpumask_of(cpu)); | 170 | desc->chip->set_affinity(irq, cpumask_of(cpu)); |
171 | spin_unlock_irq(&desc->lock); | 171 | raw_spin_unlock_irq(&desc->lock); |
172 | } | 172 | } |
173 | 173 | ||
174 | /* | 174 | /* |
diff --git a/arch/arm/mach-ns9xxx/irq.c b/arch/arm/mach-ns9xxx/irq.c index feb0e54a91de..038f24d47023 100644 --- a/arch/arm/mach-ns9xxx/irq.c +++ b/arch/arm/mach-ns9xxx/irq.c | |||
@@ -66,7 +66,7 @@ static void handle_prio_irq(unsigned int irq, struct irq_desc *desc) | |||
66 | struct irqaction *action; | 66 | struct irqaction *action; |
67 | irqreturn_t action_ret; | 67 | irqreturn_t action_ret; |
68 | 68 | ||
69 | spin_lock(&desc->lock); | 69 | raw_spin_lock(&desc->lock); |
70 | 70 | ||
71 | BUG_ON(desc->status & IRQ_INPROGRESS); | 71 | BUG_ON(desc->status & IRQ_INPROGRESS); |
72 | 72 | ||
@@ -78,7 +78,7 @@ static void handle_prio_irq(unsigned int irq, struct irq_desc *desc) | |||
78 | goto out_mask; | 78 | goto out_mask; |
79 | 79 | ||
80 | desc->status |= IRQ_INPROGRESS; | 80 | desc->status |= IRQ_INPROGRESS; |
81 | spin_unlock(&desc->lock); | 81 | raw_spin_unlock(&desc->lock); |
82 | 82 | ||
83 | action_ret = handle_IRQ_event(irq, action); | 83 | action_ret = handle_IRQ_event(irq, action); |
84 | 84 | ||
@@ -87,7 +87,7 @@ static void handle_prio_irq(unsigned int irq, struct irq_desc *desc) | |||
87 | * Maybe this function should go to kernel/irq/chip.c? */ | 87 | * Maybe this function should go to kernel/irq/chip.c? */ |
88 | note_interrupt(irq, desc, action_ret); | 88 | note_interrupt(irq, desc, action_ret); |
89 | 89 | ||
90 | spin_lock(&desc->lock); | 90 | raw_spin_lock(&desc->lock); |
91 | desc->status &= ~IRQ_INPROGRESS; | 91 | desc->status &= ~IRQ_INPROGRESS; |
92 | 92 | ||
93 | if (desc->status & IRQ_DISABLED) | 93 | if (desc->status & IRQ_DISABLED) |
@@ -97,7 +97,7 @@ out_mask: | |||
97 | /* ack unconditionally to unmask lower prio irqs */ | 97 | /* ack unconditionally to unmask lower prio irqs */ |
98 | desc->chip->ack(irq); | 98 | desc->chip->ack(irq); |
99 | 99 | ||
100 | spin_unlock(&desc->lock); | 100 | raw_spin_unlock(&desc->lock); |
101 | } | 101 | } |
102 | #define handle_irq handle_prio_irq | 102 | #define handle_irq handle_prio_irq |
103 | #endif | 103 | #endif |
diff --git a/arch/avr32/kernel/irq.c b/arch/avr32/kernel/irq.c index 9f572229d318..c8ab63e3a675 100644 --- a/arch/avr32/kernel/irq.c +++ b/arch/avr32/kernel/irq.c | |||
@@ -51,7 +51,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
51 | } | 51 | } |
52 | 52 | ||
53 | if (i < NR_IRQS) { | 53 | if (i < NR_IRQS) { |
54 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 54 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
55 | action = irq_desc[i].action; | 55 | action = irq_desc[i].action; |
56 | if (!action) | 56 | if (!action) |
57 | goto unlock; | 57 | goto unlock; |
@@ -66,7 +66,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
66 | 66 | ||
67 | seq_putc(p, '\n'); | 67 | seq_putc(p, '\n'); |
68 | unlock: | 68 | unlock: |
69 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 69 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
70 | } | 70 | } |
71 | 71 | ||
72 | return 0; | 72 | return 0; |
diff --git a/arch/blackfin/kernel/irqchip.c b/arch/blackfin/kernel/irqchip.c index db9f9c91f11f..64cff54a8a58 100644 --- a/arch/blackfin/kernel/irqchip.c +++ b/arch/blackfin/kernel/irqchip.c | |||
@@ -23,7 +23,7 @@ void ack_bad_irq(unsigned int irq) | |||
23 | 23 | ||
24 | static struct irq_desc bad_irq_desc = { | 24 | static struct irq_desc bad_irq_desc = { |
25 | .handle_irq = handle_bad_irq, | 25 | .handle_irq = handle_bad_irq, |
26 | .lock = __SPIN_LOCK_UNLOCKED(irq_desc->lock), | 26 | .lock = __RAW_SPIN_LOCK_UNLOCKED(bad_irq_desc.lock), |
27 | }; | 27 | }; |
28 | 28 | ||
29 | #ifdef CONFIG_CPUMASK_OFFSTACK | 29 | #ifdef CONFIG_CPUMASK_OFFSTACK |
@@ -39,7 +39,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
39 | unsigned long flags; | 39 | unsigned long flags; |
40 | 40 | ||
41 | if (i < NR_IRQS) { | 41 | if (i < NR_IRQS) { |
42 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 42 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
43 | action = irq_desc[i].action; | 43 | action = irq_desc[i].action; |
44 | if (!action) | 44 | if (!action) |
45 | goto skip; | 45 | goto skip; |
@@ -53,7 +53,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
53 | 53 | ||
54 | seq_putc(p, '\n'); | 54 | seq_putc(p, '\n'); |
55 | skip: | 55 | skip: |
56 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 56 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
57 | } else if (i == NR_IRQS) { | 57 | } else if (i == NR_IRQS) { |
58 | seq_printf(p, "NMI: "); | 58 | seq_printf(p, "NMI: "); |
59 | for_each_online_cpu(j) | 59 | for_each_online_cpu(j) |
diff --git a/arch/blackfin/kernel/traps.c b/arch/blackfin/kernel/traps.c index 78cb3d38f899..9636bace00e8 100644 --- a/arch/blackfin/kernel/traps.c +++ b/arch/blackfin/kernel/traps.c | |||
@@ -1140,7 +1140,7 @@ void show_regs(struct pt_regs *fp) | |||
1140 | if (fp->ipend & ~0x3F) { | 1140 | if (fp->ipend & ~0x3F) { |
1141 | for (i = 0; i < (NR_IRQS - 1); i++) { | 1141 | for (i = 0; i < (NR_IRQS - 1); i++) { |
1142 | if (!in_atomic) | 1142 | if (!in_atomic) |
1143 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 1143 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
1144 | 1144 | ||
1145 | action = irq_desc[i].action; | 1145 | action = irq_desc[i].action; |
1146 | if (!action) | 1146 | if (!action) |
@@ -1155,7 +1155,7 @@ void show_regs(struct pt_regs *fp) | |||
1155 | verbose_printk("\n"); | 1155 | verbose_printk("\n"); |
1156 | unlock: | 1156 | unlock: |
1157 | if (!in_atomic) | 1157 | if (!in_atomic) |
1158 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 1158 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
1159 | } | 1159 | } |
1160 | } | 1160 | } |
1161 | 1161 | ||
diff --git a/arch/cris/kernel/irq.c b/arch/cris/kernel/irq.c index 0ca7d9892cc6..b5ce0724a88f 100644 --- a/arch/cris/kernel/irq.c +++ b/arch/cris/kernel/irq.c | |||
@@ -52,7 +52,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
52 | } | 52 | } |
53 | 53 | ||
54 | if (i < NR_IRQS) { | 54 | if (i < NR_IRQS) { |
55 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 55 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
56 | action = irq_desc[i].action; | 56 | action = irq_desc[i].action; |
57 | if (!action) | 57 | if (!action) |
58 | goto skip; | 58 | goto skip; |
@@ -71,7 +71,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
71 | 71 | ||
72 | seq_putc(p, '\n'); | 72 | seq_putc(p, '\n'); |
73 | skip: | 73 | skip: |
74 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 74 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
75 | } | 75 | } |
76 | return 0; | 76 | return 0; |
77 | } | 77 | } |
diff --git a/arch/frv/kernel/irq.c b/arch/frv/kernel/irq.c index af3e824b91b3..62d1aba615dc 100644 --- a/arch/frv/kernel/irq.c +++ b/arch/frv/kernel/irq.c | |||
@@ -69,7 +69,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
69 | } | 69 | } |
70 | 70 | ||
71 | if (i < NR_IRQS) { | 71 | if (i < NR_IRQS) { |
72 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 72 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
73 | action = irq_desc[i].action; | 73 | action = irq_desc[i].action; |
74 | if (action) { | 74 | if (action) { |
75 | seq_printf(p, "%3d: ", i); | 75 | seq_printf(p, "%3d: ", i); |
@@ -85,7 +85,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
85 | seq_putc(p, '\n'); | 85 | seq_putc(p, '\n'); |
86 | } | 86 | } |
87 | 87 | ||
88 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 88 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
89 | } else if (i == NR_IRQS) { | 89 | } else if (i == NR_IRQS) { |
90 | seq_printf(p, "Err: %10u\n", atomic_read(&irq_err_count)); | 90 | seq_printf(p, "Err: %10u\n", atomic_read(&irq_err_count)); |
91 | } | 91 | } |
diff --git a/arch/h8300/kernel/irq.c b/arch/h8300/kernel/irq.c index 5c913d472119..c25dc2c2b1da 100644 --- a/arch/h8300/kernel/irq.c +++ b/arch/h8300/kernel/irq.c | |||
@@ -186,7 +186,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
186 | seq_puts(p, " CPU0"); | 186 | seq_puts(p, " CPU0"); |
187 | 187 | ||
188 | if (i < NR_IRQS) { | 188 | if (i < NR_IRQS) { |
189 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 189 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
190 | action = irq_desc[i].action; | 190 | action = irq_desc[i].action; |
191 | if (!action) | 191 | if (!action) |
192 | goto unlock; | 192 | goto unlock; |
@@ -200,7 +200,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
200 | seq_printf(p, ", %s", action->name); | 200 | seq_printf(p, ", %s", action->name); |
201 | seq_putc(p, '\n'); | 201 | seq_putc(p, '\n'); |
202 | unlock: | 202 | unlock: |
203 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 203 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
204 | } | 204 | } |
205 | return 0; | 205 | return 0; |
206 | } | 206 | } |
diff --git a/arch/ia64/kernel/iosapic.c b/arch/ia64/kernel/iosapic.c index dab4d393908c..95ac77aeae9b 100644 --- a/arch/ia64/kernel/iosapic.c +++ b/arch/ia64/kernel/iosapic.c | |||
@@ -793,12 +793,12 @@ iosapic_register_intr (unsigned int gsi, | |||
793 | goto unlock_iosapic_lock; | 793 | goto unlock_iosapic_lock; |
794 | } | 794 | } |
795 | 795 | ||
796 | spin_lock(&irq_desc[irq].lock); | 796 | raw_spin_lock(&irq_desc[irq].lock); |
797 | dest = get_target_cpu(gsi, irq); | 797 | dest = get_target_cpu(gsi, irq); |
798 | dmode = choose_dmode(); | 798 | dmode = choose_dmode(); |
799 | err = register_intr(gsi, irq, dmode, polarity, trigger); | 799 | err = register_intr(gsi, irq, dmode, polarity, trigger); |
800 | if (err < 0) { | 800 | if (err < 0) { |
801 | spin_unlock(&irq_desc[irq].lock); | 801 | raw_spin_unlock(&irq_desc[irq].lock); |
802 | irq = err; | 802 | irq = err; |
803 | goto unlock_iosapic_lock; | 803 | goto unlock_iosapic_lock; |
804 | } | 804 | } |
@@ -817,7 +817,7 @@ iosapic_register_intr (unsigned int gsi, | |||
817 | (polarity == IOSAPIC_POL_HIGH ? "high" : "low"), | 817 | (polarity == IOSAPIC_POL_HIGH ? "high" : "low"), |
818 | cpu_logical_id(dest), dest, irq_to_vector(irq)); | 818 | cpu_logical_id(dest), dest, irq_to_vector(irq)); |
819 | 819 | ||
820 | spin_unlock(&irq_desc[irq].lock); | 820 | raw_spin_unlock(&irq_desc[irq].lock); |
821 | unlock_iosapic_lock: | 821 | unlock_iosapic_lock: |
822 | spin_unlock_irqrestore(&iosapic_lock, flags); | 822 | spin_unlock_irqrestore(&iosapic_lock, flags); |
823 | return irq; | 823 | return irq; |
diff --git a/arch/ia64/kernel/irq.c b/arch/ia64/kernel/irq.c index 7d8951229e7c..94ee9d067cbd 100644 --- a/arch/ia64/kernel/irq.c +++ b/arch/ia64/kernel/irq.c | |||
@@ -71,7 +71,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
71 | } | 71 | } |
72 | 72 | ||
73 | if (i < NR_IRQS) { | 73 | if (i < NR_IRQS) { |
74 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 74 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
75 | action = irq_desc[i].action; | 75 | action = irq_desc[i].action; |
76 | if (!action) | 76 | if (!action) |
77 | goto skip; | 77 | goto skip; |
@@ -91,7 +91,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
91 | 91 | ||
92 | seq_putc(p, '\n'); | 92 | seq_putc(p, '\n'); |
93 | skip: | 93 | skip: |
94 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 94 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
95 | } else if (i == NR_IRQS) | 95 | } else if (i == NR_IRQS) |
96 | seq_printf(p, "ERR: %10u\n", atomic_read(&irq_err_count)); | 96 | seq_printf(p, "ERR: %10u\n", atomic_read(&irq_err_count)); |
97 | return 0; | 97 | return 0; |
diff --git a/arch/ia64/kernel/irq_ia64.c b/arch/ia64/kernel/irq_ia64.c index dd9d7b54f1a1..70e4bad23432 100644 --- a/arch/ia64/kernel/irq_ia64.c +++ b/arch/ia64/kernel/irq_ia64.c | |||
@@ -345,7 +345,7 @@ static irqreturn_t smp_irq_move_cleanup_interrupt(int irq, void *dev_id) | |||
345 | 345 | ||
346 | desc = irq_desc + irq; | 346 | desc = irq_desc + irq; |
347 | cfg = irq_cfg + irq; | 347 | cfg = irq_cfg + irq; |
348 | spin_lock(&desc->lock); | 348 | raw_spin_lock(&desc->lock); |
349 | if (!cfg->move_cleanup_count) | 349 | if (!cfg->move_cleanup_count) |
350 | goto unlock; | 350 | goto unlock; |
351 | 351 | ||
@@ -358,7 +358,7 @@ static irqreturn_t smp_irq_move_cleanup_interrupt(int irq, void *dev_id) | |||
358 | spin_unlock_irqrestore(&vector_lock, flags); | 358 | spin_unlock_irqrestore(&vector_lock, flags); |
359 | cfg->move_cleanup_count--; | 359 | cfg->move_cleanup_count--; |
360 | unlock: | 360 | unlock: |
361 | spin_unlock(&desc->lock); | 361 | raw_spin_unlock(&desc->lock); |
362 | } | 362 | } |
363 | return IRQ_HANDLED; | 363 | return IRQ_HANDLED; |
364 | } | 364 | } |
diff --git a/arch/m32r/kernel/irq.c b/arch/m32r/kernel/irq.c index 8dfd31e87c4c..3c71f776872c 100644 --- a/arch/m32r/kernel/irq.c +++ b/arch/m32r/kernel/irq.c | |||
@@ -40,7 +40,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
40 | } | 40 | } |
41 | 41 | ||
42 | if (i < NR_IRQS) { | 42 | if (i < NR_IRQS) { |
43 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 43 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
44 | action = irq_desc[i].action; | 44 | action = irq_desc[i].action; |
45 | if (!action) | 45 | if (!action) |
46 | goto skip; | 46 | goto skip; |
@@ -59,7 +59,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
59 | 59 | ||
60 | seq_putc(p, '\n'); | 60 | seq_putc(p, '\n'); |
61 | skip: | 61 | skip: |
62 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 62 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
63 | } | 63 | } |
64 | return 0; | 64 | return 0; |
65 | } | 65 | } |
diff --git a/arch/microblaze/kernel/irq.c b/arch/microblaze/kernel/irq.c index 7d5ddd62d4d2..0f06034d1fe0 100644 --- a/arch/microblaze/kernel/irq.c +++ b/arch/microblaze/kernel/irq.c | |||
@@ -68,7 +68,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
68 | } | 68 | } |
69 | 69 | ||
70 | if (i < nr_irq) { | 70 | if (i < nr_irq) { |
71 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 71 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
72 | action = irq_desc[i].action; | 72 | action = irq_desc[i].action; |
73 | if (!action) | 73 | if (!action) |
74 | goto skip; | 74 | goto skip; |
@@ -89,7 +89,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
89 | 89 | ||
90 | seq_putc(p, '\n'); | 90 | seq_putc(p, '\n'); |
91 | skip: | 91 | skip: |
92 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 92 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
93 | } | 93 | } |
94 | return 0; | 94 | return 0; |
95 | } | 95 | } |
diff --git a/arch/mips/kernel/irq.c b/arch/mips/kernel/irq.c index 7b845ba9dff4..8b0b4181219f 100644 --- a/arch/mips/kernel/irq.c +++ b/arch/mips/kernel/irq.c | |||
@@ -99,7 +99,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
99 | } | 99 | } |
100 | 100 | ||
101 | if (i < NR_IRQS) { | 101 | if (i < NR_IRQS) { |
102 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 102 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
103 | action = irq_desc[i].action; | 103 | action = irq_desc[i].action; |
104 | if (!action) | 104 | if (!action) |
105 | goto skip; | 105 | goto skip; |
@@ -118,7 +118,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
118 | 118 | ||
119 | seq_putc(p, '\n'); | 119 | seq_putc(p, '\n'); |
120 | skip: | 120 | skip: |
121 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 121 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
122 | } else if (i == NR_IRQS) { | 122 | } else if (i == NR_IRQS) { |
123 | seq_putc(p, '\n'); | 123 | seq_putc(p, '\n'); |
124 | seq_printf(p, "ERR: %10u\n", atomic_read(&irq_err_count)); | 124 | seq_printf(p, "ERR: %10u\n", atomic_read(&irq_err_count)); |
diff --git a/arch/mips/vr41xx/common/icu.c b/arch/mips/vr41xx/common/icu.c index 6d39e222b170..6153b6a05ccf 100644 --- a/arch/mips/vr41xx/common/icu.c +++ b/arch/mips/vr41xx/common/icu.c | |||
@@ -159,9 +159,9 @@ void vr41xx_enable_piuint(uint16_t mask) | |||
159 | 159 | ||
160 | if (current_cpu_type() == CPU_VR4111 || | 160 | if (current_cpu_type() == CPU_VR4111 || |
161 | current_cpu_type() == CPU_VR4121) { | 161 | current_cpu_type() == CPU_VR4121) { |
162 | spin_lock_irqsave(&desc->lock, flags); | 162 | raw_spin_lock_irqsave(&desc->lock, flags); |
163 | icu1_set(MPIUINTREG, mask); | 163 | icu1_set(MPIUINTREG, mask); |
164 | spin_unlock_irqrestore(&desc->lock, flags); | 164 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
165 | } | 165 | } |
166 | } | 166 | } |
167 | 167 | ||
@@ -174,9 +174,9 @@ void vr41xx_disable_piuint(uint16_t mask) | |||
174 | 174 | ||
175 | if (current_cpu_type() == CPU_VR4111 || | 175 | if (current_cpu_type() == CPU_VR4111 || |
176 | current_cpu_type() == CPU_VR4121) { | 176 | current_cpu_type() == CPU_VR4121) { |
177 | spin_lock_irqsave(&desc->lock, flags); | 177 | raw_spin_lock_irqsave(&desc->lock, flags); |
178 | icu1_clear(MPIUINTREG, mask); | 178 | icu1_clear(MPIUINTREG, mask); |
179 | spin_unlock_irqrestore(&desc->lock, flags); | 179 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
180 | } | 180 | } |
181 | } | 181 | } |
182 | 182 | ||
@@ -189,9 +189,9 @@ void vr41xx_enable_aiuint(uint16_t mask) | |||
189 | 189 | ||
190 | if (current_cpu_type() == CPU_VR4111 || | 190 | if (current_cpu_type() == CPU_VR4111 || |
191 | current_cpu_type() == CPU_VR4121) { | 191 | current_cpu_type() == CPU_VR4121) { |
192 | spin_lock_irqsave(&desc->lock, flags); | 192 | raw_spin_lock_irqsave(&desc->lock, flags); |
193 | icu1_set(MAIUINTREG, mask); | 193 | icu1_set(MAIUINTREG, mask); |
194 | spin_unlock_irqrestore(&desc->lock, flags); | 194 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
195 | } | 195 | } |
196 | } | 196 | } |
197 | 197 | ||
@@ -204,9 +204,9 @@ void vr41xx_disable_aiuint(uint16_t mask) | |||
204 | 204 | ||
205 | if (current_cpu_type() == CPU_VR4111 || | 205 | if (current_cpu_type() == CPU_VR4111 || |
206 | current_cpu_type() == CPU_VR4121) { | 206 | current_cpu_type() == CPU_VR4121) { |
207 | spin_lock_irqsave(&desc->lock, flags); | 207 | raw_spin_lock_irqsave(&desc->lock, flags); |
208 | icu1_clear(MAIUINTREG, mask); | 208 | icu1_clear(MAIUINTREG, mask); |
209 | spin_unlock_irqrestore(&desc->lock, flags); | 209 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
210 | } | 210 | } |
211 | } | 211 | } |
212 | 212 | ||
@@ -219,9 +219,9 @@ void vr41xx_enable_kiuint(uint16_t mask) | |||
219 | 219 | ||
220 | if (current_cpu_type() == CPU_VR4111 || | 220 | if (current_cpu_type() == CPU_VR4111 || |
221 | current_cpu_type() == CPU_VR4121) { | 221 | current_cpu_type() == CPU_VR4121) { |
222 | spin_lock_irqsave(&desc->lock, flags); | 222 | raw_spin_lock_irqsave(&desc->lock, flags); |
223 | icu1_set(MKIUINTREG, mask); | 223 | icu1_set(MKIUINTREG, mask); |
224 | spin_unlock_irqrestore(&desc->lock, flags); | 224 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
225 | } | 225 | } |
226 | } | 226 | } |
227 | 227 | ||
@@ -234,9 +234,9 @@ void vr41xx_disable_kiuint(uint16_t mask) | |||
234 | 234 | ||
235 | if (current_cpu_type() == CPU_VR4111 || | 235 | if (current_cpu_type() == CPU_VR4111 || |
236 | current_cpu_type() == CPU_VR4121) { | 236 | current_cpu_type() == CPU_VR4121) { |
237 | spin_lock_irqsave(&desc->lock, flags); | 237 | raw_spin_lock_irqsave(&desc->lock, flags); |
238 | icu1_clear(MKIUINTREG, mask); | 238 | icu1_clear(MKIUINTREG, mask); |
239 | spin_unlock_irqrestore(&desc->lock, flags); | 239 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
240 | } | 240 | } |
241 | } | 241 | } |
242 | 242 | ||
@@ -247,9 +247,9 @@ void vr41xx_enable_macint(uint16_t mask) | |||
247 | struct irq_desc *desc = irq_desc + ETHERNET_IRQ; | 247 | struct irq_desc *desc = irq_desc + ETHERNET_IRQ; |
248 | unsigned long flags; | 248 | unsigned long flags; |
249 | 249 | ||
250 | spin_lock_irqsave(&desc->lock, flags); | 250 | raw_spin_lock_irqsave(&desc->lock, flags); |
251 | icu1_set(MMACINTREG, mask); | 251 | icu1_set(MMACINTREG, mask); |
252 | spin_unlock_irqrestore(&desc->lock, flags); | 252 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
253 | } | 253 | } |
254 | 254 | ||
255 | EXPORT_SYMBOL(vr41xx_enable_macint); | 255 | EXPORT_SYMBOL(vr41xx_enable_macint); |
@@ -259,9 +259,9 @@ void vr41xx_disable_macint(uint16_t mask) | |||
259 | struct irq_desc *desc = irq_desc + ETHERNET_IRQ; | 259 | struct irq_desc *desc = irq_desc + ETHERNET_IRQ; |
260 | unsigned long flags; | 260 | unsigned long flags; |
261 | 261 | ||
262 | spin_lock_irqsave(&desc->lock, flags); | 262 | raw_spin_lock_irqsave(&desc->lock, flags); |
263 | icu1_clear(MMACINTREG, mask); | 263 | icu1_clear(MMACINTREG, mask); |
264 | spin_unlock_irqrestore(&desc->lock, flags); | 264 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
265 | } | 265 | } |
266 | 266 | ||
267 | EXPORT_SYMBOL(vr41xx_disable_macint); | 267 | EXPORT_SYMBOL(vr41xx_disable_macint); |
@@ -271,9 +271,9 @@ void vr41xx_enable_dsiuint(uint16_t mask) | |||
271 | struct irq_desc *desc = irq_desc + DSIU_IRQ; | 271 | struct irq_desc *desc = irq_desc + DSIU_IRQ; |
272 | unsigned long flags; | 272 | unsigned long flags; |
273 | 273 | ||
274 | spin_lock_irqsave(&desc->lock, flags); | 274 | raw_spin_lock_irqsave(&desc->lock, flags); |
275 | icu1_set(MDSIUINTREG, mask); | 275 | icu1_set(MDSIUINTREG, mask); |
276 | spin_unlock_irqrestore(&desc->lock, flags); | 276 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
277 | } | 277 | } |
278 | 278 | ||
279 | EXPORT_SYMBOL(vr41xx_enable_dsiuint); | 279 | EXPORT_SYMBOL(vr41xx_enable_dsiuint); |
@@ -283,9 +283,9 @@ void vr41xx_disable_dsiuint(uint16_t mask) | |||
283 | struct irq_desc *desc = irq_desc + DSIU_IRQ; | 283 | struct irq_desc *desc = irq_desc + DSIU_IRQ; |
284 | unsigned long flags; | 284 | unsigned long flags; |
285 | 285 | ||
286 | spin_lock_irqsave(&desc->lock, flags); | 286 | raw_spin_lock_irqsave(&desc->lock, flags); |
287 | icu1_clear(MDSIUINTREG, mask); | 287 | icu1_clear(MDSIUINTREG, mask); |
288 | spin_unlock_irqrestore(&desc->lock, flags); | 288 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
289 | } | 289 | } |
290 | 290 | ||
291 | EXPORT_SYMBOL(vr41xx_disable_dsiuint); | 291 | EXPORT_SYMBOL(vr41xx_disable_dsiuint); |
@@ -295,9 +295,9 @@ void vr41xx_enable_firint(uint16_t mask) | |||
295 | struct irq_desc *desc = irq_desc + FIR_IRQ; | 295 | struct irq_desc *desc = irq_desc + FIR_IRQ; |
296 | unsigned long flags; | 296 | unsigned long flags; |
297 | 297 | ||
298 | spin_lock_irqsave(&desc->lock, flags); | 298 | raw_spin_lock_irqsave(&desc->lock, flags); |
299 | icu2_set(MFIRINTREG, mask); | 299 | icu2_set(MFIRINTREG, mask); |
300 | spin_unlock_irqrestore(&desc->lock, flags); | 300 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
301 | } | 301 | } |
302 | 302 | ||
303 | EXPORT_SYMBOL(vr41xx_enable_firint); | 303 | EXPORT_SYMBOL(vr41xx_enable_firint); |
@@ -307,9 +307,9 @@ void vr41xx_disable_firint(uint16_t mask) | |||
307 | struct irq_desc *desc = irq_desc + FIR_IRQ; | 307 | struct irq_desc *desc = irq_desc + FIR_IRQ; |
308 | unsigned long flags; | 308 | unsigned long flags; |
309 | 309 | ||
310 | spin_lock_irqsave(&desc->lock, flags); | 310 | raw_spin_lock_irqsave(&desc->lock, flags); |
311 | icu2_clear(MFIRINTREG, mask); | 311 | icu2_clear(MFIRINTREG, mask); |
312 | spin_unlock_irqrestore(&desc->lock, flags); | 312 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
313 | } | 313 | } |
314 | 314 | ||
315 | EXPORT_SYMBOL(vr41xx_disable_firint); | 315 | EXPORT_SYMBOL(vr41xx_disable_firint); |
@@ -322,9 +322,9 @@ void vr41xx_enable_pciint(void) | |||
322 | if (current_cpu_type() == CPU_VR4122 || | 322 | if (current_cpu_type() == CPU_VR4122 || |
323 | current_cpu_type() == CPU_VR4131 || | 323 | current_cpu_type() == CPU_VR4131 || |
324 | current_cpu_type() == CPU_VR4133) { | 324 | current_cpu_type() == CPU_VR4133) { |
325 | spin_lock_irqsave(&desc->lock, flags); | 325 | raw_spin_lock_irqsave(&desc->lock, flags); |
326 | icu2_write(MPCIINTREG, PCIINT0); | 326 | icu2_write(MPCIINTREG, PCIINT0); |
327 | spin_unlock_irqrestore(&desc->lock, flags); | 327 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
328 | } | 328 | } |
329 | } | 329 | } |
330 | 330 | ||
@@ -338,9 +338,9 @@ void vr41xx_disable_pciint(void) | |||
338 | if (current_cpu_type() == CPU_VR4122 || | 338 | if (current_cpu_type() == CPU_VR4122 || |
339 | current_cpu_type() == CPU_VR4131 || | 339 | current_cpu_type() == CPU_VR4131 || |
340 | current_cpu_type() == CPU_VR4133) { | 340 | current_cpu_type() == CPU_VR4133) { |
341 | spin_lock_irqsave(&desc->lock, flags); | 341 | raw_spin_lock_irqsave(&desc->lock, flags); |
342 | icu2_write(MPCIINTREG, 0); | 342 | icu2_write(MPCIINTREG, 0); |
343 | spin_unlock_irqrestore(&desc->lock, flags); | 343 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
344 | } | 344 | } |
345 | } | 345 | } |
346 | 346 | ||
@@ -354,9 +354,9 @@ void vr41xx_enable_scuint(void) | |||
354 | if (current_cpu_type() == CPU_VR4122 || | 354 | if (current_cpu_type() == CPU_VR4122 || |
355 | current_cpu_type() == CPU_VR4131 || | 355 | current_cpu_type() == CPU_VR4131 || |
356 | current_cpu_type() == CPU_VR4133) { | 356 | current_cpu_type() == CPU_VR4133) { |
357 | spin_lock_irqsave(&desc->lock, flags); | 357 | raw_spin_lock_irqsave(&desc->lock, flags); |
358 | icu2_write(MSCUINTREG, SCUINT0); | 358 | icu2_write(MSCUINTREG, SCUINT0); |
359 | spin_unlock_irqrestore(&desc->lock, flags); | 359 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
360 | } | 360 | } |
361 | } | 361 | } |
362 | 362 | ||
@@ -370,9 +370,9 @@ void vr41xx_disable_scuint(void) | |||
370 | if (current_cpu_type() == CPU_VR4122 || | 370 | if (current_cpu_type() == CPU_VR4122 || |
371 | current_cpu_type() == CPU_VR4131 || | 371 | current_cpu_type() == CPU_VR4131 || |
372 | current_cpu_type() == CPU_VR4133) { | 372 | current_cpu_type() == CPU_VR4133) { |
373 | spin_lock_irqsave(&desc->lock, flags); | 373 | raw_spin_lock_irqsave(&desc->lock, flags); |
374 | icu2_write(MSCUINTREG, 0); | 374 | icu2_write(MSCUINTREG, 0); |
375 | spin_unlock_irqrestore(&desc->lock, flags); | 375 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
376 | } | 376 | } |
377 | } | 377 | } |
378 | 378 | ||
@@ -386,9 +386,9 @@ void vr41xx_enable_csiint(uint16_t mask) | |||
386 | if (current_cpu_type() == CPU_VR4122 || | 386 | if (current_cpu_type() == CPU_VR4122 || |
387 | current_cpu_type() == CPU_VR4131 || | 387 | current_cpu_type() == CPU_VR4131 || |
388 | current_cpu_type() == CPU_VR4133) { | 388 | current_cpu_type() == CPU_VR4133) { |
389 | spin_lock_irqsave(&desc->lock, flags); | 389 | raw_spin_lock_irqsave(&desc->lock, flags); |
390 | icu2_set(MCSIINTREG, mask); | 390 | icu2_set(MCSIINTREG, mask); |
391 | spin_unlock_irqrestore(&desc->lock, flags); | 391 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
392 | } | 392 | } |
393 | } | 393 | } |
394 | 394 | ||
@@ -402,9 +402,9 @@ void vr41xx_disable_csiint(uint16_t mask) | |||
402 | if (current_cpu_type() == CPU_VR4122 || | 402 | if (current_cpu_type() == CPU_VR4122 || |
403 | current_cpu_type() == CPU_VR4131 || | 403 | current_cpu_type() == CPU_VR4131 || |
404 | current_cpu_type() == CPU_VR4133) { | 404 | current_cpu_type() == CPU_VR4133) { |
405 | spin_lock_irqsave(&desc->lock, flags); | 405 | raw_spin_lock_irqsave(&desc->lock, flags); |
406 | icu2_clear(MCSIINTREG, mask); | 406 | icu2_clear(MCSIINTREG, mask); |
407 | spin_unlock_irqrestore(&desc->lock, flags); | 407 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
408 | } | 408 | } |
409 | } | 409 | } |
410 | 410 | ||
@@ -418,9 +418,9 @@ void vr41xx_enable_bcuint(void) | |||
418 | if (current_cpu_type() == CPU_VR4122 || | 418 | if (current_cpu_type() == CPU_VR4122 || |
419 | current_cpu_type() == CPU_VR4131 || | 419 | current_cpu_type() == CPU_VR4131 || |
420 | current_cpu_type() == CPU_VR4133) { | 420 | current_cpu_type() == CPU_VR4133) { |
421 | spin_lock_irqsave(&desc->lock, flags); | 421 | raw_spin_lock_irqsave(&desc->lock, flags); |
422 | icu2_write(MBCUINTREG, BCUINTR); | 422 | icu2_write(MBCUINTREG, BCUINTR); |
423 | spin_unlock_irqrestore(&desc->lock, flags); | 423 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
424 | } | 424 | } |
425 | } | 425 | } |
426 | 426 | ||
@@ -434,9 +434,9 @@ void vr41xx_disable_bcuint(void) | |||
434 | if (current_cpu_type() == CPU_VR4122 || | 434 | if (current_cpu_type() == CPU_VR4122 || |
435 | current_cpu_type() == CPU_VR4131 || | 435 | current_cpu_type() == CPU_VR4131 || |
436 | current_cpu_type() == CPU_VR4133) { | 436 | current_cpu_type() == CPU_VR4133) { |
437 | spin_lock_irqsave(&desc->lock, flags); | 437 | raw_spin_lock_irqsave(&desc->lock, flags); |
438 | icu2_write(MBCUINTREG, 0); | 438 | icu2_write(MBCUINTREG, 0); |
439 | spin_unlock_irqrestore(&desc->lock, flags); | 439 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
440 | } | 440 | } |
441 | } | 441 | } |
442 | 442 | ||
@@ -486,7 +486,7 @@ static inline int set_sysint1_assign(unsigned int irq, unsigned char assign) | |||
486 | 486 | ||
487 | pin = SYSINT1_IRQ_TO_PIN(irq); | 487 | pin = SYSINT1_IRQ_TO_PIN(irq); |
488 | 488 | ||
489 | spin_lock_irq(&desc->lock); | 489 | raw_spin_lock_irq(&desc->lock); |
490 | 490 | ||
491 | intassign0 = icu1_read(INTASSIGN0); | 491 | intassign0 = icu1_read(INTASSIGN0); |
492 | intassign1 = icu1_read(INTASSIGN1); | 492 | intassign1 = icu1_read(INTASSIGN1); |
@@ -525,7 +525,7 @@ static inline int set_sysint1_assign(unsigned int irq, unsigned char assign) | |||
525 | intassign1 |= (uint16_t)assign << 9; | 525 | intassign1 |= (uint16_t)assign << 9; |
526 | break; | 526 | break; |
527 | default: | 527 | default: |
528 | spin_unlock_irq(&desc->lock); | 528 | raw_spin_unlock_irq(&desc->lock); |
529 | return -EINVAL; | 529 | return -EINVAL; |
530 | } | 530 | } |
531 | 531 | ||
@@ -533,7 +533,7 @@ static inline int set_sysint1_assign(unsigned int irq, unsigned char assign) | |||
533 | icu1_write(INTASSIGN0, intassign0); | 533 | icu1_write(INTASSIGN0, intassign0); |
534 | icu1_write(INTASSIGN1, intassign1); | 534 | icu1_write(INTASSIGN1, intassign1); |
535 | 535 | ||
536 | spin_unlock_irq(&desc->lock); | 536 | raw_spin_unlock_irq(&desc->lock); |
537 | 537 | ||
538 | return 0; | 538 | return 0; |
539 | } | 539 | } |
@@ -546,7 +546,7 @@ static inline int set_sysint2_assign(unsigned int irq, unsigned char assign) | |||
546 | 546 | ||
547 | pin = SYSINT2_IRQ_TO_PIN(irq); | 547 | pin = SYSINT2_IRQ_TO_PIN(irq); |
548 | 548 | ||
549 | spin_lock_irq(&desc->lock); | 549 | raw_spin_lock_irq(&desc->lock); |
550 | 550 | ||
551 | intassign2 = icu1_read(INTASSIGN2); | 551 | intassign2 = icu1_read(INTASSIGN2); |
552 | intassign3 = icu1_read(INTASSIGN3); | 552 | intassign3 = icu1_read(INTASSIGN3); |
@@ -593,7 +593,7 @@ static inline int set_sysint2_assign(unsigned int irq, unsigned char assign) | |||
593 | intassign3 |= (uint16_t)assign << 12; | 593 | intassign3 |= (uint16_t)assign << 12; |
594 | break; | 594 | break; |
595 | default: | 595 | default: |
596 | spin_unlock_irq(&desc->lock); | 596 | raw_spin_unlock_irq(&desc->lock); |
597 | return -EINVAL; | 597 | return -EINVAL; |
598 | } | 598 | } |
599 | 599 | ||
@@ -601,7 +601,7 @@ static inline int set_sysint2_assign(unsigned int irq, unsigned char assign) | |||
601 | icu1_write(INTASSIGN2, intassign2); | 601 | icu1_write(INTASSIGN2, intassign2); |
602 | icu1_write(INTASSIGN3, intassign3); | 602 | icu1_write(INTASSIGN3, intassign3); |
603 | 603 | ||
604 | spin_unlock_irq(&desc->lock); | 604 | raw_spin_unlock_irq(&desc->lock); |
605 | 605 | ||
606 | return 0; | 606 | return 0; |
607 | } | 607 | } |
diff --git a/arch/mn10300/kernel/irq.c b/arch/mn10300/kernel/irq.c index 4c3c58ef5cda..e2d5ed891f37 100644 --- a/arch/mn10300/kernel/irq.c +++ b/arch/mn10300/kernel/irq.c | |||
@@ -215,7 +215,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
215 | 215 | ||
216 | /* display information rows, one per active CPU */ | 216 | /* display information rows, one per active CPU */ |
217 | case 1 ... NR_IRQS - 1: | 217 | case 1 ... NR_IRQS - 1: |
218 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 218 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
219 | 219 | ||
220 | action = irq_desc[i].action; | 220 | action = irq_desc[i].action; |
221 | if (action) { | 221 | if (action) { |
@@ -235,7 +235,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
235 | seq_putc(p, '\n'); | 235 | seq_putc(p, '\n'); |
236 | } | 236 | } |
237 | 237 | ||
238 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 238 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
239 | break; | 239 | break; |
240 | 240 | ||
241 | /* polish off with NMI and error counters */ | 241 | /* polish off with NMI and error counters */ |
diff --git a/arch/parisc/kernel/irq.c b/arch/parisc/kernel/irq.c index 2e7610cb33d5..f47465e8d040 100644 --- a/arch/parisc/kernel/irq.c +++ b/arch/parisc/kernel/irq.c | |||
@@ -180,7 +180,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
180 | if (i < NR_IRQS) { | 180 | if (i < NR_IRQS) { |
181 | struct irqaction *action; | 181 | struct irqaction *action; |
182 | 182 | ||
183 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 183 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
184 | action = irq_desc[i].action; | 184 | action = irq_desc[i].action; |
185 | if (!action) | 185 | if (!action) |
186 | goto skip; | 186 | goto skip; |
@@ -224,7 +224,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
224 | 224 | ||
225 | seq_putc(p, '\n'); | 225 | seq_putc(p, '\n'); |
226 | skip: | 226 | skip: |
227 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 227 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
228 | } | 228 | } |
229 | 229 | ||
230 | return 0; | 230 | return 0; |
diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c index f6dca4f4b295..9040330b0530 100644 --- a/arch/powerpc/kernel/irq.c +++ b/arch/powerpc/kernel/irq.c | |||
@@ -210,7 +210,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
210 | if (!desc) | 210 | if (!desc) |
211 | return 0; | 211 | return 0; |
212 | 212 | ||
213 | spin_lock_irqsave(&desc->lock, flags); | 213 | raw_spin_lock_irqsave(&desc->lock, flags); |
214 | 214 | ||
215 | action = desc->action; | 215 | action = desc->action; |
216 | if (!action || !action->handler) | 216 | if (!action || !action->handler) |
@@ -237,7 +237,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
237 | seq_putc(p, '\n'); | 237 | seq_putc(p, '\n'); |
238 | 238 | ||
239 | skip: | 239 | skip: |
240 | spin_unlock_irqrestore(&desc->lock, flags); | 240 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
241 | 241 | ||
242 | return 0; | 242 | return 0; |
243 | } | 243 | } |
@@ -1112,7 +1112,7 @@ static int virq_debug_show(struct seq_file *m, void *private) | |||
1112 | if (!desc) | 1112 | if (!desc) |
1113 | continue; | 1113 | continue; |
1114 | 1114 | ||
1115 | spin_lock_irqsave(&desc->lock, flags); | 1115 | raw_spin_lock_irqsave(&desc->lock, flags); |
1116 | 1116 | ||
1117 | if (desc->action && desc->action->handler) { | 1117 | if (desc->action && desc->action->handler) { |
1118 | seq_printf(m, "%5d ", i); | 1118 | seq_printf(m, "%5d ", i); |
@@ -1131,7 +1131,7 @@ static int virq_debug_show(struct seq_file *m, void *private) | |||
1131 | seq_printf(m, "%s\n", p); | 1131 | seq_printf(m, "%s\n", p); |
1132 | } | 1132 | } |
1133 | 1133 | ||
1134 | spin_unlock_irqrestore(&desc->lock, flags); | 1134 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
1135 | } | 1135 | } |
1136 | 1136 | ||
1137 | return 0; | 1137 | return 0; |
diff --git a/arch/powerpc/platforms/52xx/media5200.c b/arch/powerpc/platforms/52xx/media5200.c index cc0c854291d7..0bac3a3dbecf 100644 --- a/arch/powerpc/platforms/52xx/media5200.c +++ b/arch/powerpc/platforms/52xx/media5200.c | |||
@@ -86,9 +86,9 @@ void media5200_irq_cascade(unsigned int virq, struct irq_desc *desc) | |||
86 | u32 status, enable; | 86 | u32 status, enable; |
87 | 87 | ||
88 | /* Mask off the cascaded IRQ */ | 88 | /* Mask off the cascaded IRQ */ |
89 | spin_lock(&desc->lock); | 89 | raw_spin_lock(&desc->lock); |
90 | desc->chip->mask(virq); | 90 | desc->chip->mask(virq); |
91 | spin_unlock(&desc->lock); | 91 | raw_spin_unlock(&desc->lock); |
92 | 92 | ||
93 | /* Ask the FPGA for IRQ status. If 'val' is 0, then no irqs | 93 | /* Ask the FPGA for IRQ status. If 'val' is 0, then no irqs |
94 | * are pending. 'ffs()' is 1 based */ | 94 | * are pending. 'ffs()' is 1 based */ |
@@ -104,11 +104,11 @@ void media5200_irq_cascade(unsigned int virq, struct irq_desc *desc) | |||
104 | } | 104 | } |
105 | 105 | ||
106 | /* Processing done; can reenable the cascade now */ | 106 | /* Processing done; can reenable the cascade now */ |
107 | spin_lock(&desc->lock); | 107 | raw_spin_lock(&desc->lock); |
108 | desc->chip->ack(virq); | 108 | desc->chip->ack(virq); |
109 | if (!(desc->status & IRQ_DISABLED)) | 109 | if (!(desc->status & IRQ_DISABLED)) |
110 | desc->chip->unmask(virq); | 110 | desc->chip->unmask(virq); |
111 | spin_unlock(&desc->lock); | 111 | raw_spin_unlock(&desc->lock); |
112 | } | 112 | } |
113 | 113 | ||
114 | static int media5200_irq_map(struct irq_host *h, unsigned int virq, | 114 | static int media5200_irq_map(struct irq_host *h, unsigned int virq, |
diff --git a/arch/powerpc/platforms/cell/interrupt.c b/arch/powerpc/platforms/cell/interrupt.c index 7267effc8078..6829cf7e2bda 100644 --- a/arch/powerpc/platforms/cell/interrupt.c +++ b/arch/powerpc/platforms/cell/interrupt.c | |||
@@ -237,7 +237,7 @@ extern int noirqdebug; | |||
237 | 237 | ||
238 | static void handle_iic_irq(unsigned int irq, struct irq_desc *desc) | 238 | static void handle_iic_irq(unsigned int irq, struct irq_desc *desc) |
239 | { | 239 | { |
240 | spin_lock(&desc->lock); | 240 | raw_spin_lock(&desc->lock); |
241 | 241 | ||
242 | desc->status &= ~(IRQ_REPLAY | IRQ_WAITING); | 242 | desc->status &= ~(IRQ_REPLAY | IRQ_WAITING); |
243 | 243 | ||
@@ -265,18 +265,18 @@ static void handle_iic_irq(unsigned int irq, struct irq_desc *desc) | |||
265 | goto out_eoi; | 265 | goto out_eoi; |
266 | 266 | ||
267 | desc->status &= ~IRQ_PENDING; | 267 | desc->status &= ~IRQ_PENDING; |
268 | spin_unlock(&desc->lock); | 268 | raw_spin_unlock(&desc->lock); |
269 | action_ret = handle_IRQ_event(irq, action); | 269 | action_ret = handle_IRQ_event(irq, action); |
270 | if (!noirqdebug) | 270 | if (!noirqdebug) |
271 | note_interrupt(irq, desc, action_ret); | 271 | note_interrupt(irq, desc, action_ret); |
272 | spin_lock(&desc->lock); | 272 | raw_spin_lock(&desc->lock); |
273 | 273 | ||
274 | } while ((desc->status & (IRQ_PENDING | IRQ_DISABLED)) == IRQ_PENDING); | 274 | } while ((desc->status & (IRQ_PENDING | IRQ_DISABLED)) == IRQ_PENDING); |
275 | 275 | ||
276 | desc->status &= ~IRQ_INPROGRESS; | 276 | desc->status &= ~IRQ_INPROGRESS; |
277 | out_eoi: | 277 | out_eoi: |
278 | desc->chip->eoi(irq); | 278 | desc->chip->eoi(irq); |
279 | spin_unlock(&desc->lock); | 279 | raw_spin_unlock(&desc->lock); |
280 | } | 280 | } |
281 | 281 | ||
282 | static int iic_host_map(struct irq_host *h, unsigned int virq, | 282 | static int iic_host_map(struct irq_host *h, unsigned int virq, |
diff --git a/arch/powerpc/platforms/iseries/irq.c b/arch/powerpc/platforms/iseries/irq.c index 07762259c60a..86c4b29eea89 100644 --- a/arch/powerpc/platforms/iseries/irq.c +++ b/arch/powerpc/platforms/iseries/irq.c | |||
@@ -217,9 +217,9 @@ void __init iSeries_activate_IRQs() | |||
217 | struct irq_desc *desc = irq_to_desc(irq); | 217 | struct irq_desc *desc = irq_to_desc(irq); |
218 | 218 | ||
219 | if (desc && desc->chip && desc->chip->startup) { | 219 | if (desc && desc->chip && desc->chip->startup) { |
220 | spin_lock_irqsave(&desc->lock, flags); | 220 | raw_spin_lock_irqsave(&desc->lock, flags); |
221 | desc->chip->startup(irq); | 221 | desc->chip->startup(irq); |
222 | spin_unlock_irqrestore(&desc->lock, flags); | 222 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
223 | } | 223 | } |
224 | } | 224 | } |
225 | } | 225 | } |
diff --git a/arch/powerpc/platforms/pseries/xics.c b/arch/powerpc/platforms/pseries/xics.c index 7d01b58f3989..b9b9e11609ec 100644 --- a/arch/powerpc/platforms/pseries/xics.c +++ b/arch/powerpc/platforms/pseries/xics.c | |||
@@ -906,7 +906,7 @@ void xics_migrate_irqs_away(void) | |||
906 | || desc->chip->set_affinity == NULL) | 906 | || desc->chip->set_affinity == NULL) |
907 | continue; | 907 | continue; |
908 | 908 | ||
909 | spin_lock_irqsave(&desc->lock, flags); | 909 | raw_spin_lock_irqsave(&desc->lock, flags); |
910 | 910 | ||
911 | status = rtas_call(ibm_get_xive, 1, 3, xics_status, irq); | 911 | status = rtas_call(ibm_get_xive, 1, 3, xics_status, irq); |
912 | if (status) { | 912 | if (status) { |
@@ -930,7 +930,7 @@ void xics_migrate_irqs_away(void) | |||
930 | cpumask_setall(irq_to_desc(virq)->affinity); | 930 | cpumask_setall(irq_to_desc(virq)->affinity); |
931 | desc->chip->set_affinity(virq, cpu_all_mask); | 931 | desc->chip->set_affinity(virq, cpu_all_mask); |
932 | unlock: | 932 | unlock: |
933 | spin_unlock_irqrestore(&desc->lock, flags); | 933 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
934 | } | 934 | } |
935 | } | 935 | } |
936 | #endif | 936 | #endif |
diff --git a/arch/powerpc/sysdev/fsl_msi.c b/arch/powerpc/sysdev/fsl_msi.c index 62e50258cdef..c6e11b077108 100644 --- a/arch/powerpc/sysdev/fsl_msi.c +++ b/arch/powerpc/sysdev/fsl_msi.c | |||
@@ -173,7 +173,7 @@ static void fsl_msi_cascade(unsigned int irq, struct irq_desc *desc) | |||
173 | u32 intr_index; | 173 | u32 intr_index; |
174 | u32 have_shift = 0; | 174 | u32 have_shift = 0; |
175 | 175 | ||
176 | spin_lock(&desc->lock); | 176 | raw_spin_lock(&desc->lock); |
177 | if ((msi_data->feature & FSL_PIC_IP_MASK) == FSL_PIC_IP_IPIC) { | 177 | if ((msi_data->feature & FSL_PIC_IP_MASK) == FSL_PIC_IP_IPIC) { |
178 | if (desc->chip->mask_ack) | 178 | if (desc->chip->mask_ack) |
179 | desc->chip->mask_ack(irq); | 179 | desc->chip->mask_ack(irq); |
@@ -225,7 +225,7 @@ static void fsl_msi_cascade(unsigned int irq, struct irq_desc *desc) | |||
225 | break; | 225 | break; |
226 | } | 226 | } |
227 | unlock: | 227 | unlock: |
228 | spin_unlock(&desc->lock); | 228 | raw_spin_unlock(&desc->lock); |
229 | } | 229 | } |
230 | 230 | ||
231 | static int __devinit fsl_of_msi_probe(struct of_device *dev, | 231 | static int __devinit fsl_of_msi_probe(struct of_device *dev, |
diff --git a/arch/powerpc/sysdev/uic.c b/arch/powerpc/sysdev/uic.c index 7d10074b3304..6f220a913e42 100644 --- a/arch/powerpc/sysdev/uic.c +++ b/arch/powerpc/sysdev/uic.c | |||
@@ -225,12 +225,12 @@ void uic_irq_cascade(unsigned int virq, struct irq_desc *desc) | |||
225 | int src; | 225 | int src; |
226 | int subvirq; | 226 | int subvirq; |
227 | 227 | ||
228 | spin_lock(&desc->lock); | 228 | raw_spin_lock(&desc->lock); |
229 | if (desc->status & IRQ_LEVEL) | 229 | if (desc->status & IRQ_LEVEL) |
230 | desc->chip->mask(virq); | 230 | desc->chip->mask(virq); |
231 | else | 231 | else |
232 | desc->chip->mask_ack(virq); | 232 | desc->chip->mask_ack(virq); |
233 | spin_unlock(&desc->lock); | 233 | raw_spin_unlock(&desc->lock); |
234 | 234 | ||
235 | msr = mfdcr(uic->dcrbase + UIC_MSR); | 235 | msr = mfdcr(uic->dcrbase + UIC_MSR); |
236 | if (!msr) /* spurious interrupt */ | 236 | if (!msr) /* spurious interrupt */ |
@@ -242,12 +242,12 @@ void uic_irq_cascade(unsigned int virq, struct irq_desc *desc) | |||
242 | generic_handle_irq(subvirq); | 242 | generic_handle_irq(subvirq); |
243 | 243 | ||
244 | uic_irq_ret: | 244 | uic_irq_ret: |
245 | spin_lock(&desc->lock); | 245 | raw_spin_lock(&desc->lock); |
246 | if (desc->status & IRQ_LEVEL) | 246 | if (desc->status & IRQ_LEVEL) |
247 | desc->chip->ack(virq); | 247 | desc->chip->ack(virq); |
248 | if (!(desc->status & IRQ_DISABLED) && desc->chip->unmask) | 248 | if (!(desc->status & IRQ_DISABLED) && desc->chip->unmask) |
249 | desc->chip->unmask(virq); | 249 | desc->chip->unmask(virq); |
250 | spin_unlock(&desc->lock); | 250 | raw_spin_unlock(&desc->lock); |
251 | } | 251 | } |
252 | 252 | ||
253 | static struct uic * __init uic_init_one(struct device_node *node) | 253 | static struct uic * __init uic_init_one(struct device_node *node) |
diff --git a/arch/sh/kernel/irq.c b/arch/sh/kernel/irq.c index e1913f28f418..d2d41d046657 100644 --- a/arch/sh/kernel/irq.c +++ b/arch/sh/kernel/irq.c | |||
@@ -76,7 +76,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
76 | if (!desc) | 76 | if (!desc) |
77 | return 0; | 77 | return 0; |
78 | 78 | ||
79 | spin_lock_irqsave(&desc->lock, flags); | 79 | raw_spin_lock_irqsave(&desc->lock, flags); |
80 | for_each_online_cpu(j) | 80 | for_each_online_cpu(j) |
81 | any_count |= kstat_irqs_cpu(i, j); | 81 | any_count |= kstat_irqs_cpu(i, j); |
82 | action = desc->action; | 82 | action = desc->action; |
@@ -97,7 +97,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
97 | 97 | ||
98 | seq_putc(p, '\n'); | 98 | seq_putc(p, '\n'); |
99 | out: | 99 | out: |
100 | spin_unlock_irqrestore(&desc->lock, flags); | 100 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
101 | return 0; | 101 | return 0; |
102 | } | 102 | } |
103 | #endif | 103 | #endif |
diff --git a/arch/sparc/kernel/irq_64.c b/arch/sparc/kernel/irq_64.c index ce996f97855f..8d6882bb480a 100644 --- a/arch/sparc/kernel/irq_64.c +++ b/arch/sparc/kernel/irq_64.c | |||
@@ -176,7 +176,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
176 | } | 176 | } |
177 | 177 | ||
178 | if (i < NR_IRQS) { | 178 | if (i < NR_IRQS) { |
179 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 179 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
180 | action = irq_desc[i].action; | 180 | action = irq_desc[i].action; |
181 | if (!action) | 181 | if (!action) |
182 | goto skip; | 182 | goto skip; |
@@ -195,7 +195,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
195 | 195 | ||
196 | seq_putc(p, '\n'); | 196 | seq_putc(p, '\n'); |
197 | skip: | 197 | skip: |
198 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 198 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
199 | } else if (i == NR_IRQS) { | 199 | } else if (i == NR_IRQS) { |
200 | seq_printf(p, "NMI: "); | 200 | seq_printf(p, "NMI: "); |
201 | for_each_online_cpu(j) | 201 | for_each_online_cpu(j) |
@@ -785,14 +785,14 @@ void fixup_irqs(void) | |||
785 | for (irq = 0; irq < NR_IRQS; irq++) { | 785 | for (irq = 0; irq < NR_IRQS; irq++) { |
786 | unsigned long flags; | 786 | unsigned long flags; |
787 | 787 | ||
788 | spin_lock_irqsave(&irq_desc[irq].lock, flags); | 788 | raw_spin_lock_irqsave(&irq_desc[irq].lock, flags); |
789 | if (irq_desc[irq].action && | 789 | if (irq_desc[irq].action && |
790 | !(irq_desc[irq].status & IRQ_PER_CPU)) { | 790 | !(irq_desc[irq].status & IRQ_PER_CPU)) { |
791 | if (irq_desc[irq].chip->set_affinity) | 791 | if (irq_desc[irq].chip->set_affinity) |
792 | irq_desc[irq].chip->set_affinity(irq, | 792 | irq_desc[irq].chip->set_affinity(irq, |
793 | irq_desc[irq].affinity); | 793 | irq_desc[irq].affinity); |
794 | } | 794 | } |
795 | spin_unlock_irqrestore(&irq_desc[irq].lock, flags); | 795 | raw_spin_unlock_irqrestore(&irq_desc[irq].lock, flags); |
796 | } | 796 | } |
797 | 797 | ||
798 | tick_ops->disable_irq(); | 798 | tick_ops->disable_irq(); |
diff --git a/arch/um/kernel/irq.c b/arch/um/kernel/irq.c index 039270b9b73b..89474ba0741e 100644 --- a/arch/um/kernel/irq.c +++ b/arch/um/kernel/irq.c | |||
@@ -34,7 +34,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
34 | } | 34 | } |
35 | 35 | ||
36 | if (i < NR_IRQS) { | 36 | if (i < NR_IRQS) { |
37 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 37 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
38 | action = irq_desc[i].action; | 38 | action = irq_desc[i].action; |
39 | if (!action) | 39 | if (!action) |
40 | goto skip; | 40 | goto skip; |
@@ -53,7 +53,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
53 | 53 | ||
54 | seq_putc(p, '\n'); | 54 | seq_putc(p, '\n'); |
55 | skip: | 55 | skip: |
56 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 56 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
57 | } else if (i == NR_IRQS) | 57 | } else if (i == NR_IRQS) |
58 | seq_putc(p, '\n'); | 58 | seq_putc(p, '\n'); |
59 | 59 | ||
diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c index d5d498fbee4b..11a5851f1f50 100644 --- a/arch/x86/kernel/apic/io_apic.c +++ b/arch/x86/kernel/apic/io_apic.c | |||
@@ -2431,7 +2431,7 @@ asmlinkage void smp_irq_move_cleanup_interrupt(void) | |||
2431 | continue; | 2431 | continue; |
2432 | 2432 | ||
2433 | cfg = irq_cfg(irq); | 2433 | cfg = irq_cfg(irq); |
2434 | spin_lock(&desc->lock); | 2434 | raw_spin_lock(&desc->lock); |
2435 | 2435 | ||
2436 | if (vector == cfg->vector && cpumask_test_cpu(me, cfg->domain)) | 2436 | if (vector == cfg->vector && cpumask_test_cpu(me, cfg->domain)) |
2437 | goto unlock; | 2437 | goto unlock; |
@@ -2450,7 +2450,7 @@ asmlinkage void smp_irq_move_cleanup_interrupt(void) | |||
2450 | } | 2450 | } |
2451 | __get_cpu_var(vector_irq)[vector] = -1; | 2451 | __get_cpu_var(vector_irq)[vector] = -1; |
2452 | unlock: | 2452 | unlock: |
2453 | spin_unlock(&desc->lock); | 2453 | raw_spin_unlock(&desc->lock); |
2454 | } | 2454 | } |
2455 | 2455 | ||
2456 | irq_exit(); | 2456 | irq_exit(); |
diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c index 664bcb7384ac..91fd0c70a18a 100644 --- a/arch/x86/kernel/irq.c +++ b/arch/x86/kernel/irq.c | |||
@@ -149,7 +149,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
149 | if (!desc) | 149 | if (!desc) |
150 | return 0; | 150 | return 0; |
151 | 151 | ||
152 | spin_lock_irqsave(&desc->lock, flags); | 152 | raw_spin_lock_irqsave(&desc->lock, flags); |
153 | for_each_online_cpu(j) | 153 | for_each_online_cpu(j) |
154 | any_count |= kstat_irqs_cpu(i, j); | 154 | any_count |= kstat_irqs_cpu(i, j); |
155 | action = desc->action; | 155 | action = desc->action; |
@@ -170,7 +170,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
170 | 170 | ||
171 | seq_putc(p, '\n'); | 171 | seq_putc(p, '\n'); |
172 | out: | 172 | out: |
173 | spin_unlock_irqrestore(&desc->lock, flags); | 173 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
174 | return 0; | 174 | return 0; |
175 | } | 175 | } |
176 | 176 | ||
@@ -294,12 +294,12 @@ void fixup_irqs(void) | |||
294 | continue; | 294 | continue; |
295 | 295 | ||
296 | /* interrupt's are disabled at this point */ | 296 | /* interrupt's are disabled at this point */ |
297 | spin_lock(&desc->lock); | 297 | raw_spin_lock(&desc->lock); |
298 | 298 | ||
299 | affinity = desc->affinity; | 299 | affinity = desc->affinity; |
300 | if (!irq_has_action(irq) || | 300 | if (!irq_has_action(irq) || |
301 | cpumask_equal(affinity, cpu_online_mask)) { | 301 | cpumask_equal(affinity, cpu_online_mask)) { |
302 | spin_unlock(&desc->lock); | 302 | raw_spin_unlock(&desc->lock); |
303 | continue; | 303 | continue; |
304 | } | 304 | } |
305 | 305 | ||
@@ -326,7 +326,7 @@ void fixup_irqs(void) | |||
326 | if (!(desc->status & IRQ_MOVE_PCNTXT) && desc->chip->unmask) | 326 | if (!(desc->status & IRQ_MOVE_PCNTXT) && desc->chip->unmask) |
327 | desc->chip->unmask(irq); | 327 | desc->chip->unmask(irq); |
328 | 328 | ||
329 | spin_unlock(&desc->lock); | 329 | raw_spin_unlock(&desc->lock); |
330 | 330 | ||
331 | if (break_affinity && set_affinity) | 331 | if (break_affinity && set_affinity) |
332 | printk("Broke affinity for irq %i\n", irq); | 332 | printk("Broke affinity for irq %i\n", irq); |
@@ -356,10 +356,10 @@ void fixup_irqs(void) | |||
356 | irq = __get_cpu_var(vector_irq)[vector]; | 356 | irq = __get_cpu_var(vector_irq)[vector]; |
357 | 357 | ||
358 | desc = irq_to_desc(irq); | 358 | desc = irq_to_desc(irq); |
359 | spin_lock(&desc->lock); | 359 | raw_spin_lock(&desc->lock); |
360 | if (desc->chip->retrigger) | 360 | if (desc->chip->retrigger) |
361 | desc->chip->retrigger(irq); | 361 | desc->chip->retrigger(irq); |
362 | spin_unlock(&desc->lock); | 362 | raw_spin_unlock(&desc->lock); |
363 | } | 363 | } |
364 | } | 364 | } |
365 | } | 365 | } |
diff --git a/arch/xtensa/kernel/irq.c b/arch/xtensa/kernel/irq.c index a1badb32fcda..8cd38484e130 100644 --- a/arch/xtensa/kernel/irq.c +++ b/arch/xtensa/kernel/irq.c | |||
@@ -90,7 +90,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
90 | } | 90 | } |
91 | 91 | ||
92 | if (i < NR_IRQS) { | 92 | if (i < NR_IRQS) { |
93 | spin_lock_irqsave(&irq_desc[i].lock, flags); | 93 | raw_spin_lock_irqsave(&irq_desc[i].lock, flags); |
94 | action = irq_desc[i].action; | 94 | action = irq_desc[i].action; |
95 | if (!action) | 95 | if (!action) |
96 | goto skip; | 96 | goto skip; |
@@ -109,7 +109,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
109 | 109 | ||
110 | seq_putc(p, '\n'); | 110 | seq_putc(p, '\n'); |
111 | skip: | 111 | skip: |
112 | spin_unlock_irqrestore(&irq_desc[i].lock, flags); | 112 | raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); |
113 | } else if (i == NR_IRQS) { | 113 | } else if (i == NR_IRQS) { |
114 | seq_printf(p, "NMI: "); | 114 | seq_printf(p, "NMI: "); |
115 | for_each_online_cpu(j) | 115 | for_each_online_cpu(j) |
diff --git a/include/linux/irq.h b/include/linux/irq.h index a287cfc0b1a6..451481c082b5 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -192,7 +192,7 @@ struct irq_desc { | |||
192 | unsigned int irq_count; /* For detecting broken IRQs */ | 192 | unsigned int irq_count; /* For detecting broken IRQs */ |
193 | unsigned long last_unhandled; /* Aging timer for unhandled count */ | 193 | unsigned long last_unhandled; /* Aging timer for unhandled count */ |
194 | unsigned int irqs_unhandled; | 194 | unsigned int irqs_unhandled; |
195 | spinlock_t lock; | 195 | raw_spinlock_t lock; |
196 | #ifdef CONFIG_SMP | 196 | #ifdef CONFIG_SMP |
197 | cpumask_var_t affinity; | 197 | cpumask_var_t affinity; |
198 | unsigned int node; | 198 | unsigned int node; |
diff --git a/kernel/irq/autoprobe.c b/kernel/irq/autoprobe.c index 1de9700f416e..2295a31ef110 100644 --- a/kernel/irq/autoprobe.c +++ b/kernel/irq/autoprobe.c | |||
@@ -45,7 +45,7 @@ unsigned long probe_irq_on(void) | |||
45 | * flush such a longstanding irq before considering it as spurious. | 45 | * flush such a longstanding irq before considering it as spurious. |
46 | */ | 46 | */ |
47 | for_each_irq_desc_reverse(i, desc) { | 47 | for_each_irq_desc_reverse(i, desc) { |
48 | spin_lock_irq(&desc->lock); | 48 | raw_spin_lock_irq(&desc->lock); |
49 | if (!desc->action && !(desc->status & IRQ_NOPROBE)) { | 49 | if (!desc->action && !(desc->status & IRQ_NOPROBE)) { |
50 | /* | 50 | /* |
51 | * An old-style architecture might still have | 51 | * An old-style architecture might still have |
@@ -61,7 +61,7 @@ unsigned long probe_irq_on(void) | |||
61 | desc->chip->set_type(i, IRQ_TYPE_PROBE); | 61 | desc->chip->set_type(i, IRQ_TYPE_PROBE); |
62 | desc->chip->startup(i); | 62 | desc->chip->startup(i); |
63 | } | 63 | } |
64 | spin_unlock_irq(&desc->lock); | 64 | raw_spin_unlock_irq(&desc->lock); |
65 | } | 65 | } |
66 | 66 | ||
67 | /* Wait for longstanding interrupts to trigger. */ | 67 | /* Wait for longstanding interrupts to trigger. */ |
@@ -73,13 +73,13 @@ unsigned long probe_irq_on(void) | |||
73 | * happened in the previous stage, it may have masked itself) | 73 | * happened in the previous stage, it may have masked itself) |
74 | */ | 74 | */ |
75 | for_each_irq_desc_reverse(i, desc) { | 75 | for_each_irq_desc_reverse(i, desc) { |
76 | spin_lock_irq(&desc->lock); | 76 | raw_spin_lock_irq(&desc->lock); |
77 | if (!desc->action && !(desc->status & IRQ_NOPROBE)) { | 77 | if (!desc->action && !(desc->status & IRQ_NOPROBE)) { |
78 | desc->status |= IRQ_AUTODETECT | IRQ_WAITING; | 78 | desc->status |= IRQ_AUTODETECT | IRQ_WAITING; |
79 | if (desc->chip->startup(i)) | 79 | if (desc->chip->startup(i)) |
80 | desc->status |= IRQ_PENDING; | 80 | desc->status |= IRQ_PENDING; |
81 | } | 81 | } |
82 | spin_unlock_irq(&desc->lock); | 82 | raw_spin_unlock_irq(&desc->lock); |
83 | } | 83 | } |
84 | 84 | ||
85 | /* | 85 | /* |
@@ -91,7 +91,7 @@ unsigned long probe_irq_on(void) | |||
91 | * Now filter out any obviously spurious interrupts | 91 | * Now filter out any obviously spurious interrupts |
92 | */ | 92 | */ |
93 | for_each_irq_desc(i, desc) { | 93 | for_each_irq_desc(i, desc) { |
94 | spin_lock_irq(&desc->lock); | 94 | raw_spin_lock_irq(&desc->lock); |
95 | status = desc->status; | 95 | status = desc->status; |
96 | 96 | ||
97 | if (status & IRQ_AUTODETECT) { | 97 | if (status & IRQ_AUTODETECT) { |
@@ -103,7 +103,7 @@ unsigned long probe_irq_on(void) | |||
103 | if (i < 32) | 103 | if (i < 32) |
104 | mask |= 1 << i; | 104 | mask |= 1 << i; |
105 | } | 105 | } |
106 | spin_unlock_irq(&desc->lock); | 106 | raw_spin_unlock_irq(&desc->lock); |
107 | } | 107 | } |
108 | 108 | ||
109 | return mask; | 109 | return mask; |
@@ -129,7 +129,7 @@ unsigned int probe_irq_mask(unsigned long val) | |||
129 | int i; | 129 | int i; |
130 | 130 | ||
131 | for_each_irq_desc(i, desc) { | 131 | for_each_irq_desc(i, desc) { |
132 | spin_lock_irq(&desc->lock); | 132 | raw_spin_lock_irq(&desc->lock); |
133 | status = desc->status; | 133 | status = desc->status; |
134 | 134 | ||
135 | if (status & IRQ_AUTODETECT) { | 135 | if (status & IRQ_AUTODETECT) { |
@@ -139,7 +139,7 @@ unsigned int probe_irq_mask(unsigned long val) | |||
139 | desc->status = status & ~IRQ_AUTODETECT; | 139 | desc->status = status & ~IRQ_AUTODETECT; |
140 | desc->chip->shutdown(i); | 140 | desc->chip->shutdown(i); |
141 | } | 141 | } |
142 | spin_unlock_irq(&desc->lock); | 142 | raw_spin_unlock_irq(&desc->lock); |
143 | } | 143 | } |
144 | mutex_unlock(&probing_active); | 144 | mutex_unlock(&probing_active); |
145 | 145 | ||
@@ -171,7 +171,7 @@ int probe_irq_off(unsigned long val) | |||
171 | unsigned int status; | 171 | unsigned int status; |
172 | 172 | ||
173 | for_each_irq_desc(i, desc) { | 173 | for_each_irq_desc(i, desc) { |
174 | spin_lock_irq(&desc->lock); | 174 | raw_spin_lock_irq(&desc->lock); |
175 | status = desc->status; | 175 | status = desc->status; |
176 | 176 | ||
177 | if (status & IRQ_AUTODETECT) { | 177 | if (status & IRQ_AUTODETECT) { |
@@ -183,7 +183,7 @@ int probe_irq_off(unsigned long val) | |||
183 | desc->status = status & ~IRQ_AUTODETECT; | 183 | desc->status = status & ~IRQ_AUTODETECT; |
184 | desc->chip->shutdown(i); | 184 | desc->chip->shutdown(i); |
185 | } | 185 | } |
186 | spin_unlock_irq(&desc->lock); | 186 | raw_spin_unlock_irq(&desc->lock); |
187 | } | 187 | } |
188 | mutex_unlock(&probing_active); | 188 | mutex_unlock(&probing_active); |
189 | 189 | ||
diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c index ba566c261adc..ecc3fa28f666 100644 --- a/kernel/irq/chip.c +++ b/kernel/irq/chip.c | |||
@@ -34,7 +34,7 @@ void dynamic_irq_init(unsigned int irq) | |||
34 | } | 34 | } |
35 | 35 | ||
36 | /* Ensure we don't have left over values from a previous use of this irq */ | 36 | /* Ensure we don't have left over values from a previous use of this irq */ |
37 | spin_lock_irqsave(&desc->lock, flags); | 37 | raw_spin_lock_irqsave(&desc->lock, flags); |
38 | desc->status = IRQ_DISABLED; | 38 | desc->status = IRQ_DISABLED; |
39 | desc->chip = &no_irq_chip; | 39 | desc->chip = &no_irq_chip; |
40 | desc->handle_irq = handle_bad_irq; | 40 | desc->handle_irq = handle_bad_irq; |
@@ -51,7 +51,7 @@ void dynamic_irq_init(unsigned int irq) | |||
51 | cpumask_clear(desc->pending_mask); | 51 | cpumask_clear(desc->pending_mask); |
52 | #endif | 52 | #endif |
53 | #endif | 53 | #endif |
54 | spin_unlock_irqrestore(&desc->lock, flags); | 54 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
55 | } | 55 | } |
56 | 56 | ||
57 | /** | 57 | /** |
@@ -68,9 +68,9 @@ void dynamic_irq_cleanup(unsigned int irq) | |||
68 | return; | 68 | return; |
69 | } | 69 | } |
70 | 70 | ||
71 | spin_lock_irqsave(&desc->lock, flags); | 71 | raw_spin_lock_irqsave(&desc->lock, flags); |
72 | if (desc->action) { | 72 | if (desc->action) { |
73 | spin_unlock_irqrestore(&desc->lock, flags); | 73 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
74 | WARN(1, KERN_ERR "Destroying IRQ%d without calling free_irq\n", | 74 | WARN(1, KERN_ERR "Destroying IRQ%d without calling free_irq\n", |
75 | irq); | 75 | irq); |
76 | return; | 76 | return; |
@@ -82,7 +82,7 @@ void dynamic_irq_cleanup(unsigned int irq) | |||
82 | desc->chip = &no_irq_chip; | 82 | desc->chip = &no_irq_chip; |
83 | desc->name = NULL; | 83 | desc->name = NULL; |
84 | clear_kstat_irqs(desc); | 84 | clear_kstat_irqs(desc); |
85 | spin_unlock_irqrestore(&desc->lock, flags); | 85 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
86 | } | 86 | } |
87 | 87 | ||
88 | 88 | ||
@@ -104,10 +104,10 @@ int set_irq_chip(unsigned int irq, struct irq_chip *chip) | |||
104 | if (!chip) | 104 | if (!chip) |
105 | chip = &no_irq_chip; | 105 | chip = &no_irq_chip; |
106 | 106 | ||
107 | spin_lock_irqsave(&desc->lock, flags); | 107 | raw_spin_lock_irqsave(&desc->lock, flags); |
108 | irq_chip_set_defaults(chip); | 108 | irq_chip_set_defaults(chip); |
109 | desc->chip = chip; | 109 | desc->chip = chip; |
110 | spin_unlock_irqrestore(&desc->lock, flags); | 110 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
111 | 111 | ||
112 | return 0; | 112 | return 0; |
113 | } | 113 | } |
@@ -133,9 +133,9 @@ int set_irq_type(unsigned int irq, unsigned int type) | |||
133 | if (type == IRQ_TYPE_NONE) | 133 | if (type == IRQ_TYPE_NONE) |
134 | return 0; | 134 | return 0; |
135 | 135 | ||
136 | spin_lock_irqsave(&desc->lock, flags); | 136 | raw_spin_lock_irqsave(&desc->lock, flags); |
137 | ret = __irq_set_trigger(desc, irq, type); | 137 | ret = __irq_set_trigger(desc, irq, type); |
138 | spin_unlock_irqrestore(&desc->lock, flags); | 138 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
139 | return ret; | 139 | return ret; |
140 | } | 140 | } |
141 | EXPORT_SYMBOL(set_irq_type); | 141 | EXPORT_SYMBOL(set_irq_type); |
@@ -158,9 +158,9 @@ int set_irq_data(unsigned int irq, void *data) | |||
158 | return -EINVAL; | 158 | return -EINVAL; |
159 | } | 159 | } |
160 | 160 | ||
161 | spin_lock_irqsave(&desc->lock, flags); | 161 | raw_spin_lock_irqsave(&desc->lock, flags); |
162 | desc->handler_data = data; | 162 | desc->handler_data = data; |
163 | spin_unlock_irqrestore(&desc->lock, flags); | 163 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
164 | return 0; | 164 | return 0; |
165 | } | 165 | } |
166 | EXPORT_SYMBOL(set_irq_data); | 166 | EXPORT_SYMBOL(set_irq_data); |
@@ -183,11 +183,11 @@ int set_irq_msi(unsigned int irq, struct msi_desc *entry) | |||
183 | return -EINVAL; | 183 | return -EINVAL; |
184 | } | 184 | } |
185 | 185 | ||
186 | spin_lock_irqsave(&desc->lock, flags); | 186 | raw_spin_lock_irqsave(&desc->lock, flags); |
187 | desc->msi_desc = entry; | 187 | desc->msi_desc = entry; |
188 | if (entry) | 188 | if (entry) |
189 | entry->irq = irq; | 189 | entry->irq = irq; |
190 | spin_unlock_irqrestore(&desc->lock, flags); | 190 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
191 | return 0; | 191 | return 0; |
192 | } | 192 | } |
193 | 193 | ||
@@ -214,9 +214,9 @@ int set_irq_chip_data(unsigned int irq, void *data) | |||
214 | return -EINVAL; | 214 | return -EINVAL; |
215 | } | 215 | } |
216 | 216 | ||
217 | spin_lock_irqsave(&desc->lock, flags); | 217 | raw_spin_lock_irqsave(&desc->lock, flags); |
218 | desc->chip_data = data; | 218 | desc->chip_data = data; |
219 | spin_unlock_irqrestore(&desc->lock, flags); | 219 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
220 | 220 | ||
221 | return 0; | 221 | return 0; |
222 | } | 222 | } |
@@ -241,12 +241,12 @@ void set_irq_nested_thread(unsigned int irq, int nest) | |||
241 | if (!desc) | 241 | if (!desc) |
242 | return; | 242 | return; |
243 | 243 | ||
244 | spin_lock_irqsave(&desc->lock, flags); | 244 | raw_spin_lock_irqsave(&desc->lock, flags); |
245 | if (nest) | 245 | if (nest) |
246 | desc->status |= IRQ_NESTED_THREAD; | 246 | desc->status |= IRQ_NESTED_THREAD; |
247 | else | 247 | else |
248 | desc->status &= ~IRQ_NESTED_THREAD; | 248 | desc->status &= ~IRQ_NESTED_THREAD; |
249 | spin_unlock_irqrestore(&desc->lock, flags); | 249 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
250 | } | 250 | } |
251 | EXPORT_SYMBOL_GPL(set_irq_nested_thread); | 251 | EXPORT_SYMBOL_GPL(set_irq_nested_thread); |
252 | 252 | ||
@@ -343,7 +343,7 @@ void handle_nested_irq(unsigned int irq) | |||
343 | 343 | ||
344 | might_sleep(); | 344 | might_sleep(); |
345 | 345 | ||
346 | spin_lock_irq(&desc->lock); | 346 | raw_spin_lock_irq(&desc->lock); |
347 | 347 | ||
348 | kstat_incr_irqs_this_cpu(irq, desc); | 348 | kstat_incr_irqs_this_cpu(irq, desc); |
349 | 349 | ||
@@ -352,17 +352,17 @@ void handle_nested_irq(unsigned int irq) | |||
352 | goto out_unlock; | 352 | goto out_unlock; |
353 | 353 | ||
354 | desc->status |= IRQ_INPROGRESS; | 354 | desc->status |= IRQ_INPROGRESS; |
355 | spin_unlock_irq(&desc->lock); | 355 | raw_spin_unlock_irq(&desc->lock); |
356 | 356 | ||
357 | action_ret = action->thread_fn(action->irq, action->dev_id); | 357 | action_ret = action->thread_fn(action->irq, action->dev_id); |
358 | if (!noirqdebug) | 358 | if (!noirqdebug) |
359 | note_interrupt(irq, desc, action_ret); | 359 | note_interrupt(irq, desc, action_ret); |
360 | 360 | ||
361 | spin_lock_irq(&desc->lock); | 361 | raw_spin_lock_irq(&desc->lock); |
362 | desc->status &= ~IRQ_INPROGRESS; | 362 | desc->status &= ~IRQ_INPROGRESS; |
363 | 363 | ||
364 | out_unlock: | 364 | out_unlock: |
365 | spin_unlock_irq(&desc->lock); | 365 | raw_spin_unlock_irq(&desc->lock); |
366 | } | 366 | } |
367 | EXPORT_SYMBOL_GPL(handle_nested_irq); | 367 | EXPORT_SYMBOL_GPL(handle_nested_irq); |
368 | 368 | ||
@@ -384,7 +384,7 @@ handle_simple_irq(unsigned int irq, struct irq_desc *desc) | |||
384 | struct irqaction *action; | 384 | struct irqaction *action; |
385 | irqreturn_t action_ret; | 385 | irqreturn_t action_ret; |
386 | 386 | ||
387 | spin_lock(&desc->lock); | 387 | raw_spin_lock(&desc->lock); |
388 | 388 | ||
389 | if (unlikely(desc->status & IRQ_INPROGRESS)) | 389 | if (unlikely(desc->status & IRQ_INPROGRESS)) |
390 | goto out_unlock; | 390 | goto out_unlock; |
@@ -396,16 +396,16 @@ handle_simple_irq(unsigned int irq, struct irq_desc *desc) | |||
396 | goto out_unlock; | 396 | goto out_unlock; |
397 | 397 | ||
398 | desc->status |= IRQ_INPROGRESS; | 398 | desc->status |= IRQ_INPROGRESS; |
399 | spin_unlock(&desc->lock); | 399 | raw_spin_unlock(&desc->lock); |
400 | 400 | ||
401 | action_ret = handle_IRQ_event(irq, action); | 401 | action_ret = handle_IRQ_event(irq, action); |
402 | if (!noirqdebug) | 402 | if (!noirqdebug) |
403 | note_interrupt(irq, desc, action_ret); | 403 | note_interrupt(irq, desc, action_ret); |
404 | 404 | ||
405 | spin_lock(&desc->lock); | 405 | raw_spin_lock(&desc->lock); |
406 | desc->status &= ~IRQ_INPROGRESS; | 406 | desc->status &= ~IRQ_INPROGRESS; |
407 | out_unlock: | 407 | out_unlock: |
408 | spin_unlock(&desc->lock); | 408 | raw_spin_unlock(&desc->lock); |
409 | } | 409 | } |
410 | 410 | ||
411 | /** | 411 | /** |
@@ -424,7 +424,7 @@ handle_level_irq(unsigned int irq, struct irq_desc *desc) | |||
424 | struct irqaction *action; | 424 | struct irqaction *action; |
425 | irqreturn_t action_ret; | 425 | irqreturn_t action_ret; |
426 | 426 | ||
427 | spin_lock(&desc->lock); | 427 | raw_spin_lock(&desc->lock); |
428 | mask_ack_irq(desc, irq); | 428 | mask_ack_irq(desc, irq); |
429 | 429 | ||
430 | if (unlikely(desc->status & IRQ_INPROGRESS)) | 430 | if (unlikely(desc->status & IRQ_INPROGRESS)) |
@@ -441,13 +441,13 @@ handle_level_irq(unsigned int irq, struct irq_desc *desc) | |||
441 | goto out_unlock; | 441 | goto out_unlock; |
442 | 442 | ||
443 | desc->status |= IRQ_INPROGRESS; | 443 | desc->status |= IRQ_INPROGRESS; |
444 | spin_unlock(&desc->lock); | 444 | raw_spin_unlock(&desc->lock); |
445 | 445 | ||
446 | action_ret = handle_IRQ_event(irq, action); | 446 | action_ret = handle_IRQ_event(irq, action); |
447 | if (!noirqdebug) | 447 | if (!noirqdebug) |
448 | note_interrupt(irq, desc, action_ret); | 448 | note_interrupt(irq, desc, action_ret); |
449 | 449 | ||
450 | spin_lock(&desc->lock); | 450 | raw_spin_lock(&desc->lock); |
451 | desc->status &= ~IRQ_INPROGRESS; | 451 | desc->status &= ~IRQ_INPROGRESS; |
452 | 452 | ||
453 | if (unlikely(desc->status & IRQ_ONESHOT)) | 453 | if (unlikely(desc->status & IRQ_ONESHOT)) |
@@ -455,7 +455,7 @@ handle_level_irq(unsigned int irq, struct irq_desc *desc) | |||
455 | else if (!(desc->status & IRQ_DISABLED) && desc->chip->unmask) | 455 | else if (!(desc->status & IRQ_DISABLED) && desc->chip->unmask) |
456 | desc->chip->unmask(irq); | 456 | desc->chip->unmask(irq); |
457 | out_unlock: | 457 | out_unlock: |
458 | spin_unlock(&desc->lock); | 458 | raw_spin_unlock(&desc->lock); |
459 | } | 459 | } |
460 | EXPORT_SYMBOL_GPL(handle_level_irq); | 460 | EXPORT_SYMBOL_GPL(handle_level_irq); |
461 | 461 | ||
@@ -475,7 +475,7 @@ handle_fasteoi_irq(unsigned int irq, struct irq_desc *desc) | |||
475 | struct irqaction *action; | 475 | struct irqaction *action; |
476 | irqreturn_t action_ret; | 476 | irqreturn_t action_ret; |
477 | 477 | ||
478 | spin_lock(&desc->lock); | 478 | raw_spin_lock(&desc->lock); |
479 | 479 | ||
480 | if (unlikely(desc->status & IRQ_INPROGRESS)) | 480 | if (unlikely(desc->status & IRQ_INPROGRESS)) |
481 | goto out; | 481 | goto out; |
@@ -497,18 +497,18 @@ handle_fasteoi_irq(unsigned int irq, struct irq_desc *desc) | |||
497 | 497 | ||
498 | desc->status |= IRQ_INPROGRESS; | 498 | desc->status |= IRQ_INPROGRESS; |
499 | desc->status &= ~IRQ_PENDING; | 499 | desc->status &= ~IRQ_PENDING; |
500 | spin_unlock(&desc->lock); | 500 | raw_spin_unlock(&desc->lock); |
501 | 501 | ||
502 | action_ret = handle_IRQ_event(irq, action); | 502 | action_ret = handle_IRQ_event(irq, action); |
503 | if (!noirqdebug) | 503 | if (!noirqdebug) |
504 | note_interrupt(irq, desc, action_ret); | 504 | note_interrupt(irq, desc, action_ret); |
505 | 505 | ||
506 | spin_lock(&desc->lock); | 506 | raw_spin_lock(&desc->lock); |
507 | desc->status &= ~IRQ_INPROGRESS; | 507 | desc->status &= ~IRQ_INPROGRESS; |
508 | out: | 508 | out: |
509 | desc->chip->eoi(irq); | 509 | desc->chip->eoi(irq); |
510 | 510 | ||
511 | spin_unlock(&desc->lock); | 511 | raw_spin_unlock(&desc->lock); |
512 | } | 512 | } |
513 | 513 | ||
514 | /** | 514 | /** |
@@ -530,7 +530,7 @@ out: | |||
530 | void | 530 | void |
531 | handle_edge_irq(unsigned int irq, struct irq_desc *desc) | 531 | handle_edge_irq(unsigned int irq, struct irq_desc *desc) |
532 | { | 532 | { |
533 | spin_lock(&desc->lock); | 533 | raw_spin_lock(&desc->lock); |
534 | 534 | ||
535 | desc->status &= ~(IRQ_REPLAY | IRQ_WAITING); | 535 | desc->status &= ~(IRQ_REPLAY | IRQ_WAITING); |
536 | 536 | ||
@@ -576,17 +576,17 @@ handle_edge_irq(unsigned int irq, struct irq_desc *desc) | |||
576 | } | 576 | } |
577 | 577 | ||
578 | desc->status &= ~IRQ_PENDING; | 578 | desc->status &= ~IRQ_PENDING; |
579 | spin_unlock(&desc->lock); | 579 | raw_spin_unlock(&desc->lock); |
580 | action_ret = handle_IRQ_event(irq, action); | 580 | action_ret = handle_IRQ_event(irq, action); |
581 | if (!noirqdebug) | 581 | if (!noirqdebug) |
582 | note_interrupt(irq, desc, action_ret); | 582 | note_interrupt(irq, desc, action_ret); |
583 | spin_lock(&desc->lock); | 583 | raw_spin_lock(&desc->lock); |
584 | 584 | ||
585 | } while ((desc->status & (IRQ_PENDING | IRQ_DISABLED)) == IRQ_PENDING); | 585 | } while ((desc->status & (IRQ_PENDING | IRQ_DISABLED)) == IRQ_PENDING); |
586 | 586 | ||
587 | desc->status &= ~IRQ_INPROGRESS; | 587 | desc->status &= ~IRQ_INPROGRESS; |
588 | out_unlock: | 588 | out_unlock: |
589 | spin_unlock(&desc->lock); | 589 | raw_spin_unlock(&desc->lock); |
590 | } | 590 | } |
591 | 591 | ||
592 | /** | 592 | /** |
@@ -643,7 +643,7 @@ __set_irq_handler(unsigned int irq, irq_flow_handler_t handle, int is_chained, | |||
643 | } | 643 | } |
644 | 644 | ||
645 | chip_bus_lock(irq, desc); | 645 | chip_bus_lock(irq, desc); |
646 | spin_lock_irqsave(&desc->lock, flags); | 646 | raw_spin_lock_irqsave(&desc->lock, flags); |
647 | 647 | ||
648 | /* Uninstall? */ | 648 | /* Uninstall? */ |
649 | if (handle == handle_bad_irq) { | 649 | if (handle == handle_bad_irq) { |
@@ -661,7 +661,7 @@ __set_irq_handler(unsigned int irq, irq_flow_handler_t handle, int is_chained, | |||
661 | desc->depth = 0; | 661 | desc->depth = 0; |
662 | desc->chip->startup(irq); | 662 | desc->chip->startup(irq); |
663 | } | 663 | } |
664 | spin_unlock_irqrestore(&desc->lock, flags); | 664 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
665 | chip_bus_sync_unlock(irq, desc); | 665 | chip_bus_sync_unlock(irq, desc); |
666 | } | 666 | } |
667 | EXPORT_SYMBOL_GPL(__set_irq_handler); | 667 | EXPORT_SYMBOL_GPL(__set_irq_handler); |
@@ -692,9 +692,9 @@ void __init set_irq_noprobe(unsigned int irq) | |||
692 | return; | 692 | return; |
693 | } | 693 | } |
694 | 694 | ||
695 | spin_lock_irqsave(&desc->lock, flags); | 695 | raw_spin_lock_irqsave(&desc->lock, flags); |
696 | desc->status |= IRQ_NOPROBE; | 696 | desc->status |= IRQ_NOPROBE; |
697 | spin_unlock_irqrestore(&desc->lock, flags); | 697 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
698 | } | 698 | } |
699 | 699 | ||
700 | void __init set_irq_probe(unsigned int irq) | 700 | void __init set_irq_probe(unsigned int irq) |
@@ -707,7 +707,7 @@ void __init set_irq_probe(unsigned int irq) | |||
707 | return; | 707 | return; |
708 | } | 708 | } |
709 | 709 | ||
710 | spin_lock_irqsave(&desc->lock, flags); | 710 | raw_spin_lock_irqsave(&desc->lock, flags); |
711 | desc->status &= ~IRQ_NOPROBE; | 711 | desc->status &= ~IRQ_NOPROBE; |
712 | spin_unlock_irqrestore(&desc->lock, flags); | 712 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
713 | } | 713 | } |
diff --git a/kernel/irq/handle.c b/kernel/irq/handle.c index 17c71bb565c6..814940e7f485 100644 --- a/kernel/irq/handle.c +++ b/kernel/irq/handle.c | |||
@@ -80,7 +80,7 @@ static struct irq_desc irq_desc_init = { | |||
80 | .chip = &no_irq_chip, | 80 | .chip = &no_irq_chip, |
81 | .handle_irq = handle_bad_irq, | 81 | .handle_irq = handle_bad_irq, |
82 | .depth = 1, | 82 | .depth = 1, |
83 | .lock = __SPIN_LOCK_UNLOCKED(irq_desc_init.lock), | 83 | .lock = __RAW_SPIN_LOCK_UNLOCKED(irq_desc_init.lock), |
84 | }; | 84 | }; |
85 | 85 | ||
86 | void __ref init_kstat_irqs(struct irq_desc *desc, int node, int nr) | 86 | void __ref init_kstat_irqs(struct irq_desc *desc, int node, int nr) |
@@ -108,7 +108,7 @@ static void init_one_irq_desc(int irq, struct irq_desc *desc, int node) | |||
108 | { | 108 | { |
109 | memcpy(desc, &irq_desc_init, sizeof(struct irq_desc)); | 109 | memcpy(desc, &irq_desc_init, sizeof(struct irq_desc)); |
110 | 110 | ||
111 | spin_lock_init(&desc->lock); | 111 | raw_spin_lock_init(&desc->lock); |
112 | desc->irq = irq; | 112 | desc->irq = irq; |
113 | #ifdef CONFIG_SMP | 113 | #ifdef CONFIG_SMP |
114 | desc->node = node; | 114 | desc->node = node; |
@@ -130,7 +130,7 @@ static void init_one_irq_desc(int irq, struct irq_desc *desc, int node) | |||
130 | /* | 130 | /* |
131 | * Protect the sparse_irqs: | 131 | * Protect the sparse_irqs: |
132 | */ | 132 | */ |
133 | DEFINE_SPINLOCK(sparse_irq_lock); | 133 | DEFINE_RAW_SPINLOCK(sparse_irq_lock); |
134 | 134 | ||
135 | struct irq_desc **irq_desc_ptrs __read_mostly; | 135 | struct irq_desc **irq_desc_ptrs __read_mostly; |
136 | 136 | ||
@@ -141,7 +141,7 @@ static struct irq_desc irq_desc_legacy[NR_IRQS_LEGACY] __cacheline_aligned_in_sm | |||
141 | .chip = &no_irq_chip, | 141 | .chip = &no_irq_chip, |
142 | .handle_irq = handle_bad_irq, | 142 | .handle_irq = handle_bad_irq, |
143 | .depth = 1, | 143 | .depth = 1, |
144 | .lock = __SPIN_LOCK_UNLOCKED(irq_desc_init.lock), | 144 | .lock = __RAW_SPIN_LOCK_UNLOCKED(irq_desc_init.lock), |
145 | } | 145 | } |
146 | }; | 146 | }; |
147 | 147 | ||
@@ -212,7 +212,7 @@ struct irq_desc * __ref irq_to_desc_alloc_node(unsigned int irq, int node) | |||
212 | if (desc) | 212 | if (desc) |
213 | return desc; | 213 | return desc; |
214 | 214 | ||
215 | spin_lock_irqsave(&sparse_irq_lock, flags); | 215 | raw_spin_lock_irqsave(&sparse_irq_lock, flags); |
216 | 216 | ||
217 | /* We have to check it to avoid races with another CPU */ | 217 | /* We have to check it to avoid races with another CPU */ |
218 | desc = irq_desc_ptrs[irq]; | 218 | desc = irq_desc_ptrs[irq]; |
@@ -234,7 +234,7 @@ struct irq_desc * __ref irq_to_desc_alloc_node(unsigned int irq, int node) | |||
234 | irq_desc_ptrs[irq] = desc; | 234 | irq_desc_ptrs[irq] = desc; |
235 | 235 | ||
236 | out_unlock: | 236 | out_unlock: |
237 | spin_unlock_irqrestore(&sparse_irq_lock, flags); | 237 | raw_spin_unlock_irqrestore(&sparse_irq_lock, flags); |
238 | 238 | ||
239 | return desc; | 239 | return desc; |
240 | } | 240 | } |
@@ -247,7 +247,7 @@ struct irq_desc irq_desc[NR_IRQS] __cacheline_aligned_in_smp = { | |||
247 | .chip = &no_irq_chip, | 247 | .chip = &no_irq_chip, |
248 | .handle_irq = handle_bad_irq, | 248 | .handle_irq = handle_bad_irq, |
249 | .depth = 1, | 249 | .depth = 1, |
250 | .lock = __SPIN_LOCK_UNLOCKED(irq_desc->lock), | 250 | .lock = __RAW_SPIN_LOCK_UNLOCKED(irq_desc->lock), |
251 | } | 251 | } |
252 | }; | 252 | }; |
253 | 253 | ||
@@ -473,7 +473,7 @@ unsigned int __do_IRQ(unsigned int irq) | |||
473 | return 1; | 473 | return 1; |
474 | } | 474 | } |
475 | 475 | ||
476 | spin_lock(&desc->lock); | 476 | raw_spin_lock(&desc->lock); |
477 | if (desc->chip->ack) | 477 | if (desc->chip->ack) |
478 | desc->chip->ack(irq); | 478 | desc->chip->ack(irq); |
479 | /* | 479 | /* |
@@ -517,13 +517,13 @@ unsigned int __do_IRQ(unsigned int irq) | |||
517 | for (;;) { | 517 | for (;;) { |
518 | irqreturn_t action_ret; | 518 | irqreturn_t action_ret; |
519 | 519 | ||
520 | spin_unlock(&desc->lock); | 520 | raw_spin_unlock(&desc->lock); |
521 | 521 | ||
522 | action_ret = handle_IRQ_event(irq, action); | 522 | action_ret = handle_IRQ_event(irq, action); |
523 | if (!noirqdebug) | 523 | if (!noirqdebug) |
524 | note_interrupt(irq, desc, action_ret); | 524 | note_interrupt(irq, desc, action_ret); |
525 | 525 | ||
526 | spin_lock(&desc->lock); | 526 | raw_spin_lock(&desc->lock); |
527 | if (likely(!(desc->status & IRQ_PENDING))) | 527 | if (likely(!(desc->status & IRQ_PENDING))) |
528 | break; | 528 | break; |
529 | desc->status &= ~IRQ_PENDING; | 529 | desc->status &= ~IRQ_PENDING; |
@@ -536,7 +536,7 @@ out: | |||
536 | * disabled while the handler was running. | 536 | * disabled while the handler was running. |
537 | */ | 537 | */ |
538 | desc->chip->end(irq); | 538 | desc->chip->end(irq); |
539 | spin_unlock(&desc->lock); | 539 | raw_spin_unlock(&desc->lock); |
540 | 540 | ||
541 | return 1; | 541 | return 1; |
542 | } | 542 | } |
diff --git a/kernel/irq/internals.h b/kernel/irq/internals.h index 1b5d742c6a77..b2821f070a3d 100644 --- a/kernel/irq/internals.h +++ b/kernel/irq/internals.h | |||
@@ -18,7 +18,7 @@ extern void __enable_irq(struct irq_desc *desc, unsigned int irq, bool resume); | |||
18 | extern struct lock_class_key irq_desc_lock_class; | 18 | extern struct lock_class_key irq_desc_lock_class; |
19 | extern void init_kstat_irqs(struct irq_desc *desc, int node, int nr); | 19 | extern void init_kstat_irqs(struct irq_desc *desc, int node, int nr); |
20 | extern void clear_kstat_irqs(struct irq_desc *desc); | 20 | extern void clear_kstat_irqs(struct irq_desc *desc); |
21 | extern spinlock_t sparse_irq_lock; | 21 | extern raw_spinlock_t sparse_irq_lock; |
22 | 22 | ||
23 | #ifdef CONFIG_SPARSE_IRQ | 23 | #ifdef CONFIG_SPARSE_IRQ |
24 | /* irq_desc_ptrs allocated at boot time */ | 24 | /* irq_desc_ptrs allocated at boot time */ |
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index 7305b297d1eb..eb6078ca60c7 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c | |||
@@ -46,9 +46,9 @@ void synchronize_irq(unsigned int irq) | |||
46 | cpu_relax(); | 46 | cpu_relax(); |
47 | 47 | ||
48 | /* Ok, that indicated we're done: double-check carefully. */ | 48 | /* Ok, that indicated we're done: double-check carefully. */ |
49 | spin_lock_irqsave(&desc->lock, flags); | 49 | raw_spin_lock_irqsave(&desc->lock, flags); |
50 | status = desc->status; | 50 | status = desc->status; |
51 | spin_unlock_irqrestore(&desc->lock, flags); | 51 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
52 | 52 | ||
53 | /* Oops, that failed? */ | 53 | /* Oops, that failed? */ |
54 | } while (status & IRQ_INPROGRESS); | 54 | } while (status & IRQ_INPROGRESS); |
@@ -114,7 +114,7 @@ int irq_set_affinity(unsigned int irq, const struct cpumask *cpumask) | |||
114 | if (!desc->chip->set_affinity) | 114 | if (!desc->chip->set_affinity) |
115 | return -EINVAL; | 115 | return -EINVAL; |
116 | 116 | ||
117 | spin_lock_irqsave(&desc->lock, flags); | 117 | raw_spin_lock_irqsave(&desc->lock, flags); |
118 | 118 | ||
119 | #ifdef CONFIG_GENERIC_PENDING_IRQ | 119 | #ifdef CONFIG_GENERIC_PENDING_IRQ |
120 | if (desc->status & IRQ_MOVE_PCNTXT) { | 120 | if (desc->status & IRQ_MOVE_PCNTXT) { |
@@ -134,7 +134,7 @@ int irq_set_affinity(unsigned int irq, const struct cpumask *cpumask) | |||
134 | } | 134 | } |
135 | #endif | 135 | #endif |
136 | desc->status |= IRQ_AFFINITY_SET; | 136 | desc->status |= IRQ_AFFINITY_SET; |
137 | spin_unlock_irqrestore(&desc->lock, flags); | 137 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
138 | return 0; | 138 | return 0; |
139 | } | 139 | } |
140 | 140 | ||
@@ -181,11 +181,11 @@ int irq_select_affinity_usr(unsigned int irq) | |||
181 | unsigned long flags; | 181 | unsigned long flags; |
182 | int ret; | 182 | int ret; |
183 | 183 | ||
184 | spin_lock_irqsave(&desc->lock, flags); | 184 | raw_spin_lock_irqsave(&desc->lock, flags); |
185 | ret = setup_affinity(irq, desc); | 185 | ret = setup_affinity(irq, desc); |
186 | if (!ret) | 186 | if (!ret) |
187 | irq_set_thread_affinity(desc); | 187 | irq_set_thread_affinity(desc); |
188 | spin_unlock_irqrestore(&desc->lock, flags); | 188 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
189 | 189 | ||
190 | return ret; | 190 | return ret; |
191 | } | 191 | } |
@@ -231,9 +231,9 @@ void disable_irq_nosync(unsigned int irq) | |||
231 | return; | 231 | return; |
232 | 232 | ||
233 | chip_bus_lock(irq, desc); | 233 | chip_bus_lock(irq, desc); |
234 | spin_lock_irqsave(&desc->lock, flags); | 234 | raw_spin_lock_irqsave(&desc->lock, flags); |
235 | __disable_irq(desc, irq, false); | 235 | __disable_irq(desc, irq, false); |
236 | spin_unlock_irqrestore(&desc->lock, flags); | 236 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
237 | chip_bus_sync_unlock(irq, desc); | 237 | chip_bus_sync_unlock(irq, desc); |
238 | } | 238 | } |
239 | EXPORT_SYMBOL(disable_irq_nosync); | 239 | EXPORT_SYMBOL(disable_irq_nosync); |
@@ -308,9 +308,9 @@ void enable_irq(unsigned int irq) | |||
308 | return; | 308 | return; |
309 | 309 | ||
310 | chip_bus_lock(irq, desc); | 310 | chip_bus_lock(irq, desc); |
311 | spin_lock_irqsave(&desc->lock, flags); | 311 | raw_spin_lock_irqsave(&desc->lock, flags); |
312 | __enable_irq(desc, irq, false); | 312 | __enable_irq(desc, irq, false); |
313 | spin_unlock_irqrestore(&desc->lock, flags); | 313 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
314 | chip_bus_sync_unlock(irq, desc); | 314 | chip_bus_sync_unlock(irq, desc); |
315 | } | 315 | } |
316 | EXPORT_SYMBOL(enable_irq); | 316 | EXPORT_SYMBOL(enable_irq); |
@@ -347,7 +347,7 @@ int set_irq_wake(unsigned int irq, unsigned int on) | |||
347 | /* wakeup-capable irqs can be shared between drivers that | 347 | /* wakeup-capable irqs can be shared between drivers that |
348 | * don't need to have the same sleep mode behaviors. | 348 | * don't need to have the same sleep mode behaviors. |
349 | */ | 349 | */ |
350 | spin_lock_irqsave(&desc->lock, flags); | 350 | raw_spin_lock_irqsave(&desc->lock, flags); |
351 | if (on) { | 351 | if (on) { |
352 | if (desc->wake_depth++ == 0) { | 352 | if (desc->wake_depth++ == 0) { |
353 | ret = set_irq_wake_real(irq, on); | 353 | ret = set_irq_wake_real(irq, on); |
@@ -368,7 +368,7 @@ int set_irq_wake(unsigned int irq, unsigned int on) | |||
368 | } | 368 | } |
369 | } | 369 | } |
370 | 370 | ||
371 | spin_unlock_irqrestore(&desc->lock, flags); | 371 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
372 | return ret; | 372 | return ret; |
373 | } | 373 | } |
374 | EXPORT_SYMBOL(set_irq_wake); | 374 | EXPORT_SYMBOL(set_irq_wake); |
@@ -484,12 +484,12 @@ static int irq_wait_for_interrupt(struct irqaction *action) | |||
484 | static void irq_finalize_oneshot(unsigned int irq, struct irq_desc *desc) | 484 | static void irq_finalize_oneshot(unsigned int irq, struct irq_desc *desc) |
485 | { | 485 | { |
486 | chip_bus_lock(irq, desc); | 486 | chip_bus_lock(irq, desc); |
487 | spin_lock_irq(&desc->lock); | 487 | raw_spin_lock_irq(&desc->lock); |
488 | if (!(desc->status & IRQ_DISABLED) && (desc->status & IRQ_MASKED)) { | 488 | if (!(desc->status & IRQ_DISABLED) && (desc->status & IRQ_MASKED)) { |
489 | desc->status &= ~IRQ_MASKED; | 489 | desc->status &= ~IRQ_MASKED; |
490 | desc->chip->unmask(irq); | 490 | desc->chip->unmask(irq); |
491 | } | 491 | } |
492 | spin_unlock_irq(&desc->lock); | 492 | raw_spin_unlock_irq(&desc->lock); |
493 | chip_bus_sync_unlock(irq, desc); | 493 | chip_bus_sync_unlock(irq, desc); |
494 | } | 494 | } |
495 | 495 | ||
@@ -514,9 +514,9 @@ irq_thread_check_affinity(struct irq_desc *desc, struct irqaction *action) | |||
514 | return; | 514 | return; |
515 | } | 515 | } |
516 | 516 | ||
517 | spin_lock_irq(&desc->lock); | 517 | raw_spin_lock_irq(&desc->lock); |
518 | cpumask_copy(mask, desc->affinity); | 518 | cpumask_copy(mask, desc->affinity); |
519 | spin_unlock_irq(&desc->lock); | 519 | raw_spin_unlock_irq(&desc->lock); |
520 | 520 | ||
521 | set_cpus_allowed_ptr(current, mask); | 521 | set_cpus_allowed_ptr(current, mask); |
522 | free_cpumask_var(mask); | 522 | free_cpumask_var(mask); |
@@ -545,7 +545,7 @@ static int irq_thread(void *data) | |||
545 | 545 | ||
546 | atomic_inc(&desc->threads_active); | 546 | atomic_inc(&desc->threads_active); |
547 | 547 | ||
548 | spin_lock_irq(&desc->lock); | 548 | raw_spin_lock_irq(&desc->lock); |
549 | if (unlikely(desc->status & IRQ_DISABLED)) { | 549 | if (unlikely(desc->status & IRQ_DISABLED)) { |
550 | /* | 550 | /* |
551 | * CHECKME: We might need a dedicated | 551 | * CHECKME: We might need a dedicated |
@@ -555,9 +555,9 @@ static int irq_thread(void *data) | |||
555 | * retriggers the interrupt itself --- tglx | 555 | * retriggers the interrupt itself --- tglx |
556 | */ | 556 | */ |
557 | desc->status |= IRQ_PENDING; | 557 | desc->status |= IRQ_PENDING; |
558 | spin_unlock_irq(&desc->lock); | 558 | raw_spin_unlock_irq(&desc->lock); |
559 | } else { | 559 | } else { |
560 | spin_unlock_irq(&desc->lock); | 560 | raw_spin_unlock_irq(&desc->lock); |
561 | 561 | ||
562 | action->thread_fn(action->irq, action->dev_id); | 562 | action->thread_fn(action->irq, action->dev_id); |
563 | 563 | ||
@@ -679,7 +679,7 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new) | |||
679 | /* | 679 | /* |
680 | * The following block of code has to be executed atomically | 680 | * The following block of code has to be executed atomically |
681 | */ | 681 | */ |
682 | spin_lock_irqsave(&desc->lock, flags); | 682 | raw_spin_lock_irqsave(&desc->lock, flags); |
683 | old_ptr = &desc->action; | 683 | old_ptr = &desc->action; |
684 | old = *old_ptr; | 684 | old = *old_ptr; |
685 | if (old) { | 685 | if (old) { |
@@ -775,7 +775,7 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new) | |||
775 | __enable_irq(desc, irq, false); | 775 | __enable_irq(desc, irq, false); |
776 | } | 776 | } |
777 | 777 | ||
778 | spin_unlock_irqrestore(&desc->lock, flags); | 778 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
779 | 779 | ||
780 | /* | 780 | /* |
781 | * Strictly no need to wake it up, but hung_task complains | 781 | * Strictly no need to wake it up, but hung_task complains |
@@ -802,7 +802,7 @@ mismatch: | |||
802 | ret = -EBUSY; | 802 | ret = -EBUSY; |
803 | 803 | ||
804 | out_thread: | 804 | out_thread: |
805 | spin_unlock_irqrestore(&desc->lock, flags); | 805 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
806 | if (new->thread) { | 806 | if (new->thread) { |
807 | struct task_struct *t = new->thread; | 807 | struct task_struct *t = new->thread; |
808 | 808 | ||
@@ -844,7 +844,7 @@ static struct irqaction *__free_irq(unsigned int irq, void *dev_id) | |||
844 | if (!desc) | 844 | if (!desc) |
845 | return NULL; | 845 | return NULL; |
846 | 846 | ||
847 | spin_lock_irqsave(&desc->lock, flags); | 847 | raw_spin_lock_irqsave(&desc->lock, flags); |
848 | 848 | ||
849 | /* | 849 | /* |
850 | * There can be multiple actions per IRQ descriptor, find the right | 850 | * There can be multiple actions per IRQ descriptor, find the right |
@@ -856,7 +856,7 @@ static struct irqaction *__free_irq(unsigned int irq, void *dev_id) | |||
856 | 856 | ||
857 | if (!action) { | 857 | if (!action) { |
858 | WARN(1, "Trying to free already-free IRQ %d\n", irq); | 858 | WARN(1, "Trying to free already-free IRQ %d\n", irq); |
859 | spin_unlock_irqrestore(&desc->lock, flags); | 859 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
860 | 860 | ||
861 | return NULL; | 861 | return NULL; |
862 | } | 862 | } |
@@ -884,7 +884,7 @@ static struct irqaction *__free_irq(unsigned int irq, void *dev_id) | |||
884 | desc->chip->disable(irq); | 884 | desc->chip->disable(irq); |
885 | } | 885 | } |
886 | 886 | ||
887 | spin_unlock_irqrestore(&desc->lock, flags); | 887 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
888 | 888 | ||
889 | unregister_handler_proc(irq, action); | 889 | unregister_handler_proc(irq, action); |
890 | 890 | ||
diff --git a/kernel/irq/migration.c b/kernel/irq/migration.c index fcb6c96f2627..241962280836 100644 --- a/kernel/irq/migration.c +++ b/kernel/irq/migration.c | |||
@@ -27,7 +27,7 @@ void move_masked_irq(int irq) | |||
27 | if (!desc->chip->set_affinity) | 27 | if (!desc->chip->set_affinity) |
28 | return; | 28 | return; |
29 | 29 | ||
30 | assert_spin_locked(&desc->lock); | 30 | assert_raw_spin_locked(&desc->lock); |
31 | 31 | ||
32 | /* | 32 | /* |
33 | * If there was a valid mask to work with, please | 33 | * If there was a valid mask to work with, please |
diff --git a/kernel/irq/numa_migrate.c b/kernel/irq/numa_migrate.c index 3fd30197da2e..26bac9d8f860 100644 --- a/kernel/irq/numa_migrate.c +++ b/kernel/irq/numa_migrate.c | |||
@@ -42,7 +42,7 @@ static bool init_copy_one_irq_desc(int irq, struct irq_desc *old_desc, | |||
42 | "for migration.\n", irq); | 42 | "for migration.\n", irq); |
43 | return false; | 43 | return false; |
44 | } | 44 | } |
45 | spin_lock_init(&desc->lock); | 45 | raw_spin_lock_init(&desc->lock); |
46 | desc->node = node; | 46 | desc->node = node; |
47 | lockdep_set_class(&desc->lock, &irq_desc_lock_class); | 47 | lockdep_set_class(&desc->lock, &irq_desc_lock_class); |
48 | init_copy_kstat_irqs(old_desc, desc, node, nr_cpu_ids); | 48 | init_copy_kstat_irqs(old_desc, desc, node, nr_cpu_ids); |
@@ -67,7 +67,7 @@ static struct irq_desc *__real_move_irq_desc(struct irq_desc *old_desc, | |||
67 | 67 | ||
68 | irq = old_desc->irq; | 68 | irq = old_desc->irq; |
69 | 69 | ||
70 | spin_lock_irqsave(&sparse_irq_lock, flags); | 70 | raw_spin_lock_irqsave(&sparse_irq_lock, flags); |
71 | 71 | ||
72 | /* We have to check it to avoid races with another CPU */ | 72 | /* We have to check it to avoid races with another CPU */ |
73 | desc = irq_desc_ptrs[irq]; | 73 | desc = irq_desc_ptrs[irq]; |
@@ -91,7 +91,7 @@ static struct irq_desc *__real_move_irq_desc(struct irq_desc *old_desc, | |||
91 | } | 91 | } |
92 | 92 | ||
93 | irq_desc_ptrs[irq] = desc; | 93 | irq_desc_ptrs[irq] = desc; |
94 | spin_unlock_irqrestore(&sparse_irq_lock, flags); | 94 | raw_spin_unlock_irqrestore(&sparse_irq_lock, flags); |
95 | 95 | ||
96 | /* free the old one */ | 96 | /* free the old one */ |
97 | free_one_irq_desc(old_desc, desc); | 97 | free_one_irq_desc(old_desc, desc); |
@@ -100,7 +100,7 @@ static struct irq_desc *__real_move_irq_desc(struct irq_desc *old_desc, | |||
100 | return desc; | 100 | return desc; |
101 | 101 | ||
102 | out_unlock: | 102 | out_unlock: |
103 | spin_unlock_irqrestore(&sparse_irq_lock, flags); | 103 | raw_spin_unlock_irqrestore(&sparse_irq_lock, flags); |
104 | 104 | ||
105 | return desc; | 105 | return desc; |
106 | } | 106 | } |
diff --git a/kernel/irq/pm.c b/kernel/irq/pm.c index a0bb09e79867..0d4005d85b03 100644 --- a/kernel/irq/pm.c +++ b/kernel/irq/pm.c | |||
@@ -28,9 +28,9 @@ void suspend_device_irqs(void) | |||
28 | for_each_irq_desc(irq, desc) { | 28 | for_each_irq_desc(irq, desc) { |
29 | unsigned long flags; | 29 | unsigned long flags; |
30 | 30 | ||
31 | spin_lock_irqsave(&desc->lock, flags); | 31 | raw_spin_lock_irqsave(&desc->lock, flags); |
32 | __disable_irq(desc, irq, true); | 32 | __disable_irq(desc, irq, true); |
33 | spin_unlock_irqrestore(&desc->lock, flags); | 33 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
34 | } | 34 | } |
35 | 35 | ||
36 | for_each_irq_desc(irq, desc) | 36 | for_each_irq_desc(irq, desc) |
@@ -56,9 +56,9 @@ void resume_device_irqs(void) | |||
56 | if (!(desc->status & IRQ_SUSPENDED)) | 56 | if (!(desc->status & IRQ_SUSPENDED)) |
57 | continue; | 57 | continue; |
58 | 58 | ||
59 | spin_lock_irqsave(&desc->lock, flags); | 59 | raw_spin_lock_irqsave(&desc->lock, flags); |
60 | __enable_irq(desc, irq, true); | 60 | __enable_irq(desc, irq, true); |
61 | spin_unlock_irqrestore(&desc->lock, flags); | 61 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
62 | } | 62 | } |
63 | } | 63 | } |
64 | EXPORT_SYMBOL_GPL(resume_device_irqs); | 64 | EXPORT_SYMBOL_GPL(resume_device_irqs); |
diff --git a/kernel/irq/proc.c b/kernel/irq/proc.c index 0832145fea97..6f50eccc79c0 100644 --- a/kernel/irq/proc.c +++ b/kernel/irq/proc.c | |||
@@ -179,7 +179,7 @@ static int name_unique(unsigned int irq, struct irqaction *new_action) | |||
179 | unsigned long flags; | 179 | unsigned long flags; |
180 | int ret = 1; | 180 | int ret = 1; |
181 | 181 | ||
182 | spin_lock_irqsave(&desc->lock, flags); | 182 | raw_spin_lock_irqsave(&desc->lock, flags); |
183 | for (action = desc->action ; action; action = action->next) { | 183 | for (action = desc->action ; action; action = action->next) { |
184 | if ((action != new_action) && action->name && | 184 | if ((action != new_action) && action->name && |
185 | !strcmp(new_action->name, action->name)) { | 185 | !strcmp(new_action->name, action->name)) { |
@@ -187,7 +187,7 @@ static int name_unique(unsigned int irq, struct irqaction *new_action) | |||
187 | break; | 187 | break; |
188 | } | 188 | } |
189 | } | 189 | } |
190 | spin_unlock_irqrestore(&desc->lock, flags); | 190 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
191 | return ret; | 191 | return ret; |
192 | } | 192 | } |
193 | 193 | ||
diff --git a/kernel/irq/spurious.c b/kernel/irq/spurious.c index e49ea1c5232d..89fb90ae534f 100644 --- a/kernel/irq/spurious.c +++ b/kernel/irq/spurious.c | |||
@@ -28,7 +28,7 @@ static int try_one_irq(int irq, struct irq_desc *desc) | |||
28 | struct irqaction *action; | 28 | struct irqaction *action; |
29 | int ok = 0, work = 0; | 29 | int ok = 0, work = 0; |
30 | 30 | ||
31 | spin_lock(&desc->lock); | 31 | raw_spin_lock(&desc->lock); |
32 | /* Already running on another processor */ | 32 | /* Already running on another processor */ |
33 | if (desc->status & IRQ_INPROGRESS) { | 33 | if (desc->status & IRQ_INPROGRESS) { |
34 | /* | 34 | /* |
@@ -37,13 +37,13 @@ static int try_one_irq(int irq, struct irq_desc *desc) | |||
37 | */ | 37 | */ |
38 | if (desc->action && (desc->action->flags & IRQF_SHARED)) | 38 | if (desc->action && (desc->action->flags & IRQF_SHARED)) |
39 | desc->status |= IRQ_PENDING; | 39 | desc->status |= IRQ_PENDING; |
40 | spin_unlock(&desc->lock); | 40 | raw_spin_unlock(&desc->lock); |
41 | return ok; | 41 | return ok; |
42 | } | 42 | } |
43 | /* Honour the normal IRQ locking */ | 43 | /* Honour the normal IRQ locking */ |
44 | desc->status |= IRQ_INPROGRESS; | 44 | desc->status |= IRQ_INPROGRESS; |
45 | action = desc->action; | 45 | action = desc->action; |
46 | spin_unlock(&desc->lock); | 46 | raw_spin_unlock(&desc->lock); |
47 | 47 | ||
48 | while (action) { | 48 | while (action) { |
49 | /* Only shared IRQ handlers are safe to call */ | 49 | /* Only shared IRQ handlers are safe to call */ |
@@ -56,7 +56,7 @@ static int try_one_irq(int irq, struct irq_desc *desc) | |||
56 | } | 56 | } |
57 | local_irq_disable(); | 57 | local_irq_disable(); |
58 | /* Now clean up the flags */ | 58 | /* Now clean up the flags */ |
59 | spin_lock(&desc->lock); | 59 | raw_spin_lock(&desc->lock); |
60 | action = desc->action; | 60 | action = desc->action; |
61 | 61 | ||
62 | /* | 62 | /* |
@@ -68,9 +68,9 @@ static int try_one_irq(int irq, struct irq_desc *desc) | |||
68 | * Perform real IRQ processing for the IRQ we deferred | 68 | * Perform real IRQ processing for the IRQ we deferred |
69 | */ | 69 | */ |
70 | work = 1; | 70 | work = 1; |
71 | spin_unlock(&desc->lock); | 71 | raw_spin_unlock(&desc->lock); |
72 | handle_IRQ_event(irq, action); | 72 | handle_IRQ_event(irq, action); |
73 | spin_lock(&desc->lock); | 73 | raw_spin_lock(&desc->lock); |
74 | desc->status &= ~IRQ_PENDING; | 74 | desc->status &= ~IRQ_PENDING; |
75 | } | 75 | } |
76 | desc->status &= ~IRQ_INPROGRESS; | 76 | desc->status &= ~IRQ_INPROGRESS; |
@@ -80,7 +80,7 @@ static int try_one_irq(int irq, struct irq_desc *desc) | |||
80 | */ | 80 | */ |
81 | if (work && desc->chip && desc->chip->end) | 81 | if (work && desc->chip && desc->chip->end) |
82 | desc->chip->end(irq); | 82 | desc->chip->end(irq); |
83 | spin_unlock(&desc->lock); | 83 | raw_spin_unlock(&desc->lock); |
84 | 84 | ||
85 | return ok; | 85 | return ok; |
86 | } | 86 | } |