[PATCH 02/32 V2] xfs: remove xfs_tosspages

Christoph Hellwig hch at infradead.org
Thu Nov 15 10:22:12 CST 2012


On Wed, Nov 14, 2012 at 05:42:47PM +1100, Dave Chinner wrote:
> xfs: remove xfs_tosspages
> 
> From: Dave Chinner <dchinner at redhat.com>
> 
> It's a buggy, unnecessary wrapper that is duplicating
> truncate_pagecache_range().
> 
> When replacing the call in xfs_change_file_space(), also ensure that
> the length being allocated/freed is always positive before making
> any changes. These checks are done in the lower extent manipulation
> functions, too, but we need to do them before any page cache
> operations.
> 
> Reported-by: Andrew Dahl <adahl at sgi.com>
> Signed-off-by: Dave Chinner <dchinner at redhat.com>

Looks good as long as Andrews fix is included.

I wonder if we should just fix the two places with checks for easy
backportability in a first patch and then have a second on top to
kill the useless wrapper?

Either way,

Reviewed-by: Christoph Hellwig <hch at lst.de>



More information about the xfs mailing list