diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/file.h | 8 | ||||
-rw-r--r-- | include/linux/fs.h | 1 | ||||
-rw-r--r-- | include/linux/generic_acl.h | 41 | ||||
-rw-r--r-- | include/linux/ima.h | 12 | ||||
-rw-r--r-- | include/linux/mnt_namespace.h | 1 | ||||
-rw-r--r-- | include/linux/shmem_fs.h | 16 | ||||
-rw-r--r-- | include/linux/xattr.h | 13 |
7 files changed, 22 insertions, 70 deletions
diff --git a/include/linux/file.h b/include/linux/file.h index 335a0a5c316e..5555508fd517 100644 --- a/include/linux/file.h +++ b/include/linux/file.h | |||
@@ -18,11 +18,9 @@ extern void drop_file_write_access(struct file *file); | |||
18 | struct file_operations; | 18 | struct file_operations; |
19 | struct vfsmount; | 19 | struct vfsmount; |
20 | struct dentry; | 20 | struct dentry; |
21 | extern int init_file(struct file *, struct vfsmount *mnt, | 21 | struct path; |
22 | struct dentry *dentry, fmode_t mode, | 22 | extern struct file *alloc_file(struct path *, fmode_t mode, |
23 | const struct file_operations *fop); | 23 | const struct file_operations *fop); |
24 | extern struct file *alloc_file(struct vfsmount *, struct dentry *dentry, | ||
25 | fmode_t mode, const struct file_operations *fop); | ||
26 | 24 | ||
27 | static inline void fput_light(struct file *file, int fput_needed) | 25 | static inline void fput_light(struct file *file, int fput_needed) |
28 | { | 26 | { |
diff --git a/include/linux/fs.h b/include/linux/fs.h index b23a7018eb90..7c8ff12d1995 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -2189,7 +2189,6 @@ static inline void insert_inode_hash(struct inode *inode) { | |||
2189 | __insert_inode_hash(inode, inode->i_ino); | 2189 | __insert_inode_hash(inode, inode->i_ino); |
2190 | } | 2190 | } |
2191 | 2191 | ||
2192 | extern struct file * get_empty_filp(void); | ||
2193 | extern void file_move(struct file *f, struct list_head *list); | 2192 | extern void file_move(struct file *f, struct list_head *list); |
2194 | extern void file_kill(struct file *f); | 2193 | extern void file_kill(struct file *f); |
2195 | #ifdef CONFIG_BLOCK | 2194 | #ifdef CONFIG_BLOCK |
diff --git a/include/linux/generic_acl.h b/include/linux/generic_acl.h index 886f5faa08cb..ca666d18ed67 100644 --- a/include/linux/generic_acl.h +++ b/include/linux/generic_acl.h | |||
@@ -1,36 +1,15 @@ | |||
1 | /* | 1 | #ifndef LINUX_GENERIC_ACL_H |
2 | * include/linux/generic_acl.h | 2 | #define LINUX_GENERIC_ACL_H |
3 | * | ||
4 | * (C) 2005 Andreas Gruenbacher <agruen@suse.de> | ||
5 | * | ||
6 | * This file is released under the GPL. | ||
7 | */ | ||
8 | 3 | ||
9 | #ifndef GENERIC_ACL_H | 4 | #include <linux/xattr.h> |
10 | #define GENERIC_ACL_H | ||
11 | 5 | ||
12 | #include <linux/posix_acl.h> | 6 | struct inode; |
13 | #include <linux/posix_acl_xattr.h> | ||
14 | 7 | ||
15 | /** | 8 | extern struct xattr_handler generic_acl_access_handler; |
16 | * struct generic_acl_operations - filesystem operations | 9 | extern struct xattr_handler generic_acl_default_handler; |
17 | * | ||
18 | * Filesystems must make these operations available to the generic | ||
19 | * operations. | ||
20 | */ | ||
21 | struct generic_acl_operations { | ||
22 | struct posix_acl *(*getacl)(struct inode *, int); | ||
23 | void (*setacl)(struct inode *, int, struct posix_acl *); | ||
24 | }; | ||
25 | 10 | ||
26 | size_t generic_acl_list(struct inode *, struct generic_acl_operations *, int, | 11 | int generic_acl_init(struct inode *, struct inode *); |
27 | char *, size_t); | 12 | int generic_acl_chmod(struct inode *); |
28 | int generic_acl_get(struct inode *, struct generic_acl_operations *, int, | 13 | int generic_check_acl(struct inode *inode, int mask); |
29 | void *, size_t); | ||
30 | int generic_acl_set(struct inode *, struct generic_acl_operations *, int, | ||
31 | const void *, size_t); | ||
32 | int generic_acl_init(struct inode *, struct inode *, | ||
33 | struct generic_acl_operations *); | ||
34 | int generic_acl_chmod(struct inode *, struct generic_acl_operations *); | ||
35 | 14 | ||
36 | #endif | 15 | #endif /* LINUX_GENERIC_ACL_H */ |
diff --git a/include/linux/ima.h b/include/linux/ima.h index 0e3f2a4c25f6..99dc6d5cf7e5 100644 --- a/include/linux/ima.h +++ b/include/linux/ima.h | |||
@@ -13,18 +13,14 @@ | |||
13 | #include <linux/fs.h> | 13 | #include <linux/fs.h> |
14 | struct linux_binprm; | 14 | struct linux_binprm; |
15 | 15 | ||
16 | #define IMA_COUNT_UPDATE 1 | ||
17 | #define IMA_COUNT_LEAVE 0 | ||
18 | |||
19 | #ifdef CONFIG_IMA | 16 | #ifdef CONFIG_IMA |
20 | extern int ima_bprm_check(struct linux_binprm *bprm); | 17 | extern int ima_bprm_check(struct linux_binprm *bprm); |
21 | extern int ima_inode_alloc(struct inode *inode); | 18 | extern int ima_inode_alloc(struct inode *inode); |
22 | extern void ima_inode_free(struct inode *inode); | 19 | extern void ima_inode_free(struct inode *inode); |
23 | extern int ima_path_check(struct path *path, int mask, int update_counts); | 20 | extern int ima_path_check(struct path *path, int mask); |
24 | extern void ima_file_free(struct file *file); | 21 | extern void ima_file_free(struct file *file); |
25 | extern int ima_file_mmap(struct file *file, unsigned long prot); | 22 | extern int ima_file_mmap(struct file *file, unsigned long prot); |
26 | extern void ima_counts_get(struct file *file); | 23 | extern void ima_counts_get(struct file *file); |
27 | extern void ima_counts_put(struct path *path, int mask); | ||
28 | 24 | ||
29 | #else | 25 | #else |
30 | static inline int ima_bprm_check(struct linux_binprm *bprm) | 26 | static inline int ima_bprm_check(struct linux_binprm *bprm) |
@@ -42,7 +38,7 @@ static inline void ima_inode_free(struct inode *inode) | |||
42 | return; | 38 | return; |
43 | } | 39 | } |
44 | 40 | ||
45 | static inline int ima_path_check(struct path *path, int mask, int update_counts) | 41 | static inline int ima_path_check(struct path *path, int mask) |
46 | { | 42 | { |
47 | return 0; | 43 | return 0; |
48 | } | 44 | } |
@@ -62,9 +58,5 @@ static inline void ima_counts_get(struct file *file) | |||
62 | return; | 58 | return; |
63 | } | 59 | } |
64 | 60 | ||
65 | static inline void ima_counts_put(struct path *path, int mask) | ||
66 | { | ||
67 | return; | ||
68 | } | ||
69 | #endif /* CONFIG_IMA_H */ | 61 | #endif /* CONFIG_IMA_H */ |
70 | #endif /* _LINUX_IMA_H */ | 62 | #endif /* _LINUX_IMA_H */ |
diff --git a/include/linux/mnt_namespace.h b/include/linux/mnt_namespace.h index d74785c2393a..d9ebf1037dfa 100644 --- a/include/linux/mnt_namespace.h +++ b/include/linux/mnt_namespace.h | |||
@@ -23,7 +23,6 @@ struct proc_mounts { | |||
23 | 23 | ||
24 | struct fs_struct; | 24 | struct fs_struct; |
25 | 25 | ||
26 | extern struct mnt_namespace *create_mnt_ns(struct vfsmount *mnt); | ||
27 | extern struct mnt_namespace *copy_mnt_ns(unsigned long, struct mnt_namespace *, | 26 | extern struct mnt_namespace *copy_mnt_ns(unsigned long, struct mnt_namespace *, |
28 | struct fs_struct *); | 27 | struct fs_struct *); |
29 | extern void put_mnt_ns(struct mnt_namespace *ns); | 28 | extern void put_mnt_ns(struct mnt_namespace *ns); |
diff --git a/include/linux/shmem_fs.h b/include/linux/shmem_fs.h index deee7afd8d66..e164291fb3e7 100644 --- a/include/linux/shmem_fs.h +++ b/include/linux/shmem_fs.h | |||
@@ -41,20 +41,4 @@ static inline struct shmem_inode_info *SHMEM_I(struct inode *inode) | |||
41 | extern int init_tmpfs(void); | 41 | extern int init_tmpfs(void); |
42 | extern int shmem_fill_super(struct super_block *sb, void *data, int silent); | 42 | extern int shmem_fill_super(struct super_block *sb, void *data, int silent); |
43 | 43 | ||
44 | #ifdef CONFIG_TMPFS_POSIX_ACL | ||
45 | int shmem_check_acl(struct inode *, int); | ||
46 | int shmem_acl_init(struct inode *, struct inode *); | ||
47 | |||
48 | extern struct xattr_handler shmem_xattr_acl_access_handler; | ||
49 | extern struct xattr_handler shmem_xattr_acl_default_handler; | ||
50 | |||
51 | extern struct generic_acl_operations shmem_acl_ops; | ||
52 | |||
53 | #else | ||
54 | static inline int shmem_acl_init(struct inode *inode, struct inode *dir) | ||
55 | { | ||
56 | return 0; | ||
57 | } | ||
58 | #endif /* CONFIG_TMPFS_POSIX_ACL */ | ||
59 | |||
60 | #endif | 44 | #endif |
diff --git a/include/linux/xattr.h b/include/linux/xattr.h index 5c84af8c5f6f..fb9b7e6e1e2d 100644 --- a/include/linux/xattr.h +++ b/include/linux/xattr.h | |||
@@ -38,12 +38,13 @@ struct dentry; | |||
38 | 38 | ||
39 | struct xattr_handler { | 39 | struct xattr_handler { |
40 | char *prefix; | 40 | char *prefix; |
41 | size_t (*list)(struct inode *inode, char *list, size_t list_size, | 41 | int flags; /* fs private flags passed back to the handlers */ |
42 | const char *name, size_t name_len); | 42 | size_t (*list)(struct dentry *dentry, char *list, size_t list_size, |
43 | int (*get)(struct inode *inode, const char *name, void *buffer, | 43 | const char *name, size_t name_len, int handler_flags); |
44 | size_t size); | 44 | int (*get)(struct dentry *dentry, const char *name, void *buffer, |
45 | int (*set)(struct inode *inode, const char *name, const void *buffer, | 45 | size_t size, int handler_flags); |
46 | size_t size, int flags); | 46 | int (*set)(struct dentry *dentry, const char *name, const void *buffer, |
47 | size_t size, int flags, int handler_flags); | ||
47 | }; | 48 | }; |
48 | 49 | ||
49 | ssize_t xattr_getsecurity(struct inode *, const char *, void *, size_t); | 50 | ssize_t xattr_getsecurity(struct inode *, const char *, void *, size_t); |