summaryrefslogtreecommitdiff
path: root/include/uapi/asm-generic
diff options
context:
space:
mode:
Diffstat (limited to 'include/uapi/asm-generic')
-rw-r--r--include/uapi/asm-generic/errno.h4
-rw-r--r--include/uapi/asm-generic/fcntl.h54
-rw-r--r--include/uapi/asm-generic/mman-common.h1
-rw-r--r--include/uapi/asm-generic/param.h6
-rw-r--r--include/uapi/asm-generic/posix_types.h1
-rw-r--r--include/uapi/asm-generic/socket.h5
-rw-r--r--include/uapi/asm-generic/unistd.h15
7 files changed, 63 insertions, 23 deletions
diff --git a/include/uapi/asm-generic/errno.h b/include/uapi/asm-generic/errno.h
index cf9c51ac49f9..bd78e69e0a43 100644
--- a/include/uapi/asm-generic/errno.h
+++ b/include/uapi/asm-generic/errno.h
@@ -55,6 +55,7 @@
#define EMULTIHOP 72 /* Multihop attempted */
#define EDOTDOT 73 /* RFS specific error */
#define EBADMSG 74 /* Not a data message */
+#define EFSBADCRC EBADMSG /* Bad CRC detected */
#define EOVERFLOW 75 /* Value too large for defined data type */
#define ENOTUNIQ 76 /* Name not unique on network */
#define EBADFD 77 /* File descriptor in bad state */
@@ -98,6 +99,7 @@
#define EINPROGRESS 115 /* Operation now in progress */
#define ESTALE 116 /* Stale file handle */
#define EUCLEAN 117 /* Structure needs cleaning */
+#define EFSCORRUPTED EUCLEAN /* Filesystem is corrupted */
#define ENOTNAM 118 /* Not a XENIX named type file */
#define ENAVAIL 119 /* No XENIX semaphores available */
#define EISNAM 120 /* Is a named type file */
@@ -120,4 +122,6 @@
#define EHWPOISON 133 /* Memory page has hardware error */
+#define EFTYPE 134 /* Wrong file type for the intended operation */
+
#endif
diff --git a/include/uapi/asm-generic/fcntl.h b/include/uapi/asm-generic/fcntl.h
index 613475285643..883cfd7de2ef 100644
--- a/include/uapi/asm-generic/fcntl.h
+++ b/include/uapi/asm-generic/fcntl.h
@@ -15,51 +15,55 @@
* When introducing new O_* bits, please check its uniqueness in fcntl_init().
*/
-#define O_ACCMODE 00000003
-#define O_RDONLY 00000000
-#define O_WRONLY 00000001
-#define O_RDWR 00000002
+#define O_ACCMODE 3
+#define O_RDONLY 0
+#define O_WRONLY (1 << 0)
+#define O_RDWR (1 << 1)
+/* (1 << 2) must not be used -- it collides with flags on alpha, sparc */
+/* (1 << 3) must not be used -- it collides with flags on alpha, mips, parisc, sparc */
+/* (1 << 4) must not be used -- it collides with flags on mips */
+/* (1 << 5) is free */
#ifndef O_CREAT
-#define O_CREAT 00000100 /* not fcntl */
+#define O_CREAT (1 << 6) /* not fcntl */
#endif
#ifndef O_EXCL
-#define O_EXCL 00000200 /* not fcntl */
+#define O_EXCL (1 << 7) /* not fcntl */
#endif
#ifndef O_NOCTTY
-#define O_NOCTTY 00000400 /* not fcntl */
+#define O_NOCTTY (1 << 8) /* not fcntl */
#endif
#ifndef O_TRUNC
-#define O_TRUNC 00001000 /* not fcntl */
+#define O_TRUNC (1 << 9) /* not fcntl */
#endif
#ifndef O_APPEND
-#define O_APPEND 00002000
+#define O_APPEND (1 << 10)
#endif
#ifndef O_NONBLOCK
-#define O_NONBLOCK 00004000
+#define O_NONBLOCK (1 << 11)
#endif
#ifndef O_DSYNC
-#define O_DSYNC 00010000 /* used to be O_SYNC, see below */
+#define O_DSYNC (1 << 12) /* used to be O_SYNC, see below */
#endif
#ifndef FASYNC
-#define FASYNC 00020000 /* fcntl, for BSD compatibility */
+#define FASYNC (1 << 13) /* fcntl, for BSD compatibility */
#endif
#ifndef O_DIRECT
-#define O_DIRECT 00040000 /* direct disk access hint */
+#define O_DIRECT (1 << 14) /* direct disk access hint */
#endif
#ifndef O_LARGEFILE
-#define O_LARGEFILE 00100000
+#define O_LARGEFILE (1 << 15)
#endif
#ifndef O_DIRECTORY
-#define O_DIRECTORY 00200000 /* must be a directory */
+#define O_DIRECTORY (1 << 16) /* must be a directory */
#endif
#ifndef O_NOFOLLOW
-#define O_NOFOLLOW 00400000 /* don't follow links */
+#define O_NOFOLLOW (1 << 17) /* don't follow links */
#endif
#ifndef O_NOATIME
-#define O_NOATIME 01000000
+#define O_NOATIME (1 << 18)
#endif
#ifndef O_CLOEXEC
-#define O_CLOEXEC 02000000 /* set close_on_exec */
+#define O_CLOEXEC (1 << 19) /* set close_on_exec */
#endif
/*
@@ -76,16 +80,20 @@
* Note: __O_SYNC must never be used directly.
*/
#ifndef O_SYNC
-#define __O_SYNC 04000000
+#define __O_SYNC (1 << 20)
#define O_SYNC (__O_SYNC|O_DSYNC)
#endif
#ifndef O_PATH
-#define O_PATH 010000000
+#define O_PATH (1 << 21)
#endif
#ifndef __O_TMPFILE
-#define __O_TMPFILE 020000000
+#define __O_TMPFILE (1 << 22)
+#endif
+
+#ifndef O_EMPTYPATH
+#define O_EMPTYPATH (1 << 26) /* allow empty path */
#endif
/* a horrid kludge trying to make sure that this will fail on old kernels */
@@ -95,6 +103,10 @@
#define O_NDELAY O_NONBLOCK
#endif
+/* (1 << 23) must not be used -- it collides with flags on alpha, parisc, sparc */
+/* (1 << 24) must not be used -- it collides with flags on alpha, sparc */
+/* (1 << 25) must not be used -- it collides with flags on sparc */
+
#define F_DUPFD 0 /* dup */
#define F_GETFD 1 /* get close_on_exec */
#define F_SETFD 2 /* set/clear close_on_exec */
diff --git a/include/uapi/asm-generic/mman-common.h b/include/uapi/asm-generic/mman-common.h
index 1ea2c4c33b86..ef1c27fa3c57 100644
--- a/include/uapi/asm-generic/mman-common.h
+++ b/include/uapi/asm-generic/mman-common.h
@@ -85,6 +85,7 @@
/* compatibility flags */
#define MAP_FILE 0
+#define PKEY_UNRESTRICTED 0x0
#define PKEY_DISABLE_ACCESS 0x1
#define PKEY_DISABLE_WRITE 0x2
#define PKEY_ACCESS_MASK (PKEY_DISABLE_ACCESS |\
diff --git a/include/uapi/asm-generic/param.h b/include/uapi/asm-generic/param.h
index baad02ea7f93..3ed505dfea13 100644
--- a/include/uapi/asm-generic/param.h
+++ b/include/uapi/asm-generic/param.h
@@ -2,8 +2,12 @@
#ifndef _UAPI__ASM_GENERIC_PARAM_H
#define _UAPI__ASM_GENERIC_PARAM_H
+#ifndef __USER_HZ
+#define __USER_HZ 100
+#endif
+
#ifndef HZ
-#define HZ 100
+#define HZ __USER_HZ
#endif
#ifndef EXEC_PAGESIZE
diff --git a/include/uapi/asm-generic/posix_types.h b/include/uapi/asm-generic/posix_types.h
index b5f7594eee7a..0a90ad92dbf3 100644
--- a/include/uapi/asm-generic/posix_types.h
+++ b/include/uapi/asm-generic/posix_types.h
@@ -86,6 +86,7 @@ typedef struct {
*/
typedef __kernel_long_t __kernel_off_t;
typedef long long __kernel_loff_t;
+typedef unsigned long long __kernel_uoff_t;
typedef __kernel_long_t __kernel_old_time_t;
#ifndef __KERNEL__
typedef __kernel_long_t __kernel_time_t;
diff --git a/include/uapi/asm-generic/socket.h b/include/uapi/asm-generic/socket.h
index aa5016ff3d91..53b5a8c002b1 100644
--- a/include/uapi/asm-generic/socket.h
+++ b/include/uapi/asm-generic/socket.h
@@ -145,6 +145,11 @@
#define SO_RCVPRIORITY 82
+#define SO_PASSRIGHTS 83
+
+#define SO_INQ 84
+#define SCM_INQ SO_INQ
+
#if !defined(__KERNEL__)
#if __BITS_PER_LONG == 64 || (defined(__x86_64__) && defined(__ILP32__))
diff --git a/include/uapi/asm-generic/unistd.h b/include/uapi/asm-generic/unistd.h
index 88dc393c2bca..a627acc8fb5f 100644
--- a/include/uapi/asm-generic/unistd.h
+++ b/include/uapi/asm-generic/unistd.h
@@ -849,9 +849,22 @@ __SYSCALL(__NR_getxattrat, sys_getxattrat)
__SYSCALL(__NR_listxattrat, sys_listxattrat)
#define __NR_removexattrat 466
__SYSCALL(__NR_removexattrat, sys_removexattrat)
+#define __NR_open_tree_attr 467
+__SYSCALL(__NR_open_tree_attr, sys_open_tree_attr)
+
+/* fs/inode.c */
+#define __NR_file_getattr 468
+__SYSCALL(__NR_file_getattr, sys_file_getattr)
+#define __NR_file_setattr 469
+__SYSCALL(__NR_file_setattr, sys_file_setattr)
+#define __NR_listns 470
+__SYSCALL(__NR_listns, sys_listns)
+
+#define __NR_rseq_slice_yield 471
+__SYSCALL(__NR_rseq_slice_yield, sys_rseq_slice_yield)
#undef __NR_syscalls
-#define __NR_syscalls 467
+#define __NR_syscalls 472
/*
* 32 bit systems traditionally used different