summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fs/btrfs/volumes.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 340a92d08e84..2c87b727bc5c 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -533,7 +533,7 @@ static noinline int device_list_add(const char *path,
* the btrfs dev scan cli, after FS has been mounted.
*/
if (fs_devices->opened) {
- return -EBUSY;
+ goto out;
} else {
/*
* That is if the FS is _not_ mounted and if you
@@ -570,6 +570,8 @@ static noinline int device_list_add(const char *path,
fs_devices->latest_devid = devid;
fs_devices->latest_trans = found_transid;
}
+
+out:
*fs_devices_ret = fs_devices;
return ret;