From: Christoph Hellwig Subject: Re: [PATCH] fs, dax: unify IOMAP_F_DIRTY read vs write handling policy in the dax core Date: Mon, 13 Nov 2017 21:59:24 -0800 Message-ID: <20171114055924.GA15810@infradead.org> References: <151062258598.8554.8157038002895095232.stgit@dwillia2-desk3.amr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: Jan Kara , "Darrick J. Wong" , linux-nvdimm-hn68Rpc1hR1g9hUCZPvPmw@public.gmane.org, Dave Chinner , linux-xfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Christoph Hellwig To: Dan Williams Return-path: Content-Disposition: inline In-Reply-To: <151062258598.8554.8157038002895095232.stgit-p8uTFz9XbKj2zm6wflaqv1nYeNYlB/vhral2JQCrhuEAvxtiuMwx3w@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linux-nvdimm-bounces-hn68Rpc1hR1g9hUCZPvPmw@public.gmane.org Sender: "Linux-nvdimm" List-Id: linux-ext4.vger.kernel.org > - if ((flags & IOMAP_WRITE) && xfs_ipincount(ip) && > - (ip->i_itemp->ili_fsync_fields & ~XFS_ILOG_TIMESTAMP)) > - iomap->flags |= IOMAP_F_DIRTY; > + if (xfs_ipincount(ip)) > + if (ip->i_itemp->ili_fsync_fields & ~XFS_ILOG_TIMESTAMP) > + iomap->flags |= IOMAP_F_DIRTY; Please don't split up the conditional and make it harder to read. With that fixed up this looks fine to me: Reviewed-by: Christoph Hellwig