diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/nodemask.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/include/linux/nodemask.h b/include/linux/nodemask.h index 4e2cbfa640b7..58b9a02c38d2 100644 --- a/include/linux/nodemask.h +++ b/include/linux/nodemask.h | |||
@@ -98,8 +98,17 @@ | |||
98 | typedef struct { DECLARE_BITMAP(bits, MAX_NUMNODES); } nodemask_t; | 98 | typedef struct { DECLARE_BITMAP(bits, MAX_NUMNODES); } nodemask_t; |
99 | extern nodemask_t _unused_nodemask_arg_; | 99 | extern nodemask_t _unused_nodemask_arg_; |
100 | 100 | ||
101 | /* | ||
102 | * The inline keyword gives the compiler room to decide to inline, or | ||
103 | * not inline a function as it sees best. However, as these functions | ||
104 | * are called in both __init and non-__init functions, if they are not | ||
105 | * inlined we will end up with a section mis-match error (of the type of | ||
106 | * freeable items not being freed). So we must use __always_inline here | ||
107 | * to fix the problem. If other functions in the future also end up in | ||
108 | * this situation they will also need to be annotated as __always_inline | ||
109 | */ | ||
101 | #define node_set(node, dst) __node_set((node), &(dst)) | 110 | #define node_set(node, dst) __node_set((node), &(dst)) |
102 | static inline void __node_set(int node, volatile nodemask_t *dstp) | 111 | static __always_inline void __node_set(int node, volatile nodemask_t *dstp) |
103 | { | 112 | { |
104 | set_bit(node, dstp->bits); | 113 | set_bit(node, dstp->bits); |
105 | } | 114 | } |