diff options
Diffstat (limited to 'fs/ceph/mds_client.c')
-rw-r--r-- | fs/ceph/mds_client.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c index 67a9aeb2f4ec..bd13a3267ae0 100644 --- a/fs/ceph/mds_client.c +++ b/fs/ceph/mds_client.c | |||
@@ -80,12 +80,8 @@ static int parse_reply_info_in(void **p, void *end, | |||
80 | info->symlink = *p; | 80 | info->symlink = *p; |
81 | *p += info->symlink_len; | 81 | *p += info->symlink_len; |
82 | 82 | ||
83 | if (features & CEPH_FEATURE_DIRLAYOUTHASH) | 83 | ceph_decode_copy_safe(p, end, &info->dir_layout, |
84 | ceph_decode_copy_safe(p, end, &info->dir_layout, | 84 | sizeof(info->dir_layout), bad); |
85 | sizeof(info->dir_layout), bad); | ||
86 | else | ||
87 | memset(&info->dir_layout, 0, sizeof(info->dir_layout)); | ||
88 | |||
89 | ceph_decode_32_safe(p, end, info->xattr_len, bad); | 85 | ceph_decode_32_safe(p, end, info->xattr_len, bad); |
90 | ceph_decode_need(p, end, info->xattr_len, bad); | 86 | ceph_decode_need(p, end, info->xattr_len, bad); |
91 | info->xattr_data = *p; | 87 | info->xattr_data = *p; |
@@ -3182,10 +3178,8 @@ static void send_mds_reconnect(struct ceph_mds_client *mdsc, | |||
3182 | recon_state.pagelist = pagelist; | 3178 | recon_state.pagelist = pagelist; |
3183 | if (session->s_con.peer_features & CEPH_FEATURE_MDSENC) | 3179 | if (session->s_con.peer_features & CEPH_FEATURE_MDSENC) |
3184 | recon_state.msg_version = 3; | 3180 | recon_state.msg_version = 3; |
3185 | else if (session->s_con.peer_features & CEPH_FEATURE_FLOCK) | ||
3186 | recon_state.msg_version = 2; | ||
3187 | else | 3181 | else |
3188 | recon_state.msg_version = 1; | 3182 | recon_state.msg_version = 2; |
3189 | err = iterate_session_caps(session, encode_caps_cb, &recon_state); | 3183 | err = iterate_session_caps(session, encode_caps_cb, &recon_state); |
3190 | if (err < 0) | 3184 | if (err < 0) |
3191 | goto fail; | 3185 | goto fail; |