Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

vfs: export __inode_permission() to modules

We need to be able to check inode permissions (but not filesystem implied
permissions) for stackable filesystems. Expose this interface for overlayfs.

Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>

+2 -1
-1
fs/internal.h
··· 47 47 /* 48 48 * namei.c 49 49 */ 50 - extern int __inode_permission(struct inode *, int); 51 50 extern int user_path_mountpoint_at(int, const char __user *, unsigned int, struct path *); 52 51 extern int vfs_path_lookup(struct dentry *, struct vfsmount *, 53 52 const char *, unsigned int, struct path *);
+1
fs/namei.c
··· 416 416 417 417 return security_inode_permission(inode, mask); 418 418 } 419 + EXPORT_SYMBOL(__inode_permission); 419 420 420 421 /** 421 422 * sb_permission - Check superblock-level permissions
+1
include/linux/fs.h
··· 2257 2257 #endif 2258 2258 extern int notify_change(struct dentry *, struct iattr *, struct inode **); 2259 2259 extern int inode_permission(struct inode *, int); 2260 + extern int __inode_permission(struct inode *, int); 2260 2261 extern int generic_permission(struct inode *, int); 2261 2262 2262 2263 static inline bool execute_ok(struct inode *inode)