Skip to content

Commit 26567cd

Browse files
author
Al Viro
committed
fix nommu breakage in shmem.c
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
1 parent dd37978 commit 26567cd

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

‎mm/shmem.c‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2932,9 +2932,8 @@ struct file *shmem_file_setup(const char *name, loff_t size, unsigned long flags
29322932
inode->i_size = size;
29332933
clear_nlink(inode); /* It is unlinked */
29342934
#ifndef CONFIG_MMU
2935-
error = ramfs_nommu_expand_for_mapping(inode, size);
2936-
res = ERR_PTR(error);
2937-
if (error)
2935+
res = ERR_PTR(ramfs_nommu_expand_for_mapping(inode, size));
2936+
if (IS_ERR(res))
29382937
goto put_dentry;
29392938
#endif
29402939

0 commit comments

Comments
 (0)