diff options
author | Kees Cook <keescook@chromium.org> | 2016-07-25 13:50:36 -0700 |
---|---|---|
committer | Kees Cook <keescook@chromium.org> | 2016-07-25 13:50:36 -0700 |
commit | 74e630a7582e6b3cb39559d712a0049f08dea8a0 (patch) | |
tree | 98a752412dcfc74d802024c1d9e8c541b93174f9 /fs/btrfs/reada.c | |
parent | 35da60941e44dbf57868e67686dd24cc1a33125a (diff) | |
parent | 523d939ef98fd712632d93a5a2b588e477a7565e (diff) | |
download | op-kernel-dev-74e630a7582e6b3cb39559d712a0049f08dea8a0.zip op-kernel-dev-74e630a7582e6b3cb39559d712a0049f08dea8a0.tar.gz |
Merge tag 'v4.7' into for-linus/pstore
Linux 4.7
Diffstat (limited to 'fs/btrfs/reada.c')
-rw-r--r-- | fs/btrfs/reada.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/reada.c b/fs/btrfs/reada.c index 298631ea..8428db7 100644 --- a/fs/btrfs/reada.c +++ b/fs/btrfs/reada.c @@ -761,12 +761,14 @@ static void __reada_start_machine(struct btrfs_fs_info *fs_info) do { enqueued = 0; + mutex_lock(&fs_devices->device_list_mutex); list_for_each_entry(device, &fs_devices->devices, dev_list) { if (atomic_read(&device->reada_in_flight) < MAX_IN_FLIGHT) enqueued += reada_start_machine_dev(fs_info, device); } + mutex_unlock(&fs_devices->device_list_mutex); total += enqueued; } while (enqueued && total < 10000); |