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

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'timers-vdso-2025-07-29' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull VDSO selftest updates from Thomas Gleixner:

- Skip the chacha test when the architecture does not provide the
random infrastructure in the VDSO

- Switch back to a symlink for vdso_standalone_test_x86 to avoid code
duplication.

- Improve code quality and TAP output compliance

* tag 'timers-vdso-2025-07-29' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
selftests: vDSO: vdso_standalone_test_x86: Replace source file with symlink
selftests: vDSO: vdso_test_getrandom: Always print TAP header
selftests: vDSO: vdso_test_correctness: Fix -Wstrict-prototypes
selftests: vDSO: Enable -Wall
selftests: vDSO: vdso_config: Avoid -Wunused-variables
selftests: vDSO: vdso_test_getrandom: Avoid -Wunused
selftests: vDSO: vdso_test_getrandom: Drop unused include of linux/compiler.h
selftests: vDSO: clock_getres: Drop unused include of err.h
selftests: vDSO: chacha: Correctly skip test if necessary

+12 -8
+1 -1
tools/testing/selftests/vDSO/Makefile
··· 12 12 TEST_GEN_PROGS += vdso_test_getrandom 13 13 TEST_GEN_PROGS += vdso_test_chacha 14 14 15 - CFLAGS := -std=gnu99 -O2 15 + CFLAGS := -std=gnu99 -O2 -Wall -Wstrict-prototypes 16 16 17 17 ifeq ($(CONFIG_X86_32),y) 18 18 LDLIBS += -lgcc_s
+2
tools/testing/selftests/vDSO/vdso_config.h
··· 58 58 #define VDSO_NAMES 1 59 59 #endif 60 60 61 + __attribute__((unused)) 61 62 static const char *versions[7] = { 62 63 "LINUX_2.6", 63 64 "LINUX_2.6.15", ··· 69 68 "LINUX_5.10" 70 69 }; 71 70 71 + __attribute__((unused)) 72 72 static const char *names[2][7] = { 73 73 { 74 74 "__kernel_gettimeofday",
+2 -1
tools/testing/selftests/vDSO/vdso_test_chacha.c
··· 76 76 77 77 void __weak __arch_chacha20_blocks_nostack(uint8_t *dst_bytes, const uint32_t *key, uint32_t *counter, size_t nblocks) 78 78 { 79 - ksft_exit_skip("Not implemented on architecture\n"); 79 + ksft_test_result_skip("Not implemented on architecture\n"); 80 + ksft_finished(); 80 81 } 81 82 82 83 int main(int argc, char *argv[])
-1
tools/testing/selftests/vDSO/vdso_test_clock_getres.c
··· 13 13 14 14 #define _GNU_SOURCE 15 15 #include <elf.h> 16 - #include <err.h> 17 16 #include <fcntl.h> 18 17 #include <stdint.h> 19 18 #include <stdio.h>
+1 -1
tools/testing/selftests/vDSO/vdso_test_correctness.c
··· 108 108 } 109 109 110 110 111 - static void fill_function_pointers() 111 + static void fill_function_pointers(void) 112 112 { 113 113 void *vdso = dlopen("linux-vdso.so.1", 114 114 RTLD_LAZY | RTLD_LOCAL | RTLD_NOLOAD);
+6 -4
tools/testing/selftests/vDSO/vdso_test_getrandom.c
··· 21 21 #include <sys/wait.h> 22 22 #include <sys/types.h> 23 23 #include <linux/random.h> 24 - #include <linux/compiler.h> 25 24 #include <linux/ptrace.h> 26 25 27 26 #include "../kselftest.h" ··· 100 101 return state; 101 102 } 102 103 104 + __attribute__((unused)) /* Example for libc implementors */ 103 105 static void vgetrandom_put_state(void *state) 104 106 { 105 107 if (!state) ··· 242 242 pid_t child; 243 243 244 244 ksft_print_header(); 245 + vgetrandom_init(); 245 246 ksft_set_plan(2); 246 247 247 248 for (size_t i = 0; i < 1000; ++i) { ··· 266 265 } 267 266 for (;;) { 268 267 struct ptrace_syscall_info info = { 0 }; 269 - int status, ret; 268 + int status; 270 269 ksft_assert(waitpid(child, &status, 0) >= 0); 271 270 if (WIFEXITED(status)) { 272 271 ksft_assert(WEXITSTATUS(status) == 0); ··· 296 295 297 296 int main(int argc, char *argv[]) 298 297 { 299 - vgetrandom_init(); 300 - 301 298 if (argc == 1) { 302 299 kselftest(); 303 300 return 0; ··· 305 306 usage(argv[0]); 306 307 return 1; 307 308 } 309 + 310 + vgetrandom_init(); 311 + 308 312 if (!strcmp(argv[1], "bench-single")) 309 313 bench_single(); 310 314 else if (!strcmp(argv[1], "bench-multi"))