summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2008-07-29 16:07:37 +1000
committerStephen Rothwell <sfr@canb.auug.org.au>2008-07-29 16:09:35 +1000
commitdde108a23e4bf6d6d225ae18c64abeaf85fe2b50 (patch)
tree22de0ffb61baf1d3bc01a64d6a794448b14ab3a0
parent2e1b9983613b28109843011d7f6609674383a4c0 (diff)
cpumask: statement expressions confuse some versions of gcc
when you take the address of the result. Noticed on a sparc64 compile using a version 3.4.5 cross compiler. kernel/time/tick-common.c: In function `tick_check_new_device': kernel/time/tick-common.c:210: error: invalid lvalue in unary `&' kernel/time/tick-common.c:223: error: invalid lvalue in unary `&' kernel/time/tick-common.c:255: error: invalid lvalue in unary `&' Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
-rw-r--r--include/linux/cpumask.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h
index 96d0509fb8d8..d3219d73f8e6 100644
--- a/include/linux/cpumask.h
+++ b/include/linux/cpumask.h
@@ -287,7 +287,7 @@ static inline const cpumask_t *get_cpu_mask(unsigned int cpu)
* gcc optimizes it out (it's a constant) and there's no huge stack
* variable created:
*/
-#define cpumask_of_cpu(cpu) ({ *get_cpu_mask(cpu); })
+#define cpumask_of_cpu(cpu) (*get_cpu_mask(cpu))
#define CPU_MASK_LAST_WORD BITMAP_LAST_WORD_MASK(NR_CPUS)