diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-23 13:22:40 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-23 13:22:40 -0400 |
commit | 5ed487bc2c44ca4e9668ef9cb54c830e2a9fac47 (patch) | |
tree | af19ed28db83e8f52690872ac99336da1cf2fd3b /include | |
parent | 5b34653963de7a6d0d8c783527457d68fddc60fb (diff) | |
parent | fd217f4d70172c526478f2bc76859e909fdfa674 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6: (46 commits)
[PATCH] fs: add a sanity check in d_free
[PATCH] i_version: remount support
[patch] vfs: make security_inode_setattr() calling consistent
[patch 1/3] FS_MBCACHE: don't needlessly make it built-in
[PATCH] move executable checking into ->permission()
[PATCH] fs/dcache.c: update comment of d_validate()
[RFC PATCH] touch_mnt_namespace when the mount flags change
[PATCH] reiserfs: add missing llseek method
[PATCH] fix ->llseek for more directories
[PATCH vfs-2.6 6/6] vfs: add LOOKUP_RENAME_TARGET intent
[PATCH vfs-2.6 5/6] vfs: remove LOOKUP_PARENT from non LOOKUP_PARENT lookup
[PATCH vfs-2.6 4/6] vfs: remove unnecessary fsnotify_d_instantiate()
[PATCH vfs-2.6 3/6] vfs: add __d_instantiate() helper
[PATCH vfs-2.6 2/6] vfs: add d_ancestor()
[PATCH vfs-2.6 1/6] vfs: replace parent == dentry->d_parent by IS_ROOT()
[PATCH] get rid of on-stack dentry in udf
[PATCH 2/2] anondev: switch to IDA
[PATCH 1/2] anondev: init IDR statically
[JFFS2] Use d_splice_alias() not d_add() in jffs2_lookup()
[PATCH] Optimise NFS readdir hack slightly.
...
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/dcache.h | 3 | ||||
-rw-r--r-- | include/linux/fs.h | 8 | ||||
-rw-r--r-- | include/linux/namei.h | 8 |
3 files changed, 14 insertions, 5 deletions
diff --git a/include/linux/dcache.h b/include/linux/dcache.h index efba1de629ac..a37359d0bad1 100644 --- a/include/linux/dcache.h +++ b/include/linux/dcache.h | |||
@@ -228,9 +228,9 @@ extern void d_delete(struct dentry *); | |||
228 | 228 | ||
229 | /* allocate/de-allocate */ | 229 | /* allocate/de-allocate */ |
230 | extern struct dentry * d_alloc(struct dentry *, const struct qstr *); | 230 | extern struct dentry * d_alloc(struct dentry *, const struct qstr *); |
231 | extern struct dentry * d_alloc_anon(struct inode *); | ||
232 | extern struct dentry * d_splice_alias(struct inode *, struct dentry *); | 231 | extern struct dentry * d_splice_alias(struct inode *, struct dentry *); |
233 | extern struct dentry * d_add_ci(struct dentry *, struct inode *, struct qstr *); | 232 | extern struct dentry * d_add_ci(struct dentry *, struct inode *, struct qstr *); |
233 | extern struct dentry * d_obtain_alias(struct inode *); | ||
234 | extern void shrink_dcache_sb(struct super_block *); | 234 | extern void shrink_dcache_sb(struct super_block *); |
235 | extern void shrink_dcache_parent(struct dentry *); | 235 | extern void shrink_dcache_parent(struct dentry *); |
236 | extern void shrink_dcache_for_umount(struct super_block *); | 236 | extern void shrink_dcache_for_umount(struct super_block *); |
@@ -287,6 +287,7 @@ static inline struct dentry *d_add_unique(struct dentry *entry, struct inode *in | |||
287 | 287 | ||
288 | /* used for rename() and baskets */ | 288 | /* used for rename() and baskets */ |
289 | extern void d_move(struct dentry *, struct dentry *); | 289 | extern void d_move(struct dentry *, struct dentry *); |
290 | extern struct dentry *d_ancestor(struct dentry *, struct dentry *); | ||
290 | 291 | ||
291 | /* appendix may either be NULL or be used for transname suffixes */ | 292 | /* appendix may either be NULL or be used for transname suffixes */ |
292 | extern struct dentry * d_lookup(struct dentry *, struct qstr *); | 293 | extern struct dentry * d_lookup(struct dentry *, struct qstr *); |
diff --git a/include/linux/fs.h b/include/linux/fs.h index a6a625be13fc..7d719c1a18e3 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -136,7 +136,7 @@ extern int dir_notify_enable; | |||
136 | /* | 136 | /* |
137 | * Superblock flags that can be altered by MS_REMOUNT | 137 | * Superblock flags that can be altered by MS_REMOUNT |
138 | */ | 138 | */ |
139 | #define MS_RMT_MASK (MS_RDONLY|MS_SYNCHRONOUS|MS_MANDLOCK) | 139 | #define MS_RMT_MASK (MS_RDONLY|MS_SYNCHRONOUS|MS_MANDLOCK|MS_I_VERSION) |
140 | 140 | ||
141 | /* | 141 | /* |
142 | * Old magic mount flag and mask | 142 | * Old magic mount flag and mask |
@@ -1593,7 +1593,6 @@ extern int get_sb_pseudo(struct file_system_type *, char *, | |||
1593 | struct vfsmount *mnt); | 1593 | struct vfsmount *mnt); |
1594 | extern int simple_set_mnt(struct vfsmount *mnt, struct super_block *sb); | 1594 | extern int simple_set_mnt(struct vfsmount *mnt, struct super_block *sb); |
1595 | int __put_super_and_need_restart(struct super_block *sb); | 1595 | int __put_super_and_need_restart(struct super_block *sb); |
1596 | void unnamed_dev_init(void); | ||
1597 | 1596 | ||
1598 | /* Alas, no aliases. Too much hassle with bringing module.h everywhere */ | 1597 | /* Alas, no aliases. Too much hassle with bringing module.h everywhere */ |
1599 | #define fops_get(fops) \ | 1598 | #define fops_get(fops) \ |
@@ -1852,6 +1851,11 @@ extern int inode_permission(struct inode *, int); | |||
1852 | extern int generic_permission(struct inode *, int, | 1851 | extern int generic_permission(struct inode *, int, |
1853 | int (*check_acl)(struct inode *, int)); | 1852 | int (*check_acl)(struct inode *, int)); |
1854 | 1853 | ||
1854 | static inline bool execute_ok(struct inode *inode) | ||
1855 | { | ||
1856 | return (inode->i_mode & S_IXUGO) || S_ISDIR(inode->i_mode); | ||
1857 | } | ||
1858 | |||
1855 | extern int get_write_access(struct inode *); | 1859 | extern int get_write_access(struct inode *); |
1856 | extern int deny_write_access(struct file *); | 1860 | extern int deny_write_access(struct file *); |
1857 | static inline void put_write_access(struct inode * inode) | 1861 | static inline void put_write_access(struct inode * inode) |
diff --git a/include/linux/namei.h b/include/linux/namei.h index 68f8c3203c89..99eb80306dc5 100644 --- a/include/linux/namei.h +++ b/include/linux/namei.h | |||
@@ -51,8 +51,10 @@ enum {LAST_NORM, LAST_ROOT, LAST_DOT, LAST_DOTDOT, LAST_BIND}; | |||
51 | /* | 51 | /* |
52 | * Intent data | 52 | * Intent data |
53 | */ | 53 | */ |
54 | #define LOOKUP_OPEN (0x0100) | 54 | #define LOOKUP_OPEN 0x0100 |
55 | #define LOOKUP_CREATE (0x0200) | 55 | #define LOOKUP_CREATE 0x0200 |
56 | #define LOOKUP_EXCL 0x0400 | ||
57 | #define LOOKUP_RENAME_TARGET 0x0800 | ||
56 | 58 | ||
57 | extern int user_path_at(int, const char __user *, unsigned, struct path *); | 59 | extern int user_path_at(int, const char __user *, unsigned, struct path *); |
58 | 60 | ||
@@ -61,6 +63,8 @@ extern int user_path_at(int, const char __user *, unsigned, struct path *); | |||
61 | #define user_path_dir(name, path) \ | 63 | #define user_path_dir(name, path) \ |
62 | user_path_at(AT_FDCWD, name, LOOKUP_FOLLOW | LOOKUP_DIRECTORY, path) | 64 | user_path_at(AT_FDCWD, name, LOOKUP_FOLLOW | LOOKUP_DIRECTORY, path) |
63 | 65 | ||
66 | extern int kern_path(const char *, unsigned, struct path *); | ||
67 | |||
64 | extern int path_lookup(const char *, unsigned, struct nameidata *); | 68 | extern int path_lookup(const char *, unsigned, struct nameidata *); |
65 | extern int vfs_path_lookup(struct dentry *, struct vfsmount *, | 69 | extern int vfs_path_lookup(struct dentry *, struct vfsmount *, |
66 | const char *, unsigned int, struct nameidata *); | 70 | const char *, unsigned int, struct nameidata *); |