Commit 11ba6b9c authored by Yan, Zheng's avatar Yan, Zheng Committed by Ilya Dryomov
Browse files

ceph: update i_requested_max_size only when sending cap msg to auth mds



Non-auth mds can't do anything to 'update max' cap message.

Signed-off-by: default avatar"Yan, Zheng" <zyan@redhat.com>
Reviewed-by: default avatarJeff Layton <jlayton@kernel.org>
Signed-off-by: default avatarIlya Dryomov <idryomov@gmail.com>
parent 135e671e
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1371,6 +1371,7 @@ static int __send_cap(struct ceph_mds_client *mdsc, struct ceph_cap *cap,
	arg.size = inode->i_size;
	ci->i_reported_size = arg.size;
	arg.max_size = ci->i_wanted_max_size;
	if (cap == ci->i_auth_cap)
		ci->i_requested_max_size = arg.max_size;

	if (flushing & CEPH_CAP_XATTR_EXCL) {