From 4946eb5d37cb6a260b9e0ec4b812c2b104fd6ea1 Mon Sep 17 00:00:00 2001 From: "Mike Rapoport (Microsoft)" Date: Thu, 16 Jul 2026 10:51:36 +0300 Subject: [PATCH] bpf: Drop __weak from bpf_jit_alloc_exec() and bpf_jit_free_exec() bpf_jit_alloc_exec() and bpf_jit_free_exec() are wrappers for the corresponding execmem APIs. Architectures define the properties of the memory range needed by BPF in their initialization of execmem and don't need to override neither of them. Drop the __weak qualifier from bpf_jit_alloc_exec() and bpf_jit_free_exec(). Signed-off-by: Mike Rapoport (Microsoft) Acked-by: Song Liu Link: https://lore.kernel.org/bpf/20260716-execmem-x86-rox-bpf-v0-v3-2-4e76158c01c5@kernel.org Signed-off-by: Kumar Kartikeya Dwivedi --- kernel/bpf/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/bpf/core.c b/kernel/bpf/core.c index 47fe047ad30b..fc75625dc951 100644 --- a/kernel/bpf/core.c +++ b/kernel/bpf/core.c @@ -1116,12 +1116,12 @@ void bpf_jit_uncharge_modmem(u32 size) atomic_long_sub(size, &bpf_jit_current); } -void *__weak bpf_jit_alloc_exec(unsigned long size) +void *bpf_jit_alloc_exec(unsigned long size) { return execmem_alloc(EXECMEM_BPF, size); } -void __weak bpf_jit_free_exec(void *addr) +void bpf_jit_free_exec(void *addr) { execmem_free(addr); }