提交 4d80f2ec 编写于 作者: T Trond Myklebust

NFS: Remove the BKL from the permission checking code

Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
上级 fa6dc9dc
...@@ -1982,8 +1982,6 @@ int nfs_permission(struct inode *inode, int mask, struct nameidata *nd) ...@@ -1982,8 +1982,6 @@ int nfs_permission(struct inode *inode, int mask, struct nameidata *nd)
} }
force_lookup: force_lookup:
lock_kernel();
if (!NFS_PROTO(inode)->access) if (!NFS_PROTO(inode)->access)
goto out_notsup; goto out_notsup;
...@@ -1993,7 +1991,6 @@ int nfs_permission(struct inode *inode, int mask, struct nameidata *nd) ...@@ -1993,7 +1991,6 @@ int nfs_permission(struct inode *inode, int mask, struct nameidata *nd)
put_rpccred(cred); put_rpccred(cred);
} else } else
res = PTR_ERR(cred); res = PTR_ERR(cred);
unlock_kernel();
out: out:
dfprintk(VFS, "NFS: permission(%s/%ld), mask=0x%x, res=%d\n", dfprintk(VFS, "NFS: permission(%s/%ld), mask=0x%x, res=%d\n",
inode->i_sb->s_id, inode->i_ino, mask, res); inode->i_sb->s_id, inode->i_ino, mask, res);
...@@ -2002,7 +1999,6 @@ int nfs_permission(struct inode *inode, int mask, struct nameidata *nd) ...@@ -2002,7 +1999,6 @@ int nfs_permission(struct inode *inode, int mask, struct nameidata *nd)
res = nfs_revalidate_inode(NFS_SERVER(inode), inode); res = nfs_revalidate_inode(NFS_SERVER(inode), inode);
if (res == 0) if (res == 0)
res = generic_permission(inode, mask, NULL); res = generic_permission(inode, mask, NULL);
unlock_kernel();
goto out; goto out;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册