summaryrefslogtreecommitdiffstats
path: root/fs/nfs/write.c
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2015-10-01 17:17:06 -0400
committerTrond Myklebust <trond.myklebust@primarydata.com>2015-12-31 15:55:35 -0500
commit138a2935dc9783b131d9647c3bddb22ae5c84d77 (patch)
treec21379e9e3c162c65ee5a6145e6081baaae1dfd6 /fs/nfs/write.c
parentb20135d0b2431900a3a5395970ffb7e4f3767c8b (diff)
NFS: Relax requirements in nfs_flush_incompatible
If two processes share the same credentials and NFSv4 open stateid, then allow them both to dirty the same page, even if their nfs_open_context differs. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/write.c')
-rw-r--r--fs/nfs/write.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index 0aa8d6f23b4c..2c26e04d9396 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -1130,7 +1130,8 @@ int nfs_flush_incompatible(struct file *file, struct page *page)
1130 if (req == NULL) 1130 if (req == NULL)
1131 return 0; 1131 return 0;
1132 l_ctx = req->wb_lock_context; 1132 l_ctx = req->wb_lock_context;
1133 do_flush = req->wb_page != page || req->wb_context != ctx; 1133 do_flush = req->wb_page != page ||
1134 !nfs_match_open_context(req->wb_context, ctx);
1134 /* for now, flush if more than 1 request in page_group */ 1135 /* for now, flush if more than 1 request in page_group */
1135 do_flush |= req->wb_this_page != req; 1136 do_flush |= req->wb_this_page != req;
1136 if (l_ctx && flctx && 1137 if (l_ctx && flctx &&