]> git.hungrycats.org Git - linux/commitdiff
[PATCH] CPU_MASK_ALL fix
authorAndrew Morton <akpm@osdl.org>
Mon, 19 Apr 2004 05:05:02 +0000 (22:05 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Mon, 19 Apr 2004 05:05:02 +0000 (22:05 -0700)
From: Nick Piggin <nickpiggin@yahoo.com.au>

Do the typecast thing to permit CPU_MASK_ALL to be used both as an
initialiser and as a normal rvalue.

include/asm-generic/cpumask_array.h

index c7e2db29dc537bce539c57a5fcc16cf0ce9c8e11..ddd6e1185dba13ab262e5c461d03f2a54f8798aa 100644 (file)
@@ -48,7 +48,7 @@
 /*
  * um, these need to be usable as static initializers
  */
-#define CPU_MASK_ALL   { {[0 ... CPU_ARRAY_SIZE-1] = ~0UL} }
-#define CPU_MASK_NONE  { {[0 ... CPU_ARRAY_SIZE-1] =  0UL} }
+#define CPU_MASK_ALL   ((cpumask_t) { {[0 ... CPU_ARRAY_SIZE-1] = ~0UL} })
+#define CPU_MASK_NONE  ((cpumask_t) { {[0 ... CPU_ARRAY_SIZE-1] =  0UL} })
 
 #endif /* __ASM_GENERIC_CPUMASK_ARRAY_H */