From patchwork Sun May 19 20:37:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 164542 Delivered-To: patch@linaro.org Received: by 2002:a92:9e1a:0:0:0:0:0 with SMTP id q26csp4806375ili; Sun, 19 May 2019 14:19:30 -0700 (PDT) X-Google-Smtp-Source: APXvYqz0QDxiCBEp4KwWK3Klig51xB7wkbXiFNklKXglQ5prToBPTwIgS+cc6c4e4gmnDkfUCyfn X-Received: by 2002:a17:906:2785:: with SMTP id j5mr55255496ejc.94.1558300770594; Sun, 19 May 2019 14:19:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558300770; cv=none; d=google.com; s=arc-20160816; b=kH+bZ3Ya6NpBJafBiYtdLV6lhv0LNfM8Rzhh8kwYd2O3To6ci+wlXM7tpcfy4PyCg7 /+HB2SLffOJvt2iqQAg77gI9eDGR5yL5501yGPWNCjYmGavVwvNKaCVpl4yt7w0evaWq ThGYLIYkk94XIaT+imIdJacIdTuY3sUUwDcOqNYCdZ08c4FUGkRgQN77U14MKcgKDXSp msIwWGaF1XjxV1nXNr0iM2DFptlYuvOftrmwJYec1T83QGRBfcgTYs4/1nQVGy4Wrw2c +lOM9vN4e59adUEzoDr5LX5QS/I0VIKFkvoBncmUASj13TW78jkqB/2aPNU1Y4vFpygG otEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=MSnLx4TEMgAogxZCRA6zSvqXurn3uaPFvTU6tGKAUTY=; b=jK9CVKx6e65/31i2mRxzCOEOCcS+SelHz0Qp6G5uaww7jZXmo7iNMACqmWtye+7qcg d1u9idcVexGtvcWQpdeTz6ZJbHH1qC3WlAJ4XrsK+E8DZqHAYRwTgzORExbH5uRoFkCy snxYyErf7XDkecTIsIcGMVpR7axPTdfe4Kk9QwwV5MsuX1pYyR6HAUq1zFfFtGFgK80l n50c1emPX79mmEhw8YU1dksX2EB5+zKZW473TL1f6oppTF6O4hc1Sv6XwtrxLPOiL6hS V7wOJjFu7tOE1yu9UByi9DgH+CakhP7Wq/oSj1mHjgXF3EU1J/AzaPVgggLKNQk1Cl3S 9l4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=yOdEk4RB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g11si3042368edc.317.2019.05.19.14.19.30 for (version=TLS1 cipher=AES128-SHA bits=128/128); Sun, 19 May 2019 14:19:30 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=yOdEk4RB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([127.0.0.1]:53712 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hSTDN-0005oF-GI for patch@linaro.org; Sun, 19 May 2019 17:19:29 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50936) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hSSZr-0003rA-57 for qemu-devel@nongnu.org; Sun, 19 May 2019 16:38:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hSSZq-0004hg-1f for qemu-devel@nongnu.org; Sun, 19 May 2019 16:38:39 -0400 Received: from mail-pl1-x642.google.com ([2607:f8b0:4864:20::642]:41410) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hSSZp-0004gf-QO for qemu-devel@nongnu.org; Sun, 19 May 2019 16:38:37 -0400 Received: by mail-pl1-x642.google.com with SMTP id f12so5707321plt.8 for ; Sun, 19 May 2019 13:38:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=MSnLx4TEMgAogxZCRA6zSvqXurn3uaPFvTU6tGKAUTY=; b=yOdEk4RBWdpJRxv5GrOS2C+3ELsjxW6DTlLQXge1/VAhTA2M30GV6M0ZwzyotMj/T9 8DraWkYKjUgJ16N9+SME7qtxLqrIlsWYBhcszL9x10kpqMLDuUOQ6x9xKk55IVwCVPgA YAxA1jQkHnikbkRcAtYJrGhIZ27Jmu4tTfdYurD8qkBlwFejOM8JlC6J5LQC7Z6x1gdn RUJ9go/PemRQ1Q3AstEEXA8DRLLh8AOW+1tYHOjlZ0191WMfX814acBPWv1EZZDkpKLC WF5S4mXRbKA+3dk6q6Pwyga0vQhLiegklfTLanzvpU6LqwBE0K8TDMmW3Vhpd3Nliep9 KZVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=MSnLx4TEMgAogxZCRA6zSvqXurn3uaPFvTU6tGKAUTY=; b=dWg1bxegxo8MwwGHVxeimbCS850pNAg8bmYYqb/kZsht+6DHptdT77Xi2//5UmiUZe GhwSeArOr9zURXb+GlwZ135Uuiou4cBuVwV8cRsO5oY9WKW1uYDb7inmkYbQu9oXKsCU 1xpSdhPQnHsJzfVYmBqIjouEAIM/Yl62a/d7hzp897PtvdKcXJegI3hQ5Lf86MFOy0Jf ympUtjZE4fcjUl/KJzV+rxXDYpi+5oNhI6uVkdwI99G4Az+Mc83KxSxAZubjDgEnSvVB xZLxb5lUS+P0dfhcZuypJgeZlgnftYKj0k05/v/Sg3vkaWzJYA+ef0psrFMLAk20FcmZ 7wHQ== X-Gm-Message-State: APjAAAVwjhN8FmxdZA1UYO7+qcej1F3yjEAJG7YWs+v0d64wBi70UNSP NIpsWpu6GkKidByqxngOrNQi7lBx1D8= X-Received: by 2002:a17:902:70c6:: with SMTP id l6mr54073267plt.84.1558298316633; Sun, 19 May 2019 13:38:36 -0700 (PDT) Received: from localhost.localdomain (97-113-13-231.tukw.qwest.net. [97.113.13.231]) by smtp.gmail.com with ESMTPSA id i7sm11397448pfo.19.2019.05.19.13.38.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 19 May 2019 13:38:35 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Date: Sun, 19 May 2019 13:37:06 -0700 Message-Id: <20190519203726.20729-55-richard.henderson@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190519203726.20729-1-richard.henderson@linaro.org> References: <20190519203726.20729-1-richard.henderson@linaro.org> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::642 Subject: [Qemu-devel] [PATCH v7 54/74] linux-user: Split out getpgid, getpgrp X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: laurent@vivier.eu Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Richard Henderson --- linux-user/syscall-defs.h | 4 ++++ linux-user/syscall-proc.inc.c | 12 ++++++++++++ linux-user/syscall.c | 6 ------ linux-user/strace.list | 6 ------ 4 files changed, 16 insertions(+), 12 deletions(-) -- 2.17.1 diff --git a/linux-user/syscall-defs.h b/linux-user/syscall-defs.h index b93ca1f78a..2ade9ec749 100644 --- a/linux-user/syscall-defs.h +++ b/linux-user/syscall-defs.h @@ -59,6 +59,10 @@ SYSCALL_DEF(futimesat, ARG_ATDIRFD, ARG_STR, ARG_PTR); #ifdef TARGET_NR_fork SYSCALL_DEF(fork); #endif +SYSCALL_DEF(getpgid, ARG_DEC); +#ifdef TARGET_NR_getpgrp +SYSCALL_DEF(getpgrp); +#endif #ifdef TARGET_NR_getpid SYSCALL_DEF(getpid); #endif diff --git a/linux-user/syscall-proc.inc.c b/linux-user/syscall-proc.inc.c index 5bd27d1d4b..39de5b7863 100644 --- a/linux-user/syscall-proc.inc.c +++ b/linux-user/syscall-proc.inc.c @@ -438,6 +438,18 @@ SYSCALL_IMPL(fork) } #endif +SYSCALL_IMPL(getpgid) +{ + return get_errno(getpgid(arg1)); +} + +#ifdef TARGET_NR_getpgrp +SYSCALL_IMPL(getpgrp) +{ + return get_errno(getpgrp()); +} +#endif + #ifdef TARGET_NR_getpid SYSCALL_IMPL(getpid) { diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 255765aaa7..75989a01bf 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -4241,10 +4241,6 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1, void *p; switch(num) { -#ifdef TARGET_NR_getpgrp - case TARGET_NR_getpgrp: - return get_errno(getpgrp()); -#endif case TARGET_NR_setsid: return get_errno(setsid()); #ifdef TARGET_NR_sigaction @@ -5388,8 +5384,6 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1, } return ret; #endif - case TARGET_NR_getpgid: - return get_errno(getpgid(arg1)); case TARGET_NR_fchdir: return get_errno(fchdir(arg1)); case TARGET_NR_personality: diff --git a/linux-user/strace.list b/linux-user/strace.list index 7679e844b6..d283c924a7 100644 --- a/linux-user/strace.list +++ b/linux-user/strace.list @@ -262,12 +262,6 @@ #ifdef TARGET_NR_getpeername { TARGET_NR_getpeername, "getpeername" , NULL, NULL, NULL }, #endif -#ifdef TARGET_NR_getpgid -{ TARGET_NR_getpgid, "getpgid" , NULL, NULL, NULL }, -#endif -#ifdef TARGET_NR_getpgrp -{ TARGET_NR_getpgrp, "getpgrp" , NULL, NULL, NULL }, -#endif #ifdef TARGET_NR_getpmsg { TARGET_NR_getpmsg, "getpmsg" , NULL, NULL, NULL }, #endif