aboutsummaryrefslogtreecommitdiff
path: root/fs/nfs/fscache.c
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2009-12-22 17:21:47 -0700
committerDan Williams <dan.j.williams@intel.com>2009-12-22 17:21:47 -0700
commitf80ca163d65903276bec7045a484a79c0897eb2d (patch)
tree97c7d61d43248b9db0757a76af80ff58b98b5599 /fs/nfs/fscache.c
parent0794ec8ce327ec74416b569b8fb1951274693700 (diff)
parenta6d52d70677e99bdb89b6921c265d0a58c22e597 (diff)
Merge branch 'ioat' into fixes
Diffstat (limited to 'fs/nfs/fscache.c')
-rw-r--r--fs/nfs/fscache.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c
index 70fad69eb95..fa588006588 100644
--- a/fs/nfs/fscache.c
+++ b/fs/nfs/fscache.c
@@ -359,17 +359,13 @@ int nfs_fscache_release_page(struct page *page, gfp_t gfp)
BUG_ON(!cookie);
- if (fscache_check_page_write(cookie, page)) {
- if (!(gfp & __GFP_WAIT))
- return 0;
- fscache_wait_on_page_write(cookie, page);
- }
-
if (PageFsCache(page)) {
dfprintk(FSCACHE, "NFS: fscache releasepage (0x%p/0x%p/0x%p)\n",
cookie, page, nfsi);
- fscache_uncache_page(cookie, page);
+ if (!fscache_maybe_release_page(cookie, page, gfp))
+ return 0;
+
nfs_add_fscache_stats(page->mapping->host,
NFSIOS_FSCACHE_PAGES_UNCACHED, 1);
}