summaryrefslogtreecommitdiff
path: root/fs/nfs
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@hammerspace.com>2022-08-01 14:16:51 -0400
committerTrond Myklebust <trond.myklebust@hammerspace.com>2022-08-02 16:03:12 -0400
commitb1a28f2eb9ea7a5a1763fe53fe699aa0feae4231 (patch)
tree7627c128af7d54cd5c8fc121e6c2bf05374eefca /fs/nfs
parent72691a269f0baad6d5f4aa7af97c29081b86d70f (diff)
NFS: nfs_async_write_reschedule_io must not recurse into the writeback code
It is not safe to call filemap_fdatawrite_range() from nfs_async_write_reschedule_io(), since we're often calling from a page reclaim context. Just let fsync() redrive the writeback for us. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'fs/nfs')
-rw-r--r--fs/nfs/write.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index 16d166bc4099..4adf2b488da1 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -1444,8 +1444,6 @@ static void nfs_async_write_error(struct list_head *head, int error)
static void nfs_async_write_reschedule_io(struct nfs_pgio_header *hdr)
{
nfs_async_write_error(&hdr->pages, 0);
- filemap_fdatawrite_range(hdr->inode->i_mapping, hdr->args.offset,
- hdr->args.offset + hdr->args.count - 1);
}
static const struct nfs_pgio_completion_ops nfs_async_write_completion_ops = {