Lines Matching refs:ONW
45 ONW enumerator
102 if (conn->r[ONW]) in destroy_conn()
103 lws_ring_destroy(conn->r[ONW]); in destroy_conn()
139 i.pwsi = &pss->conn->wsi[ONW]; in connect_client()
261 conn->established[ONW] = 1; in callback_raw_proxy()
264 conn->rx_enabled[ONW] = 1; in callback_raw_proxy()
278 conn->closed[ONW] = 1; in callback_raw_proxy()
305 if (!lws_ring_insert(conn->r[ONW], &pkt, 1)) { in callback_raw_proxy()
312 (int)lws_ring_get_count_free_elements(conn->r[ONW])); in callback_raw_proxy()
314 if (conn->rx_enabled[ONW] && in callback_raw_proxy()
315 lws_ring_get_count_free_elements(conn->r[ONW]) < 2) in callback_raw_proxy()
316 flow_control(conn, ONW, 0); in callback_raw_proxy()
380 if (lws_ring_get_element(conn->r[ONW], &conn->t[ONW])) in callback_raw_proxy()
405 conn->r[ONW] = lws_ring_create(sizeof(struct packet), in callback_raw_proxy()
407 if (!conn->r[ONW]) { in callback_raw_proxy()
433 if (conn->closed[ONW]) in callback_raw_proxy()
440 if (!conn || !conn->wsi[ONW]) { in callback_raw_proxy()
445 if (conn->closed[ONW]) { in callback_raw_proxy()
446 lwsl_info(" closed[ONW] %d\n", conn->closed[ONW]); in callback_raw_proxy()
475 if (conn->established[ONW] && !conn->closed[ONW]) in callback_raw_proxy()
476 lws_callback_on_writable(conn->wsi[ONW]); in callback_raw_proxy()
482 if (!conn || !conn->established[ONW] || conn->closed[ONW]) in callback_raw_proxy()
485 ppkt = lws_ring_get_element(conn->r[ONW], &conn->t[ONW]); in callback_raw_proxy()
495 lws_callback_on_writable(conn->wsi[ONW]); in callback_raw_proxy()
507 lws_ring_consume(conn->r[ONW], &conn->t[ONW], NULL, 1); in callback_raw_proxy()
508 lws_ring_update_oldest_tail(conn->r[ONW], conn->t[ONW]); in callback_raw_proxy()
511 (int)lws_ring_get_count_free_elements(conn->r[ONW]), in callback_raw_proxy()
512 (int)lws_ring_get_count_waiting_elements(conn->r[ONW], in callback_raw_proxy()
513 &conn->t[ONW])); in callback_raw_proxy()
515 if (!conn->rx_enabled[ONW] && in callback_raw_proxy()
516 lws_ring_get_count_free_elements(conn->r[ONW]) > 2) in callback_raw_proxy()
517 flow_control(conn, ONW, 1); in callback_raw_proxy()
519 ppkt = lws_ring_get_element(conn->r[ONW], &conn->t[ONW]); in callback_raw_proxy()
531 if (conn->closed[ONW]) in callback_raw_proxy()
540 lws_callback_on_writable(conn->wsi[ONW]); in callback_raw_proxy()