]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
linux-user: cleanup epoll_pwait ifdeff'ery
authorMichael Tokarev <mjt@tls.msk.ru>
Fri, 9 Jan 2026 09:09:36 +0000 (12:09 +0300)
committerRichard Henderson <richard.henderson@linaro.org>
Sun, 11 Jan 2026 21:49:33 +0000 (08:49 +1100)
All linux targets these days have epoll_pwait system call
(while some miss epoll_wait, which is less generic).  And
all linux targets definitely has one or another epoll_*wait*
system call - so whole code block dealing with this system
call should always be present.

Remove the now-unneeded ifdef'fery.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20260109090937.599881-2-mjt@tls.msk.ru>

linux-user/syscall.c

index ee7c34027e0ffef0a898973b9bf345039f20b057..2c7e1eb5b29e37847566874e3360d6b736f1e1e5 100644 (file)
@@ -13619,13 +13619,10 @@ static abi_long do_syscall1(CPUArchState *cpu_env, int num, abi_long arg1,
     }
 #endif
 
-#if defined(TARGET_NR_epoll_wait) || defined(TARGET_NR_epoll_pwait)
 #if defined(TARGET_NR_epoll_wait)
     case TARGET_NR_epoll_wait:
 #endif
-#if defined(TARGET_NR_epoll_pwait)
     case TARGET_NR_epoll_pwait:
-#endif
     {
         struct target_epoll_event *target_ep;
         struct epoll_event *ep;
@@ -13650,7 +13647,6 @@ static abi_long do_syscall1(CPUArchState *cpu_env, int num, abi_long arg1,
         }
 
         switch (num) {
-#if defined(TARGET_NR_epoll_pwait)
         case TARGET_NR_epoll_pwait:
         {
             sigset_t *set = NULL;
@@ -13670,7 +13666,6 @@ static abi_long do_syscall1(CPUArchState *cpu_env, int num, abi_long arg1,
             }
             break;
         }
-#endif
 #if defined(TARGET_NR_epoll_wait)
         case TARGET_NR_epoll_wait:
             ret = get_errno(safe_epoll_pwait(epfd, ep, maxevents, timeout,
@@ -13694,8 +13689,7 @@ static abi_long do_syscall1(CPUArchState *cpu_env, int num, abi_long arg1,
         g_free(ep);
         return ret;
     }
-#endif
-#endif
+#endif /* CONFIG_EPOLL */
 #ifdef TARGET_NR_prlimit64
     case TARGET_NR_prlimit64:
     {