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 /drivers/usb/gadget/f_fs.c | |
parent | 6b4231e2f92adbcf96fb2a3fa751d7ca0a61b21f (diff) | |
download | blackbird-op-linux-48fde701aff662559b38d9a609574068f22d00fe.tar.gz blackbird-op-linux-48fde701aff662559b38d9a609574068f22d00fe.zip |
switch open-coded instances of d_make_root() to new helper
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/usb/gadget/f_fs.c')
-rw-r--r-- | drivers/usb/gadget/f_fs.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/usb/gadget/f_fs.c b/drivers/usb/gadget/f_fs.c index f63dc6c150d2..d825b248728a 100644 --- a/drivers/usb/gadget/f_fs.c +++ b/drivers/usb/gadget/f_fs.c @@ -1063,13 +1063,9 @@ static int ffs_sb_fill(struct super_block *sb, void *_data, int silent) &simple_dir_operations, &simple_dir_inode_operations, &data->perms); - if (unlikely(!inode)) + sb->s_root = d_make_root(inode); + if (unlikely(!sb->s_root)) goto Enomem; - sb->s_root = d_alloc_root(inode); - if (unlikely(!sb->s_root)) { - iput(inode); - goto Enomem; - } /* EP0 file */ if (unlikely(!ffs_sb_create_file(sb, "ep0", ffs, |