Commit aa1e420a authored by Nathan Scott's avatar Nathan Scott

[XFS] Remove unused MAC macros, never needed on Linux.

SGI Modid: xfs-linux:xfs-kern:173561a
Signed-off-by: nathans@sgi.com
parent d61692f1
......@@ -231,8 +231,6 @@ xfs_acl_vget(
int flags = 0;
VN_HOLD(vp);
if ((error = _MAC_VACCESS(vp, NULL, VREAD)))
goto out;
if(size) {
if (!(_ACL_ALLOC(xfs_acl))) {
error = ENOMEM;
......@@ -395,8 +393,6 @@ xfs_acl_allow_set(
return ENOTDIR;
if (vp->v_vfsp->vfs_flag & VFS_RDONLY)
return EROFS;
if ((error = _MAC_VACCESS(vp, NULL, VWRITE)))
return error;
va.va_mask = XFS_AT_UID;
VOP_GETATTR(vp, &va, 0, NULL, error);
if (error)
......
......@@ -3695,12 +3695,6 @@ xfs_iaccess(
mode_t orgmode = mode;
struct inode *inode = LINVFS_GET_IP(XFS_ITOV(ip));
/*
* Verify that the MAC policy allows the requested access.
*/
if ((error = _MAC_XFS_IACCESS(ip, mode, cr)))
return XFS_ERROR(error);
if (mode & S_IWUSR) {
umode_t imode = inode->i_mode;
......
......@@ -411,11 +411,6 @@ xfs_setattr(
xfs_ilock(ip, lock_flags);
if (_MAC_XFS_IACCESS(ip, MACWRITE, credp)) {
code = XFS_ERROR(EACCES);
goto error_return;
}
/* boolean: are we the file owner? */
file_owner = (current_fsuid(credp) == ip->i_d.di_uid);
......@@ -2446,11 +2441,6 @@ xfs_remove(
xfs_trans_ijoin(tp, ip, XFS_ILOCK_EXCL);
}
if ((error = _MAC_XFS_IACCESS(ip, MACWRITE, credp))) {
REMOVE_DEBUG_TRACE(__LINE__);
goto error_return;
}
/*
* Entry must exist since we did a lookup in xfs_lock_dir_and_entry.
*/
......@@ -2536,8 +2526,6 @@ xfs_remove(
error1:
xfs_bmap_cancel(&free_list);
cancel_flags |= XFS_TRANS_ABORT;
error_return:
xfs_trans_cancel(tp, cancel_flags);
goto std_return;
......@@ -3105,10 +3093,6 @@ xfs_rmdir(
ITRACE(cdp);
xfs_trans_ijoin(tp, cdp, XFS_ILOCK_EXCL);
if ((error = _MAC_XFS_IACCESS(cdp, MACWRITE, credp))) {
goto error_return;
}
ASSERT(cdp->i_d.di_nlink >= 2);
if (cdp->i_d.di_nlink != 2) {
error = XFS_ERROR(ENOTEMPTY);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment