summaryrefslogtreecommitdiffstats
path: root/fs/zonefs
diff options
context:
space:
mode:
Diffstat (limited to 'fs/zonefs')
-rw-r--r--fs/zonefs/super.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/zonefs/super.c b/fs/zonefs/super.c
index e20e7c841489..82da583da17b 100644
--- a/fs/zonefs/super.c
+++ b/fs/zonefs/super.c
@@ -689,13 +689,12 @@ static ssize_t zonefs_file_dio_append(struct kiocb *iocb, struct iov_iter *from)
struct inode *inode = file_inode(iocb->ki_filp);
struct zonefs_inode_info *zi = ZONEFS_I(inode);
struct block_device *bdev = inode->i_sb->s_bdev;
- unsigned int max;
+ unsigned int max = bdev_max_zone_append_sectors(bdev);
struct bio *bio;
ssize_t size;
int nr_pages;
ssize_t ret;
- max = queue_max_zone_append_sectors(bdev_get_queue(bdev));
max = ALIGN_DOWN(max << SECTOR_SHIFT, inode->i_sb->s_blocksize);
iov_iter_truncate(from, max);