aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/pagelist.c
diff options
context:
space:
mode:
authorBenny Halevy <bhalevy@panasas.com>2011-05-25 14:03:56 -0400
committerBoaz Harrosh <bharrosh@panasas.com>2011-05-29 13:56:54 -0400
commit18ad0a9f2ccd260d37dd6bc5fa04c7819def4c84 (patch)
treea0936cf11e81969c0f84716ab958cd4728c87f54 /fs/nfs/pagelist.c
parentdfed206b8857d41a91ebba030f99e30017a44dda (diff)
NFSv4.1: change pg_test return type to bool
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Diffstat (limited to 'fs/nfs/pagelist.c')
-rw-r--r--fs/nfs/pagelist.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/fs/nfs/pagelist.c b/fs/nfs/pagelist.c
index b8704fedcd16..5344371a257c 100644
--- a/fs/nfs/pagelist.c
+++ b/fs/nfs/pagelist.c
@@ -244,29 +244,29 @@ void nfs_pageio_init(struct nfs_pageio_descriptor *desc,
244 * 244 *
245 * Return 'true' if this is the case, else return 'false'. 245 * Return 'true' if this is the case, else return 'false'.
246 */ 246 */
247static int nfs_can_coalesce_requests(struct nfs_page *prev, 247static bool nfs_can_coalesce_requests(struct nfs_page *prev,
248 struct nfs_page *req, 248 struct nfs_page *req,
249 struct nfs_pageio_descriptor *pgio) 249 struct nfs_pageio_descriptor *pgio)
250{ 250{
251 if (req->wb_context->cred != prev->wb_context->cred) 251 if (req->wb_context->cred != prev->wb_context->cred)
252 return 0; 252 return false;
253 if (req->wb_lock_context->lockowner != prev->wb_lock_context->lockowner) 253 if (req->wb_lock_context->lockowner != prev->wb_lock_context->lockowner)
254 return 0; 254 return false;
255 if (req->wb_context->state != prev->wb_context->state) 255 if (req->wb_context->state != prev->wb_context->state)
256 return 0; 256 return false;
257 if (req->wb_index != (prev->wb_index + 1)) 257 if (req->wb_index != (prev->wb_index + 1))
258 return 0; 258 return false;
259 if (req->wb_pgbase != 0) 259 if (req->wb_pgbase != 0)
260 return 0; 260 return false;
261 if (prev->wb_pgbase + prev->wb_bytes != PAGE_CACHE_SIZE) 261 if (prev->wb_pgbase + prev->wb_bytes != PAGE_CACHE_SIZE)
262 return 0; 262 return false;
263 /* 263 /*
264 * Non-whole file layouts need to check that req is inside of 264 * Non-whole file layouts need to check that req is inside of
265 * pgio->pg_lseg. 265 * pgio->pg_lseg.
266 */ 266 */
267 if (pgio->pg_test && !pgio->pg_test(pgio, prev, req)) 267 if (pgio->pg_test && !pgio->pg_test(pgio, prev, req))
268 return 0; 268 return false;
269 return 1; 269 return true;
270} 270}
271 271
272/** 272/**