Skip to content

Commit 692cf47

Browse files
calebsanderaxboe
authored andcommitted
ublk: don't access ublk_queue in ublk_register_io_buf()
For ublk servers with many ublk queues, accessing the ublk_queue in ublk_register_io_buf() is a frequent cache miss. Get the flags from the ublk_device instead, which is accessed earlier in ublk_ch_uring_cmd_local(). Signed-off-by: Caleb Sander Mateos <csander@purestorage.com> Reviewed-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 8a81926 commit 692cf47

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/block/ublk_drv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2133,7 +2133,7 @@ static int ublk_register_io_buf(struct io_uring_cmd *cmd,
21332133
struct request *req;
21342134
int ret;
21352135

2136-
if (!ublk_support_zero_copy(ubq))
2136+
if (!ublk_dev_support_zero_copy(ub))
21372137
return -EINVAL;
21382138

21392139
req = __ublk_check_and_get_req(ub, ubq, io, 0);

0 commit comments

Comments
 (0)