summaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2024-03-29vlib: improve automatic core pinninghsandid4-7/+103
Type: feature Auto core pinning now fetches vpp cpu affinity list using pthread api. This enables us to do core-pinning in environments where the host cpu list does not necessarily align with cpus available to vpp Change-Id: Ife8c2a2351c08c5c6c4fdf7c729eeff2697bc39a Signed-off-by: hsandid <halsandi@cisco.com>
2024-03-29misc: deprecate lawful-intercepthsandid7-487/+5
Type: refactor Change-Id: Ifd7f5b351401cdcaaaf57fefc5dbbfdaf235054e Signed-off-by: hsandid <halsandi@cisco.com>
2024-03-28acl: rework headers to enable out-of-tree usageMohammed Hawari4-8/+19
Change-Id: I1f8adf1f5650ab6c04e03c95d7a8d0bfa39b5f2d Type: improvement Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
2024-03-26tls: init session for accepted ctxFlorin Coras1-7/+7
Make sure session is marked as invalid. Type: improvement Change-Id: I1c861645de95ef15a24acd4fe6dd5364a55b4fb8 Signed-off-by: Florin Coras <fcoras@cisco.com>
2024-03-26tcp: avoid fr segments less than mss if possibleFlorin Coras1-1/+5
Type: improvement Change-Id: I958e059384db3c13a29f64be96877f57617bbae2 Signed-off-by: Florin Coras <fcoras@cisco.com>
2024-03-26tests: Add a socket timeoutTom Jones1-0/+6
On FreeBSD a races seems to occur between the states socket connecting and VPP accepting the connection and calling getpeername. The recv_fd call here will fail with no fds before the VPP process has time to handle the connection. Introducing a socket timeout removes this failure on FreeBSD and allows the test suite to run. Add a timeout on all platforms to try to avoid this race everywhere. Type: improvement Change-Id: I96f77f924a9491222bc213b534cb17001d081f3f Signed-off-by: Tom Jones <thj@freebsd.org>
2024-03-26papi: Use CMSG_SPACE for sizing ancillary buffer spaceTom Jones1-1/+1
CMSG_LEN provides the length required to store an ancillary item, but it does not consider padding. RFC 3542 requires portable applications to use CMSG_SPACE(), this is documented in the python API: https://docs.python.org/3/library/socket.html#socket.CMSG_LEN Type: improvement Change-Id: I0eab470585f2f39bea38639db95d6b0e047d2cff Signed-off-by: Tom Jones <thj@freebsd.org>
2024-03-26nat: Include platform specific headers on FreeBSDTom Jones1-0/+5
Type: improvement Change-Id: I43f59037181ec6b76499e8ee1d82c04670119dc9 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-03-26vrrp: fix vrrp_garp_or_na_send()'s memory leakluoyaozu1-0/+2
need free bi after send packets Type: fix Signed-off-by: luoyaozu <luoyaozu@foxmail.com> Change-Id: I98d03820366c3d106df212c4eb353ec6a228e20e
2024-03-25vcl: add api to retrieve num bytes for txFlorin Coras3-2/+21
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Iaa1b026e2baea1c03f8c75e7d6879d0ff6d379d6
2024-03-24tls: pass session state to engine on client initFlorin Coras1-1/+3
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ibe218a922ab656b8362e3c085193cb848783c255
2024-03-23fib: fix vectorized impl buffer typoDmitry Valter1-1/+1
Fix copy-paste typo with an incorrect index. Type: fix Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: I463e6f016df9cd24e96defcd30c1b442b8809416
2024-03-22ipsec: esp_decrypt code clean upFan Zhang1-43/+42
Type: improvement Change-Id: Icac31a8a3da71334e2b877f3b8e5d5a7cc5e76b8 Signed-off-by: Fan Zhang <fanzhang.oss@gmail.com>
2024-03-22dpdk-cryptodev: fix coverity issuesDmitry Valter1-1/+1
Copy v23.10-rc0-154-gfeda2ff64 fix to the unbatched path Type: fix Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: I2f58ed9a39439b22918946f328f96e676c68add9
2024-03-22mss_clamp: fix next layer in ipv6Maxime Peim1-16/+13
Type: fix Change-Id: I06d56e6d4be2e728e13053a66273a71656ac14c4 Signed-off-by: Maxime Peim <mpeim@cisco.com>
2024-03-21session: fix workers race to allocate lookup tableFlorin Coras1-24/+39
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I60600452c91184da571d4630bf2f0d9c24a3e85e
2024-03-21ip: add support for buffer offload metadata in ip midchainArthur de Kerhor5-44/+78
The offload should be handled by gso node or by the NIC if the latter has the relevant capabilities. But ip midchain is missing the support for buffer offload metadata in case of GSO packet. This patch adds the relevant support to add the buffer metadata if the packet is GSO/IPIP to be handled accordingly. Type: improvement Change-Id: I17f5d71bf4c5f43a85ca3f2fbebfa1426b42ef69 Signed-off-by: Arthur de Kerhor <arthurdekerhor@gmail.com> Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2024-03-21ipsec: remove unused parameter for esp_add_footer_and_icvFan Zhang1-4/+3
Type: improvement Change-Id: Ib6c4e6bc42dd63cb2fdb2dfa7e94baa709e7185b Signed-off-by: Fan Zhang <fanzhang.oss@gmail.com>
2024-03-20tls: avoid app session preallocationFlorin Coras3-56/+15
Since async rx event infra decouples notification event generation from delivery we no longer run the risk of having tls realloc session pools while session layer still holds a pointer to the accepted/connected tcp session. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I1bb429a058707aba1d4f32ea33615a2367e66969
2024-03-20vppinfra: Define EBADFD on FreeBSDTom Jones1-0/+4
Type: improvement Change-Id: I303a8a7333d44f6eab902d4d61023cfa96760dd2 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-03-19vcl: Only build vcl_ldpreload on LinuxTom Jones1-1/+6
vcl_ldpreload requires some additional porting for FreeBSD, until that can be completed only build on Linux. Type: improvement Change-Id: I9b0942114252a0c6241640d2e454861c2b5d4304 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-03-18tls: handle attepts to renegotiate hsFlorin Coras3-2/+16
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I549d0c8715e5c06bfc22be26ca1dc78ec3c29a61
2024-03-18vapi: uds transport supportStanislav Zaikin6-171/+783
introduce ability to connect over unix socket instead of shared memory Type: improvement Change-Id: Id9042c74e33ad4e418896c4d7ae48bb9106195c9 Signed-off-by: Stanislav Zaikin <stanislav.zaikin@46labs.com> Signed-off-by: Klement Sekera <klement.sekera@gmail.com>
2024-03-18vppinfra: os agnostic api for getting CPU informationDamjan Marion9-30/+77
Avoid direct sysfs reads when possible... Type: improvement Change-Id: I2b84cd18f3da47925d068951f24b79b5b6e20bb1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-03-18build: add option to specify supported OS list for pluginDamjan Marion5-1/+13
Type: improvement Change-Id: I0d6f11d5ece19c5e0e00dfdadc9d4c09274ae8e1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-03-15ip: reassembly - return correct valueKlement Sekera2-2/+2
If already enabled, return 0 to indicate success. Type: fix Change-Id: I4a182e14df9b05698ad93d596a97c46a020fd54b Signed-off-by: Klement Sekera <klement.sekera@gmail.com>
2024-03-15misc: Add platform specific header on FreeBSDTom Jones1-0/+4
Type: improvement Change-Id: Ia23414e87d64567d5124b8297315ed7a426c3651 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-03-13vcl: fix bitfield truncation with clang16Florin Coras1-1/+1
Reported by phlax while building Envoy with clang16 error: implicit truncation from 'int' to a one-bit wide bit-field changes value from 1 to -1 [-Werror,-Wsingle-bit-bitfield-constant-conversion] Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ib1b731780cf27a9498299f0424a06000dc67e81e
2024-03-13misc: fix the static vppctl buildAndrew Yourtchenko1-1/+3
Change I58e1ae1c91f4a62e80eaf4e16e9932d8bab17c74 has introduced a reference to config.h, which is not there in a case of building a static standalone vppctl. Solution: add a variable STATIC_VPPCTL which, when defined, avoids including the missing include file. Thanks a lot to Damjan for the suggestion. Type: fix Change-Id: I133235ba07e5c2e0d5669be9c2292cab0fdf436f Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2024-03-13papi: use correct size for fixed length stringsKlement Sekera1-1/+1
This is required for correct packing of unions. Type: fix Change-Id: I92d04b1bbcb3fc3fe06474d8f2c59ed3502e6bd6 Signed-off-by: Klement Sekera <klement.sekera@gmail.com>
2024-03-12misc: remove GNU Indent directivesDamjan Marion649-4341/+1
Type: refactor Change-Id: I5235bf3e9aff58af6ba2c14e8c6529c4fc9ec86c Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-03-12vpp: set asan default optionsDmitry Valter2-0/+20
set asan default options in vppctl and vpp_get_stats Type: improvement Signed-off-by: Dmitry Valter <d-valter@yandex-team.com> Change-Id: I58e1ae1c91f4a62e80eaf4e16e9932d8bab17c74
2024-03-11urpf: fix uprf_update prototypeMaxime Peim1-1/+1
Type: fix Change-Id: Idc325a096903dcdfad5157db2eb728f2e61ce974 Signed-off-by: Maxime Peim <mpeim@cisco.com>
2024-03-10session: use no for ports in transport port allocatorFlorin Coras3-11/+17
Type: improvement Change-Id: Ia1d8aaa3c51938cfa15dd09102471f52ebe67a3d Signed-off-by: Florin Coras <fcoras@cisco.com>
2024-03-09session: fix port alloc for fixed lcl port reuseFlorin Coras1-2/+3
Type: fix Change-Id: If30d1aa8aa752ae4bddde776832a3009ebc7e316 Signed-off-by: Florin Coras <fcoras@cisco.com>
2024-03-07flowprobe: fix flush callbacks when multiple workersAlexander Chernavin1-0/+86
IPFIX buffers are stored on a per worker thread basis. Currently, the flush callbacks will flush only buffers stored for the main thread. And buffers for worker threads will not be sent until their size reach the path MTU configured for the exporter. So if traffic is constant, the problem will unlikely to be visible. Buffers will be sent once they reach the maximum size. However, if traffic stops at some point and flush is triggered in order to make the plugin send all currently buffered data, this will not happen. And collectors will not receive that data. The plugin will keep the remaining data until traffic starts again, the buffers reach the maximum size, and be sent. With this fix, flush buffers for worker threads and for the main thread when the flush callbacks are triggered. This will allow to remove @tag_fixme_vpp_workers from the unit tests that don't set timers. The tests that set timers will still be failing for other multi-worker related problems. Type: fix Change-Id: I9a7d9cef8ddbec7ee68c79309e48e7bc0953d488 Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
2024-03-05ip: force full reassembly before virtualMatthew Smith1-14/+5
Type: improvement The vnet buffer metadata for full IP reassembly and shallow virtual reassembly overlaps. If you have full reassembly and virtual reassembly enabled on the same interface and virtual reassembly happens to process packets first, full reassembly will stomp on the metadata populated by virtual reassembly. Virtual reassembly gets enabled implicitly when NAT feature nodes are enabled. Those NAT feature nodes rely on the virtual reassembly metadata being populated correctly in order to find L4 proto & ports. When NAT and IP full reassembly are both enabled on an interface, NAT can drop fragmented packets because the virtual reassembly metadata can be overwritten by full reassembly. Ensure that full reassembly runs before virtual reassembly. Add a runs_before dependency to ensure that ip4-full-reassembly-feature runs before ip4-sv-reassembly-feature. There was a duplicate VNET_FEATURE_INIT() for ip4-full-reassembly-feature. It seems to have been intended for enabling ip4-full-reassembly-custom as a feature node, but its contents are identical to the earlier VNET_FEATURE_INIT() for ip4-full-reassembly-feature. Removed the duplicate. Change-Id: Ie600b854d4ceb90a7cb736810140d410b8f72447 Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2024-03-05dpdk: correct waiting timesGeorgy Borodin2-9/+53
When link state interval is 3 and stats interval is 10, updates for stats will be made every 12 seconds (next number after 10, that divisible by 3). And if you get counters every 30 secs, you will get ideal "saw"-line instead of real smooth chart. This commit makes smooth line on stats intervals that are divisors of the charts update interval (regardless of link state interval), and makes it possible to configure them. Type: fix Fixes: cb9cadad578297ffd78fa8a33670bdf1ab669e7e Change-Id: Ia4350467be2b0ec0c1be37c7fda63f43b3330f44 Signed-off-by: Georgy Borodin <bor1-go@yandex-team.ru>
2024-03-05vpp: fix stdin vs non-interactive command clashVladislav Grishenko1-10/+13
In case of both stdin and non-interactive inputs are there vppctl parses them all, causing mixed corrupted output: $ echo foo | vppctl sh bar show: unknown input `bar' unknown input `foo' This is not desired, stdin should be ignored if there's a command but still allow stdin commands - following cases are still equal: $ vppctl foo $ echo foo | vppctl Type: fix Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I98667391627150c98a57d49ae544e48ef3351f34
2024-03-05octeon: add support for VF deviceMonendra Singh Kushwaha3-6/+19
This patch adds support for VF and loopback device. Type: feature Change-Id: I1ea92f3a1161851957206300ab921c27290b0305 Signed-off-by: Monendra Singh Kushwaha <kmonendra@marvell.com>
2024-03-05vlib: fix initial stats time for the process nodesVladislav Grishenko1-1/+2
Uninitialized stats time for new dynamic processes (like unix cli) leads to invalid and too high clocks diff, breaking the stats collecting. $ sudo vppctl sh runtime | grep unix unix-cli-new-session any wait 0 0 30 2.72e3 0.00 unix-cli-process-0 active 14 0 27 3.73e15 0.00 unix-epoll-input polling 6464 0 0 3.56e6 0.00 unix-epoll-input polling 68360 0 0 1.31e3 0.00 Type: fix Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: Ic70678b67a3fb3f78ed4a1a03077ae243ed5d7cd
2024-03-05vnet: fix format of deleted sw interfacesVladislav Grishenko16-82/+49
As similar 535364e90459566b603661c3dbe360c72f59ad71 is merged, printing possibly deleted interfaces by index only in all the rest cases. Type: improvement Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I4fa58b382c0279ff893523ba0188fdb9b09e10af
2024-03-04vppinfra: SHA2-256 ARM ISA supportDamjan Marion1-55/+104
Change-Id: I0fcda3e7afaab037bd12d0079d6639c6cbe8647e Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-03-04af_packet: fix the device input feature arc supportMohsin Kazmi1-32/+13
Type: fix Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: I1c900bbe441c6797215f16e99b71149904aa745f
2024-03-04misc: fix icmpMaxime Peim2-1/+1
- fix ICMPv6 lookup FIB (don't reset sw_if_index[VLIB_TX] to -1) - add locally generated flag in ICMPv4 buffers (reflect ICMPv6) Type: fix Change-Id: If25a176a9952cbe185a030f8b136718af1bff9e8 Signed-off-by: Maxime Peim <mpeim@cisco.com>
2024-03-04bpf_trace_filter: support bpf filter optimization and dumpVladislav Grishenko5-14/+95
BPF filter w/o optimization can take x2 - x3 more instructions, causing significant slow down in fast path. Enable pcap optimization by default via cli and introduce api v2 with pcap optimization control, keep v1 for a while as it exists in previous release already. Intriduce bpf filter cli dump, similar to tcpdump -d. Also fix memleak, function name typo, cli pcap format hint and add related tests. Type: improvement Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I92b2b519e92326f1b8e1a4dda6a3e3edc52f87ad
2024-03-04vppinfra: add os_get_online_cpu_core() and os_get_online_cpu_node()Damjan Marion6-22/+47
Type: improvement Change-Id: I6f99f09c7724ce656a4f41a1d5f9c88d74c00faf Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-03-04ip: fix warning on interface ipv6 prefix removeVladislav Grishenko1-1/+1
Type: fix Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I428f52abbdddd9caca9b0f619a0e934f96ac0b4a
2024-03-04fib: fix crash while adding intf-rx routesVladislav Grishenko6-5/+31
Fix crash while adding intf-rx ip4 and ip6 routes via api due invalid exporting of interface rx routes as attached. Also, add missed route path via rx-ip6 cli support. Type: fix Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I15711c8c0787398dd7e3baa4787019bb1f317666
2024-03-03svm: fix svm queue overwrite while adding 2 elementsVladislav Grishenko1-2/+2
Adding two elements to the full svm queue passes exact bounds check, therefore tail gets overwritten w/o any waiting. Fix it with requiring at lease two free slots. Type: fix Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I704ee606c47b523952cb965f848339ae1988cb60