mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-07-16 17:57:38 -04:00
block: add a rq_list type
Replace the semi-open coded request list helpers with a proper rq_list type that mirrors the bio_list and has head and tail pointers. Besides better type safety this actually allows to insert at the tail of the list, which will be useful soon. Signed-off-by: Christoph Hellwig <hch@lst.de> Link: https://lore.kernel.org/r/20241113152050.157179-5-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
committed by
Jens Axboe
parent
e8225ab150
commit
a3396b9999
@@ -1160,12 +1160,12 @@ int io_do_iopoll(struct io_ring_ctx *ctx, bool force_nonspin)
|
||||
poll_flags |= BLK_POLL_ONESHOT;
|
||||
|
||||
/* iopoll may have completed current req */
|
||||
if (!rq_list_empty(iob.req_list) ||
|
||||
if (!rq_list_empty(&iob.req_list) ||
|
||||
READ_ONCE(req->iopoll_completed))
|
||||
break;
|
||||
}
|
||||
|
||||
if (!rq_list_empty(iob.req_list))
|
||||
if (!rq_list_empty(&iob.req_list))
|
||||
iob.complete(&iob);
|
||||
else if (!pos)
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user