Merge branch 'vfs-scale-working' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-2.6.git] / security / security.c
index e5fb07a..739e403 100644 (file)
@@ -513,6 +513,15 @@ int security_inode_permission(struct inode *inode, int mask)
        return security_ops->inode_permission(inode, mask);
 }
 
+int security_inode_exec_permission(struct inode *inode, unsigned int flags)
+{
+       if (unlikely(IS_PRIVATE(inode)))
+               return 0;
+       if (flags)
+               return -ECHILD;
+       return security_ops->inode_permission(inode, MAY_EXEC);
+}
+
 int security_inode_setattr(struct dentry *dentry, struct iattr *attr)
 {
        if (unlikely(IS_PRIVATE(dentry->d_inode)))