summaryrefslogtreecommitdiffstats
path: root/fs/nfs/write.c
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2011-05-11 18:00:51 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2011-05-11 22:52:13 -0400
commita75b9df9d3bfc3cd1083974c045ae31ce5f3434f (patch)
tree039cc65774c895d704f23a2c89b7f1bcd736e0b9 /fs/nfs/write.c
parent2887fe45522843149ccf72e01f43813be4fb36c5 (diff)
downloadop-kernel-dev-a75b9df9d3bfc3cd1083974c045ae31ce5f3434f.zip
op-kernel-dev-a75b9df9d3bfc3cd1083974c045ae31ce5f3434f.tar.gz
NFSv4.1: Ensure that layoutget uses the correct gfp modes
Currently, writebacks may end up recursing back into the filesystem due to GFP_KERNEL direct reclaims in the pnfs subsystem. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/write.c')
-rw-r--r--fs/nfs/write.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index 3bd5d7e..49c715b 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -939,7 +939,7 @@ static int nfs_flush_multi(struct nfs_pageio_descriptor *desc)
atomic_set(&req->wb_complete, requests);
BUG_ON(desc->pg_lseg);
- lseg = pnfs_update_layout(desc->pg_inode, req->wb_context, IOMODE_RW);
+ lseg = pnfs_update_layout(desc->pg_inode, req->wb_context, IOMODE_RW, GFP_NOFS);
ClearPageError(page);
offset = 0;
nbytes = desc->pg_count;
@@ -1013,7 +1013,7 @@ static int nfs_flush_one(struct nfs_pageio_descriptor *desc)
}
req = nfs_list_entry(data->pages.next);
if ((!lseg) && list_is_singular(&data->pages))
- lseg = pnfs_update_layout(desc->pg_inode, req->wb_context, IOMODE_RW);
+ lseg = pnfs_update_layout(desc->pg_inode, req->wb_context, IOMODE_RW, GFP_NOFS);
if ((desc->pg_ioflags & FLUSH_COND_STABLE) &&
(desc->pg_moreio || NFS_I(desc->pg_inode)->ncommit))
OpenPOWER on IntegriCloud