Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp778287imm; Fri, 21 Sep 2018 08:09:41 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaAhaHYu82VgIEYIRYI11Cdisu1uJU40YZI5zQYWDSN9DxKaEV0F0GCCTceNYonVpN1NSlC X-Received: by 2002:a63:160d:: with SMTP id w13-v6mr2735685pgl.43.1537542581474; Fri, 21 Sep 2018 08:09:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537542581; cv=none; d=google.com; s=arc-20160816; b=imcKuqx5WpljxdmnHIigq/uwFBsaenKMnbk+LvJTApjEL3ROXHAj/8WaaBGGHl5BlD clhqF7ZLT5cFSamXgZQ0DWyZIzOn+/M079Bo2cQuimYP/GktmW/IOIbQVZi1pOi9e+4F yUJSe276MU9XBppy+ffOoigsd6rf0A0q5RdYVV2q+GVlRbxNyNr5Jz0K+YNkj4OaUUCP lrI18X5wKJZE79DjsmA0B19YtBQQ7Kz01YfHFW432exTi/M7pJQrhQ8wLbVF6Y+nD6iS RP5VA8sST6Fvlgt+Bo7l1IZHPpNCfhp2aqSVyxNm6+puIJmVAFq7LrspQle5sWbaUTjv 9Ncg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:content-id:mime-version :subject:cc:to:references:in-reply-to:from:organization; bh=/95vmq7SBxZ0zTMEhMC9TqW8IYWHpJyYm3hoAm+guYQ=; b=snbJsbAUvTRwKTgcPXSp+eql2fMUqNEa/JK0XIMD4U/uI/OldA9XD6Rp+c+93QKByz NxBH7zhoJtGiincJuZX+SJMfMwviYYI9OUeg/eiTfBgbnN0081/IjglVHdrs0ecTNYzA f39ttoFvFrthdX19Uu++vW1JEihiK8cq63wvvhH4SCNn0JojMe7FDLWEsNIa7eXtHLyN 3pK+x/7fqoeqVg1R1IZE6IhFlr7pcpzotgvcNfPngIZ+JluTAYh5oJb9Z9NIfPnJYOt9 6jo/BSjpR7QVI7aU8xconuZAyDV9YK1e8UeJ+ywedLzoOrxB7BaBOCaTxIuVTDMOwV1O MdZA== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u10-v6si26058675plr.58.2018.09.21.08.09.25; Fri, 21 Sep 2018 08:09:41 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390279AbeIUU5P (ORCPT + 99 others); Fri, 21 Sep 2018 16:57:15 -0400 Received: from mx1.redhat.com ([209.132.183.28]:13657 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728184AbeIUU5P (ORCPT ); Fri, 21 Sep 2018 16:57:15 -0400 Received: from smtp.corp.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.26]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id EFF7F3091D54; Fri, 21 Sep 2018 15:07:57 +0000 (UTC) Received: from warthog.procyon.org.uk (ovpn-123-84.rdu2.redhat.com [10.10.123.84]) by smtp.corp.redhat.com (Postfix) with ESMTP id AD2F230912F4; Fri, 21 Sep 2018 15:07:56 +0000 (UTC) Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20180920151214.15484-6-mszeredi@redhat.com> References: <20180920151214.15484-6-mszeredi@redhat.com> <20180920151214.15484-1-mszeredi@redhat.com> To: Miklos Szeredi Cc: dhowells@redhat.com, Al Viro , Christian Brauner , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 5/6] fsmount: do not use legacy MS_ flags MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <17156.1537542475.1@warthog.procyon.org.uk> Date: Fri, 21 Sep 2018 16:07:55 +0100 Message-ID: <17157.1537542475@warthog.procyon.org.uk> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.26 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.42]); Fri, 21 Sep 2018 15:07:58 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Miklos Szeredi wrote: > What happens if we introduce new flags for fsmount(2) and are already out > of flags for mount(2)? I see a big mess that way. > > So let's instead start a clean new set, to be used in the new API. If we must. But let's not call them just M_* please. Let's call them MOUNT_ATTR_* or something. > The MS_RELATIME flag was accepted but ignored. Simply leave this out of > the new set, since "relatime" is the default. Can we make RELATIME, STRICTATIME and NOATIME an enum rather than individual flags? #define MOUNT_ATTR_RDONLY 0x01 #define MOUNT_ATTR_NOSUID 0x02 #define MOUNT_ATTR_NODEV 0x04 #define MOUNT_ATTR_NOEXEC 0x08 #define MOUNT_ATTR_RELATIME 0x00 #define MOUNT_ATTR_NOATIME 0x10 #define MOUNT_ATTR_STRICTATIME 0x20 #define MOUNT_ATTR_ATIME_MASK 0x30 #define MOUNT_ATTR_NODIRATIME 0x40 We can also use these for a mount_setattr() syscall: mount_setattr(int dfd, const char *path, unsigned int atflags, unsigned int attr_values, unsigned int attr_mask); where atflags can potentially include AT_RECURSIVE. David