xref: /haiku/headers/posix/sys/ipc.h (revision 079eccf655ba39812b421ae1b87a727d41b50354)
1 /*
2  * Copyright 2008, Haiku Inc. All Rights Reserved.
3  * Distributed under the terms of the MIT License.
4  */
5 #ifndef _SYS_IPC_H
6 #define _SYS_IPC_H
7 
8 
9 #include <sys/types.h>
10 #error functionality has not yet been implemented
11 
12 
13 /* Mode bits for msgget(), semget(), and shmget() */
14 #define IPC_CREAT	01000	/* create key */
15 #define IPC_EXCL	02000	/* fail if key exists */
16 #define IPC_NOWAIT	04000	/* do not block */
17 
18 /* Control commands for msgctl(), semctl(), and shmctl() */
19 #define IPC_RMID	0		/* remove identifier */
20 #define IPC_SET		1
21 #define IPC_STAT	2
22 
23 /* Private key */
24 #define IPC_PRIVATE	0
25 
26 
27 struct ipc_perm {
28 	key_t	key;
29 	uid_t	uid;			/* owner's user ID */
30 	gid_t	gid;			/* owner's group ID */
31 	uid_t	cuid;			/* creator's user ID */
32 	gid_t	cgid;			/* creator's group ID */
33 	mode_t	mode;			/* Read/write permission */
34 };
35 
36 
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40 
41 key_t ftok(const char *path, int id);
42 
43 #ifdef __cplusplus
44 }
45 #endif
46 
47 #endif	/* _SYS_IPC_H */
48