diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/nfs/super.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/fs/nfs/super.c b/fs/nfs/super.c index 04ad881eac77..aab5cd61725d 100644 --- a/fs/nfs/super.c +++ b/fs/nfs/super.c | |||
@@ -633,13 +633,13 @@ static int nfs_get_sb(struct file_system_type *fs_type, | |||
633 | /* Validate the mount data */ | 633 | /* Validate the mount data */ |
634 | error = nfs_validate_mount_data(data, &mntfh); | 634 | error = nfs_validate_mount_data(data, &mntfh); |
635 | if (error < 0) | 635 | if (error < 0) |
636 | return error; | 636 | goto out; |
637 | 637 | ||
638 | /* Get a volume representation */ | 638 | /* Get a volume representation */ |
639 | server = nfs_create_server(data, &mntfh); | 639 | server = nfs_create_server(data, &mntfh); |
640 | if (IS_ERR(server)) { | 640 | if (IS_ERR(server)) { |
641 | error = PTR_ERR(server); | 641 | error = PTR_ERR(server); |
642 | goto out_err_noserver; | 642 | goto out; |
643 | } | 643 | } |
644 | 644 | ||
645 | /* Get a superblock - note that we may end up sharing one that already exists */ | 645 | /* Get a superblock - note that we may end up sharing one that already exists */ |
@@ -669,17 +669,19 @@ static int nfs_get_sb(struct file_system_type *fs_type, | |||
669 | s->s_flags |= MS_ACTIVE; | 669 | s->s_flags |= MS_ACTIVE; |
670 | mnt->mnt_sb = s; | 670 | mnt->mnt_sb = s; |
671 | mnt->mnt_root = mntroot; | 671 | mnt->mnt_root = mntroot; |
672 | return 0; | 672 | error = 0; |
673 | |||
674 | out: | ||
675 | return error; | ||
673 | 676 | ||
674 | out_err_nosb: | 677 | out_err_nosb: |
675 | nfs_free_server(server); | 678 | nfs_free_server(server); |
676 | out_err_noserver: | 679 | goto out; |
677 | return error; | ||
678 | 680 | ||
679 | error_splat_super: | 681 | error_splat_super: |
680 | up_write(&s->s_umount); | 682 | up_write(&s->s_umount); |
681 | deactivate_super(s); | 683 | deactivate_super(s); |
682 | return error; | 684 | goto out; |
683 | } | 685 | } |
684 | 686 | ||
685 | /* | 687 | /* |