summaryrefslogtreecommitdiffstats
path: root/fs/ceph/mds_client.c
diff options
context:
space:
mode:
authorYan, Zheng <zyan@redhat.com>2014-11-14 14:29:55 +0100
committerIlya Dryomov <idryomov@redhat.com>2014-12-17 18:09:52 +0100
commitfb01d1f8b0343f1b19be878cee89d089f06e9f38 (patch)
treec2cb02b48b5cf4df6d5a4bb59be63f07c5409b0b /fs/ceph/mds_client.c
parentlibceph: specify position of extent operation (diff)
downloadlinux-fb01d1f8b0343f1b19be878cee89d089f06e9f38.tar.xz
linux-fb01d1f8b0343f1b19be878cee89d089f06e9f38.zip
ceph: parse inline data in MClientReply and MClientCaps
Signed-off-by: Yan, Zheng <zyan@redhat.com>
Diffstat (limited to 'fs/ceph/mds_client.c')
-rw-r--r--fs/ceph/mds_client.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c
index 387a48993d34..d2171f4a6980 100644
--- a/fs/ceph/mds_client.c
+++ b/fs/ceph/mds_client.c
@@ -89,6 +89,16 @@ static int parse_reply_info_in(void **p, void *end,
ceph_decode_need(p, end, info->xattr_len, bad);
info->xattr_data = *p;
*p += info->xattr_len;
+
+ if (features & CEPH_FEATURE_MDS_INLINE_DATA) {
+ ceph_decode_64_safe(p, end, info->inline_version, bad);
+ ceph_decode_32_safe(p, end, info->inline_len, bad);
+ ceph_decode_need(p, end, info->inline_len, bad);
+ info->inline_data = *p;
+ *p += info->inline_len;
+ } else
+ info->inline_version = CEPH_INLINE_NONE;
+
return 0;
bad:
return err;