bus errors on nfs writes in latest git
Subsystems (14)
My regular connecthon tests are reporting bus errors on the "write/read 30 MB file" on recent upstream kernels. I'm travelling and haven't had a chance to do anything beyond kick off a dumb git-bisect, which pointed the blame at the following commit. Any ideas?
--b.
commit c2ec175c39f62949438354f603f4aa170846aabb
Author: Nick Piggin <[email protected]> Date: Tue Mar 31 15:23:21 2009 -0700
mm: page_mkwrite change prototype to match fault
Change the page_mkwrite prototype to take a struct vm_fault, and return VM_FAULT_xxx flags. There should be no functional change.
This makes it possible to return much more detailed error information to the VM (and also can provide more information eg. virtual_address to the driver, which might be important in some special cases).
This is required for a subsequent fix. And will also make it easier to merge page_mkwrite() with fault() in future.
Documentation/filesystems/Locking +1 -1
@@ -505,7 +505,7 @@ prototypes: void (*open)(struct vm_area_struct*); void (*close)(struct vm_area_struct*); int (*fault)(struct vm_area_struct*, struct vm_fault *); - int (*page_mkwrite)(struct vm_area_struct *, struct page *); + int (*page_mkwrite)(struct vm_area_struct *, struct vm_fault *); int (*access)(struct vm_area_struct *, unsigned long, void*, int, int); locking rules:
drivers/video/fb_defio.c +2 -1
@@ -85,8 +85,9 @@ EXPORT_SYMBOL_GPL(fb_deferred_io_fsync);/* vm_ops->page_mkwrite handler */ static int fb_deferred_io_mkwrite (struct vm_area_struct *vma, -struct page *page) +struct vm_fault *vmf) { +struct page *page = vmf->page;struct fb_info *info = vma->vm_private_data;struct fb_deferred_io *fbdefio = info->fbdefio;struct page *cur;
fs/btrfs/ctree.h +1 -1
@@ -2060,7 +2060,7 @@ int btrfs_merge_bio_hook(struct page *page, unsigned long offset,unsigned long btrfs_force_ra (struct address_space *mapping,struct file_ra_state *ra,struct file *file,pgoff_t offset,pgoff_t last_index); -int btrfs_page_mkwrite (struct vm_area_struct *vma,struct page *page); +int btrfs_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf);int btrfs_readpage (struct file *file,struct page *page);void btrfs_delete_inode (struct inode *inode);void btrfs_put_inode (struct inode *inode);
fs/btrfs/inode.c +4 -1
@@ -4292,8 +4292,9 @@ static void btrfs_invalidatepage(struct page *page, unsigned long offset)* beyond EOF, then the page is guaranteed safe against truncation until we * unlock the page. */ -int btrfs_page_mkwrite (struct vm_area_struct *vma,struct page *page) +int btrfs_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;struct inode *inode =fdentry (vma->vm_file)->d_inode;struct btrfs_root *root =BTRFS_I (inode)->root;struct extent_io_tree *io_tree = &BTRFS_I (inode)->io_tree;
@@ -4362,6 +4363,8 @@ again: out_unlock:unlock_page (page); out: +if (ret) + ret =VM_FAULT_SIGBUS ;return ret; }
fs/buffer.c +5 -1
@@ -2313,9 +2313,10 @@ int block_commit_write(struct page *page, unsigned from, unsigned to)* unlock the page. */ int -block_page_mkwrite (struct vm_area_struct *vma,struct page *page, +block_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf,get_block_t get_block) { +struct page *page = vmf->page;struct inode *inode = vma->vm_file->f_path.dentry->d_inode;unsigned long end;loff_t size;
@@ -2340,6 +2341,9 @@ block_page_mkwrite(struct vm_area_struct *vma, struct page *page, ret =block_commit_write (page,0 , end); out_unlock: +if (ret) + ret =VM_FAULT_SIGBUS ; +unlock_page (page);return ret; }
fs/ext4/ext4.h +1 -1
@@ -1098,7 +1098,7 @@ extern int ext4_meta_trans_blocks(struct inode *, int nrblocks, int idxblocks);extern int ext4_chunk_trans_blocks (struct inode *,int nrblocks);extern int ext4_block_truncate_page (handle_t *handle,struct address_space *mapping,loff_t from); -extern int ext4_page_mkwrite (struct vm_area_struct *vma,struct page *page); +extern int ext4_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf);extern qsize_t ext4_get_reserved_space (struct inode *inode);/* ioctl.c */
fs/ext4/inode.c +4 -1
@@ -5146,8 +5146,9 @@ static int ext4_bh_unmapped(handle_t *handle, struct buffer_head *bh)return !buffer_mapped (bh); } -int ext4_page_mkwrite (struct vm_area_struct *vma,struct page *page) +int ext4_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;loff_t size;unsigned long len;int ret = -EINVAL ;
@@ -5199,6 +5200,8 @@ int ext4_page_mkwrite(struct vm_area_struct *vma, struct page *page) goto out_unlock; ret =0 ; out_unlock: +if (ret) + ret =VM_FAULT_SIGBUS ;up_read (&inode->i_alloc_sem);return ret; }
fs/fuse/file.c +2 -1
@@ -1234,8 +1234,9 @@ static void fuse_vma_close(struct vm_area_struct *vma)* - sync(2) * - try_to_free_pages() with order > PAGE_ALLOC_COSTLY_ORDER */ -static int fuse_page_mkwrite (struct vm_area_struct *vma,struct page *page) +static int fuse_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;/* * Don't use page->mapping as it may become NULL from a * concurrent truncate.
fs/gfs2/ops_file.c +4 -1
@@ -337,8 +337,9 @@ static int gfs2_allocate_page_backing(struct page *page)* blocks allocated on disk to back that page. */ -static int gfs2_page_mkwrite (struct vm_area_struct *vma,struct page *page) +static int gfs2_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;struct inode *inode = vma->vm_file->f_path.dentry->d_inode;struct gfs2_inode *ip =GFS2_I (inode);struct gfs2_sbd *sdp =GFS2_SB (inode);
@@ -412,6 +413,8 @@ out_unlock:gfs2_glock_dq (&gh); out:gfs2_holder_uninit (&gh); +if (ret) + ret =VM_FAULT_SIGBUS ;return ret; }
fs/nfs/file.c +4 -1
@@ -451,8 +451,9 @@ const struct address_space_operations nfs_file_aops = { .launder_page = nfs_launder_page, }; -static int nfs_vm_page_mkwrite (struct vm_area_struct *vma,struct page *page) +static int nfs_vm_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;struct file *filp = vma->vm_file;struct dentry *dentry = filp->f_path.dentry;unsigned pagelen;
@@ -483,6 +484,8 @@ static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct page *page) ret = pagelen; out_unlock:unlock_page (page); +if (ret) + ret =VM_FAULT_SIGBUS ;return ret; }
fs/ocfs2/mmap.c +4 -2
@@ -154,8 +154,9 @@ out:return ret; } -static int ocfs2_page_mkwrite (struct vm_area_struct *vma,struct page *page) +static int ocfs2_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;struct inode *inode = vma->vm_file->f_path.dentry->d_inode;struct buffer_head *di_bh =NULL ;sigset_t blocked, oldset;
@@ -196,7 +197,8 @@ out: ret2 =ocfs2_vm_op_unblock_sigs (&oldset);if (ret2 <0 )mlog_errno (ret2); - +if (ret) + ret =VM_FAULT_SIGBUS ;return ret; }
fs/ubifs/file.c +6 -3
@@ -1434,8 +1434,9 @@ static int ubifs_releasepage(struct page *page, gfp_t unused_gfp_flags)* mmap()d file has taken write protection fault and is being made * writable. UBIFS must ensure page is budgeted for. */ -static int ubifs_vm_page_mkwrite (struct vm_area_struct *vma,struct page *page) +static int ubifs_vm_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;struct inode *inode = vma->vm_file->f_path.dentry->d_inode;struct ubifs_info *c = inode->i_sb->s_fs_info;struct timespec now =ubifs_current_time (inode);
@@ -1447,7 +1448,7 @@ static int ubifs_vm_page_mkwrite(struct vm_area_struct *vma, struct page *page)ubifs_assert (!(inode->i_sb->s_flags &MS_RDONLY ));if (unlikely (c->ro_media)) -return -EROFS ; +return VM_FAULT_SIGBUS ;/* -EROFS */ /* * We have not locked @page so far so we may budget for changing the
@@ -1480,7 +1481,7 @@ static int ubifs_vm_page_mkwrite(struct vm_area_struct *vma, struct page *page)if (err == -ENOSPC )ubifs_warn ("out of space for mmapped file " "(inode number %lu)" , inode->i_ino); -return err; +return VM_FAULT_SIGBUS ; }lock_page (page);
@@ -1520,6 +1521,8 @@ static int ubifs_vm_page_mkwrite(struct vm_area_struct *vma, struct page *page) out_unlock:unlock_page (page);ubifs_release_budget (c, &req); +if (err) + err =VM_FAULT_SIGBUS ;return err; }
fs/xfs/linux-2.6/xfs_file.c +2 -2
@@ -234,9 +234,9 @@ xfs_file_mmap( STATIC intxfs_vm_page_mkwrite (struct vm_area_struct *vma, -struct page *page) +struct vm_fault *vmf) { -return block_page_mkwrite (vma, page, xfs_get_blocks); +return block_page_mkwrite (vma, vmf, xfs_get_blocks); }const struct file_operations xfs_file_operations = {
include/linux/buffer_head.h +1 -1
@@ -216,7 +216,7 @@ int cont_write_begin(struct file *, struct address_space *, loff_t, get_block_t *, loff_t *);int generic_cont_expand_simple (struct inode *inode,loff_t size);int block_commit_write (struct page *page,unsigned from,unsigned to); -int block_page_mkwrite (struct vm_area_struct *vma,struct page *page, +int block_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf,get_block_t get_block);void block_sync_page (struct page *);sector_t generic_block_bmap (struct address_space *,sector_t ,get_block_t *);
include/linux/mm.h +2 -1
@@ -135,6 +135,7 @@ extern pgprot_t protection_map[16];#define FAULT_FLAG_WRITE 0x01/* Fault was a write access */ #define FAULT_FLAG_NONLINEAR 0x02/* Fault was via a nonlinear mapping */ +#define FAULT_FLAG_MKWRITE 0x04/* Fault was mkwrite of existing pte */ /* * This interface is used by x86 PAT code to identify a pfn mapping that is
@@ -187,7 +188,7 @@ struct vm_operations_struct {/* notification that a previously read-only page is about to become * writable, if an error is returned it will cause a SIGBUS */ -int (*page_mkwrite)(struct vm_area_struct *vma,struct page *page); +int (*page_mkwrite)(struct vm_area_struct *vma,struct vm_fault *vmf);/* called by access_process_vm when get_user_pages() fails, typically * for use by special VMAs that can switch between memory and hardware
mm/memory.c +22 -4
@@ -1945,6 +1945,15 @@ static int do_wp_page(struct mm_struct *mm, struct vm_area_struct *vma,* get_user_pages(.write=1, .force=1). */ if (vma->vm_ops && vma->vm_ops->page_mkwrite) { +struct vm_fault vmf; +int tmp; + + vmf.virtual_address = (void __user *)(address & +PAGE_MASK ); + vmf.pgoff = old_page->index; + vmf.flags =FAULT_FLAG_WRITE |FAULT_FLAG_MKWRITE ; + vmf.page = old_page; +/* * Notify the address space that the page is about to * become writable so that it can prohibit this or wait
@@ -1956,8 +1965,12 @@ static int do_wp_page(struct mm_struct *mm, struct vm_area_struct *vma,page_cache_get (old_page);pte_unmap_unlock (page_table, ptl); -if (vma->vm_ops->page_mkwrite (vma, old_page) <0 ) + tmp = vma->vm_ops->page_mkwrite (vma, &vmf); +if (unlikely (tmp & + (VM_FAULT_ERROR |VM_FAULT_NOPAGE ))) { + ret = tmp; goto unwritable_page; + }/* * Since we dropped the lock we need to revalidate
@@ -2106,7 +2119,7 @@ oom: unwritable_page:page_cache_release (old_page); -return VM_FAULT_SIGBUS ; +return ret; }/*
@@ -2648,9 +2661,14 @@ static int __do_fault(struct mm_struct *mm, struct vm_area_struct *vma,* to become writable */ if (vma->vm_ops->page_mkwrite) { +int tmp; +unlock_page (page); -if (vma->vm_ops->page_mkwrite (vma, page) <0 ) { - ret =VM_FAULT_SIGBUS ; + vmf.flags |=FAULT_FLAG_MKWRITE ; + tmp = vma->vm_ops->page_mkwrite (vma, &vmf); +if (unlikely (tmp & + (VM_FAULT_ERROR |VM_FAULT_NOPAGE ))) { + ret = tmp; anon =1 ;/* no anon but release vmf.page */ goto out_unlocked; }
Quoted 35 lines · J. Bruce Fields
My regular connecthon tests are reporting bus errors on the "write/read 30 MB file" on recent upstream kernels. I'm travelling and haven't had a chance to do anything beyond kick off a dumb git-bisect, which pointed the blame at the following commit. Any ideas?
--b.
commit
c2ec175c39f62949438354f603f4aa170846aabbAuthor: Nick Piggin <[email protected]> Date: Tue Mar 31 15:23:21 2009 -0700mm:
page_mkwritechange prototype to match faultChange the
page_mkwriteprototype to take a structvm_fault, and returnVM_FAULT_xxxflags. There should be no functional change.This makes it possible to return much more detailed error information to the VM (and also can provide more information eg.
virtual_addressto the driver, which might be important in some special cases).This is required for a subsequent fix. And will also make it easier to merge
page_mkwrite()withfault()in future.Signed-off-by Nick Piggin <[email protected]>Cc Chris Mason <[email protected]>Cc Trond Myklebust <[email protected]>Cc Miklos Szeredi <[email protected]>Cc Steven Whitehouse <[email protected]>Cc Mark Fasheh <[email protected]>Cc Joel Becker <[email protected]>Cc Artem Bityutskiy <[email protected]>Cc Felix Blyakher <[email protected]>Signed-off-by Andrew Morton <[email protected]>Signed-off-by Linus Torvalds <[email protected]>
<snip>
Quoted 16 lines
fs/nfs/file.c +2
-1@@ -451,8 +451,9 @@ const struct address_space_operations nfs_file_aops = { .launder_page = nfs_launder_page, }; -static int nfs_vm_page_mkwrite (struct vm_area_struct *vma,struct page *page) +static int nfs_vm_page_mkwrite (struct vm_area_struct *vma,struct vm_fault *vmf) { +struct page *page = vmf->page;struct file *filp = vma->vm_file;struct dentry *dentry = filp->f_path.dentry;unsigned pagelen;
fs/nfs/file.c static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct page *page) · line 484
Quoted 1 line
fs/nfs/file.c +0
-0@@ -483,6 +484,8 @@ static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct page *page) ret = pagelen;
^^^^^^^^^^^^^^^^^^
This would explain it. I assume that we're actually supposed to return 0 in case of success.
Quoted 7 lines
fs/nfs/file.c +2
-0out_unlock:unlock_page (page); +if (ret) + ret =VM_FAULT_SIGBUS ;return ret; }
Signature · 6 lines
Trond Myklebust Linux NFS client maintainer NetApp [email protected] www.netapp.com
Quoted 5 lines · Trond Myklebust
Quoted 4 lines · J. Bruce Fields
My regular connecthon tests are reporting bus errors on the "write/read 30 MB file" on recent upstream kernels. I'm travelling and haven't had a chance to do anything beyond kick off a dumb git-bisect, which pointed the blame at the following commit. Any ideas?
The following patch should fix it.
Cheers
Trond
---------------------------------------------------------------
Quoted 1 line
From
b7a178f4fab331821b8cff384e1954e62aa63e52Mon Sep 17 00:00:00 2001
From: Trond Myklebust <[email protected]>
Date: Sat, 4 Apr 2009 12:22:57 -0400
Subject: [PATCH] NFS: Fix the return value in nfs_page_mkwrite()
Commit c2ec175c39f62949438354f603f4aa170846aabb (mm: page_mkwrite change prototype to match fault) exposed a bug in the NFS implementation of page_mkwrite. We should be returning 0 on success...
--- fs/nfs/file.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-)
fs/nfs/file.c +0 -2
@@ -516,8 +516,6 @@ static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf) goto out_unlock; ret =nfs_updatepage (filp, page,0 , pagelen); -if (ret ==0 ) - ret = pagelen; out_unlock:unlock_page (page);if (ret)
Signature · 10 lines
1.6.0.4 -- Trond Myklebust Linux NFS client maintainer NetApp [email protected] www.netapp.com
J. Bruce Fields
Tested-byQuoted 8 lines · Trond Myklebust
Quoted 5 lines · Trond Myklebust
Quoted 4 lines · J. Bruce Fields
My regular connecthon tests are reporting bus errors on the "write/read 30 MB file" on recent upstream kernels. I'm travelling and haven't had a chance to do anything beyond kick off a dumb git-bisect, which pointed the blame at the following commit. Any ideas?
The following patch should fix it.
Thanks--confirmed. For what it's worth:
--b.
Quoted 42 lines
Cheers
Trond
---------------------------------------------------------------Quoted 1 line
From
b7a178f4fab331821b8cff384e1954e62aa63e52Mon Sep 17 00:00:00 2001From: Trond Myklebust <[email protected]>
Date: Sat, 4 Apr 2009 12:22:57 -0400
Subject: [PATCH] NFS: Fix the return value innfs_page_mkwrite()Commit
c2ec175c39f62949438354f603f4aa170846aabb(mm:page_mkwritechange prototype to match fault) exposed a bug in the NFS implementation ofpage_mkwrite. We should be returning 0 on success...Signed-off-by Trond Myklebust <[email protected]>--- fs/nfs/file.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-)fs/nfs/file.c +0
-2@@ -516,8 +516,6 @@ static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf) goto out_unlock; ret =nfs_updatepage (filp, page,0 , pagelen); -if (ret ==0 ) - ret = pagelen; out_unlock:unlock_page (page);if (ret)Signature · 10 lines
1.6.0.4 -- Trond Myklebust Linux NFS client maintainer NetApp [email protected] www.netapp.com
Geert Uytterhoeven
Tested-byQuoted 4 lines · J. Bruce Fields
Quoted 3 lines · Trond Myklebust
Quoted 2 lines · Trond Myklebust
Quoted 1 line · J. Bruce Fields
My regular connecthon tests are reporting bus errors on the "wr=
ite/read
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
30 MB file" on recent upstream kernels. I'm travelling and hav=
en't had
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
a chance to do anything beyond kick off a dumb git-bisect, whic=
h pointed
Quoted 7 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line
the blame at the following commit. Any ideas?
=20
The following patch should fix it.=20
Thanks--confirmed. For what it's worth:
=20Tested-by J. Bruce Fields <[email protected]>
JFYI, I was also seeing bus errors and read() returning EFAULT with cur= rent
mainline on both PS3 (ppc64) and Sequoia (ppc32). So far I only saw it happening doing:
- apt-get update
- apt-get upgrade
- apt-get install
I tried bisecting it, but unfortunately it was not 100% reproducible. So far the oldest version where I saw it fail was 2.6.29-07100-g833bb30= =2E
It _looks_ like 2.6.29-06619-ge5824c9 is OK, but I'm not 100% sure.
At first I didn't think of NFS (I'm indeed using nfsroot), but when sea= rching
for `bus error' I noticed this thread.
Your patch seems to fix it (I added a printk so I would notice when the=
bad
case got triggered), and the commit that introduced the problem lies wi= thin
the works/fails range I discovered, so
Thanks!
With kind regards,
Geert Uytterhoeven
Software Architect
Sony Techsoft Centre Europe
The Corporate Village =B7 Da Vincilaan 7-D1 =B7 B-1935 Zaventem =B7 Bel= gium
Phone: +32 (0)2 700 8453
=46ax: +32 (0)2 700 8622
E-mail: [email protected] Internet: http://www.sony-europe.com/
A division of Sony Europe (Belgium) N.V. VAT BE 0413.825.160 =B7 RPR Brussels =46ortis =B7 BIC GEBABEBB =B7 IBAN BE41293037680010
Quoted 5 lines
Quoted 5 lines
=20
Cheers
Trond
---------------------------------------------------------------Quoted 1 line
From
b7a178f4fab331821b8cff384e1954e62aa63e52Mon Sep 17 00:00:00 =
2001
Quoted 5 lines
Quoted 5 lines
From: Trond Myklebust <[email protected]>
Date: Sat, 4 Apr 2009 12:22:57 -0400
Subject: [PATCH] NFS: Fix the return value innfs_page_mkwrite()=20
Commitc2ec175c39f62949438354f603f4aa170846aabb(mm:page_mkwritec=
hange
Quoted 1 line
Quoted 1 line
prototype to match fault) exposed a bug in the NFS implementation o=
f
Quoted 4 lines
Quoted 4 lines
page_mkwrite. We should be returning 0 on success... =20Signed-off-by Trond Myklebust <[email protected]>---
Quoted 8 lines
fs/nfs/file.c static int nfs_vm_page_mkwrite(struct vm_area_s=
Quoted 8 lines
fs/nfs/file.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-)=20
fs/nfs/file.c +0
-0@@ -516,8 +516,6 @@ static int nfs_vm_page_mkwrite(struct vm_area_s=
truct *vma, struct vm_fault *vmf)
Quoted 13 lines
Quoted 13 lines
fs/nfs/file.c +0
-0goto out_unlock;=20
fs/nfs/file.c +0
-3ret =3D nfs_updatepage(filp, page, 0, pagelen); - if (ret =3D=3D 0) - ret =3D pagelen; out_unlock:unlock_page (page);if (ret) --=201.6.0.4
=20
=20
--=20
Quoted 8 lines
Quoted 6 lines
Trond Myklebust
Linux NFS client maintainer
=20
NetApp
[email protected]
www.netapp.com--
To unsubscribe from this list: send the line "unsubscribe linux-kerne=
l" in
Quoted 4 lines
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
=20
With kind regards,
Geert Uytterhoeven
Software Architect
Sony Techsoft Centre Europe
The Corporate Village =B7 Da Vincilaan 7-D1 =B7 B-1935 Zaventem =B7 Bel= gium
Phone: +32 (0)2 700 8453
=46ax: +32 (0)2 700 8622
E-mail: [email protected] Internet: http://www.sony-europe.com/
A division of Sony Europe (Belgium) N.V. VAT BE 0413.825.160 =B7 RPR Brussels =46ortis =B7 BIC GEBABEBB =B7 IBAN BE41293037680010
Quoted 31 lines · Trond Myklebust
Quoted 5 lines · Trond Myklebust
Quoted 4 lines · J. Bruce Fields
My regular connecthon tests are reporting bus errors on the "write/read 30 MB file" on recent upstream kernels. I'm travelling and haven't had a chance to do anything beyond kick off a dumb git-bisect, which pointed the blame at the following commit. Any ideas?
The following patch should fix it.
Cheers
Trond
---------------------------------------------------------------Quoted 1 line
From
b7a178f4fab331821b8cff384e1954e62aa63e52Mon Sep 17 00:00:00 2001From: Trond Myklebust <[email protected]>
Date: Sat, 4 Apr 2009 12:22:57 -0400
Subject: [PATCH] NFS: Fix the return value innfs_page_mkwrite()Commit
c2ec175c39f62949438354f603f4aa170846aabb(mm:page_mkwritechange prototype to match fault) exposed a bug in the NFS implementation ofpage_mkwrite. We should be returning 0 on success...Signed-off-by Trond Myklebust <[email protected]>--- fs/nfs/file.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-)fs/nfs/file.c +0
-0
fs/nfs/file.c static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf) · line 521
Quoted 8 lines
fs/nfs/file.c +0
-2@@ -516,8 +516,6 @@ static int nfs_vm_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf) goto out_unlock; ret =nfs_updatepage (filp, page,0 , pagelen); -if (ret ==0 ) - ret = pagelen; out_unlock:unlock_page (page);if (ret)
Thanks, looks good to me.