diff options
Diffstat (limited to 'fs/libfs.c')
-rw-r--r-- | fs/libfs.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/libfs.c b/fs/libfs.c index 5b2dbb3ba4fc..7c895a763a1e 100644 --- a/fs/libfs.c +++ b/fs/libfs.c | |||
@@ -491,11 +491,9 @@ int simple_fill_super(struct super_block *s, unsigned long magic, | |||
491 | inode->i_op = &simple_dir_inode_operations; | 491 | inode->i_op = &simple_dir_inode_operations; |
492 | inode->i_fop = &simple_dir_operations; | 492 | inode->i_fop = &simple_dir_operations; |
493 | set_nlink(inode, 2); | 493 | set_nlink(inode, 2); |
494 | root = d_alloc_root(inode); | 494 | root = d_make_root(inode); |
495 | if (!root) { | 495 | if (!root) |
496 | iput(inode); | ||
497 | return -ENOMEM; | 496 | return -ENOMEM; |
498 | } | ||
499 | for (i = 0; !files->name || files->name[0]; i++, files++) { | 497 | for (i = 0; !files->name || files->name[0]; i++, files++) { |
500 | if (!files->name) | 498 | if (!files->name) |
501 | continue; | 499 | continue; |