Skip to content

Commit ae06706

Browse files
lxbszidryomov
authored andcommitted
ceph: rename unsafe_request_wait()
Rename it to flush_mdlog_and_wait_inode_unsafe_requests() to make it more descriptive. Signed-off-by: Xiubo Li <[email protected]> Reviewed-by: Jeff Layton <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
1 parent d9d58f0 commit ae06706

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

fs/ceph/caps.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2219,9 +2219,9 @@ static int caps_are_flushed(struct inode *inode, u64 flush_tid)
22192219
}
22202220

22212221
/*
2222-
* wait for any unsafe requests to complete.
2222+
* flush the mdlog and wait for any unsafe requests to complete.
22232223
*/
2224-
static int unsafe_request_wait(struct inode *inode)
2224+
static int flush_mdlog_and_wait_inode_unsafe_requests(struct inode *inode)
22252225
{
22262226
struct ceph_mds_client *mdsc = ceph_sb_to_client(inode->i_sb)->mdsc;
22272227
struct ceph_inode_info *ci = ceph_inode(inode);
@@ -2337,7 +2337,7 @@ static int unsafe_request_wait(struct inode *inode)
23372337
kfree(sessions);
23382338
}
23392339

2340-
dout("unsafe_request_wait %p wait on tid %llu %llu\n",
2340+
dout("%s %p wait on tid %llu %llu\n", __func__,
23412341
inode, req1 ? req1->r_tid : 0ULL, req2 ? req2->r_tid : 0ULL);
23422342
if (req1) {
23432343
ret = !wait_for_completion_timeout(&req1->r_safe_completion,
@@ -2381,7 +2381,7 @@ int ceph_fsync(struct file *file, loff_t start, loff_t end, int datasync)
23812381
dirty = try_flush_caps(inode, &flush_tid);
23822382
dout("fsync dirty caps are %s\n", ceph_cap_string(dirty));
23832383

2384-
err = unsafe_request_wait(inode);
2384+
err = flush_mdlog_and_wait_inode_unsafe_requests(inode);
23852385

23862386
/*
23872387
* only wait on non-file metadata writeback (the mds

0 commit comments

Comments
 (0)