diff options
Diffstat (limited to 'include/linux/binfmts.h')
-rw-r--r-- | include/linux/binfmts.h | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/include/linux/binfmts.h b/include/linux/binfmts.h index 77b4a9e46004..61ee18c1bdb4 100644 --- a/include/linux/binfmts.h +++ b/include/linux/binfmts.h | |||
@@ -35,8 +35,7 @@ struct linux_binprm{ | |||
35 | #endif | 35 | #endif |
36 | struct mm_struct *mm; | 36 | struct mm_struct *mm; |
37 | unsigned long p; /* current top of mem */ | 37 | unsigned long p; /* current top of mem */ |
38 | unsigned int sh_bang:1, | 38 | unsigned int |
39 | misc_bang:1, | ||
40 | cred_prepared:1,/* true if creds already prepared (multiple | 39 | cred_prepared:1,/* true if creds already prepared (multiple |
41 | * preps happen for interpreters) */ | 40 | * preps happen for interpreters) */ |
42 | cap_effective:1;/* true if has elevated effective capabilities, | 41 | cap_effective:1;/* true if has elevated effective capabilities, |
@@ -83,7 +82,19 @@ struct linux_binfmt { | |||
83 | int hasvdso; | 82 | int hasvdso; |
84 | }; | 83 | }; |
85 | 84 | ||
86 | extern int register_binfmt(struct linux_binfmt *); | 85 | extern int __register_binfmt(struct linux_binfmt *fmt, int insert); |
86 | |||
87 | /* Registration of default binfmt handlers */ | ||
88 | static inline int register_binfmt(struct linux_binfmt *fmt) | ||
89 | { | ||
90 | return __register_binfmt(fmt, 0); | ||
91 | } | ||
92 | /* Same as above, but adds a new binfmt at the top of the list */ | ||
93 | static inline int insert_binfmt(struct linux_binfmt *fmt) | ||
94 | { | ||
95 | return __register_binfmt(fmt, 1); | ||
96 | } | ||
97 | |||
87 | extern void unregister_binfmt(struct linux_binfmt *); | 98 | extern void unregister_binfmt(struct linux_binfmt *); |
88 | 99 | ||
89 | extern int prepare_binprm(struct linux_binprm *); | 100 | extern int prepare_binprm(struct linux_binprm *); |