Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp639993imm; Fri, 10 Aug 2018 19:19:01 -0700 (PDT) X-Google-Smtp-Source: AA+uWPxV408c88MoYsIcZ8H80Q9eVA3sCnjZkxyhGwBTcfJnQQKSoWHS3p6H3Tkpq6vmWzmJK0uC X-Received: by 2002:a63:e647:: with SMTP id p7-v6mr8518071pgj.218.1533953941515; Fri, 10 Aug 2018 19:19:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533953941; cv=none; d=google.com; s=arc-20160816; b=wBqgN+uTiZ1eQSN7tn5yyfc0Cwfq+2FQaisi/xP0xLIZBwertRbGMKBfgXBCusu3ze O0WzsKYzcAyOeSi6tePVrpmV5tF+LKogfhKKwcPmFRYYT3tYL/q1YyxIeVqgs6PJH6Mn +te2pb4df1uDuwfs6/eEWWLSY2UjdIPn9doWlTQjYITeMj8anLv+enbUd4Kxmf9ioWdR 5KPKpV64ktcCzoX2xef0xE/7TCkI5bFU/VKf0jhT/A9n5CKrceHYZ5+jCVih7CTOFEy7 qfMLqJLYXOH976GmpE20pzL/ErBoSaZWQpdz4IKQgK+H2fKNoswnfTUhqWoqJ2WfED3q UVSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=r22sLgCFZWfVR1MoAG4QsZ/qMYC4yChbr9BZGnqYcfM=; b=kJDPHSEqADUgnwh2MK/D0q1moFGFIRNBB0hfO1yBkT9e3z2PMiqhIs0fZs96rmwAPy KZXvp7fe93N62f1dTXNqbds76qjmGyYLb7zC+2p5Y2QFLXND4UWa8kg1xlF3/qFvXqui 0iAE9GWOXEKicx23yECxvKUi8LevfXGxRtZVbaACe+iLBmP6I0xOcY6QGDUDlyDE0II3 ApjP8Tu1byxyuThWvXEYhk7T7/NDxLQnGD/WxgcwxQSIBtRxlmnP7i2kl9k8IuVVUb6J mVdnry4h6wISe89oxVxDAoYacqzgc9Z83t2EdekpqnjZEz6Xk1gDPsp08T4I2HzAbCwo j7DQ== 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 5-v6si9642959pls.431.2018.08.10.19.18.46; Fri, 10 Aug 2018 19:19:01 -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 S1727411AbeHKEtv (ORCPT + 99 others); Sat, 11 Aug 2018 00:49:51 -0400 Received: from zeniv.linux.org.uk ([195.92.253.2]:60288 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727304AbeHKEtv (ORCPT ); Sat, 11 Aug 2018 00:49:51 -0400 Received: from viro by ZenIV.linux.org.uk with local (Exim 4.87 #1 (Red Hat Linux)) id 1foJSi-0008Sq-Dq; Sat, 11 Aug 2018 02:17:04 +0000 Date: Sat, 11 Aug 2018 03:17:04 +0100 From: Al Viro To: "Eric W. Biederman" Cc: David Howells , John Johansen , Tejun Heo , selinux@tycho.nsa.gov, Paul Moore , Li Zefan , linux-api@vger.kernel.org, apparmor@lists.ubuntu.com, Casey Schaufler , fenghua.yu@intel.com, Greg Kroah-Hartman , Eric Biggers , linux-security-module@vger.kernel.org, Tetsuo Handa , Johannes Weiner , Stephen Smalley , tomoyo-dev-en@lists.sourceforge.jp, cgroups@vger.kernel.org, torvalds@linux-foundation.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, "Theodore Y. Ts'o" , Miklos Szeredi Subject: Re: BUG: Mount ignores mount options Message-ID: <20180811021704.GE6515@ZenIV.linux.org.uk> References: <153313703562.13253.5766498657900728120.stgit@warthog.procyon.org.uk> <87d0uqpba5.fsf@xmission.com> <20180810151606.GA6515@ZenIV.linux.org.uk> <87pnypiufr.fsf@xmission.com> <20180811015815.GD6515@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180811015815.GD6515@ZenIV.linux.org.uk> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Aug 11, 2018 at 02:58:15AM +0100, Al Viro wrote: > On Fri, Aug 10, 2018 at 08:05:44PM -0500, Eric W. Biederman wrote: > > > All I proposed was that we distinguish between a first mount and an > > additional mount so that userspace knows the options will be ignored. > > For pity sake, just what does it take to explain to you that your > notions of "first mount" and "additional mount" ARE HEAVILY FS-DEPENDENT > and may depend upon the pieces of state userland (especially in container) > simply does not have? > > One more time, slowly: > > mount -t nfs4 wank.example.org:/foo/bar /mnt/a > mount -t nfs4 wank.example.org:/baz/barf /mnt/b > > yield the same superblock. Is anyone who mounts something over NFS > required to know if anybody else has mounted something from the same > server, and if so how the hell are they supposed to find that out, > so that they could decide whether they are creating the "first" or > "additional" mount, whatever that might mean in this situation? > > And how, kernel-side, is that supposed to be handled by generic code > of any description? > > While we are at it, > mount -t nfs4 wank.example.org:/foo/bar -o wsize=16384 /mnt/c > is *NOT* the same superblock as the previous two. s/as the previous two/as in the previous two cases/, that is - the first two examples yield one superblock, this one - another.