struct gfs2_holder i_gh;
int error;
- error = gfs2_glock_nq_init(ip->i_gl,
- LM_ST_SHARED, LM_FLAG_ANY,
- &i_gh);
+ error = gfs2_glock_nq_init(ip->i_gl, LM_ST_SHARED, LM_FLAG_ANY, &i_gh);
if (!error) {
error = gfs2_check_acl_locked(inode, mask);
gfs2_glock_dq_uninit(&i_gh);
return ERR_PTR(error);
if (!is_root) {
- error = gfs2_repermission(dir, MAY_EXEC, NULL);
+ error = permission(dir, MAY_EXEC, NULL);
if (error)
goto out;
}
{
int error;
- error = gfs2_repermission(&dip->i_inode, MAY_WRITE | MAY_EXEC, NULL);
+ error = permission(&dip->i_inode, MAY_WRITE | MAY_EXEC, NULL);
if (error)
return error;
if (IS_APPEND(&dip->i_inode))
return -EPERM;
- error = gfs2_repermission(&dip->i_inode, MAY_WRITE | MAY_EXEC, NULL);
+ error = permission(&dip->i_inode, MAY_WRITE | MAY_EXEC, NULL);
if (error)
return error;
return error;
}
-int gfs2_repermission(struct inode *inode, int mask, struct nameidata *nd)
-{
- return permission(inode, mask, nd);
-}
-
int gfs2_setattr_simple(struct gfs2_inode *ip, struct iattr *attr);
-int gfs2_repermission(struct inode *inode, int mask, struct nameidata *nd);
-
struct inode *gfs2_lookup_simple(struct inode *dip, const char *name);
#endif /* __INODE_DOT_H__ */
!capable(CAP_LINUX_IMMUTABLE))
goto out;
if (!IS_IMMUTABLE(inode)) {
- error = gfs2_repermission(inode, MAY_WRITE, NULL);
+ error = permission(inode, MAY_WRITE, NULL);
if (error)
goto out;
}
if (error)
goto out;
- error = gfs2_repermission(dir, MAY_WRITE | MAY_EXEC, NULL);
+ error = permission(dir, MAY_WRITE | MAY_EXEC, NULL);
if (error)
goto out_gunlock;
}
}
} else {
- error = gfs2_repermission(ndir, MAY_WRITE | MAY_EXEC, NULL);
+ error = permission(ndir, MAY_WRITE | MAY_EXEC, NULL);
if (error)
goto out_gunlock;
/* Check out the dir to be renamed */
if (dir_rename) {
- error = gfs2_repermission(odentry->d_inode, MAY_WRITE, NULL);
+ error = permission(odentry->d_inode, MAY_WRITE, NULL);
if (error)
goto out_gunlock;
}
if (ip->i_vn == ip->i_gl->gl_vn)
return generic_permission(inode, mask, gfs2_check_acl);
- error = gfs2_glock_nq_init(ip->i_gl,
- LM_ST_SHARED, LM_FLAG_ANY,
- &i_gh);
+ error = gfs2_glock_nq_init(ip->i_gl, LM_ST_SHARED, LM_FLAG_ANY, &i_gh);
if (!error) {
error = generic_permission(inode, mask, gfs2_check_acl_locked);
gfs2_glock_dq_uninit(&i_gh);