Browse Source

NFS: Run COMMIT as an asynchronous RPC call when wbc->for_background is set

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Acked-by: Peter Zijlstra <peterz@infradead.org>
Acked-by: Wu Fengguang <fengguang.wu@intel.com>
Trond Myklebust 15 years ago
parent
commit
5bad5abec4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      fs/nfs/write.c

+ 1 - 1
fs/nfs/write.c

@@ -1426,7 +1426,7 @@ static int nfs_commit_unstable_pages(struct inode *inode, struct writeback_contr
 	    nfsi->ncommit <= (nfsi->npages >> 1))
 		goto out_mark_dirty;
 
-	if (wbc->nonblocking)
+	if (wbc->nonblocking || wbc->for_background)
 		flags = 0;
 	ret = nfs_commit_inode(inode, flags);
 	if (ret >= 0) {