aboutsummaryrefslogtreecommitdiffstats
path: root/src/vcl/ldp.c
AgeCommit message (Expand)AuthorFilesLines
2019-08-21vcl: fix ldp_set_app_name overflowBenoƮt Ganne1-5/+2
2019-05-09ldp: add option to eanble transparent TLS connectionsYu Ping1-2/+87
2019-04-04ldp: ignore TCP_CORK socket optionFlorin Coras1-0/+1
2019-03-20ldp: force exit if constructor init failsFlorin Coras1-2/+5
2019-03-15vcl: cleanup debug messagesFlorin Coras1-1/+1
2019-03-11ldp: fix worker alloc when using eventfdsFlorin Coras1-1/+15
2019-02-22session/vcl: fix coverity warningsFlorin Coras1-1/+5
2019-02-19ldp: return byte count from a successful recvfromHaggai Eran1-2/+6
2019-01-30ldp: initialize clib timeFlorin Coras1-8/+18
2019-01-29vls: multi-process and multi-threaded apps improvementsFlorin Coras1-9/+10
2019-01-23vcl: generate epoll events only if requestedFlorin Coras1-8/+4
2019-01-21ldp: add support for TCP_CONGESTION sockopts (VPP-1550)Florin Coras1-0/+9
2019-01-08vcl/ldp: select cleanup/improvementsFlorin Coras1-207/+185
2019-01-07vcl/ldp: add locked sessions shim layerFlorin Coras1-1284/+336
2019-01-05vcl/session: add api for changing session app workerFlorin Coras1-105/+159
2019-01-02Fixes for buliding for 32bit targets:David Johnson1-3/+6
2019-01-02ldp/vcl: epoll and shutdown cleanupFlorin Coras1-92/+45
2019-01-01vcl/ldp: add write msg function and fine tuningFlorin Coras1-45/+7
2018-12-13ldp/vcl: reduce debug verbosityFlorin Coras1-307/+113
2018-12-05ldp: avoid calling write in destructorsFlorin Coras1-3/+6
2018-12-03vcl: handle worker process exitFlorin Coras1-4/+1
2018-11-29vcl: basic support for apps that forkFlorin Coras1-2/+4
2018-11-29ldp: basic multiworker supportFlorin Coras1-119/+159
2018-11-27ldp: sid to fd mapper for apps with multiple workersFlorin Coras1-22/+105
2018-11-17ldp: fixes/improvements to selectFlorin Coras1-93/+83
2018-11-14Remove c-11 memcpy checks from perf-critical codeDave Barach1-21/+24
2018-11-14vcl/ldp: fix pollFlorin Coras1-56/+54
2018-08-10vcl: support for eventfd mq signalingFlorin Coras1-221/+197
2018-07-27vcl: use events for epoll/select/read/writeFlorin Coras1-1/+1
2018-05-31fix socket send() return size checkqchang1-1/+1
2018-02-24LDP: Refactor epoll_ctl wrapper.Dave Wallace1-45/+80
2018-02-23VCL/LDP: Suppress trace output unless debug is enabled.Dave Wallace1-14/+19
2018-02-09LD_PRELOAD: Refactor nomenclature (vcom -> ldp).Dave Wallace1-0/+3447
s = format (s, "DELETED:%d", rw->sw_if_index); } s = format (s, " mtu:%d", rw->max_l3_packet_bytes); /* Format rewrite string. */ if (rw->data_bytes > 0) s = format (s, " %U", format_hex_bytes, rw->data, rw->data_bytes); return s; } u32 vnet_tx_node_index_for_sw_interface (vnet_main_t * vnm, u32 sw_if_index) { vnet_hw_interface_t *hw = vnet_get_sup_hw_interface (vnm, sw_if_index); return (hw->output_node_index); } void vnet_rewrite_init (vnet_main_t * vnm, u32 sw_if_index, vnet_link_t linkt, u32 this_node, u32 next_node, vnet_rewrite_header_t * rw) { rw->sw_if_index = sw_if_index; rw->next_index = vlib_node_add_next (vnm->vlib_main, this_node, next_node); rw->max_l3_packet_bytes = vnet_sw_interface_get_mtu (vnm, sw_if_index, vnet_link_to_mtu (linkt)); } void vnet_rewrite_update_mtu (vnet_main_t * vnm, vnet_link_t linkt, vnet_rewrite_header_t * rw) { rw->max_l3_packet_bytes = vnet_sw_interface_get_mtu (vnm, rw->sw_if_index, vnet_link_to_mtu (linkt)); } void vnet_rewrite_for_sw_interface (vnet_main_t * vnm, vnet_link_t link_type, u32 sw_if_index, u32 node_index, void *dst_address, vnet_rewrite_header_t * rw, u32 max_rewrite_bytes) { vnet_hw_interface_t *hw = vnet_get_sup_hw_interface (vnm, sw_if_index); vnet_hw_interface_class_t *hc = vnet_get_hw_interface_class (vnm, hw->hw_class_index); u8 *rewrite = NULL; vnet_rewrite_init (vnm, sw_if_index, link_type, node_index, vnet_tx_node_index_for_sw_interface (vnm, sw_if_index), rw); ASSERT (hc->build_rewrite); rewrite = hc->build_rewrite (vnm, sw_if_index, link_type, dst_address); ASSERT (vec_len (rewrite) < max_rewrite_bytes); vnet_rewrite_set_data_internal (rw, max_rewrite_bytes, rewrite, vec_len (rewrite)); vec_free (rewrite); } void serialize_vnet_rewrite (serialize_main_t * m, va_list * va) { vnet_rewrite_header_t *rw = va_arg (*va, vnet_rewrite_header_t *); u32 max_data_bytes = va_arg (*va, u32); u8 *p; serialize_integer (m, rw->sw_if_index, sizeof (rw->sw_if_index)); serialize_integer (m, rw->data_bytes, sizeof (rw->data_bytes)); serialize_integer (m, rw->max_l3_packet_bytes, sizeof (rw->max_l3_packet_bytes)); p = serialize_get (m, rw->data_bytes); clib_memcpy (p, vnet_rewrite_get_data_internal (rw, max_data_bytes), rw->data_bytes); } void unserialize_vnet_rewrite (serialize_main_t * m, va_list * va) { vnet_rewrite_header_t *rw = va_arg (*va, vnet_rewrite_header_t *); u32 max_data_bytes = va_arg (*va, u32); u8 *p; /* It is up to user to fill these in. */ rw->next_index = ~0; unserialize_integer (m, &rw->sw_if_index, sizeof (rw->sw_if_index)); unserialize_integer (m, &rw->data_bytes, sizeof (rw->data_bytes)); unserialize_integer (m, &rw->max_l3_packet_bytes, sizeof (rw->max_l3_packet_bytes)); p = unserialize_get (m, rw->data_bytes); clib_memcpy (vnet_rewrite_get_data_internal (rw, max_data_bytes), p, rw->data_bytes); } u8 * vnet_build_rewrite_for_sw_interface (vnet_main_t * vnm, u32 sw_if_index, vnet_link_t link_type, const void *dst_address) { vnet_hw_interface_t *hw = vnet_get_sup_hw_interface (vnm, sw_if_index); vnet_hw_interface_class_t *hc = vnet_get_hw_interface_class (vnm, hw->hw_class_index); ASSERT (hc->build_rewrite); return (hc->build_rewrite (vnm, sw_if_index, link_type, dst_address)); } void vnet_update_adjacency_for_sw_interface (vnet_main_t * vnm, u32 sw_if_index, u32 ai) { vnet_hw_interface_t *hw = vnet_get_sup_hw_interface (vnm, sw_if_index); vnet_hw_interface_class_t *hc = vnet_get_hw_interface_class (vnm, hw->hw_class_index); ASSERT (hc->update_adjacency); hc->update_adjacency (vnm, sw_if_index, ai); } /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */