
From: "Randy.Dunlap" <randy.dunlap@verizon.net>

Fix up various syscalls to return longs, as x86_64 and ia64 (at least)
require.

(forwarded by akpm@digeo.com)


 arch/x86_64/ia32/sys_ia32.c |    4 ++--
 fs/dcookies.c               |    2 +-
 fs/readdir.c                |    2 +-
 include/linux/mm.h          |    2 +-
 kernel/fork.c               |    2 +-
 kernel/sched.c              |    4 ++--
 kernel/signal.c             |    2 +-
 mm/fremap.c                 |    2 +-
 8 files changed, 10 insertions(+), 10 deletions(-)

diff -puN arch/x86_64/ia32/sys_ia32.c~syscalls-return-long arch/x86_64/ia32/sys_ia32.c
--- 25/arch/x86_64/ia32/sys_ia32.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/arch/x86_64/ia32/sys_ia32.c	2003-03-20 22:58:17.000000000 -0800
@@ -2071,8 +2071,8 @@ long sys32_module_warning(void)
 	return -ENOSYS ;
 } 
 
-int sys_sched_getaffinity(pid_t pid, unsigned int len, unsigned long *new_mask_ptr); 
-int sys_sched_setaffinity(pid_t pid, unsigned int len, unsigned long *new_mask_ptr); 
+long sys_sched_getaffinity(pid_t pid, unsigned int len, unsigned long *new_mask_ptr); 
+long sys_sched_setaffinity(pid_t pid, unsigned int len, unsigned long *new_mask_ptr); 
 
 /* only works on LE */
 long sys32_sched_setaffinity(pid_t pid, unsigned int len,
diff -puN fs/dcookies.c~syscalls-return-long fs/dcookies.c
--- 25/fs/dcookies.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/fs/dcookies.c	2003-03-20 22:58:17.000000000 -0800
@@ -142,7 +142,7 @@ out:
 /* And here is where the userspace process can look up the cookie value
  * to retrieve the path.
  */
-asmlinkage int sys_lookup_dcookie(u64 cookie64, char * buf, size_t len)
+asmlinkage long sys_lookup_dcookie(u64 cookie64, char * buf, size_t len)
 {
 	unsigned long cookie = (unsigned long)cookie64;
 	int err = -EINVAL;
diff -puN fs/readdir.c~syscalls-return-long fs/readdir.c
--- 25/fs/readdir.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/fs/readdir.c	2003-03-20 22:58:17.000000000 -0800
@@ -85,7 +85,7 @@ static int fillonedir(void * __buf, cons
 	return 0;
 }
 
-asmlinkage int old_readdir(unsigned int fd, void * dirent, unsigned int count)
+asmlinkage long old_readdir(unsigned int fd, void * dirent, unsigned int count)
 {
 	int error;
 	struct file * file;
diff -puN include/linux/mm.h~syscalls-return-long include/linux/mm.h
--- 25/include/linux/mm.h~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/include/linux/mm.h	2003-03-20 22:58:17.000000000 -0800
@@ -419,7 +419,7 @@ extern int install_page(struct mm_struct
 extern int handle_mm_fault(struct mm_struct *mm,struct vm_area_struct *vma, unsigned long address, int write_access);
 extern int make_pages_present(unsigned long addr, unsigned long end);
 extern int access_process_vm(struct task_struct *tsk, unsigned long addr, void *buf, int len, int write);
-extern int sys_remap_file_pages(unsigned long start, unsigned long size, unsigned long prot, unsigned long pgoff, unsigned long nonblock);
+extern long sys_remap_file_pages(unsigned long start, unsigned long size, unsigned long prot, unsigned long pgoff, unsigned long nonblock);
 
 
 int get_user_pages(struct task_struct *tsk, struct mm_struct *mm, unsigned long start,
diff -puN kernel/fork.c~syscalls-return-long kernel/fork.c
--- 25/kernel/fork.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/kernel/fork.c	2003-03-20 22:58:17.000000000 -0800
@@ -749,7 +749,7 @@ static inline void copy_flags(unsigned l
 	p->flags = new_flags;
 }
 
-asmlinkage int sys_set_tid_address(int *tidptr)
+asmlinkage long sys_set_tid_address(int *tidptr)
 {
 	current->clear_child_tid = tidptr;
 
diff -puN kernel/sched.c~syscalls-return-long kernel/sched.c
--- 25/kernel/sched.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/kernel/sched.c	2003-03-20 22:58:17.000000000 -0800
@@ -1964,7 +1964,7 @@ out_unlock:
  * @len: length in bytes of the bitmask pointed to by user_mask_ptr
  * @user_mask_ptr: user-space pointer to the new cpu mask
  */
-asmlinkage int sys_sched_setaffinity(pid_t pid, unsigned int len,
+asmlinkage long sys_sched_setaffinity(pid_t pid, unsigned int len,
 				      unsigned long *user_mask_ptr)
 {
 	unsigned long new_mask;
@@ -2016,7 +2016,7 @@ out_unlock:
  * @len: length in bytes of the bitmask pointed to by user_mask_ptr
  * @user_mask_ptr: user-space pointer to hold the current cpu mask
  */
-asmlinkage int sys_sched_getaffinity(pid_t pid, unsigned int len,
+asmlinkage long sys_sched_getaffinity(pid_t pid, unsigned int len,
 				      unsigned long *user_mask_ptr)
 {
 	unsigned int real_len;
diff -puN kernel/signal.c~syscalls-return-long kernel/signal.c
--- 25/kernel/signal.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/kernel/signal.c	2003-03-20 22:58:17.000000000 -0800
@@ -2254,7 +2254,7 @@ sys_signal(int sig, __sighandler_t handl
 
 #ifndef HAVE_ARCH_SYS_PAUSE
 
-asmlinkage int
+asmlinkage long
 sys_pause(void)
 {
 	current->state = TASK_INTERRUPTIBLE;
diff -puN mm/fremap.c~syscalls-return-long mm/fremap.c
--- 25/mm/fremap.c~syscalls-return-long	2003-03-20 22:58:17.000000000 -0800
+++ 25-akpm/mm/fremap.c	2003-03-20 22:58:41.000000000 -0800
@@ -108,7 +108,7 @@ err:
  * protection is used. Arbitrary protections might be implemented in the
  * future.
  */
-int sys_remap_file_pages(unsigned long start, unsigned long size,
+long sys_remap_file_pages(unsigned long start, unsigned long size,
 	unsigned long __prot, unsigned long pgoff, unsigned long flags)
 {
 	struct mm_struct *mm = current->mm;

_
