From 0a2abc86c1be8f40700fbacf504c437b323b3ca0 Mon Sep 17 00:00:00 2001 From: Sergiu Moga Date: Fri, 7 Feb 2025 11:36:29 +0200 Subject: [PATCH] lib/posix-futex: Use kernel internal `uk_sys_gettid` Use the kernel internal variant of `gettid`, `uk_sys_gettid`. Unlike `uk_syscall_r_gettid`, this variant does not involve any syscall shim wrapper logic, but rather simply calls the system call's logic directly. Signed-off-by: Sergiu Moga Reviewed-by: Michalis Pappas Reviewed-by: Andrei Tatar Approved-by: Andrei Tatar GitHub-Closes: #1583 --- lib/posix-futex/futex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/posix-futex/futex.c b/lib/posix-futex/futex.c index f64b679e1..56b92465a 100644 --- a/lib/posix-futex/futex.c +++ b/lib/posix-futex/futex.c @@ -373,7 +373,7 @@ UK_POSIX_CLONE_HANDLER(CLONE_CHILD_CLEARTID, true, pfutex_child_cleartid, 0x0); */ UK_LLSYSCALL_R_DEFINE(pid_t, set_tid_address, pid_t *, tid_ref) { - pid_t self_tid = uk_syscall_r_gettid(); + pid_t self_tid = uk_sys_gettid(); if (self_tid >= 0) { /* Store new reference */ -- 2.39.5