patch-2.0.21-2.1.0 linux/kernel/sysctl.c

Next file: linux/mm/filemap.c
Previous file: linux/kernel/module.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file lx2.0/v2.0.21/linux/kernel/sysctl.c linux/kernel/sysctl.c
@@ -46,10 +46,10 @@
 
 #ifdef CONFIG_PROC_FS
 
-static int proc_readsys(struct inode * inode, struct file * file,
-			char * buf, int count);
-static int proc_writesys(struct inode * inode, struct file * file,
-			 const char * buf, int count);
+static long proc_readsys(struct inode * inode, struct file * file,
+			char * buf, unsigned long count);
+static long proc_writesys(struct inode * inode, struct file * file,
+			 const char * buf, unsigned long count);
 static int proc_sys_permission(struct inode *, int);
 
 struct file_operations proc_sys_file_operations =
@@ -456,13 +456,14 @@
 }
 
 
-static int do_rw_proc(int write, struct inode * inode, struct file * file,
-		      char * buf, int count)
+static long do_rw_proc(int write, struct inode * inode, struct file * file,
+		      char * buf, unsigned long count)
 {
-	int error, op;
+	int op;
 	struct proc_dir_entry *de;
 	struct ctl_table *table;
 	size_t res;
+	long error;
 	
 	error = verify_area(write ? VERIFY_READ : VERIFY_WRITE, buf, count);
 	if (error)
@@ -485,14 +486,14 @@
 	return res;
 }
 
-static int proc_readsys(struct inode * inode, struct file * file,
-			char * buf, int count)
+static long proc_readsys(struct inode * inode, struct file * file,
+			char * buf, unsigned long count)
 {
 	return do_rw_proc(0, inode, file, buf, count);
 }
 
-static int proc_writesys(struct inode * inode, struct file * file,
-			 const char * buf, int count)
+static long proc_writesys(struct inode * inode, struct file * file,
+			 const char * buf, unsigned long count)
 {
 	return do_rw_proc(1, inode, file, (char *) buf, count);
 }

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