diff options
author | Julia Lawall <julia@diku.dk> | 2010-03-26 18:02:23 -0400 |
---|---|---|
committer | Tony Luck <tony.luck@intel.com> | 2010-05-18 17:45:53 -0400 |
commit | 552dce3a071f0de2a84023fbba7f3b4ac36602cd (patch) | |
tree | 490c63647dcaa2b5f8519908dd003c59d17eb30c | |
parent | 93f7c93bee6382e01c34ea0c34ff8fb98c648734 (diff) |
[IA64] Use set_cpus_allowed_ptr
Use set_cpus_allowed_ptr rather than set_cpus_allowed.
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Tony Luck <tony.luck@intel.com>
-rw-r--r-- | arch/ia64/kernel/cpufreq/acpi-cpufreq.c | 10 | ||||
-rw-r--r-- | arch/ia64/kernel/salinfo.c | 5 | ||||
-rw-r--r-- | arch/ia64/kernel/topology.c | 4 |
3 files changed, 9 insertions, 10 deletions
diff --git a/arch/ia64/kernel/cpufreq/acpi-cpufreq.c b/arch/ia64/kernel/cpufreq/acpi-cpufreq.c index b0b4e6e710f2..22f61526a8e1 100644 --- a/arch/ia64/kernel/cpufreq/acpi-cpufreq.c +++ b/arch/ia64/kernel/cpufreq/acpi-cpufreq.c | |||
@@ -113,7 +113,7 @@ processor_get_freq ( | |||
113 | dprintk("processor_get_freq\n"); | 113 | dprintk("processor_get_freq\n"); |
114 | 114 | ||
115 | saved_mask = current->cpus_allowed; | 115 | saved_mask = current->cpus_allowed; |
116 | set_cpus_allowed(current, cpumask_of_cpu(cpu)); | 116 | set_cpus_allowed_ptr(current, cpumask_of(cpu)); |
117 | if (smp_processor_id() != cpu) | 117 | if (smp_processor_id() != cpu) |
118 | goto migrate_end; | 118 | goto migrate_end; |
119 | 119 | ||
@@ -121,7 +121,7 @@ processor_get_freq ( | |||
121 | ret = processor_get_pstate(&value); | 121 | ret = processor_get_pstate(&value); |
122 | 122 | ||
123 | if (ret) { | 123 | if (ret) { |
124 | set_cpus_allowed(current, saved_mask); | 124 | set_cpus_allowed_ptr(current, &saved_mask); |
125 | printk(KERN_WARNING "get performance failed with error %d\n", | 125 | printk(KERN_WARNING "get performance failed with error %d\n", |
126 | ret); | 126 | ret); |
127 | ret = 0; | 127 | ret = 0; |
@@ -131,7 +131,7 @@ processor_get_freq ( | |||
131 | ret = (clock_freq*1000); | 131 | ret = (clock_freq*1000); |
132 | 132 | ||
133 | migrate_end: | 133 | migrate_end: |
134 | set_cpus_allowed(current, saved_mask); | 134 | set_cpus_allowed_ptr(current, &saved_mask); |
135 | return ret; | 135 | return ret; |
136 | } | 136 | } |
137 | 137 | ||
@@ -151,7 +151,7 @@ processor_set_freq ( | |||
151 | dprintk("processor_set_freq\n"); | 151 | dprintk("processor_set_freq\n"); |
152 | 152 | ||
153 | saved_mask = current->cpus_allowed; | 153 | saved_mask = current->cpus_allowed; |
154 | set_cpus_allowed(current, cpumask_of_cpu(cpu)); | 154 | set_cpus_allowed_ptr(current, cpumask_of(cpu)); |
155 | if (smp_processor_id() != cpu) { | 155 | if (smp_processor_id() != cpu) { |
156 | retval = -EAGAIN; | 156 | retval = -EAGAIN; |
157 | goto migrate_end; | 157 | goto migrate_end; |
@@ -208,7 +208,7 @@ processor_set_freq ( | |||
208 | retval = 0; | 208 | retval = 0; |
209 | 209 | ||
210 | migrate_end: | 210 | migrate_end: |
211 | set_cpus_allowed(current, saved_mask); | 211 | set_cpus_allowed_ptr(current, &saved_mask); |
212 | return (retval); | 212 | return (retval); |
213 | } | 213 | } |
214 | 214 | ||
diff --git a/arch/ia64/kernel/salinfo.c b/arch/ia64/kernel/salinfo.c index e6676fca4828..aa8b5fa1a8de 100644 --- a/arch/ia64/kernel/salinfo.c +++ b/arch/ia64/kernel/salinfo.c | |||
@@ -404,10 +404,9 @@ static void | |||
404 | call_on_cpu(int cpu, void (*fn)(void *), void *arg) | 404 | call_on_cpu(int cpu, void (*fn)(void *), void *arg) |
405 | { | 405 | { |
406 | cpumask_t save_cpus_allowed = current->cpus_allowed; | 406 | cpumask_t save_cpus_allowed = current->cpus_allowed; |
407 | cpumask_t new_cpus_allowed = cpumask_of_cpu(cpu); | 407 | set_cpus_allowed_ptr(current, cpumask_of(cpu)); |
408 | set_cpus_allowed(current, new_cpus_allowed); | ||
409 | (*fn)(arg); | 408 | (*fn)(arg); |
410 | set_cpus_allowed(current, save_cpus_allowed); | 409 | set_cpus_allowed_ptr(current, &save_cpus_allowed); |
411 | } | 410 | } |
412 | 411 | ||
413 | static void | 412 | static void |
diff --git a/arch/ia64/kernel/topology.c b/arch/ia64/kernel/topology.c index 28f299de2903..0baa1bbb65fe 100644 --- a/arch/ia64/kernel/topology.c +++ b/arch/ia64/kernel/topology.c | |||
@@ -361,12 +361,12 @@ static int __cpuinit cache_add_dev(struct sys_device * sys_dev) | |||
361 | return 0; | 361 | return 0; |
362 | 362 | ||
363 | oldmask = current->cpus_allowed; | 363 | oldmask = current->cpus_allowed; |
364 | retval = set_cpus_allowed(current, cpumask_of_cpu(cpu)); | 364 | retval = set_cpus_allowed_ptr(current, cpumask_of(cpu)); |
365 | if (unlikely(retval)) | 365 | if (unlikely(retval)) |
366 | return retval; | 366 | return retval; |
367 | 367 | ||
368 | retval = cpu_cache_sysfs_init(cpu); | 368 | retval = cpu_cache_sysfs_init(cpu); |
369 | set_cpus_allowed(current, oldmask); | 369 | set_cpus_allowed_ptr(current, &oldmask); |
370 | if (unlikely(retval < 0)) | 370 | if (unlikely(retval < 0)) |
371 | return retval; | 371 | return retval; |
372 | 372 | ||