@@ -468,12 +468,5 @@ out:
int io_uring_register_wait_reg(struct io_uring *ring,
struct io_uring_reg_wait *reg, int nr)
{
- struct io_uring_cqwait_reg_arg arg = {
- .flags = 0,
- .struct_size = sizeof(*reg),
- .nr_entries = nr,
- .user_addr = (unsigned long) (uintptr_t) reg,
- };
-
- return do_register(ring, IORING_REGISTER_CQWAIT_REG, &arg, 1);
+ return -EINVAL;
}
@@ -689,29 +689,10 @@ int io_uring_free_buf_ring(struct io_uring *ring, struct io_uring_buf_ring *br,
void io_uring_free_reg_wait(struct io_uring_reg_wait *reg, unsigned nentries)
{
- __sys_munmap(reg, nentries * sizeof(struct io_uring_reg_wait));
}
struct io_uring_reg_wait *io_uring_setup_reg_wait(struct io_uring *ring,
unsigned nentries, int *err)
{
- struct io_uring_reg_wait *reg;
- size_t size = nentries * sizeof(*reg);
- int ret;
-
- reg = __sys_mmap(NULL, size, PROT_READ | PROT_WRITE,
- MAP_SHARED|MAP_POPULATE|MAP_ANONYMOUS, -1, 0);
- if (IS_ERR(reg)) {
- *err = PTR_ERR(reg);
- return NULL;
- }
-
- memset(reg, 0, size);
- ret = io_uring_register_wait_reg(ring, reg, nentries);
- if (!ret)
- return reg;
-
- __sys_munmap(reg, size);
- *err = ret;
return NULL;
}
We're changing the registration and kernel api, kill reg wait registration but leave definitions so that tests build. Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> --- src/register.c | 9 +-------- src/setup.c | 19 ------------------- 2 files changed, 1 insertion(+), 27 deletions(-)