diff options
author | Takashi Iwai <tiwai@suse.de> | 2022-09-22 13:47:09 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2022-09-22 13:47:09 +0200 |
commit | cbdac8bc2cbf91b42a92869dc938b809054d4fae (patch) | |
tree | 06118f3dc9ea6dab868ebc89aad68e19cd4c7800 /fs/btrfs/volumes.c | |
parent | 79764ec772bc1346441ae1c4b1f3bd1991d634e8 (diff) | |
parent | 0a0342ede303fc420f3a388e1ae82da3ae8ff6bd (diff) |
Merge tag 'asoc-fix-v6.0-rc6' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Fixes for v6.0
A few device specific fixes, nothing too large, and a new device
ID for a Dell laptop.
Diffstat (limited to 'fs/btrfs/volumes.c')
-rw-r--r-- | fs/btrfs/volumes.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index 272901514b0c..f63ff91e2883 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -2345,8 +2345,11 @@ int btrfs_get_dev_args_from_path(struct btrfs_fs_info *fs_info, ret = btrfs_get_bdev_and_sb(path, FMODE_READ, fs_info->bdev_holder, 0, &bdev, &disk_super); - if (ret) + if (ret) { + btrfs_put_dev_args_from_path(args); return ret; + } + args->devid = btrfs_stack_device_id(&disk_super->dev_item); memcpy(args->uuid, disk_super->dev_item.uuid, BTRFS_UUID_SIZE); if (btrfs_fs_incompat(fs_info, METADATA_UUID)) @@ -5264,6 +5267,9 @@ static int decide_stripe_size_regular(struct alloc_chunk_ctl *ctl, ctl->stripe_size); } + /* Stripe size should not go beyond 1G. */ + ctl->stripe_size = min_t(u64, ctl->stripe_size, SZ_1G); + /* Align to BTRFS_STRIPE_LEN */ ctl->stripe_size = round_down(ctl->stripe_size, BTRFS_STRIPE_LEN); ctl->chunk_size = ctl->stripe_size * data_stripes; |