diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-12-17 13:08:34 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-12-17 13:08:34 +0100 |
commit | 9466d6036f73481104039fbe99338baed11c8fea (patch) | |
tree | cc889fa3071be5fba09417eb17be3c8d2c5271d0 /arch/x86/kernel/ipi.c | |
parent | 1f3f424a6bee9de4d839be9951f4296333fac014 (diff) | |
parent | 83b19597f793fd5f91533bda0dc2eb3d21936798 (diff) | |
download | kernel_samsung_smdk4412-9466d6036f73481104039fbe99338baed11c8fea.tar.gz kernel_samsung_smdk4412-9466d6036f73481104039fbe99338baed11c8fea.tar.bz2 kernel_samsung_smdk4412-9466d6036f73481104039fbe99338baed11c8fea.zip |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/travis/linux-2.6-cpus4096-for-ingo into cpus4096
Diffstat (limited to 'arch/x86/kernel/ipi.c')
-rw-r--r-- | arch/x86/kernel/ipi.c | 28 |
1 files changed, 20 insertions, 8 deletions
diff --git a/arch/x86/kernel/ipi.c b/arch/x86/kernel/ipi.c index f1c688e46f3..285bbf8831f 100644 --- a/arch/x86/kernel/ipi.c +++ b/arch/x86/kernel/ipi.c @@ -116,18 +116,18 @@ static inline void __send_IPI_dest_field(unsigned long mask, int vector) /* * This is only used on smaller machines. */ -void send_IPI_mask_bitmask(cpumask_t cpumask, int vector) +void send_IPI_mask_bitmask(const struct cpumask *cpumask, int vector) { - unsigned long mask = cpus_addr(cpumask)[0]; + unsigned long mask = cpumask_bits(cpumask)[0]; unsigned long flags; local_irq_save(flags); - WARN_ON(mask & ~cpus_addr(cpu_online_map)[0]); + WARN_ON(mask & ~cpumask_bits(cpu_online_mask)[0]); __send_IPI_dest_field(mask, vector); local_irq_restore(flags); } -void send_IPI_mask_sequence(cpumask_t mask, int vector) +void send_IPI_mask_sequence(const struct cpumask *mask, int vector) { unsigned long flags; unsigned int query_cpu; @@ -139,12 +139,24 @@ void send_IPI_mask_sequence(cpumask_t mask, int vector) */ local_irq_save(flags); - for_each_possible_cpu(query_cpu) { - if (cpu_isset(query_cpu, mask)) { + for_each_cpu(query_cpu, mask) + __send_IPI_dest_field(cpu_to_logical_apicid(query_cpu), vector); + local_irq_restore(flags); +} + +void send_IPI_mask_allbutself(const struct cpumask *mask, int vector) +{ + unsigned long flags; + unsigned int query_cpu; + unsigned int this_cpu = smp_processor_id(); + + /* See Hack comment above */ + + local_irq_save(flags); + for_each_cpu(query_cpu, mask) + if (query_cpu != this_cpu) __send_IPI_dest_field(cpu_to_logical_apicid(query_cpu), vector); - } - } local_irq_restore(flags); } |