Whamcloud - gitweb
LU-12589 llite: swab LOV EA data in ll_getxattr_lov() 26/35626/4
authorJian Yu <yujian@whamcloud.com>
Sat, 3 Aug 2019 06:58:34 +0000 (23:58 -0700)
committerOleg Drokin <green@whamcloud.com>
Wed, 21 Aug 2019 04:59:53 +0000 (04:59 +0000)
commit5590f5aa94a57a6553636e63d7897e1e2a885b03
tree73217edc26892b569c6b50ab0df1e6ccc9711796
parent96771280b330af07781326ff8811facd1ca39deb
LU-12589 llite: swab LOV EA data in ll_getxattr_lov()

On PPC client, the LOV EA data returned by getfattr from x86_64 server
was not swabbed to the host endian. While running setfattr, the data was
swabbed in ll_lov_setstripe_ea_info(), which caused magic mis-match in
ll_lov_user_md_size() and then ll_setstripe_ea() returned -ERANGE.

This patch fixed the above issue by swabbing LOV EA data in ll_getxattr_lov().

Test-Parameters: clientarch=ppc64 \
envdefinitions=ONLY="24D 102a" testlist=sanity

Change-Id: I8069df0c8f07c0bedba2e27db7c3a5553f11afb4
Signed-off-by: Jian Yu <yujian@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/35626
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Patrick Farrell <pfarrell@whamcloud.com>
lustre/include/lustre_swab.h
lustre/llite/dir.c
lustre/llite/file.c
lustre/llite/xattr.c
lustre/ptlrpc/pack_generic.c