From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756124AbaBROaV (ORCPT ); Tue, 18 Feb 2014 09:30:21 -0500 Received: from imap.thunk.org ([74.207.234.97]:59535 "EHLO imap.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755505AbaBROaR (ORCPT ); Tue, 18 Feb 2014 09:30:17 -0500 Date: Tue, 18 Feb 2014 09:30:05 -0500 From: "Theodore Ts'o" To: Namjae Jeon Cc: =?utf-8?B?THVrw6HFoQ==?= Czerner , viro@zeniv.linux.org.uk, david@fromorbit.com, bpm@sgi.com, adilger.kernel@dilger.ca, jack@suse.cz, mtk.manpages@gmail.com, linux-fsdevel@vger.kernel.org, xfs@oss.sgi.com, linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org, Namjae Jeon , Ashish Sangwan Subject: Re: [PATCH RESEND 3/10] ext4: Add support FALLOC_FL_COLLAPSE_RANGE for fallocate Message-ID: <20140218143005.GO26580@thunk.org> Mail-Followup-To: Theodore Ts'o , Namjae Jeon , =?utf-8?B?THVrw6HFoQ==?= Czerner , viro@zeniv.linux.org.uk, david@fromorbit.com, bpm@sgi.com, adilger.kernel@dilger.ca, jack@suse.cz, mtk.manpages@gmail.com, linux-fsdevel@vger.kernel.org, xfs@oss.sgi.com, linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org, Namjae Jeon , Ashish Sangwan References: <1391319874-3203-1-git-send-email-linkinjeon@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@thunk.org X-SA-Exim-Scanned: No (on imap.thunk.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Namjae, Did you respond to Matthew Wilcox's comments/question from Feb. 2nd? > > What if the file is mmaped at the time somebody issues this command? > > Seems to me we should drop pagecache pages that overlap with the > > removed blocks. If the removed range is not a multiple of PAGE_SIZE, > > then we should also drop any pagecache pages after the removed range. > > Oops, forgot to add "and if it is a multiple of page size, then we need > to update the offsets of any pages after the removed page". Dave responded that XFS does the right thing when doing a punch hole operation, but it wasn't obvious to me whether FL_COLLAPSE_RANGE does the right thing with ext4. Thanks, - Ted