patch-2.0.21-2.1.0 linux/fs/nfs/file.c

Next file: linux/fs/pipe.c
Previous file: linux/fs/nfs/dir.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file lx2.0/v2.0.21/linux/fs/nfs/file.c linux/fs/nfs/file.c
@@ -30,8 +30,8 @@
 #include <asm/system.h>
 
 static int nfs_file_mmap(struct inode *, struct file *, struct vm_area_struct *);
-static int nfs_file_read(struct inode *, struct file *, char *, int);
-static int nfs_file_write(struct inode *, struct file *, const char *, int);
+static long nfs_file_read(struct inode *, struct file *, char *, unsigned long);
+static long nfs_file_write(struct inode *, struct file *, const char *, unsigned long);
 static int nfs_fsync(struct inode *, struct file *);
 
 static struct file_operations nfs_file_operations = {
@@ -87,8 +87,8 @@
 }
 
 
-static int nfs_file_read(struct inode * inode, struct file * file,
-	char * buf, int count)
+static long nfs_file_read(struct inode * inode, struct file * file,
+	char * buf, unsigned long count)
 {
 	revalidate_inode(NFS_SERVER(inode), inode);
 	return generic_file_read(inode, file, buf, count);
@@ -105,8 +105,8 @@
 	return 0;
 }
 
-static int nfs_file_write(struct inode *inode, struct file *file, const char *buf,
-			  int count)
+static long nfs_file_write(struct inode *inode, struct file *file,
+	const char *buf, unsigned long count)
 {
 	int result, written, wsize;
 	struct nfs_fattr fattr;
@@ -121,7 +121,7 @@
 			inode->i_mode);
 		return -EINVAL;
 	}
-	if (count <= 0)
+	if (count == 0)
 		return 0;
 
 	pos = file->f_pos;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov