aboutsummaryrefslogtreecommitdiffstats
path: root/fs/exofs
diff options
context:
space:
mode:
Diffstat (limited to 'fs/exofs')
-rw-r--r--fs/exofs/inode.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/fs/exofs/inode.c b/fs/exofs/inode.c
index 9507283be3ad..4bb6ef822e46 100644
--- a/fs/exofs/inode.c
+++ b/fs/exofs/inode.c
@@ -1153,16 +1153,7 @@ struct inode *exofs_new_inode(struct inode *dir, int mode)
1153 sbi = sb->s_fs_info; 1153 sbi = sb->s_fs_info;
1154 1154
1155 sb->s_dirt = 1; 1155 sb->s_dirt = 1;
1156 inode->i_uid = current->cred->fsuid; 1156 inode_init_owner(inode, dir, mode);
1157 if (dir->i_mode & S_ISGID) {
1158 inode->i_gid = dir->i_gid;
1159 if (S_ISDIR(mode))
1160 mode |= S_ISGID;
1161 } else {
1162 inode->i_gid = current->cred->fsgid;
1163 }
1164 inode->i_mode = mode;
1165
1166 inode->i_ino = sbi->s_nextid++; 1157 inode->i_ino = sbi->s_nextid++;
1167 inode->i_blkbits = EXOFS_BLKSHIFT; 1158 inode->i_blkbits = EXOFS_BLKSHIFT;
1168 inode->i_mtime = inode->i_atime = inode->i_ctime = CURRENT_TIME; 1159 inode->i_mtime = inode->i_atime = inode->i_ctime = CURRENT_TIME;