lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | #ifndef IPC_H |
| 2 | #define IPC_H |
| 3 | #include <syscall.h> |
| 4 | #include <bits/wordsize.h> |
| 5 | |
| 6 | #if __WORDSIZE == 32 || defined __alpha__ || defined __mips__ |
| 7 | # define __IPC_64 0x100 |
| 8 | #else |
| 9 | # define __IPC_64 0x0 |
| 10 | #endif |
| 11 | |
| 12 | #ifdef __NR_ipc |
| 13 | |
| 14 | /* The actual system call: all functions are multiplexed by this. */ |
| 15 | extern int __syscall_ipc (unsigned int __call, long __first, long __second, |
| 16 | long __third, void *__ptr, void *__fifth) attribute_hidden; |
| 17 | |
| 18 | |
| 19 | /* The codes for the functions to use the multiplexer `__syscall_ipc'. */ |
| 20 | #define IPCOP_semop 1 |
| 21 | #define IPCOP_semget 2 |
| 22 | #define IPCOP_semctl 3 |
| 23 | #define IPCOP_semtimedop 4 |
| 24 | #define IPCOP_msgsnd 11 |
| 25 | #define IPCOP_msgrcv 12 |
| 26 | #define IPCOP_msgget 13 |
| 27 | #define IPCOP_msgctl 14 |
| 28 | #define IPCOP_shmat 21 |
| 29 | #define IPCOP_shmdt 22 |
| 30 | #define IPCOP_shmget 23 |
| 31 | #define IPCOP_shmctl 24 |
| 32 | |
| 33 | #endif |
| 34 | |
| 35 | #endif /* IPC_H */ |