Messages in this thread | | | From | Alexandre Ghiti <> | Subject | [PATCH -fixes 0/2] Fix WX mappings in the linear mapping after module unloading | Date | Wed, 13 Dec 2023 14:40:25 +0100 |
| |
I fell onto a bunch of WX mappings in the linear mapping after a module gets unloaded, this is because our module_alloc() does not set the VM_FLUSH_RESET_PERMS flag (patch 1) and that set_direct_map_default_noflush() must clean the X bit (patch 2).
Note that the Fixes tags are correct but patch 2 will fail to apply since a change in this function just landed in 6.7.
Alexandre Ghiti (2): riscv: Fix module_alloc() that did not reset the linear mapping permissions riscv: Fix set_direct_map_default_noflush() to reset _PAGE_EXEC
arch/riscv/kernel/module.c | 3 ++- arch/riscv/mm/pageattr.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-)
-- 2.39.2
| |