diff options
Diffstat (limited to 'fs/nfs/file.c')
-rw-r--r-- | fs/nfs/file.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/fs/nfs/file.c b/fs/nfs/file.c index 3523b895eb4..ec7e27d00bc 100644 --- a/fs/nfs/file.c +++ b/fs/nfs/file.c @@ -516,13 +516,11 @@ 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: + if (!ret) + return VM_FAULT_LOCKED; unlock_page(page); - if (ret) - ret = VM_FAULT_SIGBUS; - return ret; + return VM_FAULT_SIGBUS; } static struct vm_operations_struct nfs_file_vm_ops = { |