Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2136533ybb; Sat, 4 Apr 2020 23:21:00 -0700 (PDT) X-Google-Smtp-Source: APiQypL89JdseN4DxU9p/OXtELV1VJj0YSV8kbMJXXjTvfG0szz1xcoNQQVVjKaG2D/mMEpZ1u0X X-Received: by 2002:a4a:9c8d:: with SMTP id z13mr13089246ooj.50.1586067660083; Sat, 04 Apr 2020 23:21:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586067660; cv=none; d=google.com; s=arc-20160816; b=EZZtOqMswN2MTtJjs2H+MYIBrKX4OuNTy/KfPQO0FZFT60h54FLNRqe6nEugM4+Oqe DiQEid+0VQrITr9CIroJsr0K/x/j0h6FgoDxWUIfjYVD9m4bSCUPCpK5aJqbSdBgWhvg gVzTWKa619D7ZYQEarstKGV6W3plO27YwHZlYeImAnLPeBfgAqXR9vm7rs97OSQ4Zyg1 3dljkD0x0edaoDlbYnKHkgcRl8PS19u/kVRtejGJQYowKNMFSDjpuxCayibrwINOMo1k bd7Ry7gt4qw/0UmDDIHILY0QGn5PXM53vQRmQAkeidsfI/yPHWrm8ODHLOLFhZszcw+t 1vzA== 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:ironport-sdr:ironport-sdr; bh=a98jrEXjlVf/TFFSzMUqyEHacbuoWOHAKYcTu5h+Fvo=; b=nQ5xkAe1coGa51iIByD/hbmT77FTLDGaZYwwZSib8v2wGMaBebIaMlw1t7mHk53JMz q2vF8poy8K5x6aI09KJ+rl85OZ65PT1zQWYFZCT7tVQJjfxot0Rg5eHEHarE2bGt7+ox 9FO8dUn/vwUEgOHnxyz3nVFC9WNi63hUIsW/fknP4MlkDC1w+q6Xk6mV27HEbKeNmjox sGaaigJQT2LC68z2Dq0Usbea9mtnx2Sx41sfRLWFRmay3VYAU8X3NR0JDa9SOcXmwsBK L+ys2ZjUwCPWFK5gzKqIKoLiiPRLJ+fQ1drgnKtpvBdOCqHFb4OZU+Uvwj0qmwRoVyxN PcgA== 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=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p204si6259978oib.241.2020.04.04.23.20.45; Sat, 04 Apr 2020 23:21:00 -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=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726397AbgDEGTs (ORCPT + 99 others); Sun, 5 Apr 2020 02:19:48 -0400 Received: from mga17.intel.com ([192.55.52.151]:48527 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726310AbgDEGTs (ORCPT ); Sun, 5 Apr 2020 02:19:48 -0400 IronPort-SDR: 0JF/wGpFCelx3CgApolLUStyJsNdNVW979B04mnerw1lWq6BEC8nlYkVqDFCp9KIufPhX6tg3h hV5j6Xo/vMng== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Apr 2020 23:19:47 -0700 IronPort-SDR: 0110s7953263huErBoTRO4j83eC8Y3EFM92Atlg5RxKrkmln04D0YozOxKZzJHYAvkykohpDAn 6hdmIjIg2wtA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.72,346,1580803200"; d="scan'208";a="253776526" Received: from iweiny-desk2.sc.intel.com ([10.3.52.147]) by orsmga006.jf.intel.com with ESMTP; 04 Apr 2020 23:19:46 -0700 Date: Sat, 4 Apr 2020 23:19:46 -0700 From: Ira Weiny To: "Darrick J. Wong" Cc: Jan Kara , Christoph Hellwig , Dave Chinner , "Theodore Y. Ts'o" , Dan Williams , Linux Kernel Mailing List , Alexander Viro , linux-ext4 , linux-xfs , linux-fsdevel , Andrew Morton , Linus Torvalds Subject: Re: [PATCH V5 00/12] Enable per-file/per-directory DAX operations V5 Message-ID: <20200405061945.GA94792@iweiny-DESK2.sc.intel.com> References: <20200316095509.GA13788@lst.de> <20200401040021.GC56958@magnolia> <20200401102511.GC19466@quack2.suse.cz> <20200402085327.GA19109@lst.de> <20200402205518.GF3952565@iweiny-DESK2.sc.intel.com> <20200403072731.GA24176@lst.de> <20200403154828.GJ3952565@iweiny-DESK2.sc.intel.com> <20200403170338.GD29920@quack2.suse.cz> <20200403181843.GK3952565@iweiny-DESK2.sc.intel.com> <20200403183746.GQ80283@magnolia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200403183746.GQ80283@magnolia> User-Agent: Mutt/1.11.1 (2018-12-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > > > > In summary: > > > > - Applications must call statx to discover the current S_DAX state. > > Ok. > > > - There exists an advisory file inode flag FS_XFLAG_DAX that is set based on > > the parent directory FS_XFLAG_DAX inode flag. (There is no way to change > > this flag after file creation.) > > > > If FS_XFLAG_DAX is set and the fs is on pmem then it will enable S_DAX at > > inode load time; if FS_XFLAG_DAX is not set, it will not enable S_DAX. > > Unless overridden... > > Ok, fine with me. :) :-D > > > - There exists a dax= mount option. > > > > "-o dax=off" means "never set S_DAX, ignore FS_XFLAG_DAX" > > "-o nodax" means "dax=off" > > I surveyed the three fses that support dax and found that none of the > filesystems actually have a 'nodax' flag. Now would be the time not to > add such a thing, and make people specify dax=off instead. It would > be handy if we could have a single fsparam_enum for figuring out the dax > mount options. yes good point. I'm working on updating the documentation patch and I think this might also be better as: -o dax=never Which is the opposite of 'always'. > > > "-o dax=always" means "always set S_DAX (at least on pmem), ignore FS_XFLAG_DAX" > > "-o dax" by itself means "dax=always" > > "-o dax=iflag" means "follow FS_XFLAG_DAX" and is the default > > > > - There exists an advisory directory inode flag FS_XFLAG_DAX that can be > > changed at any time. The flag state is copied into any files or > > subdirectories when they are created within that directory. If programs > > require file access runs in S_DAX mode, they'll have to create those files > > "...they must create..." yes > > > inside a directory with FS_XFLAG_DAX set, or mount the fs with an > > appropriate dax mount option. > > Otherwise seems ok to me. Thanks! Ira