From patchwork Thu May 9 23:00:37 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 1097732 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-101914-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="BmtF5yU3"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 450TN30C65z9s00 for ; Fri, 10 May 2019 09:00:50 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:mime-version :content-type; q=dns; s=default; b=gqkMdpIW+SEfuv2t5u6NP+Ekau7Ex 4tXW+ExOWgfWP+g2UeX2Sn/QD2i1E9MNMU6+yeNhXRkdDoMC4utxQizYpJQGAphR cbOeqVIL9kXNOIHxcEY5O+j9XadCBc8T5P0jQmmNn825UNSrfW1a+XeUG1YZGFxJ IfgKFi9jS5VAQU= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:mime-version :content-type; s=default; bh=M/2l0MAq5+TFGiT29ngm+nU1uCo=; b=Bmt F5yU3Md8z+XJ879CEGn8jWiz/FbWD4a17orFpVYOglW7FDbTYGOp5f09gqqAJtlE ekB2A0JuzMmX28jfHTVoJ1WvFS6KHYEd3yWiP2uamK8NpIcq/xSK8V9UwEXontZi pEEdKqAoaXkT3fDi1ia7WooBtJrYNyAUEdgqi8kA= Received: (qmail 126191 invoked by alias); 9 May 2019 23:00:45 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 126176 invoked by uid 89); 9 May 2019 23:00:45 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-14.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.1 spammy=mips32 X-HELO: relay1.mentorg.com Date: Thu, 9 May 2019 23:00:37 +0000 From: Joseph Myers To: Subject: Update kernel-features.h files for Linux 5.1 Message-ID: User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Linux 5.1 adds missing syscalls to the syscall table for many Linux kernel architectures. This patch updates the kernel-features.h headers accordingly. I believe the statfs64 structure used by alpha matches what the new kernel syscalls use, but that should be reviewed carefully. Tested with build-many-glibcs.py. 2019-05-09 Joseph Myers * sysdeps/unix/sysv/linux/alpha/kernel-features.h (__ASSUME_STATFS64): Only undefine if [__LINUX_KERNEL_VERSION < 0x050100]. * sysdeps/unix/sysv/linux/i386/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. * sysdeps/unix/sysv/linux/ia64/kernel-features.h (__ASSUME_STATX): Likewise. * sysdeps/unix/sysv/linux/m68k/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. * sysdeps/unix/sysv/linux/mips/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. * sysdeps/unix/sysv/linux/powerpc/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. * sysdeps/unix/sysv/linux/s390/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. * sysdeps/unix/sysv/linux/sh/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. (__ASSUME_STATX): Likewise. * sysdeps/unix/sysv/linux/sparc/kernel-features.h (__ASSUME_DIRECT_SYSVIPC_SYSCALLS): Likewise. Reviewed-by: Adhemerval Zanella diff --git a/sysdeps/unix/sysv/linux/alpha/kernel-features.h b/sysdeps/unix/sysv/linux/alpha/kernel-features.h index f3298b234e..4a5d029c1d 100644 --- a/sysdeps/unix/sysv/linux/alpha/kernel-features.h +++ b/sysdeps/unix/sysv/linux/alpha/kernel-features.h @@ -22,9 +22,11 @@ #include_next -/* There never has been support for fstat64. */ -#undef __ASSUME_STATFS64 -#define __ASSUME_STATFS64 0 +/* Support for statfs64 was added in 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_STATFS64 +# define __ASSUME_STATFS64 0 +#endif /* Alpha used to define SysV ipc shmat syscall with a different name. */ #ifndef __NR_shmat diff --git a/sysdeps/unix/sysv/linux/i386/kernel-features.h b/sysdeps/unix/sysv/linux/i386/kernel-features.h index 3ac725b5a2..8610651346 100644 --- a/sysdeps/unix/sysv/linux/i386/kernel-features.h +++ b/sysdeps/unix/sysv/linux/i386/kernel-features.h @@ -43,8 +43,10 @@ # undef __ASSUME_SENDTO_SYSCALL #endif -/* i686 only supports ipc syscall. */ -#undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* i686 only supports ipc syscall before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +#endif #undef __ASSUME_CLONE_DEFAULT #define __ASSUME_CLONE_BACKWARDS 1 diff --git a/sysdeps/unix/sysv/linux/ia64/kernel-features.h b/sysdeps/unix/sysv/linux/ia64/kernel-features.h index 0f4948b8e0..333947931d 100644 --- a/sysdeps/unix/sysv/linux/ia64/kernel-features.h +++ b/sysdeps/unix/sysv/linux/ia64/kernel-features.h @@ -26,8 +26,10 @@ #define __ASSUME_SEND_SYSCALL 1 #define __ASSUME_ACCEPT4_SYSCALL 1 -/* No statx system call on ia64 yet. */ -#undef __ASSUME_STATX +/* Support for statx was added in 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_STATX +#endif #undef __ASSUME_CLONE_DEFAULT #define __ASSUME_CLONE2 diff --git a/sysdeps/unix/sysv/linux/m68k/kernel-features.h b/sysdeps/unix/sysv/linux/m68k/kernel-features.h index 1976724362..1467474b8a 100644 --- a/sysdeps/unix/sysv/linux/m68k/kernel-features.h +++ b/sysdeps/unix/sysv/linux/m68k/kernel-features.h @@ -50,5 +50,7 @@ # undef __ASSUME_SET_ROBUST_LIST #endif -/* m68k only supports ipc syscall. */ -#undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* m68k only supports ipc syscall before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +#endif diff --git a/sysdeps/unix/sysv/linux/mips/kernel-features.h b/sysdeps/unix/sysv/linux/mips/kernel-features.h index c341c3fa10..8114090913 100644 --- a/sysdeps/unix/sysv/linux/mips/kernel-features.h +++ b/sysdeps/unix/sysv/linux/mips/kernel-features.h @@ -31,8 +31,10 @@ pairs to start with an even-number register. */ #if _MIPS_SIM == _ABIO32 # define __ASSUME_ALIGNED_REGISTER_PAIRS 1 -/* mips32 only supports ipc syscall. */ -# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* mips32 only supports ipc syscall before 5.1. */ +# if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +# endif /* The o32 MIPS fadvise64 syscall behaves as fadvise64_64. */ # define __ASSUME_FADVISE64_AS_64_64 1 diff --git a/sysdeps/unix/sysv/linux/powerpc/kernel-features.h b/sysdeps/unix/sysv/linux/powerpc/kernel-features.h index 413a185db3..5924534c22 100644 --- a/sysdeps/unix/sysv/linux/powerpc/kernel-features.h +++ b/sysdeps/unix/sysv/linux/powerpc/kernel-features.h @@ -44,8 +44,10 @@ #include_next -/* powerpc only supports ipc syscall. */ -#undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* powerpc only supports ipc syscall before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +#endif #undef __ASSUME_CLONE_DEFAULT #define __ASSUME_CLONE_BACKWARDS 1 diff --git a/sysdeps/unix/sysv/linux/s390/kernel-features.h b/sysdeps/unix/sysv/linux/s390/kernel-features.h index 8fdf38c454..dcbf1c7c53 100644 --- a/sysdeps/unix/sysv/linux/s390/kernel-features.h +++ b/sysdeps/unix/sysv/linux/s390/kernel-features.h @@ -45,8 +45,10 @@ # undef __ASSUME_SENDTO_SYSCALL #endif -/* s390 only supports ipc syscall. */ -#undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* s390 only supports ipc syscall before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +#endif #undef __ASSUME_CLONE_DEFAULT #define __ASSUME_CLONE_BACKWARDS2 diff --git a/sysdeps/unix/sysv/linux/sh/kernel-features.h b/sysdeps/unix/sysv/linux/sh/kernel-features.h index 767df721b8..8532cccadd 100644 --- a/sysdeps/unix/sysv/linux/sh/kernel-features.h +++ b/sysdeps/unix/sysv/linux/sh/kernel-features.h @@ -41,8 +41,10 @@ before the offset. */ #define __ASSUME_PRW_DUMMY_ARG 1 -/* sh only supports ipc syscall. */ -#undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* sh only supports ipc syscall before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +#endif /* Support for several syscalls was added in 4.8. */ #if __LINUX_KERNEL_VERSION < 0x040800 @@ -52,7 +54,9 @@ # undef __ASSUME_COPY_FILE_RANGE #endif -/* sh does not support the statx system call. */ -#undef __ASSUME_STATX +/* sh does not support the statx system call before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_STATX +#endif #endif diff --git a/sysdeps/unix/sysv/linux/sparc/kernel-features.h b/sysdeps/unix/sysv/linux/sparc/kernel-features.h index f441bd811d..7b5db4af17 100644 --- a/sysdeps/unix/sysv/linux/sparc/kernel-features.h +++ b/sysdeps/unix/sysv/linux/sparc/kernel-features.h @@ -58,8 +58,10 @@ # undef __NR_pause #endif -/* sparc only supports ipc syscall. */ -#undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +/* sparc only supports ipc syscall before 5.1. */ +#if __LINUX_KERNEL_VERSION < 0x050100 +# undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS +#endif /* Support for the renameat2 syscall was added in 3.16. */ #if __LINUX_KERNEL_VERSION < 0x031000