riscv: Flush the tlb when a page directory is freed
authorAlexandre Ghiti <alexghiti@rivosinc.com>
Sun, 28 Jan 2024 12:04:05 +0000 (13:04 +0100)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 7 Feb 2024 00:57:16 +0000 (16:57 -0800)
commit97cf301fa42e8ea6e0a24de97bc0abcdc87d9504
treee77cdffeafcce5dc02c867ebf41498bbcd42e55e
parent168b849728c2c47ddaab1408049561100bb7ea51
riscv: Flush the tlb when a page directory is freed

The riscv privileged specification mandates to flush the TLB whenever a
page directory is modified, so add that to tlb_flush().

Fixes: c5e9b2c2ae82 ("riscv: Improve tlb_flush()")
Signed-off-by: Alexandre Ghiti <alexghiti@rivosinc.com>
Reviewed-by: Charlie Jenkins <charlie@rivosinc.com>
Link: https://lore.kernel.org/r/20240128120405.25876-1-alexghiti@rivosinc.com
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/include/asm/tlb.h