projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
io_uring: sync with upstream API
[fio.git]
/
engines
/
io_uring.c
diff --git
a/engines/io_uring.c
b/engines/io_uring.c
index 8c5d9deb65ab327392e2c0e948d32a9b785a09b4..5fda2fc96fea8f88914083f5cb9e5d9ff962d580 100644
(file)
--- a/
engines/io_uring.c
+++ b/
engines/io_uring.c
@@
-154,7
+154,7
@@
static int fio_ioring_prep(struct thread_data *td, struct io_u *io_u)
sqe->opcode = IORING_OP_READ_FIXED;
else
sqe->opcode = IORING_OP_WRITE_FIXED;
sqe->opcode = IORING_OP_READ_FIXED;
else
sqe->opcode = IORING_OP_WRITE_FIXED;
- sqe->addr = io_u->xfer_buf;
+ sqe->addr =
(unsigned long)
io_u->xfer_buf;
sqe->len = io_u->xfer_buflen;
sqe->buf_index = io_u->index;
} else {
sqe->len = io_u->xfer_buflen;
sqe->buf_index = io_u->index;
} else {
@@
-162,7
+162,7
@@
static int fio_ioring_prep(struct thread_data *td, struct io_u *io_u)
sqe->opcode = IORING_OP_READV;
else
sqe->opcode = IORING_OP_WRITEV;
sqe->opcode = IORING_OP_READV;
else
sqe->opcode = IORING_OP_WRITEV;
- sqe->addr = &ld->iovecs[io_u->index];
+ sqe->addr =
(unsigned long)
&ld->iovecs[io_u->index];
sqe->len = 1;
}
sqe->off = io_u->offset;
sqe->len = 1;
}
sqe->off = io_u->offset;
@@
-478,13
+478,8
@@
static int fio_ioring_queue_init(struct thread_data *td)
ld->ring_fd = ret;
if (o->fixedbufs) {
ld->ring_fd = ret;
if (o->fixedbufs) {
- struct io_uring_register_buffers reg = {
- .iovecs = ld->iovecs,
- .nr_iovecs = depth
- };
-
ret = syscall(__NR_sys_io_uring_register, ld->ring_fd,
ret = syscall(__NR_sys_io_uring_register, ld->ring_fd,
- IORING_REGISTER_BUFFERS,
®
);
+ IORING_REGISTER_BUFFERS,
ld->iovecs, depth
);
if (ret < 0)
return ret;
}
if (ret < 0)
return ret;
}