From patchwork Wed Nov 18 19:55:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adhemerval Zanella Netto X-Patchwork-Id: 41108 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id B4E7239450C6; Wed, 18 Nov 2020 19:56:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B4E7239450C6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1605729379; bh=NqF5zkr2jAIFT7eJm+JrrA/0sdIP1bj4FBrtyIrs99Q=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=HaO3eQ/tVXMFjoAAiQUQuj2MUn5HtlW3Gd8z9QeKrFRL3J548P1TTgGdoULs6gnmM deUcLcCePmaq5+xvps08qj0RmUt3LYTEeWQSN6z916fU7KVeZVLnu5rQuG//4thQqs ohhn4AqBoxOw5YwE9OJL8z+4U8a5c8HFDjyuQx2s= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-qt1-x842.google.com (mail-qt1-x842.google.com [IPv6:2607:f8b0:4864:20::842]) by sourceware.org (Postfix) with ESMTPS id D60813944430 for ; Wed, 18 Nov 2020 19:56:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org D60813944430 Received: by mail-qt1-x842.google.com with SMTP id f93so2560774qtb.10 for ; Wed, 18 Nov 2020 11:56:08 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=NqF5zkr2jAIFT7eJm+JrrA/0sdIP1bj4FBrtyIrs99Q=; b=gh7ZWCUGCcXGGvyWPsFGIEcJDgZLbrY0XiiJoMNFp0Q1JiTEsp4EGsRxAkyB8XB1LD AyYXI0ny14ALd0s5na4PdZVwFZ+oQKTYS4elYpMcsB9z8Rt0EZ/Ym5jVlPLme9s3Yp9L ds1lN67iYI7E9wgpT6+C42A+hZeOynTftmgKlRJa3X6UQ9iqjaEYKBBNAvdlOAHt+XcH Tq772n1uC1VArtkICSxxLHX8kPmFuBDN0jNAkjqtFSAotJSPQysrGMHRsh31INvCtPJr E4Y1hj0cJjwbIJeKoL3OfhgVyuyyrLfWZETi+TzGdZxcxN89cnekR1WcguK5HKcMqChB O+yg== X-Gm-Message-State: AOAM530MhL6CNyma7OGbnK3j44vAa2bNpX3r11VFiuIQzJ6qnsTCAdA+ Vw9MTtyHbOjeAzlIP0//L9/aIUjS3ki+6Q== X-Google-Smtp-Source: ABdhPJxZPKZXk0F6ETJoikLYOnU5MWz+LfL1Dnk4GWjbgHzfx5KznLnFYQfG1owaoo2o2N4dF7Qyew== X-Received: by 2002:ac8:4884:: with SMTP id i4mr6127784qtq.300.1605729368157; Wed, 18 Nov 2020 11:56:08 -0800 (PST) Received: from localhost.localdomain ([177.194.48.209]) by smtp.googlemail.com with ESMTPSA id f27sm6538775qtv.95.2020.11.18.11.56.07 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Nov 2020 11:56:07 -0800 (PST) To: libc-alpha@sourceware.org Subject: [PATCH 07/28] linux: Assume bind support Date: Wed, 18 Nov 2020 16:55:31 -0300 Message-Id: <20201118195552.2687336-8-adhemerval.zanella@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201118195552.2687336-1-adhemerval.zanella@linaro.org> References: <20201118195552.2687336-1-adhemerval.zanella@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-13.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Adhemerval Zanella via Libc-alpha From: Adhemerval Zanella Netto Reply-To: Adhemerval Zanella Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" Checked with build for the affected ABI. --- sysdeps/unix/sysv/linux/alpha/syscalls.list | 1 - sysdeps/unix/sysv/linux/arm/syscalls.list | 1 - sysdeps/unix/sysv/linux/generic/syscalls.list | 1 - sysdeps/unix/sysv/linux/hppa/syscalls.list | 1 - sysdeps/unix/sysv/linux/i386/kernel-features.h | 2 +- sysdeps/unix/sysv/linux/ia64/syscalls.list | 1 - sysdeps/unix/sysv/linux/kernel-features.h | 1 + sysdeps/unix/sysv/linux/m68k/kernel-features.h | 2 +- sysdeps/unix/sysv/linux/microblaze/kernel-features.h | 1 - sysdeps/unix/sysv/linux/mips/syscalls.list | 1 - sysdeps/unix/sysv/linux/powerpc/kernel-features.h | 1 - sysdeps/unix/sysv/linux/s390/kernel-features.h | 2 +- sysdeps/unix/sysv/linux/sh/kernel-features.h | 1 - sysdeps/unix/sysv/linux/sparc/kernel-features.h | 5 ++++- sysdeps/unix/sysv/linux/x86_64/syscalls.list | 1 - 15 files changed, 8 insertions(+), 14 deletions(-) diff --git a/sysdeps/unix/sysv/linux/alpha/syscalls.list b/sysdeps/unix/sysv/linux/alpha/syscalls.list index c7cbe886ea..a4e432c50c 100644 --- a/sysdeps/unix/sysv/linux/alpha/syscalls.list +++ b/sysdeps/unix/sysv/linux/alpha/syscalls.list @@ -5,7 +5,6 @@ sigstack - sigstack 2 sigstack getpriority - getpriority i:ii __getpriority getpriority # proper socket implementations: -bind - bind i:ipi __bind bind getpeername - getpeername i:ipp __getpeername getpeername getsockname - getsockname i:ipp __getsockname getsockname getsockopt - getsockopt i:iiiBN __getsockopt getsockopt diff --git a/sysdeps/unix/sysv/linux/arm/syscalls.list b/sysdeps/unix/sysv/linux/arm/syscalls.list index b19f26a2dd..5982889636 100644 --- a/sysdeps/unix/sysv/linux/arm/syscalls.list +++ b/sysdeps/unix/sysv/linux/arm/syscalls.list @@ -20,7 +20,6 @@ prlimit64 EXTRA prlimit64 i:iipp prlimit64 fanotify_mark EXTRA fanotify_mark i:iiiiis fanotify_mark # proper socket implementations: -bind - bind i:ipi __bind bind getpeername - getpeername i:ipp __getpeername getpeername getsockname - getsockname i:ipp __getsockname getsockname getsockopt - getsockopt i:iiiBN __getsockopt getsockopt diff --git a/sysdeps/unix/sysv/linux/generic/syscalls.list b/sysdeps/unix/sysv/linux/generic/syscalls.list index ed8b216d47..98984cf59d 100644 --- a/sysdeps/unix/sysv/linux/generic/syscalls.list +++ b/sysdeps/unix/sysv/linux/generic/syscalls.list @@ -3,7 +3,6 @@ # Socket APIs socket - socket i:iii __socket socket socketpair - socketpair i:iiif __socketpair socketpair -bind - bind i:ipi __bind bind listen - listen i:ii __listen listen getsockname - getsockname i:ipp __getsockname getsockname getpeername - getpeername i:ipp __getpeername getpeername diff --git a/sysdeps/unix/sysv/linux/hppa/syscalls.list b/sysdeps/unix/sysv/linux/hppa/syscalls.list index 2a776aae27..0f54c50eba 100644 --- a/sysdeps/unix/sysv/linux/hppa/syscalls.list +++ b/sysdeps/unix/sysv/linux/hppa/syscalls.list @@ -1,7 +1,6 @@ # File name Caller Syscall name # args Strong name Weak names # proper socket implementations: -bind - bind i:ipi __bind bind getpeername - getpeername i:ipp __getpeername getpeername getsockname - getsockname i:ipp __getsockname getsockname getsockopt - getsockopt i:iiiBN __getsockopt getsockopt diff --git a/sysdeps/unix/sysv/linux/i386/kernel-features.h b/sysdeps/unix/sysv/linux/i386/kernel-features.h index 64202a1e84..46c5334385 100644 --- a/sysdeps/unix/sysv/linux/i386/kernel-features.h +++ b/sysdeps/unix/sysv/linux/i386/kernel-features.h @@ -21,7 +21,6 @@ #if __LINUX_KERNEL_VERSION >= 0x040300 # define __ASSUME_SOCKET_SYSCALL 1 # define __ASSUME_SOCKETPAIR_SYSCALL 1 -# define __ASSUME_BIND_SYSCALL 1 # define __ASSUME_LISTEN_SYSCALL 1 # define __ASSUME_GETSOCKOPT_SYSCALL 1 # define __ASSUME_SETSOCKOPT_SYSCALL 1 @@ -35,6 +34,7 @@ #undef __ASSUME_ACCEPT_SYSCALL #if __LINUX_KERNEL_VERSION < 0x040300 +# undef __ASSUME_BIND_SYSCALL # undef __ASSUME_ACCEPT4_SYSCALL # undef __ASSUME_SENDMSG_SYSCALL # undef __ASSUME_RECVMSG_SYSCALL diff --git a/sysdeps/unix/sysv/linux/ia64/syscalls.list b/sysdeps/unix/sysv/linux/ia64/syscalls.list index bd39441d3c..5a77f18ada 100644 --- a/sysdeps/unix/sysv/linux/ia64/syscalls.list +++ b/sysdeps/unix/sysv/linux/ia64/syscalls.list @@ -3,7 +3,6 @@ getpriority - getpriority i:ii __getpriority getpriority # proper socket implementations: -bind - bind i:ipi __bind bind getpeername - getpeername i:ipp __getpeername getpeername getsockname - getsockname i:ipp __getsockname getsockname getsockopt - getsockopt i:iiiBN __getsockopt getsockopt diff --git a/sysdeps/unix/sysv/linux/kernel-features.h b/sysdeps/unix/sysv/linux/kernel-features.h index e648eecc0d..71a2631fc0 100644 --- a/sysdeps/unix/sysv/linux/kernel-features.h +++ b/sysdeps/unix/sysv/linux/kernel-features.h @@ -68,6 +68,7 @@ /* On most architectures, most socket syscalls are supported for all supported kernel versions, but on some socketcall architectures separate syscalls were only added later. */ +#define __ASSUME_BIND_SYSCALL 1 #define __ASSUME_SENDMSG_SYSCALL 1 #define __ASSUME_RECVMSG_SYSCALL 1 #define __ASSUME_ACCEPT_SYSCALL 1 diff --git a/sysdeps/unix/sysv/linux/m68k/kernel-features.h b/sysdeps/unix/sysv/linux/m68k/kernel-features.h index 4cdaf93e6d..06457d3761 100644 --- a/sysdeps/unix/sysv/linux/m68k/kernel-features.h +++ b/sysdeps/unix/sysv/linux/m68k/kernel-features.h @@ -21,7 +21,6 @@ #if __LINUX_KERNEL_VERSION >= 0x040300 # define __ASSUME_SOCKET_SYSCALL 1 # define __ASSUME_SOCKETPAIR_SYSCALL 1 -# define __ASSUME_BIND_SYSCALL 1 # define __ASSUME_LISTEN_SYSCALL 1 # define __ASSUME_GETSOCKOPT_SYSCALL 1 # define __ASSUME_SETSOCKOPT_SYSCALL 1 @@ -35,6 +34,7 @@ #undef __ASSUME_ACCEPT_SYSCALL #if __LINUX_KERNEL_VERSION < 0x040300 +# undef __ASSUME_BIND_SYSCALL # undef __ASSUME_ACCEPT4_SYSCALL # undef __ASSUME_RECVMMSG_SYSCALL # undef __ASSUME_SENDMMSG_SYSCALL diff --git a/sysdeps/unix/sysv/linux/microblaze/kernel-features.h b/sysdeps/unix/sysv/linux/microblaze/kernel-features.h index def8408014..2facec8c4c 100644 --- a/sysdeps/unix/sysv/linux/microblaze/kernel-features.h +++ b/sysdeps/unix/sysv/linux/microblaze/kernel-features.h @@ -19,7 +19,6 @@ /* All supported kernel versions for MicroBlaze have these syscalls. */ #define __ASSUME_SOCKET_SYSCALL 1 -#define __ASSUME_BIND_SYSCALL 1 #define __ASSUME_CONNECT_SYSCALL 1 #define __ASSUME_LISTEN_SYSCALL 1 #define __ASSUME_GETSOCKNAME_SYSCALL 1 diff --git a/sysdeps/unix/sysv/linux/mips/syscalls.list b/sysdeps/unix/sysv/linux/mips/syscalls.list index f3621cdd51..0415d40ee8 100644 --- a/sysdeps/unix/sysv/linux/mips/syscalls.list +++ b/sysdeps/unix/sysv/linux/mips/syscalls.list @@ -12,7 +12,6 @@ sysmips - sysmips i:iiii __sysmips sysmips # Socket functions; Linux/MIPS doesn't use the socketcall(2) wrapper; # it's provided for compatibility, though. # -bind - bind i:ipi __bind bind getpeername - getpeername i:ipp __getpeername getpeername getsockname - getsockname i:ipp __getsockname getsockname getsockopt - getsockopt i:iiiBN __getsockopt getsockopt diff --git a/sysdeps/unix/sysv/linux/powerpc/kernel-features.h b/sysdeps/unix/sysv/linux/powerpc/kernel-features.h index a18a2ee97f..c7079a4507 100644 --- a/sysdeps/unix/sysv/linux/powerpc/kernel-features.h +++ b/sysdeps/unix/sysv/linux/powerpc/kernel-features.h @@ -19,7 +19,6 @@ /* New syscalls added for PowerPC in 2.6.37. */ #define __ASSUME_SOCKET_SYSCALL 1 -#define __ASSUME_BIND_SYSCALL 1 #define __ASSUME_CONNECT_SYSCALL 1 #define __ASSUME_LISTEN_SYSCALL 1 #define __ASSUME_GETSOCKNAME_SYSCALL 1 diff --git a/sysdeps/unix/sysv/linux/s390/kernel-features.h b/sysdeps/unix/sysv/linux/s390/kernel-features.h index 831d0ab7d5..549ecc994d 100644 --- a/sysdeps/unix/sysv/linux/s390/kernel-features.h +++ b/sysdeps/unix/sysv/linux/s390/kernel-features.h @@ -21,7 +21,6 @@ #if __LINUX_KERNEL_VERSION >= 0x040300 # define __ASSUME_SOCKET_SYSCALL 1 # define __ASSUME_SOCKETPAIR_SYSCALL 1 -# define __ASSUME_BIND_SYSCALL 1 # define __ASSUME_LISTEN_SYSCALL 1 # define __ASSUME_GETSOCKOPT_SYSCALL 1 # define __ASSUME_SETSOCKOPT_SYSCALL 1 @@ -35,6 +34,7 @@ #undef __ASSUME_ACCEPT_SYSCALL #if __LINUX_KERNEL_VERSION < 0x040300 +# undef __ASSUME_BIND_SYSCALL # undef __ASSUME_ACCEPT4_SYSCALL # undef __ASSUME_RECVMMSG_SYSCALL # undef __ASSUME_SENDMMSG_SYSCALL diff --git a/sysdeps/unix/sysv/linux/sh/kernel-features.h b/sysdeps/unix/sysv/linux/sh/kernel-features.h index 5bac608a11..04ecd02ecd 100644 --- a/sysdeps/unix/sysv/linux/sh/kernel-features.h +++ b/sysdeps/unix/sysv/linux/sh/kernel-features.h @@ -24,7 +24,6 @@ /* These syscalls were added for SH in 2.6.37. */ #define __ASSUME_SOCKET_SYSCALL 1 -#define __ASSUME_BIND_SYSCALL 1 #define __ASSUME_CONNECT_SYSCALL 1 #define __ASSUME_LISTEN_SYSCALL 1 #define __ASSUME_GETSOCKNAME_SYSCALL 1 diff --git a/sysdeps/unix/sysv/linux/sparc/kernel-features.h b/sysdeps/unix/sysv/linux/sparc/kernel-features.h index ea642120e9..8f7348d9ad 100644 --- a/sysdeps/unix/sysv/linux/sparc/kernel-features.h +++ b/sysdeps/unix/sysv/linux/sparc/kernel-features.h @@ -45,9 +45,12 @@ # define __ASSUME_SHUTDOWN_SYSCALL 1 #endif +#if __LINUX_KERNEL_VERSION < 0x040400 +# undef __ASSUME_BIND_SYSCALL +#endif + /* These syscalls were added for both 32-bit and 64-bit in 4.4. */ #if __LINUX_KERNEL_VERSION >= 0x040400 -# define __ASSUME_BIND_SYSCALL 1 # define __ASSUME_LISTEN_SYSCALL 1 # define __ASSUME_SETSOCKOPT_SYSCALL 1 #endif diff --git a/sysdeps/unix/sysv/linux/x86_64/syscalls.list b/sysdeps/unix/sysv/linux/x86_64/syscalls.list index d46524eff3..a6a725e198 100644 --- a/sysdeps/unix/sysv/linux/x86_64/syscalls.list +++ b/sysdeps/unix/sysv/linux/x86_64/syscalls.list @@ -6,7 +6,6 @@ syscall_clock_gettime EXTRA clock_gettime Ei:ip __syscall_clock_gettime # proper socket implementations: -bind - bind i:ipi __bind bind getpeername - getpeername i:ipp __getpeername getpeername getsockname - getsockname i:ipp __getsockname getsockname getsockopt - getsockopt i:iiiBN __getsockopt getsockopt