On 1/11/26 10:20, Richard Henderson wrote:
@@ -13644,6 +13655,7 @@ static abi_long do_syscall1(CPUArchState *cpu_env, int num, abi_long arg1,
          switch (num) {
          case TARGET_NR_epoll_pwait:
+        case TARGET_NR_epoll_pwait2:
          {
              sigset_t *set = NULL;
@@ -13654,8 +13666,13 @@ static abi_long do_syscall1(CPUArchState *cpu_env, int num, abi_long arg1,
                  }
              }
-            ret = get_errno(safe_epoll_pwait(epfd, ep, maxevents, timeout,
-                                             set, SIGSET_T_SIZE));
+            if (num == TARGET_NR_epoll_pwait) {
+                ret = get_errno(safe_epoll_pwait(epfd, ep, maxevents, arg4,
+                                                 set, SIGSET_T_SIZE));
+            } else {
+                ret = get_errno(safe_epoll_pwait2(epfd, ep, maxevents, 
timeout_ts,
+                                                  set, SIGSET_T_SIZE));
+            }

This second test needs to be vs pwait2, lest you break epoll_wait.

Bah, seconds later I noticed the switch in the context.

r~

Reply via email to