aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/seccomp.h
diff options
context:
space:
mode:
authorWill Drewry <wad@chromium.org>2012-04-12 17:47:54 -0400
committerJames Morris <james.l.morris@oracle.com>2012-04-13 21:13:19 -0400
commit932ecebb0405b9a41cd18946e6cff8a17d434e23 (patch)
treedc40e09ad9bd9964c93023c329d91296009d7e33 /include/linux/seccomp.h
parent0c5fe1b4221c6701224c2601cf3c692e5721103e (diff)
seccomp: kill the seccomp_t typedef
Replaces the seccomp_t typedef with struct seccomp to match modern kernel style. Signed-off-by: Will Drewry <wad@chromium.org> Reviewed-by: James Morris <jmorris@namei.org> Acked-by: Serge Hallyn <serge.hallyn@canonical.com> Acked-by: Eric Paris <eparis@redhat.com> v18: rebase ... v14: rebase/nochanges v13: rebase on to 88ebdda6159ffc15699f204c33feb3e431bf9bdc v12: rebase on to linux-next v8-v11: no changes v7: struct seccomp_struct -> struct seccomp v6: original inclusion in this series. Signed-off-by: James Morris <james.l.morris@oracle.com>
Diffstat (limited to 'include/linux/seccomp.h')
-rw-r--r--include/linux/seccomp.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/linux/seccomp.h b/include/linux/seccomp.h
index cc7a4e9cc7ad..d61f27fcaa97 100644
--- a/include/linux/seccomp.h
+++ b/include/linux/seccomp.h
@@ -7,7 +7,9 @@
7#include <linux/thread_info.h> 7#include <linux/thread_info.h>
8#include <asm/seccomp.h> 8#include <asm/seccomp.h>
9 9
10typedef struct { int mode; } seccomp_t; 10struct seccomp {
11 int mode;
12};
11 13
12extern void __secure_computing(int); 14extern void __secure_computing(int);
13static inline void secure_computing(int this_syscall) 15static inline void secure_computing(int this_syscall)
@@ -19,7 +21,7 @@ static inline void secure_computing(int this_syscall)
19extern long prctl_get_seccomp(void); 21extern long prctl_get_seccomp(void);
20extern long prctl_set_seccomp(unsigned long); 22extern long prctl_set_seccomp(unsigned long);
21 23
22static inline int seccomp_mode(seccomp_t *s) 24static inline int seccomp_mode(struct seccomp *s)
23{ 25{
24 return s->mode; 26 return s->mode;
25} 27}
@@ -28,7 +30,7 @@ static inline int seccomp_mode(seccomp_t *s)
28 30
29#include <linux/errno.h> 31#include <linux/errno.h>
30 32
31typedef struct { } seccomp_t; 33struct seccomp { };
32 34
33#define secure_computing(x) do { } while (0) 35#define secure_computing(x) do { } while (0)
34 36
@@ -42,7 +44,7 @@ static inline long prctl_set_seccomp(unsigned long arg2)
42 return -EINVAL; 44 return -EINVAL;
43} 45}
44 46
45static inline int seccomp_mode(seccomp_t *s) 47static inline int seccomp_mode(struct seccomp *s)
46{ 48{
47 return 0; 49 return 0;
48} 50}