diff options
Diffstat (limited to 'fs/namei.c')
-rw-r--r-- | fs/namei.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/fs/namei.c b/fs/namei.c index 6d75430358ac..396cb3e5c364 100644 --- a/fs/namei.c +++ b/fs/namei.c | |||
@@ -252,15 +252,6 @@ int permission(struct inode *inode, int mask, struct nameidata *nd) | |||
252 | return -EACCES; | 252 | return -EACCES; |
253 | } | 253 | } |
254 | 254 | ||
255 | if ((mask & MAY_EXEC) && S_ISREG(inode->i_mode)) { | ||
256 | /* | ||
257 | * MAY_EXEC on regular files is denied if the fs is mounted | ||
258 | * with the "noexec" flag. | ||
259 | */ | ||
260 | if (mnt && (mnt->mnt_flags & MNT_NOEXEC)) | ||
261 | return -EACCES; | ||
262 | } | ||
263 | |||
264 | /* Ordinary permission routines do not understand MAY_APPEND. */ | 255 | /* Ordinary permission routines do not understand MAY_APPEND. */ |
265 | if (inode->i_op && inode->i_op->permission) { | 256 | if (inode->i_op && inode->i_op->permission) { |
266 | retval = inode->i_op->permission(inode, mask); | 257 | retval = inode->i_op->permission(inode, mask); |