diff options
| author | Tiwei Bie <tiwei.btw@antgroup.com> | 2025-10-27 08:18:13 +0800 |
|---|---|---|
| committer | Johannes Berg <johannes.berg@intel.com> | 2025-10-27 16:41:53 +0100 |
| commit | 37f847b7949605e7803d72d6275beeaaf60099e6 (patch) | |
| tree | 661300889f699dc4cecb2182ad4fc9f74d2a839d | |
| parent | 1e4ee5135d814fe4785890790cec81c3132888fb (diff) | |
um: vdso: Remove getcpu support on x86
We are going to support SMP on UML/x86, so we can't hard code
the CPU and NUMA node in __vdso_getcpu() anymore. Let's just
remove it and let applications fall back to the syscall.
Suggested-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Tiwei Bie <tiwei.btw@antgroup.com>
Link: https://patch.msgid.link/20251027001815.1666872-7-tiwei.bie@linux.dev
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| -rw-r--r-- | arch/x86/um/vdso/um_vdso.c | 22 | ||||
| -rw-r--r-- | arch/x86/um/vdso/vdso.lds.S | 2 |
2 files changed, 0 insertions, 24 deletions
diff --git a/arch/x86/um/vdso/um_vdso.c b/arch/x86/um/vdso/um_vdso.c index 02d41fdb5655..ca1468865b14 100644 --- a/arch/x86/um/vdso/um_vdso.c +++ b/arch/x86/um/vdso/um_vdso.c @@ -11,12 +11,8 @@ #include <vdso/gettime.h> #include <linux/time.h> -#include <linux/getcpu.h> #include <asm/unistd.h> -/* workaround for -Wmissing-prototypes warnings */ -long __vdso_getcpu(unsigned int *cpu, unsigned int *node, struct getcpu_cache *unused); - int __vdso_clock_gettime(clockid_t clock, struct __kernel_timespec *ts) { long ret; @@ -56,21 +52,3 @@ __kernel_old_time_t __vdso_time(__kernel_old_time_t *t) return secs; } __kernel_old_time_t time(__kernel_old_time_t *t) __attribute__((weak, alias("__vdso_time"))); - -long -__vdso_getcpu(unsigned int *cpu, unsigned int *node, struct getcpu_cache *unused) -{ - /* - * UML does not support SMP, we can cheat here. :) - */ - - if (cpu) - *cpu = 0; - if (node) - *node = 0; - - return 0; -} - -long getcpu(unsigned int *cpu, unsigned int *node, struct getcpu_cache *tcache) - __attribute__((weak, alias("__vdso_getcpu"))); diff --git a/arch/x86/um/vdso/vdso.lds.S b/arch/x86/um/vdso/vdso.lds.S index 73c508587a98..401600effc0a 100644 --- a/arch/x86/um/vdso/vdso.lds.S +++ b/arch/x86/um/vdso/vdso.lds.S @@ -22,8 +22,6 @@ VERSION { __vdso_clock_gettime; gettimeofday; __vdso_gettimeofday; - getcpu; - __vdso_getcpu; time; __vdso_time; local: *; |
