diff options
Diffstat (limited to 'drivers/usb/core/inode.c')
-rw-r--r-- | drivers/usb/core/inode.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/usb/core/inode.c b/drivers/usb/core/inode.c index bdaef8e36020..06c175aee6a3 100644 --- a/drivers/usb/core/inode.c +++ b/drivers/usb/core/inode.c | |||
@@ -454,7 +454,6 @@ static const struct super_operations usbfs_ops = { | |||
454 | static int usbfs_fill_super(struct super_block *sb, void *data, int silent) | 454 | static int usbfs_fill_super(struct super_block *sb, void *data, int silent) |
455 | { | 455 | { |
456 | struct inode *inode; | 456 | struct inode *inode; |
457 | struct dentry *root; | ||
458 | 457 | ||
459 | sb->s_blocksize = PAGE_CACHE_SIZE; | 458 | sb->s_blocksize = PAGE_CACHE_SIZE; |
460 | sb->s_blocksize_bits = PAGE_CACHE_SHIFT; | 459 | sb->s_blocksize_bits = PAGE_CACHE_SHIFT; |
@@ -462,12 +461,11 @@ static int usbfs_fill_super(struct super_block *sb, void *data, int silent) | |||
462 | sb->s_op = &usbfs_ops; | 461 | sb->s_op = &usbfs_ops; |
463 | sb->s_time_gran = 1; | 462 | sb->s_time_gran = 1; |
464 | inode = usbfs_get_inode(sb, S_IFDIR | 0755, 0); | 463 | inode = usbfs_get_inode(sb, S_IFDIR | 0755, 0); |
465 | root = d_make_root(inode); | 464 | sb->s_root = d_make_root(inode); |
466 | if (!root) { | 465 | if (!sb->s_root) { |
467 | dbg("%s: could not get root dentry!",__func__); | 466 | dbg("%s: could not get root dentry!",__func__); |
468 | return -ENOMEM; | 467 | return -ENOMEM; |
469 | } | 468 | } |
470 | sb->s_root = root; | ||
471 | return 0; | 469 | return 0; |
472 | } | 470 | } |
473 | 471 | ||