Skip to content

Commit 8692969

Browse files
jtlaytonidryomov
authored andcommitted
ceph: wait on async create before checking caps for syncfs
Currently, we'll call ceph_check_caps, but if we're still waiting on the reply, we'll end up spinning around on the same inode in flush_dirty_session_caps. Wait for the async create reply before flushing caps. Cc: [email protected] URL: https://tracker.ceph.com/issues/55823 Fixes: fbed704 ("ceph: wait for async create reply before sending any cap messages") Signed-off-by: Jeff Layton <[email protected]> Reviewed-by: Xiubo Li <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
1 parent 03c765b commit 8692969

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

fs/ceph/caps.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4377,6 +4377,7 @@ static void flush_dirty_session_caps(struct ceph_mds_session *s)
43774377
ihold(inode);
43784378
dout("flush_dirty_caps %llx.%llx\n", ceph_vinop(inode));
43794379
spin_unlock(&mdsc->cap_dirty_lock);
4380+
ceph_wait_on_async_create(inode);
43804381
ceph_check_caps(ci, CHECK_CAPS_FLUSH, NULL);
43814382
iput(inode);
43824383
spin_lock(&mdsc->cap_dirty_lock);

0 commit comments

Comments
 (0)