summaryrefslogtreecommitdiffstats
path: root/fs/nfs/pagelist.c
diff options
context:
space:
mode:
authorWeston Andros Adamson2014-05-15 17:56:46 +0200
committerTrond Myklebust2014-05-29 17:11:45 +0200
commit67d0338edd71db9a4f406d8778f7c525d31e9f7f (patch)
treee0fdbb1461b833681f641d3f8263d8499f9d644c /fs/nfs/pagelist.c
parentnfs: add support for multiple nfs reqs per page (diff)
downloadkernel-qcow2-linux-67d0338edd71db9a4f406d8778f7c525d31e9f7f.tar.gz
kernel-qcow2-linux-67d0338edd71db9a4f406d8778f7c525d31e9f7f.tar.xz
kernel-qcow2-linux-67d0338edd71db9a4f406d8778f7c525d31e9f7f.zip
nfs: page group syncing in read path
Operations that modify state for a whole page must be syncronized across all requests within a page group. In the read path, this is calling unlock_page and SetPageUptodate. Both of these functions should not be called until all requests in a page group have reached the point where they would call them. This patch should have no effect yet since all page groups currently have one request, but will come into play when pg_test functions are modified to split pages into sub-page regions. Signed-off-by: Weston Andros Adamson <dros@primarydata.com> Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/pagelist.c')
-rw-r--r--fs/nfs/pagelist.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nfs/pagelist.c b/fs/nfs/pagelist.c
index 015fb7b48dfe..18ee4e99347e 100644
--- a/fs/nfs/pagelist.c
+++ b/fs/nfs/pagelist.c
@@ -395,6 +395,8 @@ static void nfs_free_request(struct nfs_page *req)
/* extra debug: make sure no sync bits are still set */
WARN_ON_ONCE(test_bit(PG_TEARDOWN, &req->wb_flags));
+ WARN_ON_ONCE(test_bit(PG_UNLOCKPAGE, &req->wb_flags));
+ WARN_ON_ONCE(test_bit(PG_UPTODATE, &req->wb_flags));
/* Release struct file and open context */
nfs_clear_request(req);