diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/coda_linux.h | 2 | ||||
-rw-r--r-- | include/linux/fs.h | 57 | ||||
-rw-r--r-- | include/linux/fs_struct.h | 3 | ||||
-rw-r--r-- | include/linux/mount.h | 2 | ||||
-rw-r--r-- | include/linux/namei.h | 19 | ||||
-rw-r--r-- | include/linux/nfs_fs.h | 3 | ||||
-rw-r--r-- | include/linux/proc_fs.h | 5 | ||||
-rw-r--r-- | include/linux/reiserfs_xattr.h | 2 | ||||
-rw-r--r-- | include/linux/security.h | 7 | ||||
-rw-r--r-- | include/linux/shmem_fs.h | 2 | ||||
-rw-r--r-- | include/linux/sysctl.h | 25 |
11 files changed, 75 insertions, 52 deletions
diff --git a/include/linux/coda_linux.h b/include/linux/coda_linux.h index 31b75311e2ca..dcc228aa335a 100644 --- a/include/linux/coda_linux.h +++ b/include/linux/coda_linux.h | |||
@@ -37,7 +37,7 @@ extern const struct file_operations coda_ioctl_operations; | |||
37 | /* operations shared over more than one file */ | 37 | /* operations shared over more than one file */ |
38 | int coda_open(struct inode *i, struct file *f); | 38 | int coda_open(struct inode *i, struct file *f); |
39 | int coda_release(struct inode *i, struct file *f); | 39 | int coda_release(struct inode *i, struct file *f); |
40 | int coda_permission(struct inode *inode, int mask, struct nameidata *nd); | 40 | int coda_permission(struct inode *inode, int mask); |
41 | int coda_revalidate_inode(struct dentry *); | 41 | int coda_revalidate_inode(struct dentry *); |
42 | int coda_getattr(struct vfsmount *, struct dentry *, struct kstat *); | 42 | int coda_getattr(struct vfsmount *, struct dentry *, struct kstat *); |
43 | int coda_setattr(struct dentry *, struct iattr *); | 43 | int coda_setattr(struct dentry *, struct iattr *); |
diff --git a/include/linux/fs.h b/include/linux/fs.h index 53d2edb709b3..8252b045e624 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -60,6 +60,8 @@ extern int dir_notify_enable; | |||
60 | #define MAY_WRITE 2 | 60 | #define MAY_WRITE 2 |
61 | #define MAY_READ 4 | 61 | #define MAY_READ 4 |
62 | #define MAY_APPEND 8 | 62 | #define MAY_APPEND 8 |
63 | #define MAY_ACCESS 16 | ||
64 | #define MAY_OPEN 32 | ||
63 | 65 | ||
64 | #define FMODE_READ 1 | 66 | #define FMODE_READ 1 |
65 | #define FMODE_WRITE 2 | 67 | #define FMODE_WRITE 2 |
@@ -277,7 +279,7 @@ extern int dir_notify_enable; | |||
277 | #include <linux/types.h> | 279 | #include <linux/types.h> |
278 | #include <linux/kdev_t.h> | 280 | #include <linux/kdev_t.h> |
279 | #include <linux/dcache.h> | 281 | #include <linux/dcache.h> |
280 | #include <linux/namei.h> | 282 | #include <linux/path.h> |
281 | #include <linux/stat.h> | 283 | #include <linux/stat.h> |
282 | #include <linux/cache.h> | 284 | #include <linux/cache.h> |
283 | #include <linux/kobject.h> | 285 | #include <linux/kobject.h> |
@@ -318,22 +320,23 @@ typedef void (dio_iodone_t)(struct kiocb *iocb, loff_t offset, | |||
318 | * Attribute flags. These should be or-ed together to figure out what | 320 | * Attribute flags. These should be or-ed together to figure out what |
319 | * has been changed! | 321 | * has been changed! |
320 | */ | 322 | */ |
321 | #define ATTR_MODE 1 | 323 | #define ATTR_MODE (1 << 0) |
322 | #define ATTR_UID 2 | 324 | #define ATTR_UID (1 << 1) |
323 | #define ATTR_GID 4 | 325 | #define ATTR_GID (1 << 2) |
324 | #define ATTR_SIZE 8 | 326 | #define ATTR_SIZE (1 << 3) |
325 | #define ATTR_ATIME 16 | 327 | #define ATTR_ATIME (1 << 4) |
326 | #define ATTR_MTIME 32 | 328 | #define ATTR_MTIME (1 << 5) |
327 | #define ATTR_CTIME 64 | 329 | #define ATTR_CTIME (1 << 6) |
328 | #define ATTR_ATIME_SET 128 | 330 | #define ATTR_ATIME_SET (1 << 7) |
329 | #define ATTR_MTIME_SET 256 | 331 | #define ATTR_MTIME_SET (1 << 8) |
330 | #define ATTR_FORCE 512 /* Not a change, but a change it */ | 332 | #define ATTR_FORCE (1 << 9) /* Not a change, but a change it */ |
331 | #define ATTR_ATTR_FLAG 1024 | 333 | #define ATTR_ATTR_FLAG (1 << 10) |
332 | #define ATTR_KILL_SUID 2048 | 334 | #define ATTR_KILL_SUID (1 << 11) |
333 | #define ATTR_KILL_SGID 4096 | 335 | #define ATTR_KILL_SGID (1 << 12) |
334 | #define ATTR_FILE 8192 | 336 | #define ATTR_FILE (1 << 13) |
335 | #define ATTR_KILL_PRIV 16384 | 337 | #define ATTR_KILL_PRIV (1 << 14) |
336 | #define ATTR_OPEN 32768 /* Truncating from open(O_TRUNC) */ | 338 | #define ATTR_OPEN (1 << 15) /* Truncating from open(O_TRUNC) */ |
339 | #define ATTR_TIMES_SET (1 << 16) | ||
337 | 340 | ||
338 | /* | 341 | /* |
339 | * This is the Inode Attributes structure, used for notify_change(). It | 342 | * This is the Inode Attributes structure, used for notify_change(). It |
@@ -792,7 +795,7 @@ struct file { | |||
792 | #define f_dentry f_path.dentry | 795 | #define f_dentry f_path.dentry |
793 | #define f_vfsmnt f_path.mnt | 796 | #define f_vfsmnt f_path.mnt |
794 | const struct file_operations *f_op; | 797 | const struct file_operations *f_op; |
795 | atomic_t f_count; | 798 | atomic_long_t f_count; |
796 | unsigned int f_flags; | 799 | unsigned int f_flags; |
797 | mode_t f_mode; | 800 | mode_t f_mode; |
798 | loff_t f_pos; | 801 | loff_t f_pos; |
@@ -821,8 +824,8 @@ extern spinlock_t files_lock; | |||
821 | #define file_list_lock() spin_lock(&files_lock); | 824 | #define file_list_lock() spin_lock(&files_lock); |
822 | #define file_list_unlock() spin_unlock(&files_lock); | 825 | #define file_list_unlock() spin_unlock(&files_lock); |
823 | 826 | ||
824 | #define get_file(x) atomic_inc(&(x)->f_count) | 827 | #define get_file(x) atomic_long_inc(&(x)->f_count) |
825 | #define file_count(x) atomic_read(&(x)->f_count) | 828 | #define file_count(x) atomic_long_read(&(x)->f_count) |
826 | 829 | ||
827 | #ifdef CONFIG_DEBUG_WRITECOUNT | 830 | #ifdef CONFIG_DEBUG_WRITECOUNT |
828 | static inline void file_take_write(struct file *f) | 831 | static inline void file_take_write(struct file *f) |
@@ -1136,7 +1139,7 @@ extern int vfs_permission(struct nameidata *, int); | |||
1136 | extern int vfs_create(struct inode *, struct dentry *, int, struct nameidata *); | 1139 | extern int vfs_create(struct inode *, struct dentry *, int, struct nameidata *); |
1137 | extern int vfs_mkdir(struct inode *, struct dentry *, int); | 1140 | extern int vfs_mkdir(struct inode *, struct dentry *, int); |
1138 | extern int vfs_mknod(struct inode *, struct dentry *, int, dev_t); | 1141 | extern int vfs_mknod(struct inode *, struct dentry *, int, dev_t); |
1139 | extern int vfs_symlink(struct inode *, struct dentry *, const char *, int); | 1142 | extern int vfs_symlink(struct inode *, struct dentry *, const char *); |
1140 | extern int vfs_link(struct dentry *, struct inode *, struct dentry *); | 1143 | extern int vfs_link(struct dentry *, struct inode *, struct dentry *); |
1141 | extern int vfs_rmdir(struct inode *, struct dentry *); | 1144 | extern int vfs_rmdir(struct inode *, struct dentry *); |
1142 | extern int vfs_unlink(struct inode *, struct dentry *); | 1145 | extern int vfs_unlink(struct inode *, struct dentry *); |
@@ -1272,7 +1275,7 @@ struct inode_operations { | |||
1272 | void * (*follow_link) (struct dentry *, struct nameidata *); | 1275 | void * (*follow_link) (struct dentry *, struct nameidata *); |
1273 | void (*put_link) (struct dentry *, struct nameidata *, void *); | 1276 | void (*put_link) (struct dentry *, struct nameidata *, void *); |
1274 | void (*truncate) (struct inode *); | 1277 | void (*truncate) (struct inode *); |
1275 | int (*permission) (struct inode *, int, struct nameidata *); | 1278 | int (*permission) (struct inode *, int); |
1276 | int (*setattr) (struct dentry *, struct iattr *); | 1279 | int (*setattr) (struct dentry *, struct iattr *); |
1277 | int (*getattr) (struct vfsmount *mnt, struct dentry *, struct kstat *); | 1280 | int (*getattr) (struct vfsmount *mnt, struct dentry *, struct kstat *); |
1278 | int (*setxattr) (struct dentry *, const char *,const void *,size_t,int); | 1281 | int (*setxattr) (struct dentry *, const char *,const void *,size_t,int); |
@@ -1696,9 +1699,9 @@ extern void init_special_inode(struct inode *, umode_t, dev_t); | |||
1696 | extern void make_bad_inode(struct inode *); | 1699 | extern void make_bad_inode(struct inode *); |
1697 | extern int is_bad_inode(struct inode *); | 1700 | extern int is_bad_inode(struct inode *); |
1698 | 1701 | ||
1699 | extern const struct file_operations read_fifo_fops; | 1702 | extern const struct file_operations read_pipefifo_fops; |
1700 | extern const struct file_operations write_fifo_fops; | 1703 | extern const struct file_operations write_pipefifo_fops; |
1701 | extern const struct file_operations rdwr_fifo_fops; | 1704 | extern const struct file_operations rdwr_pipefifo_fops; |
1702 | 1705 | ||
1703 | extern int fs_may_remount_ro(struct super_block *); | 1706 | extern int fs_may_remount_ro(struct super_block *); |
1704 | 1707 | ||
@@ -1767,7 +1770,7 @@ extern int do_remount_sb(struct super_block *sb, int flags, | |||
1767 | extern sector_t bmap(struct inode *, sector_t); | 1770 | extern sector_t bmap(struct inode *, sector_t); |
1768 | #endif | 1771 | #endif |
1769 | extern int notify_change(struct dentry *, struct iattr *); | 1772 | extern int notify_change(struct dentry *, struct iattr *); |
1770 | extern int permission(struct inode *, int, struct nameidata *); | 1773 | extern int inode_permission(struct inode *, int); |
1771 | extern int generic_permission(struct inode *, int, | 1774 | extern int generic_permission(struct inode *, int, |
1772 | int (*check_acl)(struct inode *, int)); | 1775 | int (*check_acl)(struct inode *, int)); |
1773 | 1776 | ||
@@ -1831,7 +1834,7 @@ extern void clear_inode(struct inode *); | |||
1831 | extern void destroy_inode(struct inode *); | 1834 | extern void destroy_inode(struct inode *); |
1832 | extern struct inode *new_inode(struct super_block *); | 1835 | extern struct inode *new_inode(struct super_block *); |
1833 | extern int should_remove_suid(struct dentry *); | 1836 | extern int should_remove_suid(struct dentry *); |
1834 | extern int remove_suid(struct dentry *); | 1837 | extern int file_remove_suid(struct file *); |
1835 | 1838 | ||
1836 | extern void __insert_inode_hash(struct inode *, unsigned long hashval); | 1839 | extern void __insert_inode_hash(struct inode *, unsigned long hashval); |
1837 | extern void remove_inode_hash(struct inode *); | 1840 | extern void remove_inode_hash(struct inode *); |
diff --git a/include/linux/fs_struct.h b/include/linux/fs_struct.h index 282f54219129..9e5a06e78d02 100644 --- a/include/linux/fs_struct.h +++ b/include/linux/fs_struct.h | |||
@@ -7,7 +7,7 @@ struct fs_struct { | |||
7 | atomic_t count; | 7 | atomic_t count; |
8 | rwlock_t lock; | 8 | rwlock_t lock; |
9 | int umask; | 9 | int umask; |
10 | struct path root, pwd, altroot; | 10 | struct path root, pwd; |
11 | }; | 11 | }; |
12 | 12 | ||
13 | #define INIT_FS { \ | 13 | #define INIT_FS { \ |
@@ -19,7 +19,6 @@ struct fs_struct { | |||
19 | extern struct kmem_cache *fs_cachep; | 19 | extern struct kmem_cache *fs_cachep; |
20 | 20 | ||
21 | extern void exit_fs(struct task_struct *); | 21 | extern void exit_fs(struct task_struct *); |
22 | extern void set_fs_altroot(void); | ||
23 | extern void set_fs_root(struct fs_struct *, struct path *); | 22 | extern void set_fs_root(struct fs_struct *, struct path *); |
24 | extern void set_fs_pwd(struct fs_struct *, struct path *); | 23 | extern void set_fs_pwd(struct fs_struct *, struct path *); |
25 | extern struct fs_struct *copy_fs_struct(struct fs_struct *); | 24 | extern struct fs_struct *copy_fs_struct(struct fs_struct *); |
diff --git a/include/linux/mount.h b/include/linux/mount.h index 4374d1adeb4b..b5efaa2132ab 100644 --- a/include/linux/mount.h +++ b/include/linux/mount.h | |||
@@ -47,7 +47,7 @@ struct vfsmount { | |||
47 | struct list_head mnt_child; /* and going through their mnt_child */ | 47 | struct list_head mnt_child; /* and going through their mnt_child */ |
48 | int mnt_flags; | 48 | int mnt_flags; |
49 | /* 4 bytes hole on 64bits arches */ | 49 | /* 4 bytes hole on 64bits arches */ |
50 | char *mnt_devname; /* Name of device e.g. /dev/dsk/hda1 */ | 50 | const char *mnt_devname; /* Name of device e.g. /dev/dsk/hda1 */ |
51 | struct list_head mnt_list; | 51 | struct list_head mnt_list; |
52 | struct list_head mnt_expire; /* link in fs-specific expiry list */ | 52 | struct list_head mnt_expire; /* link in fs-specific expiry list */ |
53 | struct list_head mnt_share; /* circular list of shared mounts */ | 53 | struct list_head mnt_share; /* circular list of shared mounts */ |
diff --git a/include/linux/namei.h b/include/linux/namei.h index 24d88e98a626..68f8c3203c89 100644 --- a/include/linux/namei.h +++ b/include/linux/namei.h | |||
@@ -47,27 +47,24 @@ enum {LAST_NORM, LAST_ROOT, LAST_DOT, LAST_DOTDOT, LAST_BIND}; | |||
47 | #define LOOKUP_DIRECTORY 2 | 47 | #define LOOKUP_DIRECTORY 2 |
48 | #define LOOKUP_CONTINUE 4 | 48 | #define LOOKUP_CONTINUE 4 |
49 | #define LOOKUP_PARENT 16 | 49 | #define LOOKUP_PARENT 16 |
50 | #define LOOKUP_NOALT 32 | ||
51 | #define LOOKUP_REVAL 64 | 50 | #define LOOKUP_REVAL 64 |
52 | /* | 51 | /* |
53 | * Intent data | 52 | * Intent data |
54 | */ | 53 | */ |
55 | #define LOOKUP_OPEN (0x0100) | 54 | #define LOOKUP_OPEN (0x0100) |
56 | #define LOOKUP_CREATE (0x0200) | 55 | #define LOOKUP_CREATE (0x0200) |
57 | #define LOOKUP_ACCESS (0x0400) | 56 | |
58 | #define LOOKUP_CHDIR (0x0800) | 57 | extern int user_path_at(int, const char __user *, unsigned, struct path *); |
59 | 58 | ||
60 | extern int __user_walk(const char __user *, unsigned, struct nameidata *); | 59 | #define user_path(name, path) user_path_at(AT_FDCWD, name, LOOKUP_FOLLOW, path) |
61 | extern int __user_walk_fd(int dfd, const char __user *, unsigned, struct nameidata *); | 60 | #define user_lpath(name, path) user_path_at(AT_FDCWD, name, 0, path) |
62 | #define user_path_walk(name,nd) \ | 61 | #define user_path_dir(name, path) \ |
63 | __user_walk_fd(AT_FDCWD, name, LOOKUP_FOLLOW, nd) | 62 | user_path_at(AT_FDCWD, name, LOOKUP_FOLLOW | LOOKUP_DIRECTORY, path) |
64 | #define user_path_walk_link(name,nd) \ | 63 | |
65 | __user_walk_fd(AT_FDCWD, name, 0, nd) | ||
66 | extern int path_lookup(const char *, unsigned, struct nameidata *); | 64 | extern int path_lookup(const char *, unsigned, struct nameidata *); |
67 | extern int vfs_path_lookup(struct dentry *, struct vfsmount *, | 65 | extern int vfs_path_lookup(struct dentry *, struct vfsmount *, |
68 | const char *, unsigned int, struct nameidata *); | 66 | const char *, unsigned int, struct nameidata *); |
69 | 67 | ||
70 | extern int __user_path_lookup_open(const char __user *, unsigned lookup_flags, struct nameidata *nd, int open_flags); | ||
71 | extern int path_lookup_open(int dfd, const char *name, unsigned lookup_flags, struct nameidata *, int open_flags); | 68 | extern int path_lookup_open(int dfd, const char *name, unsigned lookup_flags, struct nameidata *, int open_flags); |
72 | extern struct file *lookup_instantiate_filp(struct nameidata *nd, struct dentry *dentry, | 69 | extern struct file *lookup_instantiate_filp(struct nameidata *nd, struct dentry *dentry, |
73 | int (*open)(struct inode *, struct file *)); | 70 | int (*open)(struct inode *, struct file *)); |
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index 29d261918734..78a5922a2f11 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h | |||
@@ -42,7 +42,6 @@ | |||
42 | #include <linux/in.h> | 42 | #include <linux/in.h> |
43 | #include <linux/kref.h> | 43 | #include <linux/kref.h> |
44 | #include <linux/mm.h> | 44 | #include <linux/mm.h> |
45 | #include <linux/namei.h> | ||
46 | #include <linux/pagemap.h> | 45 | #include <linux/pagemap.h> |
47 | #include <linux/rbtree.h> | 46 | #include <linux/rbtree.h> |
48 | #include <linux/rwsem.h> | 47 | #include <linux/rwsem.h> |
@@ -332,7 +331,7 @@ extern int nfs_refresh_inode(struct inode *, struct nfs_fattr *); | |||
332 | extern int nfs_post_op_update_inode(struct inode *inode, struct nfs_fattr *fattr); | 331 | extern int nfs_post_op_update_inode(struct inode *inode, struct nfs_fattr *fattr); |
333 | extern int nfs_post_op_update_inode_force_wcc(struct inode *inode, struct nfs_fattr *fattr); | 332 | extern int nfs_post_op_update_inode_force_wcc(struct inode *inode, struct nfs_fattr *fattr); |
334 | extern int nfs_getattr(struct vfsmount *, struct dentry *, struct kstat *); | 333 | extern int nfs_getattr(struct vfsmount *, struct dentry *, struct kstat *); |
335 | extern int nfs_permission(struct inode *, int, struct nameidata *); | 334 | extern int nfs_permission(struct inode *, int); |
336 | extern int nfs_open(struct inode *, struct file *); | 335 | extern int nfs_open(struct inode *, struct file *); |
337 | extern int nfs_release(struct inode *, struct file *); | 336 | extern int nfs_release(struct inode *, struct file *); |
338 | extern int nfs_attribute_timeout(struct inode *inode); | 337 | extern int nfs_attribute_timeout(struct inode *inode); |
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h index f560d1705afe..fb61850d1cfc 100644 --- a/include/linux/proc_fs.h +++ b/include/linux/proc_fs.h | |||
@@ -282,11 +282,16 @@ union proc_op { | |||
282 | struct task_struct *task); | 282 | struct task_struct *task); |
283 | }; | 283 | }; |
284 | 284 | ||
285 | struct ctl_table_header; | ||
286 | struct ctl_table; | ||
287 | |||
285 | struct proc_inode { | 288 | struct proc_inode { |
286 | struct pid *pid; | 289 | struct pid *pid; |
287 | int fd; | 290 | int fd; |
288 | union proc_op op; | 291 | union proc_op op; |
289 | struct proc_dir_entry *pde; | 292 | struct proc_dir_entry *pde; |
293 | struct ctl_table_header *sysctl; | ||
294 | struct ctl_table *sysctl_entry; | ||
290 | struct inode vfs_inode; | 295 | struct inode vfs_inode; |
291 | }; | 296 | }; |
292 | 297 | ||
diff --git a/include/linux/reiserfs_xattr.h b/include/linux/reiserfs_xattr.h index 66a96814d614..af135ae895db 100644 --- a/include/linux/reiserfs_xattr.h +++ b/include/linux/reiserfs_xattr.h | |||
@@ -55,7 +55,7 @@ int reiserfs_removexattr(struct dentry *dentry, const char *name); | |||
55 | int reiserfs_delete_xattrs(struct inode *inode); | 55 | int reiserfs_delete_xattrs(struct inode *inode); |
56 | int reiserfs_chown_xattrs(struct inode *inode, struct iattr *attrs); | 56 | int reiserfs_chown_xattrs(struct inode *inode, struct iattr *attrs); |
57 | int reiserfs_xattr_init(struct super_block *sb, int mount_flags); | 57 | int reiserfs_xattr_init(struct super_block *sb, int mount_flags); |
58 | int reiserfs_permission(struct inode *inode, int mask, struct nameidata *nd); | 58 | int reiserfs_permission(struct inode *inode, int mask); |
59 | 59 | ||
60 | int reiserfs_xattr_del(struct inode *, const char *); | 60 | int reiserfs_xattr_del(struct inode *, const char *); |
61 | int reiserfs_xattr_get(const struct inode *, const char *, void *, size_t); | 61 | int reiserfs_xattr_get(const struct inode *, const char *, void *, size_t); |
diff --git a/include/linux/security.h b/include/linux/security.h index f0e9adb22ac2..fd96e7f8a6f9 100644 --- a/include/linux/security.h +++ b/include/linux/security.h | |||
@@ -1362,7 +1362,7 @@ struct security_operations { | |||
1362 | struct inode *new_dir, struct dentry *new_dentry); | 1362 | struct inode *new_dir, struct dentry *new_dentry); |
1363 | int (*inode_readlink) (struct dentry *dentry); | 1363 | int (*inode_readlink) (struct dentry *dentry); |
1364 | int (*inode_follow_link) (struct dentry *dentry, struct nameidata *nd); | 1364 | int (*inode_follow_link) (struct dentry *dentry, struct nameidata *nd); |
1365 | int (*inode_permission) (struct inode *inode, int mask, struct nameidata *nd); | 1365 | int (*inode_permission) (struct inode *inode, int mask); |
1366 | int (*inode_setattr) (struct dentry *dentry, struct iattr *attr); | 1366 | int (*inode_setattr) (struct dentry *dentry, struct iattr *attr); |
1367 | int (*inode_getattr) (struct vfsmount *mnt, struct dentry *dentry); | 1367 | int (*inode_getattr) (struct vfsmount *mnt, struct dentry *dentry); |
1368 | void (*inode_delete) (struct inode *inode); | 1368 | void (*inode_delete) (struct inode *inode); |
@@ -1628,7 +1628,7 @@ int security_inode_rename(struct inode *old_dir, struct dentry *old_dentry, | |||
1628 | struct inode *new_dir, struct dentry *new_dentry); | 1628 | struct inode *new_dir, struct dentry *new_dentry); |
1629 | int security_inode_readlink(struct dentry *dentry); | 1629 | int security_inode_readlink(struct dentry *dentry); |
1630 | int security_inode_follow_link(struct dentry *dentry, struct nameidata *nd); | 1630 | int security_inode_follow_link(struct dentry *dentry, struct nameidata *nd); |
1631 | int security_inode_permission(struct inode *inode, int mask, struct nameidata *nd); | 1631 | int security_inode_permission(struct inode *inode, int mask); |
1632 | int security_inode_setattr(struct dentry *dentry, struct iattr *attr); | 1632 | int security_inode_setattr(struct dentry *dentry, struct iattr *attr); |
1633 | int security_inode_getattr(struct vfsmount *mnt, struct dentry *dentry); | 1633 | int security_inode_getattr(struct vfsmount *mnt, struct dentry *dentry); |
1634 | void security_inode_delete(struct inode *inode); | 1634 | void security_inode_delete(struct inode *inode); |
@@ -2021,8 +2021,7 @@ static inline int security_inode_follow_link(struct dentry *dentry, | |||
2021 | return 0; | 2021 | return 0; |
2022 | } | 2022 | } |
2023 | 2023 | ||
2024 | static inline int security_inode_permission(struct inode *inode, int mask, | 2024 | static inline int security_inode_permission(struct inode *inode, int mask) |
2025 | struct nameidata *nd) | ||
2026 | { | 2025 | { |
2027 | return 0; | 2026 | return 0; |
2028 | } | 2027 | } |
diff --git a/include/linux/shmem_fs.h b/include/linux/shmem_fs.h index f2d12d5a21b8..fd83f2584b15 100644 --- a/include/linux/shmem_fs.h +++ b/include/linux/shmem_fs.h | |||
@@ -43,7 +43,7 @@ static inline struct shmem_inode_info *SHMEM_I(struct inode *inode) | |||
43 | } | 43 | } |
44 | 44 | ||
45 | #ifdef CONFIG_TMPFS_POSIX_ACL | 45 | #ifdef CONFIG_TMPFS_POSIX_ACL |
46 | int shmem_permission(struct inode *, int, struct nameidata *); | 46 | int shmem_permission(struct inode *, int); |
47 | int shmem_acl_init(struct inode *, struct inode *); | 47 | int shmem_acl_init(struct inode *, struct inode *); |
48 | void shmem_acl_destroy_inode(struct inode *); | 48 | void shmem_acl_destroy_inode(struct inode *); |
49 | 49 | ||
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h index 24141b4d1a11..d0437f36921f 100644 --- a/include/linux/sysctl.h +++ b/include/linux/sysctl.h | |||
@@ -947,6 +947,22 @@ struct ctl_table; | |||
947 | struct nsproxy; | 947 | struct nsproxy; |
948 | struct ctl_table_root; | 948 | struct ctl_table_root; |
949 | 949 | ||
950 | struct ctl_table_set { | ||
951 | struct list_head list; | ||
952 | struct ctl_table_set *parent; | ||
953 | int (*is_seen)(struct ctl_table_set *); | ||
954 | }; | ||
955 | |||
956 | extern void setup_sysctl_set(struct ctl_table_set *p, | ||
957 | struct ctl_table_set *parent, | ||
958 | int (*is_seen)(struct ctl_table_set *)); | ||
959 | |||
960 | struct ctl_table_header; | ||
961 | |||
962 | extern void sysctl_head_get(struct ctl_table_header *); | ||
963 | extern void sysctl_head_put(struct ctl_table_header *); | ||
964 | extern int sysctl_is_seen(struct ctl_table_header *); | ||
965 | extern struct ctl_table_header *sysctl_head_grab(struct ctl_table_header *); | ||
950 | extern struct ctl_table_header *sysctl_head_next(struct ctl_table_header *prev); | 966 | extern struct ctl_table_header *sysctl_head_next(struct ctl_table_header *prev); |
951 | extern struct ctl_table_header *__sysctl_head_next(struct nsproxy *namespaces, | 967 | extern struct ctl_table_header *__sysctl_head_next(struct nsproxy *namespaces, |
952 | struct ctl_table_header *prev); | 968 | struct ctl_table_header *prev); |
@@ -1049,8 +1065,8 @@ struct ctl_table | |||
1049 | 1065 | ||
1050 | struct ctl_table_root { | 1066 | struct ctl_table_root { |
1051 | struct list_head root_list; | 1067 | struct list_head root_list; |
1052 | struct list_head header_list; | 1068 | struct ctl_table_set default_set; |
1053 | struct list_head *(*lookup)(struct ctl_table_root *root, | 1069 | struct ctl_table_set *(*lookup)(struct ctl_table_root *root, |
1054 | struct nsproxy *namespaces); | 1070 | struct nsproxy *namespaces); |
1055 | int (*permissions)(struct ctl_table_root *root, | 1071 | int (*permissions)(struct ctl_table_root *root, |
1056 | struct nsproxy *namespaces, struct ctl_table *table); | 1072 | struct nsproxy *namespaces, struct ctl_table *table); |
@@ -1063,9 +1079,14 @@ struct ctl_table_header | |||
1063 | struct ctl_table *ctl_table; | 1079 | struct ctl_table *ctl_table; |
1064 | struct list_head ctl_entry; | 1080 | struct list_head ctl_entry; |
1065 | int used; | 1081 | int used; |
1082 | int count; | ||
1066 | struct completion *unregistering; | 1083 | struct completion *unregistering; |
1067 | struct ctl_table *ctl_table_arg; | 1084 | struct ctl_table *ctl_table_arg; |
1068 | struct ctl_table_root *root; | 1085 | struct ctl_table_root *root; |
1086 | struct ctl_table_set *set; | ||
1087 | struct ctl_table *attached_by; | ||
1088 | struct ctl_table *attached_to; | ||
1089 | struct ctl_table_header *parent; | ||
1069 | }; | 1090 | }; |
1070 | 1091 | ||
1071 | /* struct ctl_path describes where in the hierarchy a table is added */ | 1092 | /* struct ctl_path describes where in the hierarchy a table is added */ |