Received: by 10.213.65.68 with SMTP id h4csp487587imn; Tue, 13 Mar 2018 10:35:59 -0700 (PDT) X-Google-Smtp-Source: AG47ELu41YHR3sTKrJ/t5u22E8kcCo1L8tNixNzg4b78cFJ3ClA7b06tgoOda3LPruYjfnQ0XDrY X-Received: by 10.98.152.86 with SMTP id q83mr1374961pfd.218.1520962558933; Tue, 13 Mar 2018 10:35:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1520962558; cv=none; d=google.com; s=arc-20160816; b=n+fg0jEqJNij6Y4yYOamLHuIu/rOPtZDDlP6eOiO/WgCMGULRZqKe24U//VxDTtdOO vKvdf28N28nLLBunTCwXTpSbZnxOpFeqqjQS0+8+fqb2+5Au1SXNFbij6F+6+iheMdn0 vFw8RitTc5zg6ivmYuHQ/+oagSsBPiw8njXn0HvIeEMe5x6krvbheKS8jWtzl3ZD213v YanSPJWL/cEhcUFkIu66uk8SOHmKE/TKwa/+4MAH6GZ9Bcdukoq7xdKMkK04gWjgLfVQ OI9eCbhrwNeguxVOzqK2Vd6VAUfjNOsJJxpPAeSRZvsRtCidcD63NRA6A64wuxjqup3i izRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:subject:mime-version:user-agent :message-id:in-reply-to:date:references:cc:to:from :arc-authentication-results; bh=waWZDWbkYUtvyZGaNoSkYL8aP26gTbMXPIRf7VXeuj0=; b=S4DLIP6XX8BpqiQEormhiWJyLZVosymGN5wbAbyKVG5yWNCAPh6j0MJyTq76OD44fQ AXqJ7CF8D5S35b7eSQ2N2xrf94bwa0Y3GK3L/TO4mGMwIVF7QNEg8WthOUNsbFDDAZtx s1lTQwssuG8ppL9q7WuXb6FV2YUPNX37/NikQ4mXcvQTu3d9sDksPBZOvwbGL6DKRFJK lSVVKtXLcVXa3jkKkagyJh1hm/D/IpO2yLkJvlfHmger6u+JKb2GPj+4aWlHekt4sunz /N2/3/aTMt/yDNS/cFleYOhb9kqRc1BxFBC2T1qcjzdSt+4Vy5vdh8tcqRo2Qzq/V11U c6vA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f4-v6si444518plr.267.2018.03.13.10.35.44; Tue, 13 Mar 2018 10:35:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932418AbeCMRdk (ORCPT + 99 others); Tue, 13 Mar 2018 13:33:40 -0400 Received: from out02.mta.xmission.com ([166.70.13.232]:60446 "EHLO out02.mta.xmission.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932322AbeCMRdj (ORCPT ); Tue, 13 Mar 2018 13:33:39 -0400 Received: from in02.mta.xmission.com ([166.70.13.52]) by out02.mta.xmission.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87) (envelope-from ) id 1evnnv-00016Q-2W; Tue, 13 Mar 2018 11:33:39 -0600 Received: from 174-19-85-160.omah.qwest.net ([174.19.85.160] helo=x220.xmission.com) by in02.mta.xmission.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87) (envelope-from ) id 1evnnf-0008Mq-NK; Tue, 13 Mar 2018 11:33:38 -0600 From: ebiederm@xmission.com (Eric W. Biederman) To: Christian Brauner Cc: viro@zeniv.linux.org.uk, linux-kernel@vger.kernel.org, torvalds@linux-foundation.org, gregkh@linuxfoundation.org, containers@lists.linux-foundation.org References: <20180313165527.24038-1-christian.brauner@ubuntu.com> Date: Tue, 13 Mar 2018 12:32:37 -0500 In-Reply-To: <20180313165527.24038-1-christian.brauner@ubuntu.com> (Christian Brauner's message of "Tue, 13 Mar 2018 17:55:23 +0100") Message-ID: <87o9jr285m.fsf@xmission.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-XM-SPF: eid=1evnnf-0008Mq-NK;;;mid=<87o9jr285m.fsf@xmission.com>;;;hst=in02.mta.xmission.com;;;ip=174.19.85.160;;;frm=ebiederm@xmission.com;;;spf=neutral X-XM-AID: U2FsdGVkX1/8zONZg2y9RCLuJMzl1CUJ0MZ/IJm+q5I= X-SA-Exim-Connect-IP: 174.19.85.160 X-SA-Exim-Mail-From: ebiederm@xmission.com X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on sa07.xmission.com X-Spam-Level: ** X-Spam-Status: No, score=2.0 required=8.0 tests=ALL_TRUSTED,BAYES_50, DCC_CHECK_NEGATIVE,TVD_RCVD_IP,T_TM2_M_HEADER_IN_MSG,T_TooManySym_01, XMNoVowels,XMSubLong autolearn=disabled version=3.4.1 X-Spam-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP * 0.7 XMSubLong Long Subject * 1.5 XMNoVowels Alpha-numberic number with no vowels * 0.0 TVD_RCVD_IP Message was received from an IP address * 0.0 T_TM2_M_HEADER_IN_MSG BODY: No description available. * 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% * [score: 0.5000] * -0.0 DCC_CHECK_NEGATIVE Not listed in DCC * [sa07 1397; Body=1 Fuz1=1 Fuz2=1] * 0.0 T_TooManySym_01 4+ unique symbols in subject X-Spam-DCC: XMission; sa07 1397; Body=1 Fuz1=1 Fuz2=1 X-Spam-Combo: **;Christian Brauner X-Spam-Relay-Country: X-Spam-Timing: total 15024 ms - load_scoreonly_sql: 0.06 (0.0%), signal_user_changed: 2.4 (0.0%), b_tie_ro: 1.57 (0.0%), parse: 0.82 (0.0%), extract_message_metadata: 13 (0.1%), get_uri_detail_list: 1.64 (0.0%), tests_pri_-1000: 2.8 (0.0%), tests_pri_-950: 1.14 (0.0%), tests_pri_-900: 0.98 (0.0%), tests_pri_-400: 27 (0.2%), check_bayes: 26 (0.2%), b_tokenize: 6 (0.0%), b_tok_get_all: 9 (0.1%), b_comp_prob: 1.96 (0.0%), b_tok_touch_all: 7 (0.0%), b_finish: 0.55 (0.0%), tests_pri_0: 167 (1.1%), check_dkim_signature: 0.55 (0.0%), check_dkim_adsp: 3.6 (0.0%), tests_pri_500: 14807 (98.6%), poll_dns_idle: 14798 (98.5%), rewrite_mail: 0.00 (0.0%) Subject: Re: [PATCH 0/4 v5 RESEND] devpts: handle bind-mounts correctly X-Spam-Flag: No X-SA-Exim-Version: 4.2.1 (built Thu, 05 May 2016 13:38:54 -0600) X-SA-Exim-Scanned: Yes (on in02.mta.xmission.com) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Christian Brauner writes: > Resending to CC grekh. Acked-by: "Eric W. Biederman" And the first two patches can also have Reviewed-by: "Eric W. Biederman" Greg this patchset looks read or just about ready to be merged. Do you want to take this through your tty tree or should I take it through my tree. Eric > > Hey everyone, > > This is the fith iteration of this patch. Per-patch changes are > summarized in the individual patches: > > ChangeLog v4->v5: > * added non-functional patch to document devpts_mntget(). > Reason for putting this in a separate patch is that it allows you, > Linus and Eric, to simply drop it if judged useless. > * reverse error handling logic to further simplify > * dput() dentry in the non-function patch. This was not really a problem > since the following patch included a fix for it. But better to get it > right in all individual patches. > * I did another rewrite of the problem analysis for > posterity in the patch "Subject: [PATCH 2/3 v3] devpts: resolve devpts > bind-mounts" and in this cover letter. > > ChangeLog v3->v4: > * small logical simplifications > * add test that bind-mounts of /dev/pts/ptmx to locations that do not > resolve to a valid slave pty path under the originating devpts mount > fail > > ChangeLog v2->v3: > * rewritten commit message to thoroughly analyse the problem for > posterity in the patch "Subject: [PATCH 2/3 v3] devpts: resolve devpts > bind-mounts" and in this cover letter. > * extended selftests to test for correct handling of /dev/pts/ptmx > bind-mounts to /dev/ptmx and non-standard devpts mounts such as > mount -t devpts devpts /mnt > > ChangeLog v1->v2: > * see individual patches > ChangeLog v0->v1: > * see individual patches > > Christian Brauner (4): > devpts: hoist out check for DEVPTS_SUPER_MAGIC > devpts: resolve devpts bind-mounts > devpts: comment devpts_mntget() > selftests: add devpts selftests > > fs/devpts/inode.c | 66 +++-- > tools/testing/selftests/Makefile | 1 + > tools/testing/selftests/filesystems/.gitignore | 1 + > tools/testing/selftests/filesystems/Makefile | 2 +- > tools/testing/selftests/filesystems/devpts_pts.c | 313 +++++++++++++++++++++++ > 5 files changed, 363 insertions(+), 20 deletions(-) > create mode 100644 tools/testing/selftests/filesystems/devpts_pts.c