Commit a62f735cbb1a0937ab6a9196dadf752694ef0b7f

Authored by David Howells
Committed by Linus Torvalds
1 parent 5e45bb2eba

MM: Fix macro argument substitution in PageHead() and PageTail()

Fix macro argument substitution in PageHead() and PageTail() - 'page' should
have brackets surrounding it (commit 6d7779538f765963ced45a3fa4bed7ba8d2c277d).

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 1 changed file with 2 additions and 2 deletions Side-by-side Diff

include/linux/page-flags.h
... ... @@ -266,7 +266,7 @@
266 266  
267 267 #define PG_head_tail_mask ((1L << PG_compound) | (1L << PG_reclaim))
268 268  
269   -#define PageTail(page) ((page->flags & PG_head_tail_mask) \
  269 +#define PageTail(page) (((page)->flags & PG_head_tail_mask) \
270 270 == PG_head_tail_mask)
271 271  
272 272 static inline void __SetPageTail(struct page *page)
... ... @@ -279,7 +279,7 @@
279 279 page->flags &= ~PG_head_tail_mask;
280 280 }
281 281  
282   -#define PageHead(page) ((page->flags & PG_head_tail_mask) \
  282 +#define PageHead(page) (((page)->flags & PG_head_tail_mask) \
283 283 == (1L << PG_compound))
284 284 #define __SetPageHead(page) __SetPageCompound(page)
285 285 #define __ClearPageHead(page) __ClearPageCompound(page)