aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/pagelist.c
diff options
context:
space:
mode:
authorFred Isaman <iisaman@netapp.com>2012-04-20 19:55:31 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2012-04-27 14:10:38 -0400
commit1825a0d08f22463e5a8f4b1636473efd057a3479 (patch)
treeb010b2bbb71431802cb1714483b69060ce09ff39 /fs/nfs/pagelist.c
parent9533da2979757258d3fd5429d830a297013d69ed (diff)
NFS: prepare coalesce testing for directio
The coalesce code made assumptions that will no longer be true once non-page aligned io occurs. This introduces no change in current behavior, but allows for more general situations to come. Signed-off-by: Fred Isaman <iisaman@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/pagelist.c')
-rw-r--r--fs/nfs/pagelist.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/nfs/pagelist.c b/fs/nfs/pagelist.c
index 5d01a1651084..638ca7f5a1e4 100644
--- a/fs/nfs/pagelist.c
+++ b/fs/nfs/pagelist.c
@@ -280,12 +280,12 @@ static bool nfs_can_coalesce_requests(struct nfs_page *prev,
280 return false; 280 return false;
281 if (req->wb_context->state != prev->wb_context->state) 281 if (req->wb_context->state != prev->wb_context->state)
282 return false; 282 return false;
283 if (req->wb_index != (prev->wb_index + 1))
284 return false;
285 if (req->wb_pgbase != 0) 283 if (req->wb_pgbase != 0)
286 return false; 284 return false;
287 if (prev->wb_pgbase + prev->wb_bytes != PAGE_CACHE_SIZE) 285 if (prev->wb_pgbase + prev->wb_bytes != PAGE_CACHE_SIZE)
288 return false; 286 return false;
287 if (req_offset(req) != req_offset(prev) + prev->wb_bytes)
288 return false;
289 return pgio->pg_ops->pg_test(pgio, prev, req); 289 return pgio->pg_ops->pg_test(pgio, prev, req);
290} 290}
291 291