btrfs: return original error code when failing from option parsing
[sfrench/cifs-2.6.git] / fs / btrfs / super.c
index 0628092b0b1bde633f9e2c0f6c339feda75013ec..c67fafaa2fe713fa6358afcb2fd5197d917e6f7a 100644 (file)
@@ -1782,10 +1782,8 @@ static int btrfs_remount(struct super_block *sb, int *flags, char *data)
        }
 
        ret = btrfs_parse_options(fs_info, data, *flags);
-       if (ret) {
-               ret = -EINVAL;
+       if (ret)
                goto restore;
-       }
 
        btrfs_remount_begin(fs_info, old_opts, *flags);
        btrfs_resize_thread_pool(fs_info,