]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
tool build: Remove __get_cpuid feature test
authorIan Rogers <irogers@google.com>
Mon, 10 Nov 2025 01:31:50 +0000 (17:31 -0800)
committerNamhyung Kim <namhyung@kernel.org>
Fri, 14 Nov 2025 07:03:11 +0000 (23:03 -0800)
This feature test is no longer used so remove.

The function tested by the feature test is used in:
tools/power/x86/x86_energy_perf_policy/x86_energy_perf_policy.c
however, the Makefile just assumes the presence of the function and
doesn't perform a build feature test for it.

Signed-off-by: Ian Rogers <irogers@google.com>
Reviewed-by: James Clark <james.clark@linaro.org>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
tools/build/Makefile.feature
tools/build/feature/Makefile
tools/build/feature/test-all.c
tools/build/feature/test-get_cpuid.c [deleted file]

index 32bbe29fe5f6c5b385b661c36fc299ebb2fac6bb..fc6abe369f7373c5de34568606acd283d444fa24 100644 (file)
@@ -90,7 +90,6 @@ FEATURE_TESTS_BASIC :=                  \
         timerfd                         \
         zlib                            \
         lzma                            \
-        get_cpuid                       \
         bpf                             \
         scandirat                      \
         sched_getcpu                   \
@@ -146,7 +145,6 @@ FEATURE_DISPLAY ?=              \
          llvm-perf              \
          zlib                   \
          lzma                   \
-         get_cpuid              \
          bpf                   \
          libaio                        \
          libzstd
index 49b0add392b1c11aa35ece992457463c405eaff8..7c90e0d0157ac9b122a269fac89b618559c1c52c 100644 (file)
@@ -56,7 +56,6 @@ FILES=                                          \
          test-lzma.bin                          \
          test-bpf.bin                           \
          test-libbpf.bin                        \
-         test-get_cpuid.bin                     \
          test-sdt.bin                           \
          test-cxx.bin                           \
          test-gettid.bin                       \
@@ -318,9 +317,6 @@ $(OUTPUT)test-zlib.bin:
 $(OUTPUT)test-lzma.bin:
        $(BUILD) -llzma
 
-$(OUTPUT)test-get_cpuid.bin:
-       $(BUILD)
-
 $(OUTPUT)test-bpf.bin:
        $(BUILD)
 
index 8a354b81417c6fcc357ef01952f8043579dec442..eb346160d0ba0e2f3b3928a505b4be95ab4b95f4 100644 (file)
 # include "test-lzma.c"
 #undef main
 
-#define main main_test_get_cpuid
-# include "test-get_cpuid.c"
-#undef main
-
 #define main main_test_bpf
 # include "test-bpf.c"
 #undef main
@@ -168,7 +164,6 @@ int main(int argc, char *argv[])
        main_test_pthread_attr_setaffinity_np();
        main_test_pthread_barrier();
        main_test_lzma();
-       main_test_get_cpuid();
        main_test_bpf();
        main_test_scandirat();
        main_test_sched_getcpu();
diff --git a/tools/build/feature/test-get_cpuid.c b/tools/build/feature/test-get_cpuid.c
deleted file mode 100644 (file)
index bb4f065..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0
-#include <cpuid.h>
-
-int main(void)
-{
-       unsigned int eax = 0, ebx = 0, ecx = 0, edx = 0;
-       return __get_cpuid(0x15, &eax, &ebx, &ecx, &edx);
-}