提交 0840d8af 编写于 作者: S Sage Weil

ceph: invalidate pages even if truncate is pending

There is no reason not to invalidate pages when a truncate is pending.
Both throw out page cache pages.
Signed-off-by: NSage Weil <sage@newdream.net>
上级 3c6f6b79
......@@ -1444,7 +1444,6 @@ void ceph_check_caps(struct ceph_inode_info *ci, int flags,
ci->i_rdcache_gen && /* may have cached pages */
(file_wanted == 0 || /* no open files */
(revoking & CEPH_CAP_FILE_CACHE)) && /* or revoking cache */
!ci->i_truncate_pending &&
!tried_invalidate) {
u32 invalidating_gen = ci->i_rdcache_gen;
int ret;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册