xfs: log file size updates as part of unwritten extent conversion

If we convert and unwritten extent past the current i_size log the size update
as part of the extent manipulation transactions instead of doing an unlogged
metadata update later.

Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Mark Tinguely <tinguely@sgi.com>
Signed-off-by: Ben Myers <bpm@sgi.com>
This commit is contained in:
Christoph Hellwig
2012-02-29 09:53:50 +00:00
committed by Ben Myers
parent 6923e686f1
commit 84803fb782
2 changed files with 24 additions and 6 deletions

View File

@ -179,13 +179,14 @@ xfs_end_io(
ioend->io_error = -error;
goto done;
}
} else {
/*
* We might have to update the on-disk file size after
* extending writes.
*/
xfs_setfilesize(ioend);
}
/*
* We might have to update the on-disk file size after extending
* writes.
*/
xfs_setfilesize(ioend);
done:
xfs_destroy_ioend(ioend);
}