00db10
Backport of this upstream commit, with ports/ readded to the path.
00db10
00db10
commit 5c40c3bab2fddaca8cfe12d75944d1fef8adf1a4
00db10
Author: Alan Hayward <alan.hayward@arm.com>
00db10
Date:   Tue Nov 11 16:32:34 2014 +0000
00db10
00db10
    [AArch64] Add ipc.h.
00db10
    
00db10
    Adding ipc.h for AArch64 adjusted to behave correctly on big endian
00db10
    targets.
00db10
00db10
diff --git a/ports/sysdeps/unix/sysv/linux/aarch64/bits/ipc.h b/ports/sysdeps/unix/sysv/linux/aarch64/bits/ipc.h
00db10
new file mode 100644
00db10
index 0000000..aa50eb0
00db10
--- /dev/null
00db10
+++ b/ports/sysdeps/unix/sysv/linux/aarch64/bits/ipc.h
00db10
@@ -0,0 +1,54 @@
00db10
+/* Copyright (C) 1995-2014 Free Software Foundation, Inc.
00db10
+   This file is part of the GNU C Library.
00db10
+
00db10
+   The GNU C Library is free software; you can redistribute it and/or
00db10
+   modify it under the terms of the GNU Lesser General Public
00db10
+   License as published by the Free Software Foundation; either
00db10
+   version 2.1 of the License, or (at your option) any later version.
00db10
+
00db10
+   The GNU C Library is distributed in the hope that it will be useful,
00db10
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
00db10
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00db10
+   Lesser General Public License for more details.
00db10
+
00db10
+   You should have received a copy of the GNU Lesser General Public
00db10
+   License along with the GNU C Library; if not, see
00db10
+   <http://www.gnu.org/licenses/>.  */
00db10
+
00db10
+#ifndef _SYS_IPC_H
00db10
+# error "Never use <bits/ipc.h> directly; include <sys/ipc.h> instead."
00db10
+#endif
00db10
+
00db10
+#include <bits/types.h>
00db10
+
00db10
+/* Mode bits for `msgget', `semget', and `shmget'.  */
00db10
+#define IPC_CREAT	01000		/* Create key if key does not exist. */
00db10
+#define IPC_EXCL	02000		/* Fail if key exists.  */
00db10
+#define IPC_NOWAIT	04000		/* Return error on wait.  */
00db10
+
00db10
+/* Control commands for `msgctl', `semctl', and `shmctl'.  */
00db10
+#define IPC_RMID	0		/* Remove identifier.  */
00db10
+#define IPC_SET		1		/* Set `ipc_perm' options.  */
00db10
+#define IPC_STAT	2		/* Get `ipc_perm' options.  */
00db10
+#ifdef __USE_GNU
00db10
+# define IPC_INFO	3		/* See ipcs.  */
00db10
+#endif
00db10
+
00db10
+/* Special key values.  */
00db10
+#define IPC_PRIVATE	((__key_t) 0)	/* Private key.  */
00db10
+
00db10
+
00db10
+/* Data structure used to pass permission information to IPC operations.  */
00db10
+struct ipc_perm
00db10
+  {
00db10
+    __key_t __key;			/* Key.  */
00db10
+    __uid_t uid;			/* Owner's user ID.  */
00db10
+    __gid_t gid;			/* Owner's group ID.  */
00db10
+    __uid_t cuid;			/* Creator's user ID.  */
00db10
+    __gid_t cgid;			/* Creator's group ID.  */
00db10
+    unsigned int mode;			/* Read/write permission.  */
00db10
+    unsigned short int __seq;		/* Sequence number.  */
00db10
+    unsigned short int __pad1;
00db10
+    __syscall_ulong_t __glibc_reserved1;
00db10
+    __syscall_ulong_t __glibc_reserved2;
00db10
+  };