diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2022-09-15 13:10:44 +0200 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2022-10-17 16:40:57 +0200 |
commit | 4c4eb3ecc91f4fee6d6bf7cfbc1e21f2e38d19ff (patch) | |
tree | 1b2be88704951a295a226cb84867b8add3edbd37 /arch/x86/kernel/ftrace.c | |
parent | 2cb15faaedeb67f52f2ddc32b5ca152acfc422c2 (diff) | |
download | linux-stable-4c4eb3ecc91f4fee6d6bf7cfbc1e21f2e38d19ff.tar.gz linux-stable-4c4eb3ecc91f4fee6d6bf7cfbc1e21f2e38d19ff.tar.bz2 linux-stable-4c4eb3ecc91f4fee6d6bf7cfbc1e21f2e38d19ff.zip |
x86/modules: Set VM_FLUSH_RESET_PERMS in module_alloc()
Instead of resetting permissions all over the place when freeing module
memory tell the vmalloc code to do so. Avoids the exercise for the next
upcoming user.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20220915111143.406703869@infradead.org
Diffstat (limited to 'arch/x86/kernel/ftrace.c')
-rw-r--r-- | arch/x86/kernel/ftrace.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/x86/kernel/ftrace.c b/arch/x86/kernel/ftrace.c index bd165004776d..00eac455a3a1 100644 --- a/arch/x86/kernel/ftrace.c +++ b/arch/x86/kernel/ftrace.c @@ -413,8 +413,6 @@ create_trampoline(struct ftrace_ops *ops, unsigned int *tramp_size) /* ALLOC_TRAMP flags lets us know we created it */ ops->flags |= FTRACE_OPS_FL_ALLOC_TRAMP; - set_vm_flush_reset_perms(trampoline); - if (likely(system_state != SYSTEM_BOOTING)) set_memory_ro((unsigned long)trampoline, npages); set_memory_x((unsigned long)trampoline, npages); |