Skip to contentSkip to conversation

arch/x86/include/asm/page.h: update usage of movableflags

RFC PATCH New Huaisheng Ye 1 participant 1 message May 23, 2018

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

RFC PATCH v3 9/9 arch/x86/include/asm/page.h: update usage of movableflags

From: Huaisheng Ye <[email protected]>

GFP_HIGHUSER_MOVABLE doesn't equal to GFP_HIGHUSER | __GFP_MOVABLE, modify it to adapt patch of getting rid of GFP_ZONE_TABLE/BAD.

Cc Thomas Gleixner <[email protected]>
Cc Ingo Molnar <[email protected]>
Cc "H. Peter Anvin" <[email protected]>
Cc Kate Stewart <[email protected]>
Cc Greg Kroah-Hartman <[email protected]>
Cc Philippe Ombredanne <pombredanne-od1rfyK75/[email protected]>
Cc Christoph Hellwig <[email protected]>
---
 arch/x86/include/asm/page.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/x86/include/asm/page.h +2 -1
index 7555b48..a47f42d 100644
@@ -35,7 +35,8 @@ static inline void copy_user_page(void *to, void *from, unsigned long vaddr,
 }
 
 #define __alloc_zeroed_user_highpage(movableflags, vma, vaddr) \
-	alloc_page_vma(GFP_HIGHUSER | __GFP_ZERO | movableflags, vma, vaddr)
+	alloc_page_vma((movableflags ? GFP_HIGHUSER_MOVABLE : GFP_HIGHUSER) \
+	| __GFP_ZERO, vma, vaddr)
 #define __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE
 
 #ifndef __pa
Signature · 1 line
1.8.3.1