Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp5639293ybg; Tue, 22 Oct 2019 06:20:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqySHsKGjZDg/GoZjsn234hBw77zNArJzwTws4TlJgAd2l1dz8iJGwuUvlxpCaZz/x5WEPvp X-Received: by 2002:a50:f699:: with SMTP id d25mr16764160edn.72.1571750441758; Tue, 22 Oct 2019 06:20:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571750441; cv=none; d=google.com; s=arc-20160816; b=c3IW4v6zaxIaT+q0fy3SzmKW6Onyoc8BeQ6yBfE5mUBoKGBu0QvQYKVJpMhHownuEK elBguvXvfTY37tq7f16Emnrk3F/KaCeOOQS4bTqDoo81/Njfmk/UI7/FXH+ZdjNKYkyf t2d5EY6CxQ2u74911qF3P5tuU3nzjJzb4L+PksKeA1T6ciSHNuugdlYAbI3W0RDuKb1/ yJFl21J9BP5YckDW94436xG6R+dX673Wl/3Q635eayXz/8vev7ed3UI/tblje6miGgvm w+PiZxR75yAQLr+p5p5Fy1uV9YBsHg/7CFFpOLIPWCAPTDLeYEZWHq9yXCz23h5GLbfT vEiQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=hkPjYtxu0G68TNOL7v3J1p13GtJ9bbjz9PgUJHvGUO4=; b=Z6vD3gfgCfCBKRsBCh+5TJrZ0wKdFj+T4OcNiR4DoKck6o/cypq40PPYzyC1atXT+M LanhF2GqvCoWT5Yl1KdFE8PNXp+I2SRkDKRi/aMBYHMw+eWn4hfyL2BSR4eflXDyPyvZ vZZcMU8gqz+gFVcSzpk3B8Wvm8uCe2uK/nEBM3FgKLc7YKXYWMnF1aIKHEEJYYr7fO/i Azqgk3g0tZoeFiFP7O5QSiw4oVMiF4ceDuo4iM/mimwQleoBSV9FqydS16e4YyWyrywf /sDeeIcGqkfRkVz5spR4dLEKVUuMQXj4XP5nI7heVCERX9gmcelSUgzaFMzT7wWspt0K InMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@plexistor-com.20150623.gappssmtp.com header.s=20150623 header.b="NY/Vg+KY"; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-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 fx11si5033374ejb.302.2019.10.22.06.19.50; Tue, 22 Oct 2019 06:20:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@plexistor-com.20150623.gappssmtp.com header.s=20150623 header.b="NY/Vg+KY"; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387998AbfJVLVW (ORCPT + 99 others); Tue, 22 Oct 2019 07:21:22 -0400 Received: from mail-ed1-f67.google.com ([209.85.208.67]:40899 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387776AbfJVLVW (ORCPT ); Tue, 22 Oct 2019 07:21:22 -0400 Received: by mail-ed1-f67.google.com with SMTP id p59so4160484edp.7 for ; Tue, 22 Oct 2019 04:21:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=plexistor-com.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=hkPjYtxu0G68TNOL7v3J1p13GtJ9bbjz9PgUJHvGUO4=; b=NY/Vg+KYkfRz80jxUYpA7t8Pxm2pGBYJ+h3r9wYIIS9WTnYFDXAjUzhM7N78ek5F9C r+L+12vJiHo+PxQ82cmaBgOJ/yw90xHGpO3E/d1R8cdSmLS6Yahs+PXzpAuGzRBVsxK0 vVyBefcjZfG2X6pLWNK7Nwn0zpyX2pIy/kqKQ30ad7Q13i7lmWZysLFyuUJr8CYGtBZZ pD6hzp4Zj64Usi8SQFo0A0wCk2GQMYBUBurH4YTO2khbUC78TgpcrMLnyeIturUEx/bF pMEbQwbm9AJOtx6+JoIjFQCQYvqOi5Xft8n5yxfj7F7VjRbYykLjhXNarDhLy1Zj//i/ MQzA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=hkPjYtxu0G68TNOL7v3J1p13GtJ9bbjz9PgUJHvGUO4=; b=tak1TrJST9dAnMCE0/HHFtfrC8M4Fq1/G1SmNFJ7UVlLOsKMvWmRanE5eEJJcIXkwH XWnlp8YhwEUgG+WKZGc5WEUquKsjKJy9s+gDOI53w7N+Q+LzhKna569fjtLP4AHBLEAF uztC0wDQYyjLLdLVVXWFY8xHJV5u4AzmMHNLhiaKcGTB3AsmojXRb5U8g9APFV3W2h9B vP/wzQqqwaxGZfKCIDyDuVNCa61cPjlluRg8hLZomkipjYxoROseN9PniKtD8pF+m62e Icl1O42T2q5rbiLLvynKt1bObPUH2lg7Qv+ByGnRbV+C+4uUlr6WfIkxugaquOcjemNa WlEw== X-Gm-Message-State: APjAAAWFba+ClNJImQffuKqjngVrOidwCYOA9VmP4tYmvdm1gMYjLOVq JoYfMxhsJTrURX44UzLjRNxqVw== X-Received: by 2002:a17:906:bfcb:: with SMTP id us11mr26657460ejb.299.1571743279644; Tue, 22 Oct 2019 04:21:19 -0700 (PDT) Received: from [10.68.217.182] ([217.70.210.43]) by smtp.googlemail.com with ESMTPSA id gl4sm114537ejb.6.2019.10.22.04.21.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 22 Oct 2019 04:21:18 -0700 (PDT) Subject: Re: [PATCH 0/5] Enable per-file/directory DAX operations To: ira.weiny@intel.com, linux-kernel@vger.kernel.org Cc: Alexander Viro , "Darrick J. Wong" , Dan Williams , Dave Chinner , Christoph Hellwig , "Theodore Y. Ts'o" , Jan Kara , linux-ext4@vger.kernel.org, linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org References: <20191020155935.12297-1-ira.weiny@intel.com> From: Boaz Harrosh Message-ID: Date: Tue, 22 Oct 2019 14:21:16 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.0 MIME-Version: 1.0 In-Reply-To: <20191020155935.12297-1-ira.weiny@intel.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On 20/10/2019 18:59, ira.weiny@intel.com wrote: > From: Ira Weiny > > At LSF/MM'19 [1] [2] we discussed applications that overestimate memory > consumption due to their inability to detect whether the kernel will > instantiate page cache for a file, and cases where a global dax enable via a > mount option is too coarse. > > The following patch series enables selecting the use of DAX on individual files > and/or directories on xfs, and lays some groundwork to do so in ext4. In this > scheme the dax mount option can be omitted to allow the per-file property to > take effect. > > The insight at LSF/MM was to separate the per-mount or per-file "physical" > capability switch from an "effective" attribute for the file. > > At LSF/MM we discussed the difficulties of switching the mode of a file with > active mappings / page cache. Rather than solve those races the decision was to > just limit mode flips to 0-length files. > What I understand above is that only "writers" before writing any bytes may turn the flag on, which then persists. But as a very long time user of DAX, usually it is the writers that are least interesting. With lots of DAX technologies and emulations the write is slower and needs slow "flushing". The more interesting and performance gains comes from DAX READs actually. specially cross the VM guest. (IE. All VMs share host memory or pmem) This fixture as I understand it, that I need to know before I write if I will want DAX or not and then the write is DAX as well as reads after that, looks not very interesting for me as a user. Just my $0.17 Boaz > Finally, the physical DAX flag inheritance is maintained from previous work on > XFS but should be added for other file systems for consistence. > > > [1] https://lwn.net/Articles/787973/ > [2] https://lwn.net/Articles/787233/ > > To: linux-kernel@vger.kernel.org > Cc: Alexander Viro > Cc: "Darrick J. Wong" > Cc: Dan Williams > Cc: Dave Chinner > Cc: Christoph Hellwig > Cc: "Theodore Y. Ts'o" > Cc: Jan Kara > Cc: linux-ext4@vger.kernel.org > Cc: linux-xfs@vger.kernel.org > Cc: linux-fsdevel@vger.kernel.org > > Ira Weiny (5): > fs/stat: Define DAX statx attribute > fs/xfs: Isolate the physical DAX flag from effective > fs/xfs: Separate functionality of xfs_inode_supports_dax() > fs/xfs: Clean up DAX support check > fs/xfs: Allow toggle of physical DAX flag > > fs/stat.c | 3 +++ > fs/xfs/xfs_ioctl.c | 32 ++++++++++++++------------------ > fs/xfs/xfs_iops.c | 36 ++++++++++++++++++++++++++++++------ > fs/xfs/xfs_iops.h | 2 ++ > include/uapi/linux/stat.h | 1 + > 5 files changed, 50 insertions(+), 24 deletions(-) >