Received: by 10.223.164.221 with SMTP id h29csp1993514wrb; Wed, 25 Oct 2017 10:13:45 -0700 (PDT) X-Google-Smtp-Source: ABhQp+QemKOy44UW+wZkOwJ8Jf5WpyrH39ZJjVUjCoLYHKGOB7ntFI0me+dlbRV+YWJEMPX2xQ0N X-Received: by 10.99.178.77 with SMTP id t13mr2617472pgo.219.1508951625578; Wed, 25 Oct 2017 10:13:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1508951625; cv=none; d=google.com; s=arc-20160816; b=OaiZVuWGzy+Vcqzagk28CPNLsAWR++xi6xks76vfcBCbcqrE8E3+eslSs9HlC8zJpE GLxahIfC/GCBunNhh4yA5kV8jaYglnMqfRGik3FnwVJtr5xo6M6cmiGxuXKZYuuU1qvw qbhE8Ocmu7rc6zJIlqkpOLXwAq4C0awrbHyAyiaABWzjikvWG84T8efByTGiKGhho8bC UVIqladzByApgH57bjjtTuOEUs3kvsxfQVrainNVHrWbRIb6JRhmnaSEtkivxuu+D6Zu 51IQe5zQlOXESaDdZ4Lo/NYJLGOgWqrvBUmTGxXBpirQXP6eQocSgIkfisZ29ibBxZPz Gd9g== 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:mail-followup-to :message-id:subject:cc:to:from:date:arc-authentication-results; bh=bNbRm4jQo0qDpX2t+ty8AMxiqT095VHgULVP7HVE6+U=; b=ZrymkEmH6amF0xmm5CotZFQAcXyWzIqcgkkx7nwetVwVAtDN4iY4bbBp9ujozFCCU/ ineviMu9lDOSNWrH7afKi7dHnEOn60Auy8/P6qNAegeV5tNr2Zhj8x3FljDJ541RhODh NwiqXdJiuTAEML8lhF19Z/gpxzSUClehuQmRNdpShL7Gt+uWVMn0nFzTP9Gwdtg0aH/r NceELtDM/niOBrGG1KHuxNhA+VMk4YecoaxwPmwJAj/QAkg5TglBXEOeTq2qoA/OcCb6 /xievp+R7e7rK42zLlt9wdbNGHnCara9v+97gdMMJdCLXNOhf+YPaIwbc1q1qPt8t/aJ JX7w== 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 d15si1812997plj.822.2017.10.25.10.13.29; Wed, 25 Oct 2017 10:13:45 -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 S932287AbdJYRMh (ORCPT + 99 others); Wed, 25 Oct 2017 13:12:37 -0400 Received: from mga09.intel.com ([134.134.136.24]:48317 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932219AbdJYRM2 (ORCPT ); Wed, 25 Oct 2017 13:12:28 -0400 Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 25 Oct 2017 10:12:27 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.43,432,1503385200"; d="scan'208";a="1029313592" Received: from theros.lm.intel.com (HELO linux.intel.com) ([10.232.112.77]) by orsmga003.jf.intel.com with ESMTP; 25 Oct 2017 10:12:25 -0700 Date: Wed, 25 Oct 2017 11:12:24 -0600 From: Ross Zwisler To: Amir Goldstein Cc: Ross Zwisler , linux-kernel , Josef Bacik , Eryu Guan , fstests , Alasdair Kergon , Dan Williams , Dave Chinner , Jan Kara , Mike Snitzer , Shaohua Li , dm-devel@redhat.com, linux-nvdimm@lists.01.org, linux-raid@vger.kernel.org, linux-fsdevel , Ext4 , linux-xfs , Christoph Hellwig Subject: Re: [fstests PATCH v2] generic: add test for DAX MAP_SYNC support Message-ID: <20171025171224.GA12331@linux.intel.com> Mail-Followup-To: Ross Zwisler , Amir Goldstein , linux-kernel , Josef Bacik , Eryu Guan , fstests , Alasdair Kergon , Dan Williams , Dave Chinner , Jan Kara , Mike Snitzer , Shaohua Li , dm-devel@redhat.com, linux-nvdimm@lists.01.org, linux-raid@vger.kernel.org, linux-fsdevel , Ext4 , linux-xfs , Christoph Hellwig References: <20171020052943.15104-1-ross.zwisler@linux.intel.com> <20171020212556.30816-1-ross.zwisler@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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 Wed, Oct 25, 2017 at 03:19:22PM +0300, Amir Goldstein wrote: > On Sun, Oct 22, 2017 at 9:56 AM, Amir Goldstein wrote: > > On Sat, Oct 21, 2017 at 12:25 AM, Ross Zwisler > > wrote: > >> Add a test that exercises DAX's new MAP_SYNC flag. > >> > >> This test creates a file and writes to it via an mmap(), but never syncs > >> via fsync/msync. This process is tracked via dm-log-writes, then replayed. > >> > >> If MAP_SYNC is working the dm-log-writes replay will show the test file > >> with 1MiB of on-media block allocations. This is because each allocating > >> page fault included an implicit metadata sync. If MAP_SYNC isn't working > >> (which you can test by fiddling with the parameters to mmap()) the file > >> will be smaller or missing entirely. > >> > >> Note that dm-log-writes doesn't track the data that we write via the > >> mmap(), so we can't do any data integrity checking. We can only verify > >> that the metadata writes for the page faults happened. > >> > >> Signed-off-by: Ross Zwisler > >> > >> --- > >> > >> Changes since v1: > >> - Addressed review feedback from Amir. Thank you for the review! > > > > Looks good. > > > >> > >> --- > >> .gitignore | 1 + > >> common/dmlogwrites | 1 - > >> src/Makefile | 3 +- > >> src/t_map_sync.c | 92 +++++++++++++++++++++++++++++++++++++++++++++++++++ > >> tests/generic/466 | 76 ++++++++++++++++++++++++++++++++++++++++++ > >> tests/generic/466.out | 3 ++ > >> tests/generic/group | 1 + > >> 7 files changed, 175 insertions(+), 2 deletions(-) > >> create mode 100644 src/t_map_sync.c > >> create mode 100755 tests/generic/466 > >> create mode 100644 tests/generic/466.out > >> > >> diff --git a/.gitignore b/.gitignore > >> index 2014c08..9fc0695 100644 > >> --- a/.gitignore > >> +++ b/.gitignore > >> @@ -119,6 +119,7 @@ > >> /src/t_getcwd > >> /src/t_holes > >> /src/t_immutable > >> +/src/t_map_sync > >> /src/t_mmap_cow_race > >> /src/t_mmap_dio > >> /src/t_mmap_fallocate > >> diff --git a/common/dmlogwrites b/common/dmlogwrites > >> index 247c744..5b57df9 100644 > >> --- a/common/dmlogwrites > >> +++ b/common/dmlogwrites > >> @@ -23,7 +23,6 @@ _require_log_writes() > >> [ -z "$LOGWRITES_DEV" -o ! -b "$LOGWRITES_DEV" ] && \ > >> _notrun "This test requires a valid \$LOGWRITES_DEV" > >> > >> - _exclude_scratch_mount_option dax > > Wait. It this really ok to relax no dax from _require_log_writes()? > Shouldn't you check log-write target version or something to verify > that log-writes+dax is really supported? > I think you should. Ah, yep, that makes sense. I'll update for v3. From 1582232083595006868@xxx Wed Oct 25 12:21:40 +0000 2017 X-GM-THRID: 1581753232979805473 X-Gmail-Labels: Inbox,Category Forums