在 2021/7/26 上午9:48, Huang Pei 写道:
This reverts commit 002d8b395fa1c0679fc3c3e68873de6c1cc300a2.
b2b29d6d011944 (mm: account PMD tables like PTE tables) is
introduced between v5.9 and v5.10, so this fix should NOT
apply to any pre-5.10 branch
Missing sign-off.
Also I think you should make it clear that the patch is for stable in
subject
(like [PATCH for stable]) and Cc stable folks like Greg to catch their
attention.
Thanks.
- Jiaxun
---
arch/mips/include/asm/pgalloc.h | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/arch/mips/include/asm/pgalloc.h b/arch/mips/include/asm/pgalloc.h
index dd10854321ca..166842337eb2 100644
--- a/arch/mips/include/asm/pgalloc.h
+++ b/arch/mips/include/asm/pgalloc.h
@@ -62,15 +62,11 @@ do { \
static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
{
- pmd_t *pmd = NULL;
- struct page *pg;
+ pmd_t *pmd;
- pg = alloc_pages(GFP_KERNEL | __GFP_ACCOUNT, PMD_ORDER);
- if (pg) {
- pgtable_pmd_page_ctor(pg);
- pmd = (pmd_t *)page_address(pg);
+ pmd = (pmd_t *) __get_free_pages(GFP_KERNEL, PMD_ORDER);
+ if (pmd)
pmd_init((unsigned long)pmd, (unsigned long)invalid_pte_table);
- }
return pmd;
}