[PATCH 3/3] arm: replace old cpumask functions with new one.

From: KOSAKI Motohiro
Date: Thu Jun 23 2011 - 04:31:56 EST


Now cpus_xx() cpumask functions are marked as deprecated. This
patch replace them with modern one.

Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx>
Cc: Russell King <linux@xxxxxxxxxxxxxxxx>
Cc: linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
---
arch/arm/common/gic.c | 2 +-
arch/arm/kernel/kprobes.c | 2 +-
arch/arm/kernel/smp.c | 5 +++--
3 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/arch/arm/common/gic.c b/arch/arm/common/gic.c
index 4ddd0a6..ebd6b3b 100644
--- a/arch/arm/common/gic.c
+++ b/arch/arm/common/gic.c
@@ -389,7 +389,7 @@ void __cpuinit gic_enable_ppi(unsigned int irq)
#ifdef CONFIG_SMP
void gic_raise_softirq(const struct cpumask *mask, unsigned int irq)
{
- unsigned long map = *cpus_addr(*mask);
+ unsigned long map = *cpumask_bits(mask);

/*
* Ensure that stores to Normal memory are visible to the
diff --git a/arch/arm/kernel/kprobes.c b/arch/arm/kernel/kprobes.c
index 1656c87..4ecc5ce 100644
--- a/arch/arm/kernel/kprobes.c
+++ b/arch/arm/kernel/kprobes.c
@@ -102,7 +102,7 @@ int __kprobes __arch_disarm_kprobe(void *p)

void __kprobes arch_disarm_kprobe(struct kprobe *p)
{
- stop_machine(__arch_disarm_kprobe, p, &cpu_online_map);
+ stop_machine(__arch_disarm_kprobe, p, cpu_online_mask);
}

void __kprobes arch_remove_kprobe(struct kprobe *p)
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 344e52b..98a48ab 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -601,8 +601,9 @@ void smp_send_stop(void)
unsigned long timeout;

if (num_online_cpus() > 1) {
- cpumask_t mask = cpu_online_map;
- cpu_clear(smp_processor_id(), mask);
+ cpumask_t mask;
+ cpumask_copy(&mask, cpu_online_mask);
+ cpumask_clear_cpu(smp_processor_id(), &mask);

smp_cross_call(&mask, IPI_CPU_STOP);
}
--
1.7.3.1



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/