]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit - libxfs/xfs_bmap.h
xfs: remove local fork format handling from xfs_bmapi_write()
authorDave Chinner <dchinner@redhat.com>
Wed, 4 Sep 2013 22:05:18 +0000 (22:05 +0000)
committerRich Johnston <rjohnston@sgi.com>
Mon, 16 Sep 2013 20:14:41 +0000 (15:14 -0500)
commit3f17ed4b3e1bd4df38ed598a158c18cbc4170358
treefcb87667fb1bc5b4943b211871322bc2433b63cd
parent6bddecbc4d2f6015151ca4568cfcb7ee9fb4683a
xfs: remove local fork format handling from xfs_bmapi_write()

The conversion from local format to extent format requires
interpretation of the data in the fork being converted, so it cannot
be done in a generic way. It is up to the caller to convert the fork
format to extent format before calling into xfs_bmapi_write() so
format conversion can be done correctly.

The code in xfs_bmapi_write() to convert the format is used
implicitly by the attribute and directory code, but they
specifically zero the fork size so that the conversion does not do
any allocation or manipulation. Move this conversion into the
shortform to leaf functions for the dir/attr code so the conversions
are explicitly controlled by all callers.

Now we can remove the conversion code in xfs_bmapi_write.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Review-by: Mark Tinguely <tinguely@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
include/xfs_bmap.h
libxfs/xfs_attr_leaf.c
libxfs/xfs_bmap.c
libxfs/xfs_dir2_block.c