mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
ceph: new cap message flags indicate if there is pending capsnap
These flags tell mds if there is pending capsnap explicitly. Without this explicit notification, mds can only conclude if client has pending capsnap. The method mds use is inefficient and error-prone. Signed-off-by: "Yan, Zheng" <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
This commit is contained in:
parent
3fb99d483e
commit
95569713af
2 changed files with 7 additions and 2 deletions
|
|
@ -1248,7 +1248,10 @@ static int __send_cap(struct ceph_mds_client *mdsc, struct ceph_cap *cap,
|
|||
arg.mode = inode->i_mode;
|
||||
|
||||
arg.inline_data = ci->i_inline_version != CEPH_INLINE_NONE;
|
||||
arg.flags = 0;
|
||||
if (list_empty(&ci->i_cap_snaps))
|
||||
arg.flags = CEPH_CLIENT_CAPS_NO_CAPSNAP;
|
||||
else
|
||||
arg.flags = CEPH_CLIENT_CAPS_PENDING_CAPSNAP;
|
||||
if (sync)
|
||||
arg.flags |= CEPH_CLIENT_CAPS_SYNC;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue