On Tue, Dec 30, 2025 at 08:08:44AM +0100, Thomas Weißschuh wrote: > The cache parameter of getcpu() is useless nowadays for various reasons. > * It is never passed by userspace for either the vDSO or syscalls. > * It is never used by the kernel. > * It could not be made to work on the current vDSO architecture. > * The structure definition is not part of the UAPI headers. > * vdso_getcpu() is superseded by restartable sequences in any case. > > Remove the struct and its header. > > As a side-effect we get rid of an unwanted inclusion of the linux/ > header namespace from vDSO code. > > Signed-off-by: Thomas Weißschuh <[email protected]> > --- > Changes in v3: > - Rebase on v6.19-rc1 > - Fix conflict with UML vdso_getcpu() removal > - Flesh out commit message > - Link to v2: > https://lore.kernel.org/r/[email protected] > > Changes in v2: > - Rebase on v6.18-rc1 > - Link to v1: > https://lore.kernel.org/r/[email protected] > --- > We could also completely remove the parameter, but I am not sure if > that is a good idea for syscalls and vDSO entrypoints. > --- > arch/loongarch/vdso/vgetcpu.c | 5 ++--- > arch/s390/kernel/vdso/getcpu.c | 3 +-- > arch/s390/kernel/vdso/vdso.h | 4 +--- > arch/x86/entry/vdso/vgetcpu.c | 5 ++--- > arch/x86/include/asm/vdso/processor.h | 4 +--- > include/linux/getcpu.h | 19 ------------------- > include/linux/syscalls.h | 3 +-- > kernel/sys.c | 4 +--- > tools/testing/selftests/vDSO/vdso_test_getcpu.c | 4 +--- > 9 files changed, 10 insertions(+), 41 deletions(-)
Acked-by: Heiko Carstens <[email protected]> # s390

