alpha: add generic get{eg,eu,g,p,u,pp}id() syscalls
authorArnd Bergmann <arnd@arndb.de>
Fri, 11 Jan 2019 14:09:11 +0000 (15:09 +0100)
committerArnd Bergmann <arnd@arndb.de>
Fri, 25 Jan 2019 16:22:51 +0000 (17:22 +0100)
Alpha has traditionally followed the OSF1 calling conventions
here, with its getxpid, getxuid, getxgid system calls returning
two different values in separate registers.

Following what glibc has done here, we can define getpid,
getuid and getgid to be aliases for getxpid, getxuid and getxgid
respectively, and add new system call numbers for getppid, geteuid
and getegid.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
arch/alpha/include/asm/unistd.h
arch/alpha/include/uapi/asm/unistd.h
arch/alpha/kernel/syscalls/syscall.tbl

index 31ad350b58a09c40dc263997a515669d1a85c8f7..986f5da9b7d8b4a6c568e28914bedad459203d17 100644 (file)
 #define __ARCH_WANT_SYS_VFORK
 #define __ARCH_WANT_SYS_CLONE
 
-/*
- * Ignore legacy syscalls that we don't use.
- */
-#define __IGNORE_getegid
-#define __IGNORE_geteuid
-#define __IGNORE_getgid
-#define __IGNORE_getpid
-#define __IGNORE_getppid
-#define __IGNORE_getuid
-
-
 #endif /* _ALPHA_UNISTD_H */
index 4507071f995fbd756b7fce7d26529797186c17fb..71fd5db06866d7193befa0ee58881724823998e6 100644 (file)
@@ -7,6 +7,11 @@
 #define __NR_umount    __NR_umount2
 #define __NR_osf_shmat __NR_shmat
 
+/* These return an extra value but can be used as aliases */
+#define __NR_getpid    __NR_getxpid
+#define __NR_getuid    __NR_getxuid
+#define __NR_getgid    __NR_getxgid
+
 #include <asm/unistd_32.h>
 
 #endif /* _UAPI_ALPHA_UNISTD_H */
index 2a0ec5a08f9ad4ce2622637e9773736e7466eed0..340b88dd397ecd409aa6ca79a8f09f91b7135634 100644 (file)
 527    common  rseq                            sys_rseq
 528    common  statfs64                        sys_statfs64
 529    common  fstatfs64                       sys_fstatfs64
+530    common  getegid                         sys_getegid
+531    common  geteuid                         sys_geteuid
+532    common  getppid                         sys_getppid