···343343 external peek_cqe : t -> cqe_option = "ocaml_uring_peek_cqe"
344344345345 external error_of_errno : int -> Unix.error = "ocaml_uring_error_of_errno"
346346+ external register_eventfd : t -> Unix.file_descr -> unit = "ocaml_uring_register_eventfd"
346347end
347348348349type 'a t = {
···582583 fn_on_ring Uring.peek_cqe t
583584584585let peek = get_cqe_nonblocking
586586+587587+let register_eventfd t fd =
588588+ check t;
589589+ Uring.register_eventfd t.uring fd
585590586591let wait ?timeout t =
587592 check t;
+4
vendor/opam/uring/lib/uring/uring.mli
···441441val peek : 'a t -> 'a completion_option
442442[@@deprecated "Renamed to Uring.get_cqe_nonblocking"]
443443444444+val register_eventfd : 'a t -> Unix.file_descr -> unit
445445+(** [register_eventfd t fd] will register an eventfd to the the uring [t].
446446+ See documentation for io_uring_register_eventfd *)
447447+444448val error_of_errno : int -> Unix.error
445449(** [error_of_errno e] converts the error code [abs e] to a Unix error type. *)
446450
+12
vendor/opam/uring/lib/uring/uring_stubs.c
···998998 else
999999 return Val_false;
10001000}
10011001+10021002+value
10031003+ocaml_uring_register_eventfd(value v_uring, value v_fd) {
10041004+ struct io_uring *ring = Ring_val(v_uring);
10051005+ int fd = Int_val(v_fd);
10061006+10071007+ int ret = io_uring_register_eventfd(ring, fd);
10081008+ if (ret)
10091009+ unix_error(-ret, "io_uring_register_eventfd", Nothing);
10101010+10111011+ return Val_unit;
10121012+}