aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/file.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/file.c')
-rw-r--r--fs/cifs/file.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/cifs/file.c b/fs/cifs/file.c
index 5f1f7682256b..d53d6308bf3a 100644
--- a/fs/cifs/file.c
+++ b/fs/cifs/file.c
@@ -2306,12 +2306,10 @@ cifs_oplock_break(struct slow_work *work)
2306 int rc, waitrc = 0; 2306 int rc, waitrc = 0;
2307 2307
2308 if (inode && S_ISREG(inode->i_mode)) { 2308 if (inode && S_ISREG(inode->i_mode)) {
2309#ifdef CONFIG_CIFS_EXPERIMENTAL 2309 if (cinode->clientCanCacheRead)
2310 if (cinode->clientCanCacheAll == 0)
2311 break_lease(inode, O_RDONLY); 2310 break_lease(inode, O_RDONLY);
2312 else if (cinode->clientCanCacheRead == 0) 2311 else
2313 break_lease(inode, O_WRONLY); 2312 break_lease(inode, O_WRONLY);
2314#endif
2315 rc = filemap_fdatawrite(inode->i_mapping); 2313 rc = filemap_fdatawrite(inode->i_mapping);
2316 if (cinode->clientCanCacheRead == 0) { 2314 if (cinode->clientCanCacheRead == 0) {
2317 waitrc = filemap_fdatawait(inode->i_mapping); 2315 waitrc = filemap_fdatawait(inode->i_mapping);