summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/volumes.c
diff options
context:
space:
mode:
authorStefan Schmidt <stefan@datenfreihafen.org>2018-08-06 09:04:48 +0200
committerStefan Schmidt <stefan@datenfreihafen.org>2018-08-06 09:04:48 +0200
commita30461080366214b690a367225a48c95d7a6a189 (patch)
tree02cd7cfb8cea14cebe1ab2a1638edd8c9b9e0d3f /fs/btrfs/volumes.c
parent811e299f4645588cc7a1b78d97b6847c155324b9 (diff)
parent981467033a37d916649647fa3afe1fe99bba1817 (diff)
downloadlinux-stable-a30461080366214b690a367225a48c95d7a6a189.tar.gz
linux-stable-a30461080366214b690a367225a48c95d7a6a189.tar.bz2
linux-stable-a30461080366214b690a367225a48c95d7a6a189.zip
Merge remote-tracking branch 'net-next/master'
Diffstat (limited to 'fs/btrfs/volumes.c')
-rw-r--r--fs/btrfs/volumes.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index e034ad9e23b4..1da162928d1a 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -1146,6 +1146,7 @@ int btrfs_open_devices(struct btrfs_fs_devices *fs_devices,
{
int ret;
+ mutex_lock(&uuid_mutex);
mutex_lock(&fs_devices->device_list_mutex);
if (fs_devices->opened) {
fs_devices->opened++;
@@ -1155,6 +1156,7 @@ int btrfs_open_devices(struct btrfs_fs_devices *fs_devices,
ret = open_fs_devices(fs_devices, flags, holder);
}
mutex_unlock(&fs_devices->device_list_mutex);
+ mutex_unlock(&uuid_mutex);
return ret;
}