ceph: delete unreachable code in ceph_check_caps()

"revoking & (CEPH_CAP_FILE_CACHE|CEPH_CAP_FILE_LAZYIO)" has already
been tested before calling try_nonblocking_invalidate()

Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
This commit is contained in:
Yan, Zheng 2018-01-08 14:36:25 +08:00 committed by Ilya Dryomov
parent d84b37f9fa
commit ee612d954f

View File

@ -1793,18 +1793,9 @@ retry_locked:
!tried_invalidate) { !tried_invalidate) {
dout("check_caps trying to invalidate on %p\n", inode); dout("check_caps trying to invalidate on %p\n", inode);
if (try_nonblocking_invalidate(inode) < 0) { if (try_nonblocking_invalidate(inode) < 0) {
if (revoking & (CEPH_CAP_FILE_CACHE|
CEPH_CAP_FILE_LAZYIO)) {
dout("check_caps queuing invalidate\n"); dout("check_caps queuing invalidate\n");
queue_invalidate = true; queue_invalidate = true;
ci->i_rdcache_revoking = ci->i_rdcache_gen; ci->i_rdcache_revoking = ci->i_rdcache_gen;
} else {
dout("check_caps failed to invalidate pages\n");
/* we failed to invalidate pages. check these
caps again later. */
force_requeue = true;
__cap_set_timeouts(mdsc, ci);
}
} }
tried_invalidate = true; tried_invalidate = true;
goto retry_locked; goto retry_locked;