Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* |
| 2 | * This file is subject to the terms and conditions of the GNU General Public |
| 3 | * License. See the file "COPYING" in the main directory of this archive |
| 4 | * for more details. |
| 5 | * |
| 6 | * Copyright (C) 1995, 96, 97, 98, 99, 2000 by Ralf Baechle |
| 7 | * Copyright (C) 1999, 2000 Silicon Graphics, Inc. |
| 8 | * |
| 9 | * Changed system calls macros _syscall5 - _syscall7 to push args 5 to 7 onto |
| 10 | * the stack. Robin Farine for ACN S.A, Copyright (C) 1996 by ACN S.A |
| 11 | */ |
| 12 | #ifndef _ASM_UNISTD_H |
| 13 | #define _ASM_UNISTD_H |
| 14 | |
David Howells | 61730c5 | 2012-10-09 09:47:14 +0100 | [diff] [blame] | 15 | #include <uapi/asm/unistd.h> |
Firoz Khan | 99bf73e | 2018-12-13 14:37:39 +0530 | [diff] [blame] | 16 | #include <asm/unistd_nr_n32.h> |
| 17 | #include <asm/unistd_nr_n64.h> |
| 18 | #include <asm/unistd_nr_o32.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 19 | |
Masahiro Yamada | faf243e | 2021-05-28 12:46:14 +0900 | [diff] [blame] | 20 | #define __NR_N32_Linux 6000 |
| 21 | #define __NR_64_Linux 5000 |
| 22 | #define __NR_O32_Linux 4000 |
| 23 | |
Ralf Baechle | 1d7bf99 | 2013-09-06 20:24:48 +0200 | [diff] [blame] | 24 | #ifdef CONFIG_MIPS32_N32 |
| 25 | #define NR_syscalls (__NR_N32_Linux + __NR_N32_Linux_syscalls) |
| 26 | #elif defined(CONFIG_64BIT) |
| 27 | #define NR_syscalls (__NR_64_Linux + __NR_64_Linux_syscalls) |
| 28 | #else |
| 29 | #define NR_syscalls (__NR_O32_Linux + __NR_O32_Linux_syscalls) |
| 30 | #endif |
David Woodhouse | 5614253 | 2006-04-29 01:51:47 +0100 | [diff] [blame] | 31 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 32 | #ifndef __ASSEMBLY__ |
| 33 | |
Arnd Bergmann | 82b355d | 2018-04-13 11:50:12 +0200 | [diff] [blame] | 34 | #define __ARCH_WANT_NEW_STAT |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 35 | #define __ARCH_WANT_OLD_READDIR |
| 36 | #define __ARCH_WANT_SYS_ALARM |
| 37 | #define __ARCH_WANT_SYS_GETHOSTNAME |
Christoph Hellwig | baed7fc | 2010-03-10 15:21:18 -0800 | [diff] [blame] | 38 | #define __ARCH_WANT_SYS_IPC |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 39 | #define __ARCH_WANT_SYS_PAUSE |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 40 | #define __ARCH_WANT_SYS_UTIME |
Arnd Bergmann | 4faea23 | 2018-04-17 12:03:19 +0200 | [diff] [blame] | 41 | #define __ARCH_WANT_SYS_UTIME32 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 42 | #define __ARCH_WANT_SYS_WAITPID |
| 43 | #define __ARCH_WANT_SYS_SOCKETCALL |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 44 | #define __ARCH_WANT_SYS_GETPGRP |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 45 | #define __ARCH_WANT_SYS_NICE |
Christoph Hellwig | 5cacdb4 | 2010-03-10 15:21:21 -0800 | [diff] [blame] | 46 | #define __ARCH_WANT_SYS_OLD_UNAME |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 47 | #define __ARCH_WANT_SYS_OLDUMOUNT |
| 48 | #define __ARCH_WANT_SYS_SIGPENDING |
| 49 | #define __ARCH_WANT_SYS_SIGPROCMASK |
Ralf Baechle | 875d43e | 2005-09-03 15:56:16 -0700 | [diff] [blame] | 50 | # ifdef CONFIG_32BIT |
Ralf Baechle | 359bbd4 | 2006-02-09 12:13:28 +0000 | [diff] [blame] | 51 | # define __ARCH_WANT_STAT64 |
Arnd Bergmann | d33c577 | 2019-01-06 23:45:29 +0100 | [diff] [blame] | 52 | # define __ARCH_WANT_SYS_TIME32 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 53 | # endif |
| 54 | # ifdef CONFIG_MIPS32_O32 |
Arnd Bergmann | d33c577 | 2019-01-06 23:45:29 +0100 | [diff] [blame] | 55 | # define __ARCH_WANT_SYS_TIME32 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 56 | # endif |
Al Viro | 50150d2 | 2012-12-27 12:11:46 -0500 | [diff] [blame] | 57 | #define __ARCH_WANT_SYS_FORK |
| 58 | #define __ARCH_WANT_SYS_CLONE |
Paul Burton | 0671c5b | 2019-10-02 18:59:49 +0000 | [diff] [blame] | 59 | #define __ARCH_WANT_SYS_CLONE3 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 60 | |
Atsushi Nemoto | 83d0f23 | 2007-05-29 23:30:04 +0900 | [diff] [blame] | 61 | /* whitelists for checksyscalls */ |
Atsushi Nemoto | 83d0f23 | 2007-05-29 23:30:04 +0900 | [diff] [blame] | 62 | #define __IGNORE_fadvise64_64 |
Atsushi Nemoto | 83d0f23 | 2007-05-29 23:30:04 +0900 | [diff] [blame] | 63 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 64 | #endif /* !__ASSEMBLY__ */ |
| 65 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 66 | #endif /* _ASM_UNISTD_H */ |