[PATCH] riscv: Fixup one-page wasting

guoren at kernel.org guoren at kernel.org
Tue Nov 23 22:05:21 PST 2021


From: Guo Ren <guoren at linux.alibaba.com>

For small memory systems(Allwinner D1s/F133), one page size memory
cannot be ignored.

Signed-off-by: Guo Ren <guoren at linux.alibaba.com>
Cc: Alexandre Ghiti <alex at ghiti.fr>
Cc: Anup Patel <anup at brainfault.org>
Cc: Atish Patra <Atish.Patra at wdc.com>
---
 arch/riscv/mm/init.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
index 24b2b8044602..097bb3bc4020 100644
--- a/arch/riscv/mm/init.c
+++ b/arch/riscv/mm/init.c
@@ -241,9 +241,9 @@ unsigned long riscv_pfn_base __ro_after_init;
 EXPORT_SYMBOL(riscv_pfn_base);
 
 pgd_t swapper_pg_dir[PTRS_PER_PGD] __page_aligned_bss;
-pgd_t trampoline_pg_dir[PTRS_PER_PGD] __page_aligned_bss;
 static pte_t fixmap_pte[PTRS_PER_PTE] __page_aligned_bss;
 
+pgd_t trampoline_pg_dir[PTRS_PER_PGD] __initdata __aligned(PAGE_SIZE);
 pgd_t early_pg_dir[PTRS_PER_PGD] __initdata __aligned(PAGE_SIZE);
 static pmd_t __maybe_unused early_dtb_pmd[PTRS_PER_PMD] __initdata __aligned(PAGE_SIZE);
 
-- 
2.25.1




More information about the linux-riscv mailing list