diff options
author | Ameer Hamza <[email protected]> | 2024-08-16 02:29:50 +0500 |
---|---|---|
committer | Tony Hutter <[email protected]> | 2024-08-26 15:10:16 -0700 |
commit | c60df6a80179f45a64daeb47113b0a342461ef97 (patch) | |
tree | d064bf79a0425fe93a6d0c330cbbdb7f6fe6d063 /man/man4/zfs.4 | |
parent | d8fa32a79d8b5f759ad30ed54eb75b2ab0a746f0 (diff) |
linux/zvol_os: fix zvol queue limits initialization
zvol queue limits initialization depends on `zv_volblocksize`, but it is
initialized later, leading to several limits being initialized with
incorrect values, including `max_discard_*` limits. This also causes
`blkdiscard` command to consistently fail, as `blk_ioctl_discard` reads
`bdev_max_discard_sectors()` limits as 0, leading to failure. The fix is
straightforward: initialize `zv->zv_volblocksize` early, before setting
the queue limits. This PR should fix `zvol/zvol_misc/zvol_misc_trim`
failure on recent PRs, as the test case issues `blkdiscard` for a zvol.
Additionally, `zvol_misc_trim` was recently enabled in `6c7d41a`,
which is why the issue wasn't identified earlier.
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Ameer Hamza <[email protected]>
Closes #16454
Diffstat (limited to 'man/man4/zfs.4')
0 files changed, 0 insertions, 0 deletions