From patchwork Sat Jan 27 22:50:56 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866792 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-89716-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="jiBK7fyG"; 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 3zTWSB2Dftz9s9Y for ; Sun, 28 Jan 2018 09:59:38 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=UPQDIQY7PiUiwM/OG73YZU/D+uwqjxc JR3hBkwEQWC3doYcR8+y3NdAADVCwbQeoLkYQUgtJeis5+wje31enNKhaCcvub1e zrHTmMSuAf+YCork5pUX0iTVQ8u/hIALt3HUYhLFHEP8NHlFUGwYjv6TAfkqVUhv 26RNuq6wX2Mw= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=svCI2TQHfvksTYtz9BoYQqov5I8=; b=jiBK7 fyGRo7t9jRLlmh4sDsfTngCb/qNegCet91quhlEY4jNs4o8mNfVa17kTfPC7ocaX 8iBAMBUoP27s5ELqy15zdSJzlBV4qYAMZ81tngB2o2Kp3ULiVQduW3IM3P1ZkeyQ fbckxDLxLrVO4yCxiMDivhyCnsBJJKR99n7hAg= Received: (qmail 14367 invoked by alias); 27 Jan 2018 22:59:32 -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 14342 invoked by uid 89); 27 Jan 2018 22:59:32 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy=2034 X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 1/7] hurd: fix warning Date: Sat, 27 Jan 2018 23:50:56 +0100 Message-Id: <20180127225102.11373-2-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> * sysdeps/mach/hurd/Makefile [$(subdir)==nis]: Add -DUSE_BINDINGDIR=1 to CFLAGS-ypclnt.c. --- ChangeLog | 2 ++ sysdeps/mach/hurd/Makefile | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/ChangeLog b/ChangeLog index 88f6d93c12..4e1e4bf730 100644 --- a/ChangeLog +++ b/ChangeLog @@ -19,6 +19,8 @@ timer_ptr2id to cast struct timer_node * to void *. * scripts/build-many-glibcs.py [os == gnu] (build_gcc): Pass --disable-libcilkrts to gcc configure. + * sysdeps/mach/hurd/Makefile [$(subdir)==nis]: Add + -DUSE_BINDINGDIR=1 to CFLAGS-ypclnt.c. 2018-01-27 James Clarke diff --git a/sysdeps/mach/hurd/Makefile b/sysdeps/mach/hurd/Makefile index f0d3373b64..492ace05eb 100644 --- a/sysdeps/mach/hurd/Makefile +++ b/sysdeps/mach/hurd/Makefile @@ -203,4 +203,8 @@ sysdep_headers += net/ethernet.h net/if_arp.h net/if_ether.h net/if_ppp.h \ net/route.h endif +ifeq ($(subdir),nis) +CFLAGS-ypclnt.c += -DUSE_BINDINGDIR=1 +endif + endif # in-Makerules From patchwork Sat Jan 27 22:50:57 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866790 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-89714-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="uMYHFGlY"; 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 3zTWH56GN1z9sRm for ; Sun, 28 Jan 2018 09:51:45 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=jRDTXeuwcx0ya4CdXaWtX1Gv7jULD7c WbAllgtyh10eDNJ8Z6xZefcwuc04GpfG67B3+nmoFOhLVFpTzkzxm2OYr+wPi5ur oAqVefiQ+o1FyrJU/KjGH9mZ54tBOJCzFtybU8Kf7VV+NErE972GwDf4WhQ3C2Fb RYf5mt4G/eQU= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=QUpsfiNoLnJH1o45fPdp2pAPA1M=; b=uMYHF GlYy1BRwF8Vyvenns+3wzyu2BCxFb8ANF2aYkPZxXtwU5doXw9WcwbeMuZ6/W/sS jvltysG39kT0qdosgxdWm1f/HqNRVxTjQW3gbBhhlA42gIxjMGYVz7dWWAX8TcxI N/erCwgUusr1GiIkyXjv5kR0a72B7TAd8xhlMw= Received: (qmail 4843 invoked by alias); 27 Jan 2018 22:51:12 -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 4723 invoked by uid 89); 27 Jan 2018 22:51:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy=poly, 2139, RPC X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 2/7] hurd: drop elder MACH_IPC_COMPAT handling Date: Sat, 27 Jan 2018 23:50:57 +0100 Message-Id: <20180127225102.11373-3-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> This was dropped from GNU Mach in 2006. * mach/Machrules (MIGFLAGS): Do not set -DMACH_IPC_COMPAT=0. * mach/mach/mach_traps.h: Drop comment about MACH_IPC_COMPAT. * sysdeps/mach/hurd/fork.c (__fork): Drop special casing MACH_IPC_COMPAT. --- ChangeLog | 4 ++++ mach/Machrules | 2 +- mach/mach/mach_traps.h | 3 +-- sysdeps/mach/hurd/fork.c | 35 +++-------------------------------- 4 files changed, 9 insertions(+), 35 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4e1e4bf730..7d7800dbb1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -21,6 +21,10 @@ --disable-libcilkrts to gcc configure. * sysdeps/mach/hurd/Makefile [$(subdir)==nis]: Add -DUSE_BINDINGDIR=1 to CFLAGS-ypclnt.c. + * mach/Machrules (MIGFLAGS): Do not set -DMACH_IPC_COMPAT=0. + * mach/mach/mach_traps.h: Drop comment about MACH_IPC_COMPAT. + * sysdeps/mach/hurd/fork.c (__fork): Drop special casing + MACH_IPC_COMPAT. 2018-01-27 James Clarke diff --git a/mach/Machrules b/mach/Machrules index 49e6399b7c..4f9ec421ec 100644 --- a/mach/Machrules +++ b/mach/Machrules @@ -51,7 +51,7 @@ $(objpfx)dummy.mk: $(make-target-directory) echo '# Empty' > $@ -MIGFLAGS = -DMACH_IPC_COMPAT=0 -DSTANDALONE -DTypeCheck=0 \ +MIGFLAGS = -DSTANDALONE -DTypeCheck=0 \ $(+includes) $(migdefines) -subrprefix __ # Putting CC in the enivronment makes the mig wrapper script # use the same compiler setup we are using to run cpp. diff --git a/mach/mach/mach_traps.h b/mach/mach/mach_traps.h index 5e09a95310..cefbd2d372 100644 --- a/mach/mach/mach_traps.h +++ b/mach/mach/mach_traps.h @@ -17,8 +17,7 @@ /* Declare the few Mach system calls (except mach_msg, in ). This does not include the kernel RPC shortcut calls (in ). - - This file omits the MACH_IPC_COMPAT functions. */ + */ #ifndef _MACH_MACH_TRAPS_H diff --git a/sysdeps/mach/hurd/fork.c b/sysdeps/mach/hurd/fork.c index fe3f544f2b..b55eecffc6 100644 --- a/sysdeps/mach/hurd/fork.c +++ b/sysdeps/mach/hurd/fork.c @@ -213,38 +213,9 @@ __fork (void) { /* This is a receive right. We want to give the child task its own new receive right under the same name. */ - err = __mach_port_allocate_name (newtask, - MACH_PORT_RIGHT_RECEIVE, - portnames[i]); - if (err == KERN_NAME_EXISTS) - { - /* It already has a right under this name (?!). Well, - there is this bizarre old Mach IPC feature (in #ifdef - MACH_IPC_COMPAT in the ukernel) which results in new - tasks getting a new receive right for task special - port number 2. What else might be going on I'm not - sure. So let's check. */ -#if !MACH_IPC_COMPAT -#define TASK_NOTIFY_PORT 2 -#endif - assert (({ mach_port_t thisport, notify_port; - mach_msg_type_name_t poly; - (__task_get_special_port (newtask, - TASK_NOTIFY_PORT, - ¬ify_port) == 0 && - __mach_port_extract_right - (newtask, - portnames[i], - MACH_MSG_TYPE_MAKE_SEND, - &thisport, &poly) == 0 && - (thisport == notify_port) && - __mach_port_deallocate (__mach_task_self (), - thisport) == 0 && - __mach_port_deallocate (__mach_task_self (), - notify_port) == 0); - })); - } - else if (err) + if (err = __mach_port_allocate_name (newtask, + MACH_PORT_RIGHT_RECEIVE, + portnames[i])) LOSE; if (porttypes[i] & MACH_PORT_TYPE_SEND) { From patchwork Sat Jan 27 22:50:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866785 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-89711-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="Gsc6lgg9"; 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 3zTWGd6jxtz9sP9 for ; Sun, 28 Jan 2018 09:51:21 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=XU8jRH5SN+AzGdXqvT1qTuo2BvLq5HN WLJIOauW6xrhmA5BaTeyjuhyS8wDwuAcJ5hIMGHxhIHHiO8YF9SGxPR04vcTRgpI JALf5UfeVvQHNvuwgZHkbVpw1P1Zi3zK4wou7Kyt6ccT7Yao4E0WjbbajXuyjagZ cfepwZNuwO48= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=yEUfVjCrg6ObZ3XQe4dMlnRoip4=; b=Gsc6l gg9B+wo2IwY6cpWXNHLjR0Gt1yJ7KroAb2BNN4VepsMv3W76ZsrXdUUwBsm5cSzW gFZy/NYIz4gRvV9pGECMUTqFaYCR14ffg/3jbmMx1eRBkVBMS3qOYCF3Qa2Grx5y 5MlvRU4S04vu8+HLgokNGx4wzppsEI1nZ4l/KU= Received: (qmail 4137 invoked by alias); 27 Jan 2018 22:51:08 -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 4059 invoked by uid 89); 27 Jan 2018 22:51:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy=Hx-languages-length:1810 X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd, commited 3/7] hurd: make build-many-glibcs.py use mainline mig Date: Sat, 27 Jan 2018 23:50:58 +0100 Message-Id: <20180127225102.11373-4-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> Some warnings come from code generated by mig, so we need a very recent version for now. * scripts/build-many-glibcs.py (checkout_vcs): Add mig repository URL, and run autoreconf, make it the default for now. --- ChangeLog | 2 ++ scripts/build-many-glibcs.py | 9 ++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 7d7800dbb1..9582d8cfed 100644 --- a/ChangeLog +++ b/ChangeLog @@ -19,6 +19,8 @@ timer_ptr2id to cast struct timer_node * to void *. * scripts/build-many-glibcs.py [os == gnu] (build_gcc): Pass --disable-libcilkrts to gcc configure. + (checkout_vcs): Add mig repository URL, and run autoreconf, make it the + default for now. * sysdeps/mach/hurd/Makefile [$(subdir)==nis]: Add -DUSE_BINDINGDIR=1 to CFLAGS-ypclnt.c. * mach/Machrules (MIGFLAGS): Do not set -DMACH_IPC_COMPAT=0. diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py index fbb701e25d..d7adcc8022 100755 --- a/scripts/build-many-glibcs.py +++ b/scripts/build-many-glibcs.py @@ -704,7 +704,7 @@ class Context(object): 'linux': '4.14', 'mpc': '1.1.0', 'mpfr': '4.0.0', - 'mig': '1.8', + 'mig': 'vcs-mainline', 'gnumach': '1.8', 'hurd': 'vcs-mainline'} use_versions = {} @@ -786,6 +786,13 @@ class Context(object): r = self.git_checkout(component, git_url, git_branch, update) self.fix_glibc_timestamps() return r + elif component == 'mig': + git_url = 'git://git.savannah.gnu.org/hurd/mig.git' + git_branch = 'master' + r = self.git_checkout(component, git_url, git_branch, update) + subprocess.run(['autoreconf', '-i'], + cwd=self.component_srcdir(component), check=True) + return r elif component == 'hurd': git_url = 'git://git.savannah.gnu.org/hurd/hurd.git' git_branch = 'master' From patchwork Sat Jan 27 22:50:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866787 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-89713-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="HhZs4hbb"; 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 3zTWGy0zVxz9s9Y for ; Sun, 28 Jan 2018 09:51:37 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=Y1sRMET76xg1/jzGGH9eaTHoy8SD9Up KFUfJIEsG8c+k6IEOomMbhHyzJOFa//vHfJX3G7hJfITm1B0DKJxUqCSfkKelpCN 3cWDPaslpVH8Zb3QI3wcCRI7xDWmXK4rQiZRnNywGrL4pJgBs1fC9/SsnjcSKkcn IFhS9/9/uH5o= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=b2RQU5M5B2VGwoAjjK3CncfpciI=; b=HhZs4 hbbCq3YzR7Fmr2uttcFSKNB6vfsLRrZdzK/HD9faXk2qenESVcWUrURPDjPbVwL6 K0rlKEFCA87L32bYGBaLJnwcI/wBGvk7enk0/oz8Rb5gKHfLamwApHcQ7u88W9Kc hzrmt6oInSrDfnlD1UG/OO51YVAAwL6YoWwIDY= Received: (qmail 4441 invoked by alias); 27 Jan 2018 22:51:09 -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 4285 invoked by uid 89); 27 Jan 2018 22:51:09 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy= X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 4/7] hurd: fix warning Date: Sat, 27 Jan 2018 23:50:59 +0100 Message-Id: <20180127225102.11373-5-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> * sysdeps/mach/hurd/dl-sysdep.c (_exit): Call LOSE and abort() if __task_terminate would ever return successfully. --- ChangeLog | 2 ++ sysdeps/mach/hurd/dl-sysdep.c | 3 +++ 2 files changed, 5 insertions(+) diff --git a/ChangeLog b/ChangeLog index 9582d8cfed..5dd9e9fcb6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -27,6 +27,8 @@ * mach/mach/mach_traps.h: Drop comment about MACH_IPC_COMPAT. * sysdeps/mach/hurd/fork.c (__fork): Drop special casing MACH_IPC_COMPAT. + * sysdeps/mach/hurd/dl-sysdep.c (_exit): Call LOSE and abort() if + __task_terminate would ever return successfully. 2018-01-27 James Clarke diff --git a/sysdeps/mach/hurd/dl-sysdep.c b/sysdeps/mach/hurd/dl-sysdep.c index 2cd63bb83a..ef96df054e 100644 --- a/sysdeps/mach/hurd/dl-sysdep.c +++ b/sysdeps/mach/hurd/dl-sysdep.c @@ -643,6 +643,9 @@ _exit (int status) W_EXITCODE (status, 0), 0); while (__task_terminate (__mach_task_self ())) __mach_task_self_ = (__mach_task_self) (); + + LOSE; + abort (); } /* We need this alias to satisfy references from libc_pic.a objects that were affected by the libc_hidden_proto declaration for _exit. */ From patchwork Sat Jan 27 22:51:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866786 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-89712-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="jOvZLJ4d"; 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 3zTWGp11xRz9sP9 for ; Sun, 28 Jan 2018 09:51:29 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=yJgOv/JT3eq4ugeoE/tPFXQ58TBiIcB TJPkRoOt6VsogzXutwrmqGFzByWqOkI90JhDv3xbexz8f791wNLzzvgeICMnfCTt TRmPErJMa6BnqhGUf0bbud3bzMKiFn9giH6cMMQ7/32Ko5MZqFCltBMLkoG9T6Pp IwxEyb1DQo7g= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=8TmL5PotJdvGzzpa1ZJD4aYMnvw=; b=jOvZL J4dpIjA8IF3BTqr3v5GWAjfr12LSBMOR+82djyiOjCuZXUZy4hZhvwXWT4tGwBrZ ySnfyhVwOrqWHLUm0uEDSvxWHuaKdUoPJCeitqQQ+BMd7RUcCymvmsSx8fpHHcV7 yMCHi/8Bdxm270b+89HFiQify2xTRnELyyDPhE= Received: (qmail 4330 invoked by alias); 27 Jan 2018 22:51:09 -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 4135 invoked by uid 89); 27 Jan 2018 22:51:08 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy= X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 5/7] hurd: fix warning Date: Sat, 27 Jan 2018 23:51:00 +0100 Message-Id: <20180127225102.11373-6-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> Making `special_profil_failure' both avoids warning "variable 'special_profil_failure' set but not used", and makes it easier to access with gdb. * sysdeps/mach/hurd/profil.c (special_profil_failure): Move variable to global scope. --- ChangeLog | 2 ++ sysdeps/mach/hurd/profil.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 5dd9e9fcb6..5e62415607 100644 --- a/ChangeLog +++ b/ChangeLog @@ -29,6 +29,8 @@ MACH_IPC_COMPAT. * sysdeps/mach/hurd/dl-sysdep.c (_exit): Call LOSE and abort() if __task_terminate would ever return successfully. + * sysdeps/mach/hurd/profil.c (special_profil_failure): Move variable + to global scope. 2018-01-27 James Clarke diff --git a/sysdeps/mach/hurd/profil.c b/sysdeps/mach/hurd/profil.c index 2fe8f9de56..b3f201b016 100644 --- a/sysdeps/mach/hurd/profil.c +++ b/sysdeps/mach/hurd/profil.c @@ -138,6 +138,8 @@ __profil (u_short *sample_buffer, size_t size, size_t offset, u_int scale) } weak_alias (__profil, profil) +static volatile error_t special_profil_failure; + /* Fetch PC samples. This function must be very careful not to depend on Hurd threadvar variables. We arrange that by using a special stub arranged for at the end of this file. */ @@ -154,7 +156,6 @@ fetch_samples (void) pc_samples, &nsamples); if (err) { - static volatile error_t special_profil_failure; static volatile int a, b; special_profil_failure = err; From patchwork Sat Jan 27 22:51:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866791 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-89715-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="xZHpbH+Q"; 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 3zTWHF71vwz9s9Y for ; Sun, 28 Jan 2018 09:51:53 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=JIr2slkp4Ny+DuJIdCLcofCGqxgAG3A 5gmod4IqJy1tRDrTIn2CE2ZxmEehsAV/6UuJD2RLxyALa0C4EGuCNJep/75goyU1 ubuhlO769XlbVmT1l2jsyIaSB3Q+vowqX4PvpUGOhK8kKQ+cs9LwJeqs9YBO9uiI 65MYUeNmokfo= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=oshwyjqesRFX31pB9560rt4K4bk=; b=xZHpb H+Qwr28vP1Jilhgj+3a0VNiS2nlUOtTBJkEuZlyE1iEoS9BDkI/SHADRgxiRZAXb 70/m1ZdBmYNJ7vYjzMuEsb1xlIyYcmosWgiZmbAICYgBm651glazRWfmZzPO5NEw 6z+Rz3TJ5Js/+q4j330diWYit3WcOU0FPNONV8= Received: (qmail 4899 invoked by alias); 27 Jan 2018 22:51:12 -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 4769 invoked by uid 89); 27 Jan 2018 22:51:12 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy= X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 6/7] hurd: Fix enabling vm_copy Date: Sat, 27 Jan 2018 23:51:01 +0100 Message-Id: <20180127225102.11373-7-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> Benchmarked on http://lists.gnu.org/archive/html/bug-hurd/2014-12/msg00081.html * sysdeps/mach/pagecopy.h (PAGE_THRESHOLD): Rename to PAGE_COPY_THRESHOLD and set to benchmarked 16384. --- ChangeLog | 2 ++ sysdeps/mach/pagecopy.h | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5e62415607..95e2c07df5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -31,6 +31,8 @@ __task_terminate would ever return successfully. * sysdeps/mach/hurd/profil.c (special_profil_failure): Move variable to global scope. + * sysdeps/mach/pagecopy.h (PAGE_THRESHOLD): Rename to + PAGE_COPY_THRESHOLD and set to benchmarked 16384. 2018-01-27 James Clarke diff --git a/sysdeps/mach/pagecopy.h b/sysdeps/mach/pagecopy.h index 6285ffb416..8583df4569 100644 --- a/sysdeps/mach/pagecopy.h +++ b/sysdeps/mach/pagecopy.h @@ -19,8 +19,8 @@ #include /* Threshold at which vm_copy is more efficient than well-optimized copying - by words. This parameter should be tuned as necessary. */ -#define PAGE_THRESHOLD (2 * PAGE_SIZE) /* XXX ? */ + by words. */ +#define PAGE_COPY_THRESHOLD (16384) #define PAGE_SIZE __vm_page_size #define PAGE_COPY_FWD(dstp, srcp, nbytes_left, nbytes) \ From patchwork Sat Jan 27 22:51:02 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866793 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-89717-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="rsE9ULbp"; 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 3zTWSK6bnYz9sRm for ; Sun, 28 Jan 2018 09:59:45 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=yYr47uGvDq3LIsDskfqPleRVxo3ag2V kGHd4rUbNsOgnY5HTeMuHmjVj7W5LFOs4l8iYGPoPVJUGtxASJQJsajG27ZFt0/L PVD46RpQKVFKIslmqT10trzAIVrdNgYJ4IP6D55WiuJuGqDX3nhP4pYbHKOW2YuI 8Kurw0k0H3Pk= 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:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=LyfE+JGVTdCO17/lIrbUD8lC4EU=; b=rsE9U LbpwddyMpwLts08pbQ6AB1JSXTXWR/2CCQJ4oP0sBG830VrxjwmA/Y7Q+wIgqVIP YoKariv4BytAx20yrgSsp75r4gA38QF4t5O3wuUy8Kqs6vChedlugd/r3BkWzEcn ddfFJ49EPZAlviYnNzEcx/B92Efyocg+1j0vb4= Received: (qmail 14378 invoked by alias); 27 Jan 2018 22:59:32 -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 14344 invoked by uid 89); 27 Jan 2018 22:59:32 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy=UD:lock X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 7/7] hurd: fix warning Date: Sat, 27 Jan 2018 23:51:02 +0100 Message-Id: <20180127225102.11373-8-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> References: <20180127225102.11373-1-samuel.thibault@ens-lyon.org> * sysdeps/mach/hurd/getresgid.c (__getresgid): Set result from critical section to make code simpler and avoid warning. * sysdeps/mach/hurd/getresuid.c (__getresuid): Set result from critical section to make code simpler and avoid warning. --- ChangeLog | 4 ++++ sysdeps/mach/hurd/getresgid.c | 17 ++++++----------- sysdeps/mach/hurd/getresuid.c | 17 ++++++----------- 3 files changed, 16 insertions(+), 22 deletions(-) diff --git a/ChangeLog b/ChangeLog index 95e2c07df5..5eebc649cc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -33,6 +33,10 @@ to global scope. * sysdeps/mach/pagecopy.h (PAGE_THRESHOLD): Rename to PAGE_COPY_THRESHOLD and set to benchmarked 16384. + * sysdeps/mach/hurd/getresgid.c (__getresgid): Set result from + critical section to make code simpler and avoid warning. + * sysdeps/mach/hurd/getresuid.c (__getresuid): Set result from + critical section to make code simpler and avoid warning. 2018-01-27 James Clarke diff --git a/sysdeps/mach/hurd/getresgid.c b/sysdeps/mach/hurd/getresgid.c index 41823ff3e1..e5eeba8ac5 100644 --- a/sysdeps/mach/hurd/getresgid.c +++ b/sysdeps/mach/hurd/getresgid.c @@ -27,7 +27,6 @@ int __getresgid (gid_t *rgid, gid_t *egid, gid_t *sgid) { error_t err; - gid_t real, eff, saved; HURD_CRITICAL_BEGIN; __mutex_lock (&_hurd_id.lock); @@ -40,22 +39,18 @@ __getresgid (gid_t *rgid, gid_t *egid, gid_t *sgid) err = EGRATUITOUS; else { - real = _hurd_id.aux.gids[0]; - eff = _hurd_id.gen.ngids < 1 ? real : _hurd_id.gen.gids[0]; - saved = _hurd_id.aux.ngids < 2 ? real : _hurd_id.aux.gids[1]; + gid_t real = _hurd_id.aux.gids[0]; + + *rgid = real; + *egid = _hurd_id.gen.ngids < 1 ? real : _hurd_id.gen.gids[0]; + *sgid = _hurd_id.aux.ngids < 2 ? real : _hurd_id.aux.gids[1]; } } __mutex_unlock (&_hurd_id.lock); HURD_CRITICAL_END; - if (err) - return __hurd_fail (err); - - *rgid = real; - *egid = eff; - *sgid = saved; - return 0; + return __hurd_fail (err); } libc_hidden_def (__getresgid) weak_alias (__getresgid, getresgid) diff --git a/sysdeps/mach/hurd/getresuid.c b/sysdeps/mach/hurd/getresuid.c index 1f2340350b..4af4786fc5 100644 --- a/sysdeps/mach/hurd/getresuid.c +++ b/sysdeps/mach/hurd/getresuid.c @@ -27,7 +27,6 @@ int __getresuid (uid_t *ruid, uid_t *euid, uid_t *suid) { error_t err; - uid_t real, eff, saved; HURD_CRITICAL_BEGIN; __mutex_lock (&_hurd_id.lock); @@ -40,22 +39,18 @@ __getresuid (uid_t *ruid, uid_t *euid, uid_t *suid) err = EGRATUITOUS; else { - real = _hurd_id.aux.uids[0]; - eff = _hurd_id.gen.nuids < 1 ? real : _hurd_id.gen.uids[0]; - saved = _hurd_id.aux.nuids < 2 ? real : _hurd_id.aux.uids[1]; + uid_t real = _hurd_id.aux.uids[0]; + + *ruid = real; + *euid = _hurd_id.gen.nuids < 1 ? real : _hurd_id.gen.uids[0]; + *suid = _hurd_id.aux.nuids < 2 ? real : _hurd_id.aux.uids[1]; } } __mutex_unlock (&_hurd_id.lock); HURD_CRITICAL_END; - if (err) - return __hurd_fail (err); - - *ruid = real; - *euid = eff; - *suid = saved; - return 0; + return __hurd_fail (err); } libc_hidden_def (__getresuid) weak_alias (__getresuid, getresuid)