diff options
author | Mark Salter <msalter@redhat.com> | 2012-12-12 10:36:37 -0500 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2012-12-12 10:46:14 -0500 |
commit | 7d361cb754720d69695a3efc973e9a1a51e46b21 (patch) | |
tree | 4db3debac5fc6f6a78f0f185c4dcc5d9ddf01249 /arch/mn10300/kernel/smp.c | |
parent | c98c406eb2c518c7c5bc922fafa1f9fdcb7b76f4 (diff) |
MN10300: cleanup IRQ affinity setting
The irq_set_affinity handler for the mn10300 cpu pic had some hard-coded IRQs
which were not to be migrated from one cpu to another. This patch cleans those
up by using a combination of IRQF_NOBALANCING and specialized irq chips with
no irq_set_affinity handler. This maintains the previous behavior by using
generic IRQ interfaces rather than hard coding IRQ numbers in the default
irq_set_affinity handler.
Signed-off-by: Mark Salter <msalter@redhat.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'arch/mn10300/kernel/smp.c')
-rw-r--r-- | arch/mn10300/kernel/smp.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/arch/mn10300/kernel/smp.c b/arch/mn10300/kernel/smp.c index e62c223e4c45..95983cd21e77 100644 --- a/arch/mn10300/kernel/smp.c +++ b/arch/mn10300/kernel/smp.c | |||
@@ -130,10 +130,12 @@ static irqreturn_t smp_call_function_interrupt(int irq, void *dev_id); | |||
130 | 130 | ||
131 | static struct irqaction reschedule_ipi = { | 131 | static struct irqaction reschedule_ipi = { |
132 | .handler = smp_reschedule_interrupt, | 132 | .handler = smp_reschedule_interrupt, |
133 | .flags = IRQF_NOBALANCING, | ||
133 | .name = "smp reschedule IPI" | 134 | .name = "smp reschedule IPI" |
134 | }; | 135 | }; |
135 | static struct irqaction call_function_ipi = { | 136 | static struct irqaction call_function_ipi = { |
136 | .handler = smp_call_function_interrupt, | 137 | .handler = smp_call_function_interrupt, |
138 | .flags = IRQF_NOBALANCING, | ||
137 | .name = "smp call function IPI" | 139 | .name = "smp call function IPI" |
138 | }; | 140 | }; |
139 | 141 | ||
@@ -141,7 +143,7 @@ static struct irqaction call_function_ipi = { | |||
141 | static irqreturn_t smp_ipi_timer_interrupt(int irq, void *dev_id); | 143 | static irqreturn_t smp_ipi_timer_interrupt(int irq, void *dev_id); |
142 | static struct irqaction local_timer_ipi = { | 144 | static struct irqaction local_timer_ipi = { |
143 | .handler = smp_ipi_timer_interrupt, | 145 | .handler = smp_ipi_timer_interrupt, |
144 | .flags = IRQF_DISABLED, | 146 | .flags = IRQF_DISABLED | IRQF_NOBALANCING, |
145 | .name = "smp local timer IPI" | 147 | .name = "smp local timer IPI" |
146 | }; | 148 | }; |
147 | #endif | 149 | #endif |
@@ -180,6 +182,7 @@ static void init_ipi(void) | |||
180 | 182 | ||
181 | #ifdef CONFIG_MN10300_CACHE_ENABLED | 183 | #ifdef CONFIG_MN10300_CACHE_ENABLED |
182 | /* set up the cache flush IPI */ | 184 | /* set up the cache flush IPI */ |
185 | irq_set_chip(FLUSH_CACHE_IPI, &mn10300_ipi_type); | ||
183 | flags = arch_local_cli_save(); | 186 | flags = arch_local_cli_save(); |
184 | __set_intr_stub(NUM2EXCEP_IRQ_LEVEL(FLUSH_CACHE_GxICR_LV), | 187 | __set_intr_stub(NUM2EXCEP_IRQ_LEVEL(FLUSH_CACHE_GxICR_LV), |
185 | mn10300_low_ipi_handler); | 188 | mn10300_low_ipi_handler); |
@@ -189,6 +192,7 @@ static void init_ipi(void) | |||
189 | #endif | 192 | #endif |
190 | 193 | ||
191 | /* set up the NMI call function IPI */ | 194 | /* set up the NMI call function IPI */ |
195 | irq_set_chip(CALL_FUNCTION_NMI_IPI, &mn10300_ipi_type); | ||
192 | flags = arch_local_cli_save(); | 196 | flags = arch_local_cli_save(); |
193 | GxICR(CALL_FUNCTION_NMI_IPI) = GxICR_NMI | GxICR_ENABLE | GxICR_DETECT; | 197 | GxICR(CALL_FUNCTION_NMI_IPI) = GxICR_NMI | GxICR_ENABLE | GxICR_DETECT; |
194 | tmp16 = GxICR(CALL_FUNCTION_NMI_IPI); | 198 | tmp16 = GxICR(CALL_FUNCTION_NMI_IPI); |
@@ -199,6 +203,10 @@ static void init_ipi(void) | |||
199 | __set_intr_stub(NUM2EXCEP_IRQ_LEVEL(SMP_BOOT_GxICR_LV), | 203 | __set_intr_stub(NUM2EXCEP_IRQ_LEVEL(SMP_BOOT_GxICR_LV), |
200 | mn10300_low_ipi_handler); | 204 | mn10300_low_ipi_handler); |
201 | arch_local_irq_restore(flags); | 205 | arch_local_irq_restore(flags); |
206 | |||
207 | #ifdef CONFIG_KERNEL_DEBUGGER | ||
208 | irq_set_chip(DEBUGGER_NMI_IPI, &mn10300_ipi_type); | ||
209 | #endif | ||
202 | } | 210 | } |
203 | 211 | ||
204 | /** | 212 | /** |