os/chain_xattr: stripe shortish xattrs over small chunks for XFS
XFS has a hard limit of 255 (or 254?) bytes for xattrs to be inlined in the
inode due to a single byte for the length in the on-disk format. If we
have an xattr that is a bit bigger than that it will get kicked out into a
separate extent, but if we stripe it across a few shorter xattrs it can
be inlined when the xfs inode is e.g. 2K.
Adjust the chain_xattr logic to capture this case. Note that we are doing
this unconditionally regardless of fs type, but that is probably okay
given that most users use XFS and the cost isn't huge.
Reported-by: Ning Yao <yaoning@ruijie.com.cn> Signed-off-by: Sage Weil <sage@redhat.com>