summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/volumes.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2024-04-18 06:34:31 +0200
committerAl Viro <viro@zeniv.linux.org.uk>2024-05-02 23:39:44 +0200
commitead083aeeed9df44fab9227e47688f7305c3a233 (patch)
tree1678d6d34fa3483f2bcfe7dea3ced9b4c6d2a9bd /fs/btrfs/volumes.c
parentbtrfs_get_bdev_and_sb(): call set_blocksize() only for exclusive opens (diff)
downloadlinux-ead083aeeed9df44fab9227e47688f7305c3a233.tar.xz
linux-ead083aeeed9df44fab9227e47688f7305c3a233.zip
set_blocksize(): switch to passing struct file *
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/btrfs/volumes.c')
-rw-r--r--fs/btrfs/volumes.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 43af5a9fb547..65c03ddecc59 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -483,7 +483,7 @@ btrfs_get_bdev_and_sb(const char *device_path, blk_mode_t flags, void *holder,
if (flush)
sync_blockdev(bdev);
if (holder) {
- ret = set_blocksize(bdev, BTRFS_BDEV_BLOCKSIZE);
+ ret = set_blocksize(*bdev_file, BTRFS_BDEV_BLOCKSIZE);
if (ret) {
fput(*bdev_file);
goto error;
@@ -2717,7 +2717,7 @@ int btrfs_init_new_device(struct btrfs_fs_info *fs_info, const char *device_path
set_bit(BTRFS_DEV_STATE_IN_FS_METADATA, &device->dev_state);
clear_bit(BTRFS_DEV_STATE_REPLACE_TGT, &device->dev_state);
device->dev_stats_valid = 1;
- set_blocksize(device->bdev, BTRFS_BDEV_BLOCKSIZE);
+ set_blocksize(device->bdev_file, BTRFS_BDEV_BLOCKSIZE);
if (seeding_dev) {
btrfs_clear_sb_rdonly(sb);