riscv: Don't use PGD entries for the linear mapping
authorAlexandre Ghiti <alexghiti@rivosinc.com>
Wed, 8 Nov 2023 07:59:29 +0000 (08:59 +0100)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 8 Nov 2023 15:08:32 +0000 (07:08 -0800)
commit629db01c64ff6cea08fc61b52426362689ef8618
tree2fb8971e08ada522c0becc8e1c2943536dbdd71f
parent0bb80ecc33a8fb5a682236443c1e740d5c917d1d
riscv: Don't use PGD entries for the linear mapping

Propagating changes at this level is cumbersome as we need to go through
all the page tables when that happens (either when changing the
permissions or when splitting the mapping).

Note that this prevents the use of 4MB mapping for sv32 and 1GB mapping for
sv39 in the linear mapping.

Signed-off-by: Alexandre Ghiti <alexghiti@rivosinc.com>
Link: https://lore.kernel.org/r/20231108075930.7157-2-alexghiti@rivosinc.com
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/mm/init.c