ext4: retry storing value in external inode with xattr block too
authorTahsin Erdogan <tahsin@google.com>
Thu, 22 Jun 2017 02:20:32 +0000 (22:20 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 22 Jun 2017 02:20:32 +0000 (22:20 -0400)
commitb347e2bcd18eba7ed44659d12e4a39a9b5bdc873
tree5f5494ed08c033e76266ace6196320e951ecfbeb
parentb3155298910c64a312620309f320d26e9461eb19
ext4: retry storing value in external inode with xattr block too

When value size is <= EXT4_XATTR_MIN_LARGE_EA_SIZE(), and it
doesn't fit in either inline or xattr block, a second try is made to
store it in an external inode while storing the entry itself in inline
area. There should also be an attempt to store the entry in xattr block.

This patch adds a retry loop to do that. It also makes the caller the
sole decider on whether to store a value in an external inode.

Signed-off-by: Tahsin Erdogan <tahsin@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/xattr.c