/io_uring/ |
A D | nop.c | 18 int fd; member 39 nop->fd = READ_ONCE(sqe->fd); in io_nop_prep() 41 nop->fd = -1; in io_nop_prep() 54 req->file = io_file_get_fixed(req, nop->fd, issue_flags); in io_nop() 57 req->file = io_file_get_normal(req, nop->fd); in io_nop()
|
A D | cancel.c | 26 s32 fd; member 154 cancel->fd = READ_ONCE(sqe->fd); in io_async_cancel_prep() 215 req->file = io_file_get_fixed(req, cancel->fd, in io_async_cancel() 218 req->file = io_file_get_normal(req, cancel->fd); in io_async_cancel() 236 struct io_cancel_data *cd, int fd) in __io_sync_cancel() argument 245 node = io_rsrc_node_lookup(&ctx->file_table.data, fd); in __io_sync_cancel() 287 file = fget(sc.fd); in io_sync_cancel() 293 ret = __io_sync_cancel(current->io_uring, &cd, sc.fd); in io_sync_cancel() 317 ret = __io_sync_cancel(current->io_uring, &cd, sc.fd); in io_sync_cancel()
|
A D | epoll.c | 19 int fd; member 36 epoll->epfd = READ_ONCE(sqe->fd); in io_epoll_ctl_prep() 38 epoll->fd = READ_ONCE(sqe->off); in io_epoll_ctl_prep() 57 ret = do_epoll_ctl(ie->epfd, ie->op, ie->fd, &ie->event, force_nonblock); in io_epoll_ctl()
|
A D | mock_file.c | 217 int fd = -1, ret; in io_create_mock_file() local 249 ret = fd = get_unused_fd_flags(O_RDWR | O_CLOEXEC); in io_create_mock_file() 250 if (fd < 0) in io_create_mock_file() 274 mc.out_fd = fd; in io_create_mock_file() 281 fd_install(fd, file); in io_create_mock_file() 284 if (fd >= 0) in io_create_mock_file() 285 put_unused_fd(fd); in io_create_mock_file()
|
A D | openclose.c | 32 int fd; member 67 open->dfd = READ_ONCE(sqe->fd); in __io_openat_prep() 218 close->fd = READ_ONCE(sqe->fd); in io_close_prep() 220 if (close->file_slot && close->fd) in io_close_prep() 239 file = files_lookup_fd_locked(files, close->fd); in io_close() 251 file = file_close_fd_locked(files, close->fd); in io_close() 320 if (sqe->fd || sqe->off || sqe->addr3) in io_pipe_prep()
|
A D | eventfd.c | 120 int fd; in io_eventfd_register() local 127 if (copy_from_user(&fd, fds, sizeof(*fds))) in io_eventfd_register() 134 ev_fd->cq_ev_fd = eventfd_ctx_fdget(fd); in io_eventfd_register()
|
A D | fs.c | 60 ren->old_dfd = READ_ONCE(sqe->fd); in io_renameat_prep() 114 un->dfd = READ_ONCE(sqe->fd); in io_unlinkat_prep() 164 mkd->dfd = READ_ONCE(sqe->fd); in io_mkdirat_prep() 208 sl->new_dfd = READ_ONCE(sqe->fd); in io_symlinkat_prep() 251 lnk->old_dfd = READ_ONCE(sqe->fd); in io_linkat_prep()
|
A D | rsrc.c | 229 int fd, i, err = 0; in __io_sqe_files_update() local 241 copy_from_user(&fd, &fds[done], sizeof(fd))) { in __io_sqe_files_update() 245 if ((fd == IORING_REGISTER_FILES_SKIP || fd == -1) && tag) { in __io_sqe_files_update() 256 if (fd != -1) { in __io_sqe_files_update() 450 int ret, fd; in io_files_update_with_index_alloc() local 456 if (copy_from_user(&fd, &fds[done], sizeof(fd))) { in io_files_update_with_index_alloc() 461 file = fget(fd); in io_files_update_with_index_alloc() 546 int fd, ret; in io_sqe_files_register() local 567 if (fds && copy_from_user(&fd, &fds[i], sizeof(fd))) in io_sqe_files_register() 570 if (!fds || fd == -1) { in io_sqe_files_register() [all …]
|
A D | register.c | 851 struct file *io_uring_register_get_file(unsigned int fd, bool registered) in io_uring_register_get_file() argument 862 if (unlikely(!tctx || fd >= IO_RINGFD_REG_MAX)) in io_uring_register_get_file() 864 fd = array_index_nospec(fd, IO_RINGFD_REG_MAX); in io_uring_register_get_file() 865 file = tctx->registered_rings[fd]; in io_uring_register_get_file() 869 file = fget(fd); in io_uring_register_get_file() 906 SYSCALL_DEFINE4(io_uring_register, unsigned int, fd, unsigned int, opcode, in SYSCALL_DEFINE4() argument 920 if (fd == -1) in SYSCALL_DEFINE4() 923 file = io_uring_register_get_file(fd, use_registered_ring); in SYSCALL_DEFINE4()
|
A D | register.h | 7 struct file *io_uring_register_get_file(unsigned int fd, bool registered);
|
A D | net.c | 1662 int ret, fd; in io_accept() local 1671 if (unlikely(fd < 0)) in io_accept() 1672 return fd; in io_accept() 1680 put_unused_fd(fd); in io_accept() 1689 fd_install(fd, file); in io_accept() 1690 ret = fd; in io_accept() 1739 int ret, fd; in io_socket() local 1743 if (unlikely(fd < 0)) in io_socket() 1744 return fd; in io_socket() 1749 put_unused_fd(fd); in io_socket() [all …]
|
A D | io_uring.c | 1966 struct file *file = fget(fd); in io_file_get_normal() 1968 trace_io_uring_file_get(req, fd); in io_file_get_normal() 2169 req->cqe.fd = READ_ONCE(sqe->fd); in io_init_req() 3423 fd = array_index_nospec(fd, IO_RINGFD_REG_MAX); in SYSCALL_DEFINE6() 3424 file = tctx->registered_rings[fd]; in SYSCALL_DEFINE6() 3428 file = fget(fd); in SYSCALL_DEFINE6() 3605 int fd; in io_uring_install_fd() local 3608 if (fd < 0) in io_uring_install_fd() 3609 return fd; in io_uring_install_fd() 3610 fd_install(fd, file); in io_uring_install_fd() [all …]
|
A D | statx.c | 33 sx->dfd = READ_ONCE(sqe->fd); in io_statx_prep()
|
A D | futex.c | 135 flags = READ_ONCE(sqe->fd); in io_futex_prep() 175 if (unlikely(sqe->fd || sqe->buf_index || sqe->file_index || in io_futexv_prep()
|
A D | tctx.c | 236 static int io_ring_add_registered_fd(struct io_uring_task *tctx, int fd, in io_ring_add_registered_fd() argument 242 file = fget(fd); in io_ring_add_registered_fd()
|
A D | msg_ring.c | 350 CLASS(fd, f)(sqe->fd); in io_uring_sync_msg_ring()
|
A D | io_uring.h | 88 struct file *io_file_get_normal(struct io_kiocb *req, int fd); 89 struct file *io_file_get_fixed(struct io_kiocb *req, int fd,
|
A D | sqpoll.c | 119 CLASS(fd, f)(p->wq_fd); in io_attach_sq_data() 428 CLASS(fd, f)(p->wq_fd); in io_sq_offload_create()
|
A D | fdinfo.c | 110 sq_idx, io_uring_get_opcode(sqe->opcode), sqe->fd, in __io_uring_show_fdinfo()
|
A D | waitid.c | 259 iw->upid = READ_ONCE(sqe->fd); in io_waitid_prep()
|
A D | kbuf.c | 450 tmp = READ_ONCE(sqe->fd); in io_remove_buffers_prep() 469 tmp = READ_ONCE(sqe->fd); in io_provide_buffers_prep()
|