From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from imap.thunk.org ([74.207.234.97]:55322 "EHLO imap.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934857AbeFRXds (ORCPT ); Mon, 18 Jun 2018 19:33:48 -0400 Date: Mon, 18 Jun 2018 19:33:41 -0400 From: "Theodore Y. Ts'o" To: David Howells Cc: "Eric W. Biederman" , viro@zeniv.linux.org.uk, linux-fsdevel@vger.kernel.org, linux-afs@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 00/32] VFS: Introduce filesystem context [ver #8] Message-ID: <20180618233341.GA6931@thunk.org> References: <87in6kptqt.fsf@xmission.com> <152720672288.9073.9868393448836301272.stgit@warthog.procyon.org.uk> <3949.1529353850@warthog.procyon.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3949.1529353850@warthog.procyon.org.uk> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Mon, Jun 18, 2018 at 09:30:50PM +0100, David Howells wrote: > > The fscontext code *requires* you to parse the parameters *before* any attempt > to access the superblock is made. Note that this will actually be a problem > for, say, ext4 which passes a text string stored in the superblock through the > parser *before* parsing the mount syscall data. Fun. > > I'm intending to deal with that particular case by having ext4 create multiple > private contexts, one filled in from the user data, and then a second one > filled in from the superblock string. These can then be validated one against > the other before the super_block struct is published. Yeah, what we're trying to do is let the options in the superblock act as defaults which then can be overridden by what the user specifies on the command line. So when you parse the user-supplied data, will there be a way to determine what was specified explicitly, versus what was implied by the defaults? I'll need that in order to be able to merge the two contexts together. - Ted