Skip to contentSkip to conversation

mips: Remove __GFP_HIGHMEM masking

PATCH Applied Vishal Moola (Oracle) 2 participants 2 messages Nov 7, 2025 – Dec 1, 2025 MIPS

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mips: Remove __GFP_HIGHMEM masking

Remove unnecessary __GFP_HIGHMEM masking, which was introduced with commit 3e14fb19ad7c ("mips: convert various functions to use ptdescs"). GFP_KERNEL doesn't contain __GFP_HIGHMEM.

---
 arch/mips/include/asm/pgalloc.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
arch/mips/include/asm/pgalloc.h +1 -2
index 942af87f1cdd..7a04381efa0b 100644
@@ -81,8 +81,7 @@ static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
 static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long address)
 {
 	pud_t *pud;
-	struct ptdesc *ptdesc = pagetable_alloc(GFP_KERNEL & ~__GFP_HIGHMEM,
-			PUD_TABLE_ORDER);
+	struct ptdesc *ptdesc = pagetable_alloc(GFP_KERNEL, PUD_TABLE_ORDER);
 
 	if (!ptdesc)
 		return NULL;
Signature · 1 line
2.51.1
maintainer Applied
#1 lore raw
Quoted 25 lines · Vishal Moola (Oracle)

Remove unnecessary __GFP_HIGHMEM masking, which was introduced with commit 3e14fb19ad7c ("mips: convert various functions to use ptdescs"). GFP_KERNEL doesn't contain __GFP_HIGHMEM.

---
 arch/mips/include/asm/pgalloc.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
arch/mips/include/asm/pgalloc.h +1 -2
index 942af87f1cdd..7a04381efa0b 100644
@@ -81,8 +81,7 @@ static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
 static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long address)
 {
 	pud_t *pud;
-	struct ptdesc *ptdesc = pagetable_alloc(GFP_KERNEL & ~__GFP_HIGHMEM,
-			PUD_TABLE_ORDER);
+	struct ptdesc *ptdesc = pagetable_alloc(GFP_KERNEL, PUD_TABLE_ORDER);
 
 	if (!ptdesc)
 		return NULL;
Signature · 1 line
2.51.1

applied to mips-next.

Thomas.

Signature · 2 lines
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]