aboutsummaryrefslogtreecommitdiffstats
path: root/mm/shmem.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/shmem.c')
-rw-r--r--mm/shmem.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/mm/shmem.c b/mm/shmem.c
index 118dfa4952f4..a87990cf9f94 100644
--- a/mm/shmem.c
+++ b/mm/shmem.c
@@ -1936,6 +1936,13 @@ shmem_mknod(struct inode *dir, struct dentry *dentry, umode_t mode, dev_t dev)
1936 1936
1937 inode = shmem_get_inode(dir->i_sb, dir, mode, dev, VM_NORESERVE); 1937 inode = shmem_get_inode(dir->i_sb, dir, mode, dev, VM_NORESERVE);
1938 if (inode) { 1938 if (inode) {
1939#ifdef CONFIG_TMPFS_POSIX_ACL
1940 error = generic_acl_init(inode, dir);
1941 if (error) {
1942 iput(inode);
1943 return error;
1944 }
1945#endif
1939 error = security_inode_init_security(inode, dir, 1946 error = security_inode_init_security(inode, dir,
1940 &dentry->d_name, 1947 &dentry->d_name,
1941 shmem_initxattrs, NULL); 1948 shmem_initxattrs, NULL);
@@ -1945,15 +1952,8 @@ shmem_mknod(struct inode *dir, struct dentry *dentry, umode_t mode, dev_t dev)
1945 return error; 1952 return error;
1946 } 1953 }
1947 } 1954 }
1948#ifdef CONFIG_TMPFS_POSIX_ACL 1955
1949 error = generic_acl_init(inode, dir);
1950 if (error) {
1951 iput(inode);
1952 return error;
1953 }
1954#else
1955 error = 0; 1956 error = 0;
1956#endif
1957 dir->i_size += BOGO_DIRENT_SIZE; 1957 dir->i_size += BOGO_DIRENT_SIZE;
1958 dir->i_ctime = dir->i_mtime = CURRENT_TIME; 1958 dir->i_ctime = dir->i_mtime = CURRENT_TIME;
1959 d_instantiate(dentry, inode); 1959 d_instantiate(dentry, inode);