Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests: Emit a warning if getcpu() is missing on 32bit

The VDSO implementation for getcpu() has been wired up on 32bit so warn if
missing.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Shuah Khan <skhan@linuxfoundation.org>
Link: https://lore.kernel.org/r/20221125094216.3663444-4-bigeasy@linutronix.de

authored by

Sebastian Andrzej Siewior and committed by
Thomas Gleixner
5646bbd6 92d33063

+2 -5
+2 -5
tools/testing/selftests/x86/test_vsyscall.c
··· 92 92 printf("[WARN]\tfailed to find time in vDSO\n"); 93 93 94 94 vdso_getcpu = (getcpu_t)dlsym(vdso, "__vdso_getcpu"); 95 - if (!vdso_getcpu) { 96 - /* getcpu() was never wired up in the 32-bit vDSO. */ 97 - printf("[%s]\tfailed to find getcpu in vDSO\n", 98 - sizeof(long) == 8 ? "WARN" : "NOTE"); 99 - } 95 + if (!vdso_getcpu) 96 + printf("[WARN]\tfailed to find getcpu in vDSO\n"); 100 97 } 101 98 102 99 static int init_vsys(void)