Skip to contentSkip to conversation

mask ADT: simplify i386/mach-es7000 cpumask use [18/22]

PATCH New Paul Jackson 1 participant 1 message Mar 29, 2004

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mask ADT: simplify i386/mach-es7000 cpumask use [18/22]

Patch_18_of_22 - Optimize i386 cpumask macro usage.
Optimize a bit of cpumask code for asm-i386/mach-es7000 Code untested, unreviewed. Feedback welcome.

diffstat Patch_18_of_22:

 mach_ipi.h |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher. # This patch includes the following deltas:
# ChangeSet 1.1724 -> 1.1725
# include/asm-i386/mach-es7000/mach_ipi.h 1.2 -> 1.3
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 04/03/29 [email protected] 1.1725
# Optimize i386 cpumask macro usage. Code untested and unreviewed. # Feedback welcome.
# --------------------------------------------
#

include/asm-i386/mach-es7000/mach_ipi.h +2 -3
diff -Nru a/include/asm-i386/mach-es7000/mach_ipi.h b/include/asm-i386/mach-es7000/mach_ipi.h
@@ -10,9 +10,8 @@
 
 static inline void send_IPI_allbutself(int vector)
 {
-	cpumask_t mask = cpumask_of_cpu(smp_processor_id());
-	cpus_complement(mask);
-	cpus_and(mask, mask, cpu_online_map);
+	cpumask_t mask = cpu_online_map;
+	cpu_clear(smp_processor_id(), mask);
 	if (!cpus_empty(mask))
 		send_IPI_mask(mask, vector);
 }
Signature · 3 lines
                          I won't rest till it's the best ...
                          Programmer, Linux Scalability
                          Paul Jackson <[email protected]> 1.650.933.1373