HomeFreeBSD

Linux 6.10: rework queue limits setup

Description

Linux 6.10: rework queue limits setup

Linux has started moving to a model where instead of applying block
queue limits through individual modification functions, a complete
limits structure is built up and applied atomically, either when the
block device or open, or some time afterwards. As of 6.10 this
transition appears only partly completed.

This commit matches that model within OpenZFS in a way that should work
for past and future kernels. We set up a queue limits structure with any
limits that have had their modification functions removed. For newer
kernels that can have limits applied at block device open
(HAVE_BLK_ALLOC_DISK_2ARG), we have a conversion function to turn the
OpenZFS queue limits structure into Linux's queue_limits structure,
which can then be passed in. For older kernels, we provide an
application function that just calls the old functions for each limit in
the structure.

Signed-off-by: Rob Norris <robn@despairlabs.com>
Sponsored-by: https://despairlabs.com/sponsor/
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>

Details

Provenance
rob.norris_klarasystems.comAuthored on May 28 2024, 1:32 AM
Tony Hutter <hutter2@llnl.gov>Committed on Jul 16 2024, 10:33 PM
Parents
rGd7bf0e5259f3: Linux 6.9: Fix UBSAN errors in zap_micro.c
Branches
Unknown
Tags
Unknown