aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/bpf/prog_tests/test_task_local_data.c
diff options
context:
space:
mode:
authorAlan Maguire <alan.maguire@oracle.com>2025-09-11 17:30:56 +0100
committerDaniel Borkmann <daniel@iogearbox.net>2025-09-15 20:39:24 +0200
commit3ae4c527080ce81b889ffc2780e077770b95ae88 (patch)
treea3e122290086991e91cb42d8b945b71d8adae82f /tools/testing/selftests/bpf/prog_tests/test_task_local_data.c
parentMerge branch 'remove-use-of-current-cgns-in-bpf_cgroup_from_id' (diff)
downloadlinux-3ae4c527080ce81b889ffc2780e077770b95ae88.tar.gz
linux-3ae4c527080ce81b889ffc2780e077770b95ae88.zip
selftests/bpf: More open-coded gettid syscall cleanup
Commit 0e2fb011a0ba ("selftests/bpf: Clean up open-coded gettid syscall invocations") addressed the issue that older libc may not have a gettid() function call wrapper for the associated syscall. A few more instances have crept into tests, use sys_gettid() instead, and poison raw gettid() usage to avoid future issues. Signed-off-by: Alan Maguire <alan.maguire@oracle.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Link: https://lore.kernel.org/bpf/20250911163056.543071-1-alan.maguire@oracle.com
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/test_task_local_data.c')
-rw-r--r--tools/testing/selftests/bpf/prog_tests/test_task_local_data.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/bpf/prog_tests/test_task_local_data.c b/tools/testing/selftests/bpf/prog_tests/test_task_local_data.c
index 3b5cd2cd89c7..9fd6306b455c 100644
--- a/tools/testing/selftests/bpf/prog_tests/test_task_local_data.c
+++ b/tools/testing/selftests/bpf/prog_tests/test_task_local_data.c
@@ -63,7 +63,7 @@ void *test_task_local_data_basic_thread(void *arg)
if (!ASSERT_OK_PTR(value2, "tld_get_data"))
goto out;
- tid = gettid();
+ tid = sys_gettid();
*value0 = tid + 0;
*value1 = tid + 1;