diff options
Diffstat (limited to 'src/nxt_port_memory.h')
-rw-r--r-- | src/nxt_port_memory.h | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/src/nxt_port_memory.h b/src/nxt_port_memory.h index d1f29df8..c6a49ccf 100644 --- a/src/nxt_port_memory.h +++ b/src/nxt_port_memory.h @@ -15,6 +15,27 @@ typedef struct nxt_port_mmap_handler_s nxt_port_mmap_handler_t; void nxt_port_mmaps_destroy(nxt_port_mmaps_t *port_mmaps, nxt_bool_t free_elts); +typedef struct nxt_port_mmap_tracking_s nxt_port_mmap_tracking_t; + +struct nxt_port_mmap_tracking_s { + void *mmap_handler; + nxt_atomic_t *tracking; +}; + +nxt_int_t +nxt_port_mmap_get_tracking(nxt_task_t *task, nxt_port_t *port, + nxt_port_mmap_tracking_t *tracking, uint32_t stream); + +nxt_bool_t +nxt_port_mmap_tracking_cancel(nxt_task_t *task, + nxt_port_mmap_tracking_t *tracking, uint32_t stream); + +nxt_int_t +nxt_port_mmap_tracking_write(uint32_t *buf, nxt_port_mmap_tracking_t *t); + +nxt_bool_t +nxt_port_mmap_tracking_read(nxt_task_t *task, nxt_port_recv_msg_t *msg); + /* * Allocates nxt_but_t structure from port's mem_pool, assigns this buf 'mem' * pointers to first available shared mem bucket(s). 'size' used as a hint to @@ -37,8 +58,7 @@ nxt_port_mmap_write(nxt_task_t *task, nxt_port_t *port, nxt_port_send_msg_t *msg, nxt_sendbuf_coalesce_t *sb); void -nxt_port_mmap_read(nxt_task_t *task, nxt_port_t *port, - nxt_port_recv_msg_t *msg); +nxt_port_mmap_read(nxt_task_t *task, nxt_port_recv_msg_t *msg); enum nxt_port_method_e { NXT_PORT_METHOD_ANY = 0, |