diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-01-08 22:15:13 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-03-20 21:29:35 -0400 |
commit | 48fde701aff662559b38d9a609574068f22d00fe (patch) | |
tree | aa6b203dc671b51d58575b65eb08310ff8309b60 /mm/shmem.c | |
parent | 6b4231e2f92adbcf96fb2a3fa751d7ca0a61b21f (diff) |
switch open-coded instances of d_make_root() to new helper
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'mm/shmem.c')
-rw-r--r-- | mm/shmem.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/mm/shmem.c b/mm/shmem.c index 269d049294ab..154243f0a27c 100644 --- a/mm/shmem.c +++ b/mm/shmem.c | |||
@@ -2232,14 +2232,12 @@ int shmem_fill_super(struct super_block *sb, void *data, int silent) | |||
2232 | goto failed; | 2232 | goto failed; |
2233 | inode->i_uid = sbinfo->uid; | 2233 | inode->i_uid = sbinfo->uid; |
2234 | inode->i_gid = sbinfo->gid; | 2234 | inode->i_gid = sbinfo->gid; |
2235 | root = d_alloc_root(inode); | 2235 | root = d_make_root(inode); |
2236 | if (!root) | 2236 | if (!root) |
2237 | goto failed_iput; | 2237 | goto failed; |
2238 | sb->s_root = root; | 2238 | sb->s_root = root; |
2239 | return 0; | 2239 | return 0; |
2240 | 2240 | ||
2241 | failed_iput: | ||
2242 | iput(inode); | ||
2243 | failed: | 2241 | failed: |
2244 | shmem_put_super(sb); | 2242 | shmem_put_super(sb); |
2245 | return err; | 2243 | return err; |