diff options
Diffstat (limited to 'uring.h')
-rw-r--r-- | uring.h | 59 |
1 files changed, 25 insertions, 34 deletions
@@ -6,75 +6,66 @@ extern uint64_t cqe_count; void uring_task_refdump(struct uring_task *task); -void uring_task_destroy(struct cfg *cfg, struct uring_task *task); +void uring_task_destroy(struct uring_task *task); -void uring_task_put(struct cfg *cfg, struct uring_task *task); +void uring_task_put(struct uring_task *task); -void uring_task_get(struct cfg *cfg, struct uring_task *task); +void uring_task_get(struct uring_task *task); void uring_task_set_buf(struct uring_task *task, struct uring_task_buf *tbuf); void uring_task_set_fd(struct uring_task *task, int fd); -void uring_task_close_fd(struct cfg *cfg, struct uring_task *task); +void uring_task_close_fd(struct uring_task *task); -struct uring_task *uring_parent(struct cfg *cfg); +struct uring_task *uring_parent(); -void uring_task_init(struct cfg *cfg, struct uring_task *task, const char *name, +void uring_task_init(struct uring_task *task, const char *name, struct uring_task *parent, void (*free)(struct uring_task *)); -void uring_close(struct cfg *cfg, struct uring_task *task, int fd); +void uring_close(struct uring_task *task, int fd); -void uring_tbuf_write(struct cfg *cfg, struct uring_task *task, - utask_cb_t final_cb); +void uring_tbuf_write(struct uring_task *task, utask_cb_t final_cb); -void uring_write(struct cfg *cfg, struct uring_task *task, void *buf, - size_t len, utask_cb_t cb); +void uring_write(struct uring_task *task, void *buf, size_t len, utask_cb_t cb); -void uring_tbuf_read_until(struct cfg *cfg, struct uring_task *task, +void uring_tbuf_read_until(struct uring_task *task, rutask_cb_t is_complete_cb, utask_cb_t final_cb); -void uring_tbuf_read_until_eof(struct cfg *cfg, struct uring_task *task, - utask_cb_t final_cb); +void uring_tbuf_read_until_eof(struct uring_task *task, utask_cb_t final_cb); -void uring_tbuf_read(struct cfg *cfg, struct uring_task *task, - utask_cb_t final_cb); +void uring_tbuf_read(struct uring_task *task, utask_cb_t final_cb); -void uring_read_offset(struct cfg *cfg, struct uring_task *task, void *buf, +void uring_read_offset(struct uring_task *task, void *buf, size_t len, off_t offset, utask_cb_t cb); static inline void -uring_read(struct cfg *cfg, struct uring_task *task, void *buf, size_t len, - utask_cb_t cb) +uring_read(struct uring_task *task, void *buf, size_t len, utask_cb_t cb) { - uring_read_offset(cfg, task, buf, len, 0, cb); + uring_read_offset(task, buf, len, 0, cb); } -void uring_openat(struct cfg *cfg, struct uring_task *task, const char *path, - utask_cb_t cb); +void uring_openat(struct uring_task *task, const char *path, utask_cb_t cb); -void uring_tbuf_recvmsg(struct cfg *cfg, struct uring_task *task, utask_cb_t cb); +void uring_tbuf_recvmsg(struct uring_task *task, utask_cb_t cb); -void uring_tbuf_sendmsg(struct cfg *cfg, struct uring_task *task, utask_cb_t cb); +void uring_tbuf_sendmsg(struct uring_task *task, utask_cb_t cb); -void uring_connect(struct cfg *cfg, struct uring_task *task, - struct saddr *saddr, utask_cb_t cb); +void uring_connect(struct uring_task *task, struct saddr *saddr, utask_cb_t cb); -void uring_accept(struct cfg *cfg, struct uring_task *task, - struct saddr *saddr, utask_cb_t cb); +void uring_accept(struct uring_task *task, struct saddr *saddr, utask_cb_t cb); -void uring_poll(struct cfg *cfg, struct uring_task *task, short poll_mask, - utask_cb_t cb); +void uring_poll(struct uring_task *task, short poll_mask, utask_cb_t cb); -void uring_poll_cancel(struct cfg *cfg, struct uring_task *task); +void uring_poll_cancel(struct uring_task *task); -void uring_delete(struct cfg *cfg); +void uring_delete(); void uring_refdump(struct uring_ev *uev); -void uring_init(struct cfg *cfg); +void uring_init(); -void uring_event_loop(struct cfg *cfg); +void uring_event_loop(); #endif |