* [PATCH] nfs_updatepage must not extend the write
@ 2008-03-10 6:07 Jiang Guiqing
0 siblings, 0 replies; only message in thread
From: Jiang Guiqing @ 2008-03-10 6:07 UTC (permalink / raw)
To: nfs, linux-nfs, nfsv4
hi,all
I think, when mounting nfs with sync option, nfs_updatepage must not
extend the write to cover the entire page.
Signed-off-by: Jiang Guiqing <jianggq@cn.fujitsu.com>
---
linux-2.6.25-rc4/fs/nfs/write.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/linux-2.6.25-rc4/fs/nfs/write.c b/linux-2.6.25-rc4/fs/nfs/write.c
index 80c61fd..94d6aaf 100644
--- a/linux-2.6.25-rc4/fs/nfs/write.c
+++ b/linux-2.6.25-rc4/fs/nfs/write.c
@@ -734,7 +734,8 @@ int nfs_updatepage(struct file *file, struct page *page,
*/
if (nfs_write_pageuptodate(page, inode) &&
inode->i_flock == NULL &&
- !(file->f_flags & O_SYNC)) {
+ !(file->f_flags & O_SYNC) &&
+ !(IS_SYNC(inode))) {
count = max(count + offset, nfs_page_length(page));
offset = 0;
}
--
1.5.3.8
Thanks.
-Jiang Guiqing
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2008-03-10 6:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-10 6:07 [PATCH] nfs_updatepage must not extend the write Jiang Guiqing
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox