Skip to content

Commit a584b26

Browse files
Ming Leiaxboe
authored andcommitted
ublk: remove the check of ublk_need_req_ref() from __ublk_check_and_get_req
__ublk_check_and_get_req() is only called from ublk_check_and_get_req() and ublk_register_io_buf(), the same check has been covered in the two calling sites. So remove the check from __ublk_check_and_get_req(). Suggested-by: Caleb Sander Mateos <csander@purestorage.com> Signed-off-by: Ming Lei <ming.lei@redhat.com> Link: https://lore.kernel.org/r/20250429022941.1718671-5-ming.lei@redhat.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 6240f43 commit a584b26

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

drivers/block/ublk_drv.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2148,9 +2148,6 @@ static inline struct request *__ublk_check_and_get_req(struct ublk_device *ub,
21482148
{
21492149
struct request *req;
21502150

2151-
if (!ublk_need_req_ref(ubq))
2152-
return NULL;
2153-
21542151
req = blk_mq_tag_to_rq(ub->tag_set.tags[ubq->q_id], tag);
21552152
if (!req)
21562153
return NULL;

0 commit comments

Comments
 (0)