diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2008-12-13 05:50:26 -0500 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2008-12-13 05:50:26 -0500 |
commit | 0de26520c7cabf36e1de090ea8092f011a6106ce (patch) | |
tree | 3d02e509b6315fdfd9cdb8c9e0b9ed0a30cf9384 /arch/alpha | |
parent | 29c0177e6a4ac094302bed54a1d4bbb6b740a9ef (diff) |
cpumask: make irq_set_affinity() take a const struct cpumask
Impact: change existing irq_chip API
Not much point with gentle transition here: the struct irq_chip's
setaffinity method signature needs to change.
Fortunately, not widely used code, but hits a few architectures.
Note: In irq_select_affinity() I save a temporary in by mangling
irq_desc[irq].affinity directly. Ingo, does this break anything?
(Folded in fix from KOSAKI Motohiro)
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Mike Travis <travis@sgi.com>
Reviewed-by: Grant Grundler <grundler@parisc-linux.org>
Acked-by: Ingo Molnar <mingo@redhat.com>
Cc: ralf@linux-mips.org
Cc: grundler@parisc-linux.org
Cc: jeremy@xensource.com
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Diffstat (limited to 'arch/alpha')
-rw-r--r-- | arch/alpha/kernel/irq.c | 2 | ||||
-rw-r--r-- | arch/alpha/kernel/sys_dp264.c | 8 | ||||
-rw-r--r-- | arch/alpha/kernel/sys_titan.c | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/arch/alpha/kernel/irq.c b/arch/alpha/kernel/irq.c index c626a821cdcb..d0f1620007f7 100644 --- a/arch/alpha/kernel/irq.c +++ b/arch/alpha/kernel/irq.c | |||
@@ -55,7 +55,7 @@ int irq_select_affinity(unsigned int irq) | |||
55 | last_cpu = cpu; | 55 | last_cpu = cpu; |
56 | 56 | ||
57 | irq_desc[irq].affinity = cpumask_of_cpu(cpu); | 57 | irq_desc[irq].affinity = cpumask_of_cpu(cpu); |
58 | irq_desc[irq].chip->set_affinity(irq, cpumask_of_cpu(cpu)); | 58 | irq_desc[irq].chip->set_affinity(irq, cpumask_of(cpu)); |
59 | return 0; | 59 | return 0; |
60 | } | 60 | } |
61 | #endif /* CONFIG_SMP */ | 61 | #endif /* CONFIG_SMP */ |
diff --git a/arch/alpha/kernel/sys_dp264.c b/arch/alpha/kernel/sys_dp264.c index c71b0fd7a61f..ab44c164d9d4 100644 --- a/arch/alpha/kernel/sys_dp264.c +++ b/arch/alpha/kernel/sys_dp264.c | |||
@@ -177,19 +177,19 @@ cpu_set_irq_affinity(unsigned int irq, cpumask_t affinity) | |||
177 | } | 177 | } |
178 | 178 | ||
179 | static void | 179 | static void |
180 | dp264_set_affinity(unsigned int irq, cpumask_t affinity) | 180 | dp264_set_affinity(unsigned int irq, const struct cpumask *affinity) |
181 | { | 181 | { |
182 | spin_lock(&dp264_irq_lock); | 182 | spin_lock(&dp264_irq_lock); |
183 | cpu_set_irq_affinity(irq, affinity); | 183 | cpu_set_irq_affinity(irq, *affinity); |
184 | tsunami_update_irq_hw(cached_irq_mask); | 184 | tsunami_update_irq_hw(cached_irq_mask); |
185 | spin_unlock(&dp264_irq_lock); | 185 | spin_unlock(&dp264_irq_lock); |
186 | } | 186 | } |
187 | 187 | ||
188 | static void | 188 | static void |
189 | clipper_set_affinity(unsigned int irq, cpumask_t affinity) | 189 | clipper_set_affinity(unsigned int irq, const struct cpumask *affinity) |
190 | { | 190 | { |
191 | spin_lock(&dp264_irq_lock); | 191 | spin_lock(&dp264_irq_lock); |
192 | cpu_set_irq_affinity(irq - 16, affinity); | 192 | cpu_set_irq_affinity(irq - 16, *affinity); |
193 | tsunami_update_irq_hw(cached_irq_mask); | 193 | tsunami_update_irq_hw(cached_irq_mask); |
194 | spin_unlock(&dp264_irq_lock); | 194 | spin_unlock(&dp264_irq_lock); |
195 | } | 195 | } |
diff --git a/arch/alpha/kernel/sys_titan.c b/arch/alpha/kernel/sys_titan.c index 52c91ccc1648..27f840a4ad3d 100644 --- a/arch/alpha/kernel/sys_titan.c +++ b/arch/alpha/kernel/sys_titan.c | |||
@@ -158,10 +158,10 @@ titan_cpu_set_irq_affinity(unsigned int irq, cpumask_t affinity) | |||
158 | } | 158 | } |
159 | 159 | ||
160 | static void | 160 | static void |
161 | titan_set_irq_affinity(unsigned int irq, cpumask_t affinity) | 161 | titan_set_irq_affinity(unsigned int irq, const struct cpumask *affinity) |
162 | { | 162 | { |
163 | spin_lock(&titan_irq_lock); | 163 | spin_lock(&titan_irq_lock); |
164 | titan_cpu_set_irq_affinity(irq - 16, affinity); | 164 | titan_cpu_set_irq_affinity(irq - 16, *affinity); |
165 | titan_update_irq_hw(titan_cached_irq_mask); | 165 | titan_update_irq_hw(titan_cached_irq_mask); |
166 | spin_unlock(&titan_irq_lock); | 166 | spin_unlock(&titan_irq_lock); |
167 | } | 167 | } |