]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
tools/nolibc: remove __nolibc_enosys() fallback from dup2()
authorThomas Weißschuh <linux@weissschuh.net>
Thu, 21 Aug 2025 15:40:34 +0000 (17:40 +0200)
committerThomas Weißschuh <linux@weissschuh.net>
Mon, 1 Sep 2025 18:47:53 +0000 (20:47 +0200)
All architectures have one of the real functions available.
The additional fallback to __nolibc_enosys() is superfluous.

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Acked-by: Willy Tarreau <w@1wt.eu>
Link: https://lore.kernel.org/r/20250821-nolibc-enosys-v1-3-4b63f2caaa89@weissschuh.net
tools/include/nolibc/sys.h

index 12030c80317375c5cd91e33273f023391cb92054..32cc741f2f7d70cb963b8686348db2da9b1f2932 100644 (file)
@@ -248,10 +248,8 @@ int sys_dup2(int old, int new)
        }
 
        return my_syscall3(__NR_dup3, old, new, 0);
-#elif defined(__NR_dup2)
-       return my_syscall2(__NR_dup2, old, new);
 #else
-       return __nolibc_enosys(__func__, old, new);
+       return my_syscall2(__NR_dup2, old, new);
 #endif
 }