NFS: nfs_write_end clean up
authorChuck Lever <chuck.lever@oracle.com>
Thu, 20 Dec 2007 19:55:04 +0000 (14:55 -0500)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Wed, 30 Jan 2008 07:06:02 +0000 (02:06 -0500)
Clean up: commit 4899f9c8 added nfs_write_end(), which introduces a
conditional expression that returns an unsigned integer in one arm and
a signed integer in the other.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
fs/nfs/file.c

index 4560fc2..ef57a5a 100644 (file)
@@ -349,7 +349,9 @@ static int nfs_write_end(struct file *file, struct address_space *mapping,
        unlock_page(page);
        page_cache_release(page);
 
-       return status < 0 ? status : copied;
+       if (status < 0)
+               return status;
+       return copied;
 }
 
 static void nfs_invalidate_page(struct page *page, unsigned long offset)