module, bpf: Store BTF base pointer in struct module
authorAlan Maguire <alan.maguire@oracle.com>
Thu, 20 Jun 2024 09:17:29 +0000 (10:17 +0100)
committerAndrii Nakryiko <andrii@kernel.org>
Fri, 21 Jun 2024 21:45:07 +0000 (14:45 -0700)
commitd4e48e3dd45017abdd69a19285d197de897ef44f
treea0f022a078e3faa261970df64601e3b446660f2e
parentd1cf840854bb603c0718a011bc993f69f2df014e
module, bpf: Store BTF base pointer in struct module

...as this will allow split BTF modules with a base BTF
representation (rather than the full vmlinux BTF at time of
BTF encoding) to resolve their references to kernel types in a
way that is more resilient to small changes in kernel types.

This will allow modules that are not built every time the kernel
is to provide more resilient BTF, rather than have it invalidated
every time BTF ids for core kernel types change.

Fields are ordered to avoid holes in struct module.

Signed-off-by: Alan Maguire <alan.maguire@oracle.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Acked-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20240620091733.1967885-3-alan.maguire@oracle.com
include/linux/module.h
kernel/module/main.c