|
@@ -104,9 +104,16 @@ extern nodemask_t _unused_nodemask_arg_;
|
|
|
*
|
|
|
* Can be used to provide arguments for '%*pb[l]' when printing a nodemask.
|
|
|
*/
|
|
|
-#define nodemask_pr_args(maskp) \
|
|
|
- ((maskp) != NULL) ? MAX_NUMNODES : 0, \
|
|
|
- ((maskp) != NULL) ? (maskp)->bits : NULL
|
|
|
+#define nodemask_pr_args(maskp) __nodemask_pr_numnodes(maskp), \
|
|
|
+ __nodemask_pr_bits(maskp)
|
|
|
+static inline unsigned int __nodemask_pr_numnodes(const nodemask_t *m)
|
|
|
+{
|
|
|
+ return m ? MAX_NUMNODES : 0;
|
|
|
+}
|
|
|
+static inline const unsigned long *__nodemask_pr_bits(const nodemask_t *m)
|
|
|
+{
|
|
|
+ return m ? m->bits : NULL;
|
|
|
+}
|
|
|
|
|
|
/*
|
|
|
* The inline keyword gives the compiler room to decide to inline, or
|