diff mbox series

[47/66] bsd-user: In do_freebsd_thr_new, use unlock_user_struct

Message ID 20260515-misc-2026q2-v1-47-5438ca41b27a@bsdimp.com
State New
Headers show
Series bsd-user: Upstream most of the remaining system calls | expand

Commit Message

Warner Losh May 15, 2026, 9:19 p.m. UTC
Since these were locked with lock_user_struct, unlock them with
unlock_user_struct.

Signed-off-by: Warner Losh <imp@bsdimp.com>
---
 bsd-user/freebsd/os-thread.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/bsd-user/freebsd/os-thread.c b/bsd-user/freebsd/os-thread.c
index 7c3256a87e..f90f13076f 100644
--- a/bsd-user/freebsd/os-thread.c
+++ b/bsd-user/freebsd/os-thread.c
@@ -1567,7 +1567,7 @@  abi_long do_freebsd_thr_new(CPUArchState *env,
     info.param.parent_tid = tswapal(target_param->parent_tid);
     info.param.flags = tswap32(target_param->flags);
     target_rtp_addr = info.param.rtp = tswapal(target_param->rtp);
-    unlock_user(target_param, target_param_addr, 0);
+    unlock_user_struct(target_param, target_param_addr, 0);
 
     thr_self(&info.parent_tid);
 
@@ -1577,7 +1577,7 @@  abi_long do_freebsd_thr_new(CPUArchState *env,
         }
         rtp.type = tswap16(target_rtp->type);
         rtp.prio = tswap16(target_rtp->prio);
-        unlock_user(target_rtp, target_rtp_addr, 0);
+        unlock_user_struct(target_rtp, target_rtp_addr, 0);
         rtp_ptr = &rtp;
     } else {
         rtp_ptr = NULL;