From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dave Chinner Subject: Re: [PATCH 5/8] xfs: add DAX file operations support Date: Thu, 16 Apr 2015 21:47:50 +1000 Message-ID: <20150416114750.GC21261@dastard> References: <1427194266-2885-1-git-send-email-david@fromorbit.com> <1427194266-2885-6-git-send-email-david@fromorbit.com> <552F81E6.4050700@plexistor.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: xfs@oss.sgi.com, linux-fsdevel@vger.kernel.org, willy@linux.intel.com, jack@suse.cz To: Boaz Harrosh Return-path: Received: from ipmail07.adl2.internode.on.net ([150.101.137.131]:43891 "EHLO ipmail07.adl2.internode.on.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753439AbbDPLsF (ORCPT ); Thu, 16 Apr 2015 07:48:05 -0400 Content-Disposition: inline In-Reply-To: <552F81E6.4050700@plexistor.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Thu, Apr 16, 2015 at 12:33:26PM +0300, Boaz Harrosh wrote: > On 03/24/2015 12:51 PM, Dave Chinner wrote: > <> > > diff --git a/fs/xfs/xfs_file.c b/fs/xfs/xfs_file.c > > index 94713c2..8017175 100644 > > --- a/fs/xfs/xfs_file.c > > +++ b/fs/xfs/xfs_file.c > > @@ -385,7 +385,11 @@ xfs_file_splice_read( > > > > trace_xfs_file_splice_read(ip, count, *ppos, ioflags); > > > > - ret = generic_file_splice_read(infilp, ppos, pipe, count, flags); > > + /* for dax, we need to avoid the page cache */ > > + if (IS_DAX(VFS_I(ip))) > > + ret = default_file_splice_read(infilp, ppos, pipe, count, flags); > > + else > > + ret = generic_file_splice_read(infilp, ppos, pipe, count, flags); > > Dave hi > > Linus has accepted this patch: > [be64f884be] dax: unify ext2/4_{dax,}_file_operations > > Which adds the same exact if(IS_DAX)) to generic_file_splice_read for use > by ext2/4. (It made things easier for both ext2/4) > > But also this code is just fine of course I'll leave it like this for the moment - I've missed the 4.1 merge window for this code so I'll fix it up when 4.1-rc1 is out and I can merge it pretty much straight away for the 4.2 cycle.... Cheers, Dave. -- Dave Chinner david@fromorbit.com