From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Thu, 31 May 2018 18:12:22 +0200 From: Christoph Hellwig To: Brian Foster Cc: Christoph Hellwig , linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, Dave Chinner Subject: Re: [PATCH 06/18] xfs: make xfs_writepage_map extent map centric Message-ID: <20180531161222.GC30465@lst.de> References: <20180530100013.31358-1-hch@lst.de> <20180530100013.31358-7-hch@lst.de> <20180530173955.GF112411@bfoster.bfoster> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180530173955.GF112411@bfoster.bfoster> Sender: owner-linux-mm@kvack.org List-ID: On Wed, May 30, 2018 at 01:39:56PM -0400, Brian Foster wrote: > What if the file is reflinked and the current page covers a non-shared > block but has an overlapping cow mapping due to cowextsize? The current > logic unconditionally uses the COW mapping for writeback. The updated > logic doesn't appear to do that in all cases. Consider if the current > imap was delalloc (and so not trimmed) or the cow mapping was introduced > after the current imap was mapped. This logic appears to prioritize the > current mapping so long as it is valid. Doesn't that break the > cowextsize hint? It does. I've fixed it for the next version.