aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/write.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nfs/write.c')
-rw-r--r--fs/nfs/write.c21
1 files changed, 1 insertions, 20 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index fab214a4bcb..f983c51e05a 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -79,7 +79,6 @@ static struct nfs_page * nfs_update_request(struct nfs_open_context*,
79 unsigned int, unsigned int); 79 unsigned int, unsigned int);
80static void nfs_mark_request_dirty(struct nfs_page *req); 80static void nfs_mark_request_dirty(struct nfs_page *req);
81static int nfs_wait_on_write_congestion(struct address_space *, int); 81static int nfs_wait_on_write_congestion(struct address_space *, int);
82static int nfs_wait_on_requests(struct inode *, unsigned long, unsigned int);
83static long nfs_flush_mapping(struct address_space *mapping, struct writeback_control *wbc, int how); 82static long nfs_flush_mapping(struct address_space *mapping, struct writeback_control *wbc, int how);
84static const struct rpc_call_ops nfs_write_partial_ops; 83static const struct rpc_call_ops nfs_write_partial_ops;
85static const struct rpc_call_ops nfs_write_full_ops; 84static const struct rpc_call_ops nfs_write_full_ops;
@@ -360,14 +359,7 @@ int nfs_writepages(struct address_space *mapping, struct writeback_control *wbc)
360 if (err < 0) 359 if (err < 0)
361 goto out; 360 goto out;
362 nfs_add_stats(inode, NFSIOS_WRITEPAGES, err); 361 nfs_add_stats(inode, NFSIOS_WRITEPAGES, err);
363 if (!wbc->nonblocking && wbc->sync_mode == WB_SYNC_ALL) { 362 err = 0;
364 err = nfs_wait_on_requests(inode, 0, 0);
365 if (err < 0)
366 goto out;
367 }
368 err = nfs_commit_inode(inode, wb_priority(wbc));
369 if (err > 0)
370 err = 0;
371out: 363out:
372 clear_bit(BDI_write_congested, &bdi->state); 364 clear_bit(BDI_write_congested, &bdi->state);
373 wake_up_all(&nfs_write_congestion); 365 wake_up_all(&nfs_write_congestion);
@@ -516,17 +508,6 @@ static int nfs_wait_on_requests_locked(struct inode *inode, unsigned long idx_st
516 return res; 508 return res;
517} 509}
518 510
519static int nfs_wait_on_requests(struct inode *inode, unsigned long idx_start, unsigned int npages)
520{
521 struct nfs_inode *nfsi = NFS_I(inode);
522 int ret;
523
524 spin_lock(&nfsi->req_lock);
525 ret = nfs_wait_on_requests_locked(inode, idx_start, npages);
526 spin_unlock(&nfsi->req_lock);
527 return ret;
528}
529
530static void nfs_cancel_dirty_list(struct list_head *head) 511static void nfs_cancel_dirty_list(struct list_head *head)
531{ 512{
532 struct nfs_page *req; 513 struct nfs_page *req;