| 4e6a2312 | 23-Dec-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Add test for clock_getres_time64()
Some architectures will start to implement this function. Make sure it works correctly.
Signed-off-by: Thomas Weißschuh <thomas.we
selftests: vDSO: vdso_test_abi: Add test for clock_getres_time64()
Some architectures will start to implement this function. Make sure it works correctly.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@kernel.org> Link: https://patch.msgid.link/20251223-vdso-compat-time32-v1-4-97ea7a06a543@linutronix.de
show more ...
|
| 1dcd1273 | 23-Dec-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Use UAPI system call numbers
SYS_clock_getres might have been redirected by libc to some other system call than the actual clock_getres. For testing it is required to
selftests: vDSO: vdso_test_abi: Use UAPI system call numbers
SYS_clock_getres might have been redirected by libc to some other system call than the actual clock_getres. For testing it is required to use exactly this system call.
Use the system call number exported by the UAPI headers which is always correct.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@kernel.org> Link: https://patch.msgid.link/20251223-vdso-compat-time32-v1-3-97ea7a06a543@linutronix.de
show more ...
|
| e82bf757 | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: Drop vdso_test_clock_getres
vdso_test_abi provides the exact same functionality, properly uses kselftest.h and explicitly calls into the vDSO without relying on the libc.
Drop the
selftests: vDSO: Drop vdso_test_clock_getres
vdso_test_abi provides the exact same functionality, properly uses kselftest.h and explicitly calls into the vDSO without relying on the libc.
Drop the pointless testcase.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-8-90f499dd35f8@linutronix.de
show more ...
|
| 7262aa78 | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Add tests for clock_gettime64()
To be y2038-safe, 32-bit userspace needs to explicitly call the 64-bit safe time APIs. For this the 32-bit vDSOs contains a clock_gett
selftests: vDSO: vdso_test_abi: Add tests for clock_gettime64()
To be y2038-safe, 32-bit userspace needs to explicitly call the 64-bit safe time APIs. For this the 32-bit vDSOs contains a clock_gettime() variant which always uses 64-bit time types.
Also test this vDSO function.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-7-90f499dd35f8@linutronix.de
show more ...
|
| 7b87dbf9 | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Test CPUTIME clocks
The structure is already there anyways, so test the CPUTIME clocks, too.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed
selftests: vDSO: vdso_test_abi: Test CPUTIME clocks
The structure is already there anyways, so test the CPUTIME clocks, too.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-6-90f499dd35f8@linutronix.de
show more ...
|
| 74b408ff | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Use explicit indices for name array
The array relies on the numeric values of the clock IDs. When reading the code it is not obvious that the order is correct.
Make
selftests: vDSO: vdso_test_abi: Use explicit indices for name array
The array relies on the numeric values of the clock IDs. When reading the code it is not obvious that the order is correct.
Make the code easier to read by using explicit indices.
While at it make the array static.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-5-90f499dd35f8@linutronix.de
show more ...
|
| d7516f25 | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Drop clock availability tests
The test uses the kselftest.h framework and declares in its testplan to always execute 16 testcases. If any of the clockids were not ava
selftests: vDSO: vdso_test_abi: Drop clock availability tests
The test uses the kselftest.h framework and declares in its testplan to always execute 16 testcases. If any of the clockids were not available, the testplan would not be satisfied anymore and the test would fail. Apparently that never happened, so the clockids are always available.
Remove the pointless checks.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-4-90f499dd35f8@linutronix.de
show more ...
|
| 3afe371d | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Use ksft_finished()
The existing logic is just an open-coded ksft_finished(). Replace it with the real thing.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linu
selftests: vDSO: vdso_test_abi: Use ksft_finished()
The existing logic is just an open-coded ksft_finished(). Replace it with the real thing.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-3-90f499dd35f8@linutronix.de
show more ...
|
| 4b59a9f7 | 12-Aug-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_abi: Correctly skip whole test with missing vDSO
If AT_SYSINFO_EHDR is missing the whole test needs to be skipped. Currently this results in the following output:
TAP ve
selftests: vDSO: vdso_test_abi: Correctly skip whole test with missing vDSO
If AT_SYSINFO_EHDR is missing the whole test needs to be skipped. Currently this results in the following output:
TAP version 13 1..16 # AT_SYSINFO_EHDR is not present!
This output is incorrect, as "1..16" still requires the subtest lines to be printed, which isn't done however.
Switch to the correct skipping functions, so the output now correctly indicates that no subtests are being run:
TAP version 13 1..0 # SKIP AT_SYSINFO_EHDR is not present!
Fixes: 693f5ca08ca0 ("kselftest: Extend vDSO selftest") Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250812-vdso-tests-fixes-v2-2-90f499dd35f8@linutronix.de
show more ...
|
| 43707960 | 11-Jun-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_standalone_test_x86: Replace source file with symlink
With the switch over to nolibc the source file vdso_standalone_test_x86.c was intended to be replaced with a symlink to vd
selftests: vDSO: vdso_standalone_test_x86: Replace source file with symlink
With the switch over to nolibc the source file vdso_standalone_test_x86.c was intended to be replaced with a symlink to vdso_test_gettimeofday.c. This was the patch that was submitted to LKML, but during application the symlink was replaced by a textual copy of the linked-to file.
Having two copies introduces the possibility of divergence and increases maintenance burden, switch back to a symlink.
Fixes: 8770a9183fe1 ("selftests: vDSO: vdso_standalone_test_x86: Switch to nolibc") Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/lkml/20250226-parse_vdso-nolibc-v2-16-28e14e031ed8@linutronix.de/ Link: https://lore.kernel.org/all/20250611-selftests-vdso-fixes-v3-9-e62e37a6bcf5@linutronix.de
show more ...
|
| 1158220b | 11-Jun-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_getrandom: Always print TAP header
The TAP specification requires that the output begins with a header line. If vgetrandom_init() fails and skips the test, that header lin
selftests: vDSO: vdso_test_getrandom: Always print TAP header
The TAP specification requires that the output begins with a header line. If vgetrandom_init() fails and skips the test, that header line is missing.
Call vgetrandom_init() after ksft_print_header().
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Muhammad Usama Anjum <usama.anjum@collabora.com> Link: https://lore.kernel.org/all/20250611-selftests-vdso-fixes-v3-8-e62e37a6bcf5@linutronix.de
show more ...
|
| 58265d64 | 11-Jun-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_correctness: Fix -Wstrict-prototypes
Functions definitions without any argument list produce a warning with -Wstrict-prototypes:
vdso_test_correctness.c:111:13: warning:
selftests: vDSO: vdso_test_correctness: Fix -Wstrict-prototypes
Functions definitions without any argument list produce a warning with -Wstrict-prototypes:
vdso_test_correctness.c:111:13: warning: function declaration isn’t a prototype [-Wstrict-prototypes] 111 | static void fill_function_pointers() | ^~~~~~~~~~~~~~~~~~~~~~
Explicitly use an empty argument list.
Now that all selftests a free of this warning, enable it in the Makefile.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250611-selftests-vdso-fixes-v3-7-e62e37a6bcf5@linutronix.de
show more ...
|
| 8863cd78 | 11-Jun-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: Enable -Wall
Protect against common programming errors through compiler warnings. These warnings are also used for the kernel itself.
Signed-off-by: Thomas Weißschuh <thomas.weisss
selftests: vDSO: Enable -Wall
Protect against common programming errors through compiler warnings. These warnings are also used for the kernel itself.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250611-selftests-vdso-fixes-v3-6-e62e37a6bcf5@linutronix.de
show more ...
|
| ecabe99a | 11-Jun-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_config: Avoid -Wunused-variables
Not all users of this header make use of all its variables. For example vdso_test_correctness.c does not use "versions":
In file included from
selftests: vDSO: vdso_config: Avoid -Wunused-variables
Not all users of this header make use of all its variables. For example vdso_test_correctness.c does not use "versions":
In file included from vdso_test_correctness.c:22: vdso_config.h:61:20: warning: ‘versions’ defined but not used [-Wunused-variable] 61 | static const char *versions[7] = { | ^~~~~~~~
Avoid those warnings through attribute((unused)).
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Muhammad Usama Anjum <usama.anjum@collabora.com> Link: https://lore.kernel.org/all/20250611-selftests-vdso-fixes-v3-5-e62e37a6bcf5@linutronix.de
show more ...
|
| b8ae4308 | 11-Jun-2025 |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> |
selftests: vDSO: vdso_test_getrandom: Avoid -Wunused
vgetrandom_put_state() and the variable "ret" in kselftest() are unused.
Drop the variable "ret". Suppress the warning for vgetrandom_put_state
selftests: vDSO: vdso_test_getrandom: Avoid -Wunused
vgetrandom_put_state() and the variable "ret" in kselftest() are unused.
Drop the variable "ret". Suppress the warning for vgetrandom_put_state() as it is meant as an example for libc implementors.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250611-selftests-vdso-fixes-v3-4-e62e37a6bcf5@linutronix.de
show more ...
|