On Tue, Dec 16, 2025 at 10:34:45PM -0700, Caleb Sander Mateos wrote:
__ublk_check_and_get_req() checks that the passed in offset is within the data length of the specified ublk request. However, only user copy (ublk_check_and_get_req()) supports accessing ublk request data at a nonzero offset. Zero-copy buffer registration (ublk_register_io_buf()) always passes 0 for the offset, so the check is unnecessary. Move the check from __ublk_check_and_get_req() to ublk_check_and_get_req().
Signed-off-by: Caleb Sander Mateos csander@purestorage.com
Reviewed-by: Ming Lei ming.lei@redhat.com
Thanks, Ming