Thread (49 messages) 49 messages, 7 authors, 2023-11-07

Re: [PATCH v3 09/13] powerpc: extend execmem_params for kprobes allocations

From: Song Liu <song@kernel.org>
Date: 2023-09-21 22:31:05
Also in: bpf, linux-arm-kernel, linux-mips, linux-mm, linux-modules, linux-riscv, linux-s390, linux-trace-kernel, linuxppc-dev, lkml, loongarch, sparclinux

On Mon, Sep 18, 2023 at 12:31 AM Mike Rapoport [off-list ref] wrote:
[...]
quoted hunk ↗ jump to hunk
@@ -135,5 +138,13 @@ struct execmem_params __init *execmem_arch_params(void)

        range->pgprot = prot;

+       execmem_params.ranges[EXECMEM_KPROBES].start = VMALLOC_START;
+       execmem_params.ranges[EXECMEM_KPROBES].start = VMALLOC_END;
.end = VMALLOC_END.

Thanks,
Song
+
+       if (strict_module_rwx_enabled())
+               execmem_params.ranges[EXECMEM_KPROBES].pgprot = PAGE_KERNEL_ROX;
+       else
+               execmem_params.ranges[EXECMEM_KPROBES].pgprot = PAGE_KERNEL_EXEC;
+
        return &execmem_params;
 }
--
2.39.2
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help