Lines Matching refs:socket

47     port->socket.task = task;  in nxt_port_socket_init()
122 nxt_socket_close(port->socket.task, port->socket.fd); in nxt_port_destroy()
130 port->socket.fd = port->pair[1]; in nxt_port_write_enable()
131 port->socket.log = &nxt_main_log; in nxt_port_write_enable()
132 port->socket.write_ready = 1; in nxt_port_write_enable()
136 port->socket.write_work_queue = &port->engine->fast_work_queue; in nxt_port_write_enable()
137 port->socket.write_handler = nxt_port_write_handler; in nxt_port_write_enable()
138 port->socket.error_handler = nxt_port_error_handler; in nxt_port_write_enable()
145 nxt_socket_close(port->socket.task, port->pair[1]); in nxt_port_write_close()
206 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_socket_write2()
233 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_socket_write2()
244 nxt_port_write_handler(task, &port->socket, &msg); in nxt_port_socket_write2()
310 if (nxt_fast_path(port->socket.write_ready in nxt_port_msg_chk_insert()
355 nxt_fd_event_block_write(task->thread->engine, &port->socket); in nxt_port_fd_block_write()
362 nxt_fd_event_enable_write(task->thread->engine, &port->socket); in nxt_port_fd_enable_write()
381 port = nxt_container_of(obj, nxt_port_t, socket); in nxt_port_write_handler()
446 n = nxt_socketpair_send(&port->socket, msg->fd, iov, sb.niov + 1); in nxt_port_write_handler()
451 port->socket.fd, n, sb.size + iov[0].iov_len); in nxt_port_write_handler()
461 nxt_debug(task, "port %d: frag stream #%uD", port->socket.fd, in nxt_port_write_handler()
537 } while (port->socket.write_ready); in nxt_port_write_handler()
539 if (nxt_fd_event_is_disabled(port->socket.write)) { in nxt_port_write_handler()
549 nxt_work_queue_add(wq, nxt_port_error_handler, task, &port->socket, in nxt_port_write_handler()
550 &port->socket); in nxt_port_write_handler()
554 if (block_write && nxt_fd_event_is_active(port->socket.write)) { in nxt_port_write_handler()
705 port->socket.fd = port->pair[0]; in nxt_port_read_enable()
706 port->socket.log = &nxt_main_log; in nxt_port_read_enable()
710 port->socket.read_work_queue = &port->engine->fast_work_queue; in nxt_port_read_enable()
711 port->socket.read_handler = port->queue != NULL in nxt_port_read_enable()
714 port->socket.error_handler = nxt_port_error_handler; in nxt_port_read_enable()
716 nxt_fd_event_enable_read(port->engine, &port->socket); in nxt_port_read_enable()
723 port->socket.read_ready = 0; in nxt_port_read_close()
724 port->socket.read = NXT_EVENT_INACTIVE; in nxt_port_read_close()
725 nxt_socket_close(port->socket.task, port->pair[0]); in nxt_port_read_close()
741 port = msg.port = nxt_container_of(obj, nxt_port_t, socket); in nxt_port_read_handler()
758 n = nxt_socketpair_recv(&port->socket, iov, 2, &oob); in nxt_port_read_handler()
768 port->socket.fd); in nxt_port_read_handler()
788 if (port->socket.read_ready) { in nxt_port_read_handler()
798 nxt_fd_event_enable_read(task->thread->engine, &port->socket); in nxt_port_read_handler()
805 nxt_port_error_handler, task, &port->socket, NULL); in nxt_port_read_handler()
824 port = nxt_container_of(obj, nxt_port_t, socket); in nxt_port_queue_read_handler()
837 if (n < 0 && !port->socket.read_ready) { in nxt_port_queue_read_handler()
852 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
859 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
875 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
884 if (n < 0 && !port->socket.read_ready) { in nxt_port_queue_read_handler()
910 n = nxt_socketpair_recv(&port->socket, iov, 2, &oob); in nxt_port_queue_read_handler()
920 port->socket.fd); in nxt_port_queue_read_handler()
934 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
941 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
947 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
960 port->socket.fd); in nxt_port_queue_read_handler()
972 port->socket.fd); in nxt_port_queue_read_handler()
1013 nxt_fd_event_enable_read(task->thread->engine, &port->socket); in nxt_port_queue_read_handler()
1021 nxt_port_error_handler, task, &port->socket, NULL); in nxt_port_queue_read_handler()
1179 port->socket.fd, msg->size); in nxt_port_read_msg_process()
1289 nxt_work_queue_add(port->socket.read_work_queue, in nxt_port_read_msg_process()
1347 port = nxt_container_of(obj, nxt_port_t, socket); in nxt_port_error_handler()