Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 308590
b: refs/heads/master
c: 14546c3
h: refs/heads/master
v: v3
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed May 8, 2012
1 parent f2b168c commit 1ff146a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1385b8117325e79f74c1e7d1cbf45c789deb85c5
refs/heads/master: 14546c337588370dced50dcaf43398939be9829e
7 changes: 7 additions & 0 deletions trunk/fs/nfs/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,13 @@ nfs_file_flush(struct file *file, fl_owner_t id)
if ((file->f_mode & FMODE_WRITE) == 0)
return 0;

/*
* If we're holding a write delegation, then just start the i/o
* but don't wait for completion (or send a commit).
*/
if (nfs_have_delegation(inode, FMODE_WRITE))
return filemap_fdatawrite(file->f_mapping);

/* Flush writes to the server and return any errors */
return vfs_fsync(file, 0);
}
Expand Down

0 comments on commit 1ff146a

Please sign in to comment.