Use io_uring_cqe_get_data() internally
Replace all cqe->user_data casts with io_uring_cqe_get_data(). Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
@@ -173,7 +173,7 @@ static int copy_file(struct io_uring *ring, off_t insize)
|
||||
if (!cqe)
|
||||
break;
|
||||
|
||||
data = (struct io_data *) (uintptr_t) cqe->user_data;
|
||||
data = io_uring_cqe_get_data(cqe);
|
||||
if (cqe->res < 0) {
|
||||
if (cqe->res == -EAGAIN) {
|
||||
queue_prepped(ring, data);
|
||||
|
||||
Reference in New Issue
Block a user