diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2009-01-14 08:13:54 -0500 |
---|---|---|
committer | Heiko Carstens <heiko.carstens@de.ibm.com> | 2009-01-14 08:15:14 -0500 |
commit | 2ed7c03ec17779afb4fcfa3b8c61df61bd4879ba (patch) | |
tree | 4e0fefd574bab5470a02edf439727f472a9663c6 | |
parent | 4c696ba7982501d43dea11dbbaabd2aa8a19cc42 (diff) |
[CVE-2009-0029] Convert all system calls to return a long
Convert all system calls to return a long. This should be a NOP since all
converted types should have the same size anyway.
With the exception of sys_exit_group which returned void. But that doesn't
matter since the system call doesn't return.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
-rw-r--r-- | fs/read_write.c | 18 | ||||
-rw-r--r-- | fs/xattr.c | 12 | ||||
-rw-r--r-- | include/linux/syscalls.h | 79 | ||||
-rw-r--r-- | ipc/mqueue.c | 2 | ||||
-rw-r--r-- | kernel/exit.c | 4 | ||||
-rw-r--r-- | kernel/signal.c | 2 | ||||
-rw-r--r-- | kernel/timer.c | 2 | ||||
-rw-r--r-- | mm/filemap.c | 2 | ||||
-rw-r--r-- | mm/mmap.c | 2 | ||||
-rw-r--r-- | mm/mremap.c | 2 | ||||
-rw-r--r-- | mm/nommu.c | 2 |
11 files changed, 64 insertions, 63 deletions
diff --git a/fs/read_write.c b/fs/read_write.c index 5cc6924eb158..940367f51f2a 100644 --- a/fs/read_write.c +++ b/fs/read_write.c | |||
@@ -147,7 +147,7 @@ loff_t vfs_llseek(struct file *file, loff_t offset, int origin) | |||
147 | } | 147 | } |
148 | EXPORT_SYMBOL(vfs_llseek); | 148 | EXPORT_SYMBOL(vfs_llseek); |
149 | 149 | ||
150 | asmlinkage off_t sys_lseek(unsigned int fd, off_t offset, unsigned int origin) | 150 | asmlinkage long sys_lseek(unsigned int fd, off_t offset, unsigned int origin) |
151 | { | 151 | { |
152 | off_t retval; | 152 | off_t retval; |
153 | struct file * file; | 153 | struct file * file; |
@@ -369,7 +369,7 @@ static inline void file_pos_write(struct file *file, loff_t pos) | |||
369 | file->f_pos = pos; | 369 | file->f_pos = pos; |
370 | } | 370 | } |
371 | 371 | ||
372 | asmlinkage ssize_t sys_read(unsigned int fd, char __user * buf, size_t count) | 372 | asmlinkage long sys_read(unsigned int fd, char __user * buf, size_t count) |
373 | { | 373 | { |
374 | struct file *file; | 374 | struct file *file; |
375 | ssize_t ret = -EBADF; | 375 | ssize_t ret = -EBADF; |
@@ -386,7 +386,7 @@ asmlinkage ssize_t sys_read(unsigned int fd, char __user * buf, size_t count) | |||
386 | return ret; | 386 | return ret; |
387 | } | 387 | } |
388 | 388 | ||
389 | asmlinkage ssize_t sys_write(unsigned int fd, const char __user * buf, size_t count) | 389 | asmlinkage long sys_write(unsigned int fd, const char __user * buf, size_t count) |
390 | { | 390 | { |
391 | struct file *file; | 391 | struct file *file; |
392 | ssize_t ret = -EBADF; | 392 | ssize_t ret = -EBADF; |
@@ -403,7 +403,7 @@ asmlinkage ssize_t sys_write(unsigned int fd, const char __user * buf, size_t co | |||
403 | return ret; | 403 | return ret; |
404 | } | 404 | } |
405 | 405 | ||
406 | asmlinkage ssize_t sys_pread64(unsigned int fd, char __user *buf, | 406 | asmlinkage long sys_pread64(unsigned int fd, char __user *buf, |
407 | size_t count, loff_t pos) | 407 | size_t count, loff_t pos) |
408 | { | 408 | { |
409 | struct file *file; | 409 | struct file *file; |
@@ -424,7 +424,7 @@ asmlinkage ssize_t sys_pread64(unsigned int fd, char __user *buf, | |||
424 | return ret; | 424 | return ret; |
425 | } | 425 | } |
426 | 426 | ||
427 | asmlinkage ssize_t sys_pwrite64(unsigned int fd, const char __user *buf, | 427 | asmlinkage long sys_pwrite64(unsigned int fd, const char __user *buf, |
428 | size_t count, loff_t pos) | 428 | size_t count, loff_t pos) |
429 | { | 429 | { |
430 | struct file *file; | 430 | struct file *file; |
@@ -672,7 +672,7 @@ ssize_t vfs_writev(struct file *file, const struct iovec __user *vec, | |||
672 | 672 | ||
673 | EXPORT_SYMBOL(vfs_writev); | 673 | EXPORT_SYMBOL(vfs_writev); |
674 | 674 | ||
675 | asmlinkage ssize_t | 675 | asmlinkage long |
676 | sys_readv(unsigned long fd, const struct iovec __user *vec, unsigned long vlen) | 676 | sys_readv(unsigned long fd, const struct iovec __user *vec, unsigned long vlen) |
677 | { | 677 | { |
678 | struct file *file; | 678 | struct file *file; |
@@ -693,7 +693,7 @@ sys_readv(unsigned long fd, const struct iovec __user *vec, unsigned long vlen) | |||
693 | return ret; | 693 | return ret; |
694 | } | 694 | } |
695 | 695 | ||
696 | asmlinkage ssize_t | 696 | asmlinkage long |
697 | sys_writev(unsigned long fd, const struct iovec __user *vec, unsigned long vlen) | 697 | sys_writev(unsigned long fd, const struct iovec __user *vec, unsigned long vlen) |
698 | { | 698 | { |
699 | struct file *file; | 699 | struct file *file; |
@@ -812,7 +812,7 @@ out: | |||
812 | return retval; | 812 | return retval; |
813 | } | 813 | } |
814 | 814 | ||
815 | asmlinkage ssize_t sys_sendfile(int out_fd, int in_fd, off_t __user *offset, size_t count) | 815 | asmlinkage long sys_sendfile(int out_fd, int in_fd, off_t __user *offset, size_t count) |
816 | { | 816 | { |
817 | loff_t pos; | 817 | loff_t pos; |
818 | off_t off; | 818 | off_t off; |
@@ -831,7 +831,7 @@ asmlinkage ssize_t sys_sendfile(int out_fd, int in_fd, off_t __user *offset, siz | |||
831 | return do_sendfile(out_fd, in_fd, NULL, count, 0); | 831 | return do_sendfile(out_fd, in_fd, NULL, count, 0); |
832 | } | 832 | } |
833 | 833 | ||
834 | asmlinkage ssize_t sys_sendfile64(int out_fd, int in_fd, loff_t __user *offset, size_t count) | 834 | asmlinkage long sys_sendfile64(int out_fd, int in_fd, loff_t __user *offset, size_t count) |
835 | { | 835 | { |
836 | loff_t pos; | 836 | loff_t pos; |
837 | ssize_t ret; | 837 | ssize_t ret; |
diff --git a/fs/xattr.c b/fs/xattr.c index 237804cd6b56..d049ae27aae7 100644 --- a/fs/xattr.c +++ b/fs/xattr.c | |||
@@ -349,7 +349,7 @@ getxattr(struct dentry *d, const char __user *name, void __user *value, | |||
349 | return error; | 349 | return error; |
350 | } | 350 | } |
351 | 351 | ||
352 | asmlinkage ssize_t | 352 | asmlinkage long |
353 | sys_getxattr(const char __user *pathname, const char __user *name, | 353 | sys_getxattr(const char __user *pathname, const char __user *name, |
354 | void __user *value, size_t size) | 354 | void __user *value, size_t size) |
355 | { | 355 | { |
@@ -364,7 +364,7 @@ sys_getxattr(const char __user *pathname, const char __user *name, | |||
364 | return error; | 364 | return error; |
365 | } | 365 | } |
366 | 366 | ||
367 | asmlinkage ssize_t | 367 | asmlinkage long |
368 | sys_lgetxattr(const char __user *pathname, const char __user *name, void __user *value, | 368 | sys_lgetxattr(const char __user *pathname, const char __user *name, void __user *value, |
369 | size_t size) | 369 | size_t size) |
370 | { | 370 | { |
@@ -379,7 +379,7 @@ sys_lgetxattr(const char __user *pathname, const char __user *name, void __user | |||
379 | return error; | 379 | return error; |
380 | } | 380 | } |
381 | 381 | ||
382 | asmlinkage ssize_t | 382 | asmlinkage long |
383 | sys_fgetxattr(int fd, const char __user *name, void __user *value, size_t size) | 383 | sys_fgetxattr(int fd, const char __user *name, void __user *value, size_t size) |
384 | { | 384 | { |
385 | struct file *f; | 385 | struct file *f; |
@@ -424,7 +424,7 @@ listxattr(struct dentry *d, char __user *list, size_t size) | |||
424 | return error; | 424 | return error; |
425 | } | 425 | } |
426 | 426 | ||
427 | asmlinkage ssize_t | 427 | asmlinkage long |
428 | sys_listxattr(const char __user *pathname, char __user *list, size_t size) | 428 | sys_listxattr(const char __user *pathname, char __user *list, size_t size) |
429 | { | 429 | { |
430 | struct path path; | 430 | struct path path; |
@@ -438,7 +438,7 @@ sys_listxattr(const char __user *pathname, char __user *list, size_t size) | |||
438 | return error; | 438 | return error; |
439 | } | 439 | } |
440 | 440 | ||
441 | asmlinkage ssize_t | 441 | asmlinkage long |
442 | sys_llistxattr(const char __user *pathname, char __user *list, size_t size) | 442 | sys_llistxattr(const char __user *pathname, char __user *list, size_t size) |
443 | { | 443 | { |
444 | struct path path; | 444 | struct path path; |
@@ -452,7 +452,7 @@ sys_llistxattr(const char __user *pathname, char __user *list, size_t size) | |||
452 | return error; | 452 | return error; |
453 | } | 453 | } |
454 | 454 | ||
455 | asmlinkage ssize_t | 455 | asmlinkage long |
456 | sys_flistxattr(int fd, char __user *list, size_t size) | 456 | sys_flistxattr(int fd, char __user *list, size_t size) |
457 | { | 457 | { |
458 | struct file *f; | 458 | struct file *f; |
diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h index a7593f670ca6..22290eeaf553 100644 --- a/include/linux/syscalls.h +++ b/include/linux/syscalls.h | |||
@@ -77,7 +77,7 @@ asmlinkage long sys_times(struct tms __user *tbuf); | |||
77 | 77 | ||
78 | asmlinkage long sys_gettid(void); | 78 | asmlinkage long sys_gettid(void); |
79 | asmlinkage long sys_nanosleep(struct timespec __user *rqtp, struct timespec __user *rmtp); | 79 | asmlinkage long sys_nanosleep(struct timespec __user *rqtp, struct timespec __user *rmtp); |
80 | asmlinkage unsigned long sys_alarm(unsigned int seconds); | 80 | asmlinkage long sys_alarm(unsigned int seconds); |
81 | asmlinkage long sys_getpid(void); | 81 | asmlinkage long sys_getpid(void); |
82 | asmlinkage long sys_getppid(void); | 82 | asmlinkage long sys_getppid(void); |
83 | asmlinkage long sys_getuid(void); | 83 | asmlinkage long sys_getuid(void); |
@@ -166,7 +166,7 @@ asmlinkage long sys_kexec_load(unsigned long entry, unsigned long nr_segments, | |||
166 | unsigned long flags); | 166 | unsigned long flags); |
167 | 167 | ||
168 | asmlinkage long sys_exit(int error_code); | 168 | asmlinkage long sys_exit(int error_code); |
169 | asmlinkage void sys_exit_group(int error_code); | 169 | asmlinkage long sys_exit_group(int error_code); |
170 | asmlinkage long sys_wait4(pid_t pid, int __user *stat_addr, | 170 | asmlinkage long sys_wait4(pid_t pid, int __user *stat_addr, |
171 | int options, struct rusage __user *ru); | 171 | int options, struct rusage __user *ru); |
172 | asmlinkage long sys_waitid(int which, pid_t pid, | 172 | asmlinkage long sys_waitid(int which, pid_t pid, |
@@ -196,7 +196,7 @@ asmlinkage long sys_tkill(int pid, int sig); | |||
196 | asmlinkage long sys_rt_sigqueueinfo(int pid, int sig, siginfo_t __user *uinfo); | 196 | asmlinkage long sys_rt_sigqueueinfo(int pid, int sig, siginfo_t __user *uinfo); |
197 | asmlinkage long sys_sgetmask(void); | 197 | asmlinkage long sys_sgetmask(void); |
198 | asmlinkage long sys_ssetmask(int newmask); | 198 | asmlinkage long sys_ssetmask(int newmask); |
199 | asmlinkage unsigned long sys_signal(int sig, __sighandler_t handler); | 199 | asmlinkage long sys_signal(int sig, __sighandler_t handler); |
200 | asmlinkage long sys_pause(void); | 200 | asmlinkage long sys_pause(void); |
201 | 201 | ||
202 | asmlinkage long sys_sync(void); | 202 | asmlinkage long sys_sync(void); |
@@ -246,29 +246,29 @@ asmlinkage long sys_lsetxattr(const char __user *path, const char __user *name, | |||
246 | const void __user *value, size_t size, int flags); | 246 | const void __user *value, size_t size, int flags); |
247 | asmlinkage long sys_fsetxattr(int fd, const char __user *name, | 247 | asmlinkage long sys_fsetxattr(int fd, const char __user *name, |
248 | const void __user *value, size_t size, int flags); | 248 | const void __user *value, size_t size, int flags); |
249 | asmlinkage ssize_t sys_getxattr(const char __user *path, const char __user *name, | 249 | asmlinkage long sys_getxattr(const char __user *path, const char __user *name, |
250 | void __user *value, size_t size); | 250 | void __user *value, size_t size); |
251 | asmlinkage ssize_t sys_lgetxattr(const char __user *path, const char __user *name, | 251 | asmlinkage long sys_lgetxattr(const char __user *path, const char __user *name, |
252 | void __user *value, size_t size); | 252 | void __user *value, size_t size); |
253 | asmlinkage ssize_t sys_fgetxattr(int fd, const char __user *name, | 253 | asmlinkage long sys_fgetxattr(int fd, const char __user *name, |
254 | void __user *value, size_t size); | 254 | void __user *value, size_t size); |
255 | asmlinkage ssize_t sys_listxattr(const char __user *path, char __user *list, | 255 | asmlinkage long sys_listxattr(const char __user *path, char __user *list, |
256 | size_t size); | 256 | size_t size); |
257 | asmlinkage ssize_t sys_llistxattr(const char __user *path, char __user *list, | 257 | asmlinkage long sys_llistxattr(const char __user *path, char __user *list, |
258 | size_t size); | 258 | size_t size); |
259 | asmlinkage ssize_t sys_flistxattr(int fd, char __user *list, size_t size); | 259 | asmlinkage long sys_flistxattr(int fd, char __user *list, size_t size); |
260 | asmlinkage long sys_removexattr(const char __user *path, | 260 | asmlinkage long sys_removexattr(const char __user *path, |
261 | const char __user *name); | 261 | const char __user *name); |
262 | asmlinkage long sys_lremovexattr(const char __user *path, | 262 | asmlinkage long sys_lremovexattr(const char __user *path, |
263 | const char __user *name); | 263 | const char __user *name); |
264 | asmlinkage long sys_fremovexattr(int fd, const char __user *name); | 264 | asmlinkage long sys_fremovexattr(int fd, const char __user *name); |
265 | 265 | ||
266 | asmlinkage unsigned long sys_brk(unsigned long brk); | 266 | asmlinkage long sys_brk(unsigned long brk); |
267 | asmlinkage long sys_mprotect(unsigned long start, size_t len, | 267 | asmlinkage long sys_mprotect(unsigned long start, size_t len, |
268 | unsigned long prot); | 268 | unsigned long prot); |
269 | asmlinkage unsigned long sys_mremap(unsigned long addr, | 269 | asmlinkage long sys_mremap(unsigned long addr, |
270 | unsigned long old_len, unsigned long new_len, | 270 | unsigned long old_len, unsigned long new_len, |
271 | unsigned long flags, unsigned long new_addr); | 271 | unsigned long flags, unsigned long new_addr); |
272 | asmlinkage long sys_remap_file_pages(unsigned long start, unsigned long size, | 272 | asmlinkage long sys_remap_file_pages(unsigned long start, unsigned long size, |
273 | unsigned long prot, unsigned long pgoff, | 273 | unsigned long prot, unsigned long pgoff, |
274 | unsigned long flags); | 274 | unsigned long flags); |
@@ -321,10 +321,10 @@ asmlinkage long sys_io_submit(aio_context_t, long, | |||
321 | struct iocb __user * __user *); | 321 | struct iocb __user * __user *); |
322 | asmlinkage long sys_io_cancel(aio_context_t ctx_id, struct iocb __user *iocb, | 322 | asmlinkage long sys_io_cancel(aio_context_t ctx_id, struct iocb __user *iocb, |
323 | struct io_event __user *result); | 323 | struct io_event __user *result); |
324 | asmlinkage ssize_t sys_sendfile(int out_fd, int in_fd, | 324 | asmlinkage long sys_sendfile(int out_fd, int in_fd, |
325 | off_t __user *offset, size_t count); | 325 | off_t __user *offset, size_t count); |
326 | asmlinkage ssize_t sys_sendfile64(int out_fd, int in_fd, | 326 | asmlinkage long sys_sendfile64(int out_fd, int in_fd, |
327 | loff_t __user *offset, size_t count); | 327 | loff_t __user *offset, size_t count); |
328 | asmlinkage long sys_readlink(const char __user *path, | 328 | asmlinkage long sys_readlink(const char __user *path, |
329 | char __user *buf, int bufsiz); | 329 | char __user *buf, int bufsiz); |
330 | asmlinkage long sys_creat(const char __user *pathname, int mode); | 330 | asmlinkage long sys_creat(const char __user *pathname, int mode); |
@@ -368,26 +368,25 @@ asmlinkage long sys_utime(char __user *filename, | |||
368 | struct utimbuf __user *times); | 368 | struct utimbuf __user *times); |
369 | asmlinkage long sys_utimes(char __user *filename, | 369 | asmlinkage long sys_utimes(char __user *filename, |
370 | struct timeval __user *utimes); | 370 | struct timeval __user *utimes); |
371 | asmlinkage off_t sys_lseek(unsigned int fd, off_t offset, | 371 | asmlinkage long sys_lseek(unsigned int fd, off_t offset, |
372 | unsigned int origin); | 372 | unsigned int origin); |
373 | asmlinkage long sys_llseek(unsigned int fd, unsigned long offset_high, | 373 | asmlinkage long sys_llseek(unsigned int fd, unsigned long offset_high, |
374 | unsigned long offset_low, loff_t __user *result, | 374 | unsigned long offset_low, loff_t __user *result, |
375 | unsigned int origin); | 375 | unsigned int origin); |
376 | asmlinkage ssize_t sys_read(unsigned int fd, char __user *buf, | 376 | asmlinkage long sys_read(unsigned int fd, char __user *buf, size_t count); |
377 | size_t count); | 377 | asmlinkage long sys_readahead(int fd, loff_t offset, size_t count); |
378 | asmlinkage ssize_t sys_readahead(int fd, loff_t offset, size_t count); | 378 | asmlinkage long sys_readv(unsigned long fd, |
379 | asmlinkage ssize_t sys_readv(unsigned long fd, | 379 | const struct iovec __user *vec, |
380 | const struct iovec __user *vec, | 380 | unsigned long vlen); |
381 | unsigned long vlen); | 381 | asmlinkage long sys_write(unsigned int fd, const char __user *buf, |
382 | asmlinkage ssize_t sys_write(unsigned int fd, const char __user *buf, | 382 | size_t count); |
383 | size_t count); | 383 | asmlinkage long sys_writev(unsigned long fd, |
384 | asmlinkage ssize_t sys_writev(unsigned long fd, | 384 | const struct iovec __user *vec, |
385 | const struct iovec __user *vec, | 385 | unsigned long vlen); |
386 | unsigned long vlen); | 386 | asmlinkage long sys_pread64(unsigned int fd, char __user *buf, |
387 | asmlinkage ssize_t sys_pread64(unsigned int fd, char __user *buf, | 387 | size_t count, loff_t pos); |
388 | size_t count, loff_t pos); | 388 | asmlinkage long sys_pwrite64(unsigned int fd, const char __user *buf, |
389 | asmlinkage ssize_t sys_pwrite64(unsigned int fd, const char __user *buf, | 389 | size_t count, loff_t pos); |
390 | size_t count, loff_t pos); | ||
391 | asmlinkage long sys_getcwd(char __user *buf, unsigned long size); | 390 | asmlinkage long sys_getcwd(char __user *buf, unsigned long size); |
392 | asmlinkage long sys_mkdir(const char __user *pathname, int mode); | 391 | asmlinkage long sys_mkdir(const char __user *pathname, int mode); |
393 | asmlinkage long sys_chdir(const char __user *filename); | 392 | asmlinkage long sys_chdir(const char __user *filename); |
@@ -476,7 +475,7 @@ asmlinkage long sys_shmctl(int shmid, int cmd, struct shmid_ds __user *buf); | |||
476 | asmlinkage long sys_mq_open(const char __user *name, int oflag, mode_t mode, struct mq_attr __user *attr); | 475 | asmlinkage long sys_mq_open(const char __user *name, int oflag, mode_t mode, struct mq_attr __user *attr); |
477 | asmlinkage long sys_mq_unlink(const char __user *name); | 476 | asmlinkage long sys_mq_unlink(const char __user *name); |
478 | asmlinkage long sys_mq_timedsend(mqd_t mqdes, const char __user *msg_ptr, size_t msg_len, unsigned int msg_prio, const struct timespec __user *abs_timeout); | 477 | asmlinkage long sys_mq_timedsend(mqd_t mqdes, const char __user *msg_ptr, size_t msg_len, unsigned int msg_prio, const struct timespec __user *abs_timeout); |
479 | asmlinkage ssize_t sys_mq_timedreceive(mqd_t mqdes, char __user *msg_ptr, size_t msg_len, unsigned int __user *msg_prio, const struct timespec __user *abs_timeout); | 478 | asmlinkage long sys_mq_timedreceive(mqd_t mqdes, char __user *msg_ptr, size_t msg_len, unsigned int __user *msg_prio, const struct timespec __user *abs_timeout); |
480 | asmlinkage long sys_mq_notify(mqd_t mqdes, const struct sigevent __user *notification); | 479 | asmlinkage long sys_mq_notify(mqd_t mqdes, const struct sigevent __user *notification); |
481 | asmlinkage long sys_mq_getsetattr(mqd_t mqdes, const struct mq_attr __user *mqstat, struct mq_attr __user *omqstat); | 480 | asmlinkage long sys_mq_getsetattr(mqd_t mqdes, const struct mq_attr __user *mqstat, struct mq_attr __user *omqstat); |
482 | 481 | ||
diff --git a/ipc/mqueue.c b/ipc/mqueue.c index 23fdb8492b8e..6df028b70543 100644 --- a/ipc/mqueue.c +++ b/ipc/mqueue.c | |||
@@ -907,7 +907,7 @@ out: | |||
907 | return ret; | 907 | return ret; |
908 | } | 908 | } |
909 | 909 | ||
910 | asmlinkage ssize_t sys_mq_timedreceive(mqd_t mqdes, char __user *u_msg_ptr, | 910 | asmlinkage long sys_mq_timedreceive(mqd_t mqdes, char __user *u_msg_ptr, |
911 | size_t msg_len, unsigned int __user *u_msg_prio, | 911 | size_t msg_len, unsigned int __user *u_msg_prio, |
912 | const struct timespec __user *u_abs_timeout) | 912 | const struct timespec __user *u_abs_timeout) |
913 | { | 913 | { |
diff --git a/kernel/exit.c b/kernel/exit.c index c7740fa3252c..fac9b040af2c 100644 --- a/kernel/exit.c +++ b/kernel/exit.c | |||
@@ -1182,9 +1182,11 @@ do_group_exit(int exit_code) | |||
1182 | * wait4()-ing process will get the correct exit code - even if this | 1182 | * wait4()-ing process will get the correct exit code - even if this |
1183 | * thread is not the thread group leader. | 1183 | * thread is not the thread group leader. |
1184 | */ | 1184 | */ |
1185 | asmlinkage void sys_exit_group(int error_code) | 1185 | asmlinkage long sys_exit_group(int error_code) |
1186 | { | 1186 | { |
1187 | do_group_exit((error_code & 0xff) << 8); | 1187 | do_group_exit((error_code & 0xff) << 8); |
1188 | /* NOTREACHED */ | ||
1189 | return 0; | ||
1188 | } | 1190 | } |
1189 | 1191 | ||
1190 | static struct pid *task_pid_type(struct task_struct *task, enum pid_type type) | 1192 | static struct pid *task_pid_type(struct task_struct *task, enum pid_type type) |
diff --git a/kernel/signal.c b/kernel/signal.c index 3152ac3b62e2..856a5479d49d 100644 --- a/kernel/signal.c +++ b/kernel/signal.c | |||
@@ -2559,7 +2559,7 @@ sys_ssetmask(int newmask) | |||
2559 | /* | 2559 | /* |
2560 | * For backwards compatibility. Functionality superseded by sigaction. | 2560 | * For backwards compatibility. Functionality superseded by sigaction. |
2561 | */ | 2561 | */ |
2562 | asmlinkage unsigned long | 2562 | asmlinkage long |
2563 | sys_signal(int sig, __sighandler_t handler) | 2563 | sys_signal(int sig, __sighandler_t handler) |
2564 | { | 2564 | { |
2565 | struct k_sigaction new_sa, old_sa; | 2565 | struct k_sigaction new_sa, old_sa; |
diff --git a/kernel/timer.c b/kernel/timer.c index dee3f641a7a7..7b8697d7f04d 100644 --- a/kernel/timer.c +++ b/kernel/timer.c | |||
@@ -1129,7 +1129,7 @@ void do_timer(unsigned long ticks) | |||
1129 | * For backwards compatibility? This can be done in libc so Alpha | 1129 | * For backwards compatibility? This can be done in libc so Alpha |
1130 | * and all newer ports shouldn't need it. | 1130 | * and all newer ports shouldn't need it. |
1131 | */ | 1131 | */ |
1132 | asmlinkage unsigned long sys_alarm(unsigned int seconds) | 1132 | asmlinkage long sys_alarm(unsigned int seconds) |
1133 | { | 1133 | { |
1134 | return alarm_setitimer(seconds); | 1134 | return alarm_setitimer(seconds); |
1135 | } | 1135 | } |
diff --git a/mm/filemap.c b/mm/filemap.c index ceba0bd03662..538b75ed6236 100644 --- a/mm/filemap.c +++ b/mm/filemap.c | |||
@@ -1374,7 +1374,7 @@ do_readahead(struct address_space *mapping, struct file *filp, | |||
1374 | return 0; | 1374 | return 0; |
1375 | } | 1375 | } |
1376 | 1376 | ||
1377 | asmlinkage ssize_t sys_readahead(int fd, loff_t offset, size_t count) | 1377 | asmlinkage long sys_readahead(int fd, loff_t offset, size_t count) |
1378 | { | 1378 | { |
1379 | ssize_t ret; | 1379 | ssize_t ret; |
1380 | struct file *file; | 1380 | struct file *file; |
@@ -245,7 +245,7 @@ static struct vm_area_struct *remove_vma(struct vm_area_struct *vma) | |||
245 | return next; | 245 | return next; |
246 | } | 246 | } |
247 | 247 | ||
248 | asmlinkage unsigned long sys_brk(unsigned long brk) | 248 | asmlinkage long sys_brk(unsigned long brk) |
249 | { | 249 | { |
250 | unsigned long rlim, retval; | 250 | unsigned long rlim, retval; |
251 | unsigned long newbrk, oldbrk; | 251 | unsigned long newbrk, oldbrk; |
diff --git a/mm/mremap.c b/mm/mremap.c index 646de959aa58..5572e0825d80 100644 --- a/mm/mremap.c +++ b/mm/mremap.c | |||
@@ -420,7 +420,7 @@ out_nc: | |||
420 | return ret; | 420 | return ret; |
421 | } | 421 | } |
422 | 422 | ||
423 | asmlinkage unsigned long sys_mremap(unsigned long addr, | 423 | asmlinkage long sys_mremap(unsigned long addr, |
424 | unsigned long old_len, unsigned long new_len, | 424 | unsigned long old_len, unsigned long new_len, |
425 | unsigned long flags, unsigned long new_addr) | 425 | unsigned long flags, unsigned long new_addr) |
426 | { | 426 | { |
diff --git a/mm/nommu.c b/mm/nommu.c index 60ed8375c986..ee3e78927739 100644 --- a/mm/nommu.c +++ b/mm/nommu.c | |||
@@ -416,7 +416,7 @@ EXPORT_SYMBOL(vm_insert_page); | |||
416 | * to a regular file. in this case, the unmapping will need | 416 | * to a regular file. in this case, the unmapping will need |
417 | * to invoke file system routines that need the global lock. | 417 | * to invoke file system routines that need the global lock. |
418 | */ | 418 | */ |
419 | asmlinkage unsigned long sys_brk(unsigned long brk) | 419 | asmlinkage long sys_brk(unsigned long brk) |
420 | { | 420 | { |
421 | struct mm_struct *mm = current->mm; | 421 | struct mm_struct *mm = current->mm; |
422 | 422 | ||