summaryrefslogtreecommitdiffstats
path: root/src/plugins
AgeCommit message (Collapse)AuthorFilesLines
2022-01-06dpdk: port type from speed_capa bitmap on Cisco VICDamjan Marion1-35/+1
enic driver now properly exposes speed_capa bitmap so this workaround is not needed anymore. Type: refactor Change-Id: Ic754de0b9de32d488405ffcd8d62dd6aa035d2bc Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-06tap: add num_tx_queues APINathan Skrzypczak1-0/+1
This adds a create_tap_v3 api that has a num_tx_queues parameter allowing to create more than num_workers queues, following on multi TX support Type: feature Change-Id: Idce433147e8dd165f842241d6c76e041e1b1c9b8 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2022-01-05dpdk: remove unused definesDamjan Marion1-7/+0
Type: refactor Change-Id: I41d5d07eef670e89eba8fd816e123981940b5d79 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05dpdk: no need to copy default tx confDamjan Marion3-6/+2
Type: improvement Change-Id: Ifd5201c101da7f4fb63f9b64280a6ec35b2af6a0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05dpdk: improve checksum computationFlorin Coras2-3/+26
Type: improvement Based on gerrit 26480 by chenmin.sun@intel.com Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id8f2127f0fac5f555b38483714fe92c038875915
2022-01-05interface: refactor interface capabilities codeDamjan Marion8-34/+26
Make it shorter to type, easier to debug, make adding callbacks in future simpler. Type: improvement Change-Id: I6cdd6375e36da23bd452a7c7273ff42789e94433 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05dpdk: move port config to single structDamjan Marion6-220/+206
Type: refactor Change-Id: I0bce385c7e391fa2b74646d001980610f80f7062 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05dpdk: remove unused flagDamjan Marion6-132/+91
Type: refactor Change-Id: Iff96a79323d7d428a779e9736e07c1dc9dddb518 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05srv6-mobile: Update GTP4/6.D functionTetsuya Murakami9-1194/+1539
GTP4/6.D behavior is updated as shown below. 1. When receiving GTP-U message or IPv6 linklocal destination in inner IP, GTP packet is tnralated to SRv6. 2. When receiving T-PDU packet, OuterIP/UDP/GTP headers are stripped off and Inner IP is encapsulated into SRv6 based on L3VPN SRv6 manner. Type: feature Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com> Change-Id: I6092c98ea80236d54017f84c5b35cca0b645f034 Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com>
2022-01-05dpdk: keep buffer flags per-deviceDamjan Marion4-15/+7
Type: improvement Change-Id: Idb0b079df49c12643c9a93ee0effe011d3489068 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05dpdk: remove unused logging classDamjan Marion2-2/+0
Type: refactor Change-Id: I2de762953faa5056d5fefa678e4faafbe7710dc6 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05dpdk: remove vlan-strip offload codeFilip Varga2-58/+0
This code was actually never working. It was just used as workaround for Cisco ENIC issue with tagged default vlan frames. Today Cisco ENIC provides solution to this problem with devargs flags... Change-Id: Ia8284274117cb200bf6c7f7911d945d5a093d878 Type: refactor Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05crypto: encrypt/decrypt queues sw_schedulerJakub Wysocki4-236/+292
Type: improvement Previously multiple sw crypto scheduler queues per core design caused unaverage frame processing rate for each async op ID – the lower the op ID is the highly likely they are processed first. For example, when a RX core is feeding both encryption and decryption jobs of the same crypto algorithm to the queues at a high rate, in the mean time the crypto cores have no enough cycles to process all: the jobs in the decryption queue are less likely being processed, causing packet drop. To improve the situation this patch makes every core only owning a two queues, one for encrypt operations and one for decrypt. The queue is changed either after checking each core or after founding a frame to process. All crypto jobs with different algorithm are pushed to thoses queues and are treated evenly. In addition, the crypto async infra now uses unified dequeue handler, one per engine. Only the active engine will be registered its dequeue handler in crypto main. Signed-off-by: DariuszX Kazimierski <dariuszx.kazimierski@intel.com> Signed-off-by: PiotrX Kleski <piotrx.kleski@intel.com> Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com> Signed-off-by: Jakub Wysocki <jakubx.wysocki@intel.com> Change-Id: I517ee8e31633980de5e0dd4b05e1d5db5dea760e
2022-01-05dpdk: remove "convenience" varsDamjan Marion8-39/+29
It is actually longer and slower... Type: refactor Change-Id: I0f126d4cdb13ecc60a2d370409f23820d7f7eb72 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-05wireguard: fix 'wireguard add peer' cli behaviorMiroslav Miklus1-6/+6
- change 'port' to 'dst-port' to make the input self-explanatory - add empty spaces to short help Type: fix Signed-off-by: Miroslav Miklus <miroslav.miklus@pantheon.tech> Change-Id: I74c783e6e8629e61b1c100e9355d09cf5e35a750
2022-01-04nsim: cli improvementsFlorin Coras2-14/+56
- improve format and unformat of bandwidth and delay - integer packet size - track worker wheel size as config Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I616fa96237c5e06d9c809bb5c2e0bed0447f2c4d
2022-01-04nat: remove nat44-ed relation between SM and addrFilip Varga6-555/+436
Change [1] put static mappings in flow hash. This change also broke relationship between nat pool addresses and static mappings. Port and address are no longer reserved in nat pool address records for a new static mapping. Because of this change both nat objects and their configuration can function independently. This change also removed already broken logic of having static-mapping-only configuration. In this patch i have cleaned up and removed unnecessary logic for static mapping configuration functions, address configuration functions, interface configuraiton functions and all callback functions used for resolving interface address bound records. No more viable configuration option static-mapping-only is also removed because there is no more option to run traffic through vpp for static mappings without having flow hash table allocated. Instead user is now able to create static mapping records without using nat pool addresses. Fixed and improved management of required fib entries (ensuring VPP will reply to ARP for all external addresses on outside interfaces) through holding a refcount for their creation and removal. [1] https://gerrit.fd.io/r/c/vpp/+/34077 Type: improvement Change-Id: Ic16deefbede833d574c2a5972155c9afa5bc62ce Signed-off-by: Filip Varga <fivarga@cisco.com>
2022-01-04nat: nat44-ed pool address allocation improvementFilip Varga4-58/+289
This patch improves algorithm responsible for choosing nat pool address during dynamic session creation. Patch synchronizes nat pool address attributes with vpp interfaces doing so gives nat option to determine correct nat pool address when creating dynamic session. Improvements: * match dst address subnet and src fib with nat pool address * for output-feature also fallback match of tx_sw_if_index with nat pool address Type: improvement Change-Id: I594638bc76fc1153f582add376838b4b72ff573a Signed-off-by: Filip Varga <fivarga@cisco.com>
2022-01-03vrrp: fix support for VRs in different FIBsMatthew Smith1-15/+13
Type: fix Fixes: 4b1b13315a3c When adding or deleting a VR, multicast routes can be added or deleted. When the first VR is added, a local (dpo-receive) route is added. The route is deleted when the last VR is deleted. Perform the check on whether to add or delete the route on a per-FIB basis. Otherwise, if the route is only added after the first VR is added without regards to the FIB being used and a second VR is added later on an interface attached to a different FIB, the necessary route will not be added to the FIB used by the second interface. Change-Id: Ib30925ecf45c714cfe3ac6a223754bea918f10e3 Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-12-31misc: Remove the unused GBP fields from the buffer meta-dataNeale Ranns1-2/+0
Type: refactor Signed-off-by: Neale Ranns <neale@graphiant.com> Change-Id: I92496501360ee073795206bde87f4731a5ce074c
2021-12-31vlib: remove external thread management supportDamjan Marion6-179/+13
Now DPDK have API to register external threads so we can remove this mess... Type: improvement Change-Id: I71a21f0cd94bd668aa406710c75a0bcc63fdc840 Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-12-30svm: merge want deq and leq threshold notificationsFlorin Coras1-8/+5
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I2775af35386a4e52ba82991c68bce6c56f13410f
2021-12-29http_static: Fix timeout on large filesMichal Kalderon1-3/+19
When trying to read files that are larger than the fifo a timeout was reached on client side leading to an abort of the request and a retry (sending another GET command). The svm fifo notification request was set to notify when the fifo is no longer full, this lead to an inefficient loop of sending small amounts of data each time with a large overhead of context switch and waiting for the next notification, eventually leading to a timeout. Modifying the trigger on the svm-fifo to be notified on a preset threshold value enabled sending larger amounts of data between context switches and sending large files more efficiently. This solved the timeout issue. In addition, cap the max write from application to 4MB to avoid running into a case of trying to allocate chunks that are too large. Reproduce: Server: http static server www-root /var/www/data uri tcp://0.0.0.0/80 cache-size 5m fifo-size 300 Client: wget http://11.0.0.2/file_of_size_32M Type: fix Change-Id: Idfceedffd935da9486cde820e9dca5dad69d9ca5 Signed-off-by: Yuval Caduri <cyuval@marvell.com> Signed-off-by: Michal Kalderon <mkalderon@marvell.com>
2021-12-22memif: refactor descriptor handling in the input nodeDamjan Marion3-184/+446
Type: improvement Change-Id: I06130447b4e6f4726c4f5bffbe606385c45b8bd4 Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-12-21hsi: host stack intercept pluginFlorin Coras5-0/+453
Enable selective punting of flows to host stack Type: feature Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ib31a3abfe3b21a2aa448bfacc4591fa5c840f935
2021-12-20vrrp:fix vrrp vr delete case memory leakjinsh1-0/+1
when vrrp vr delete, vr->config.peer_addrs not free Type: fix Signed-off-by: jinsh <jinsh11@chinatelecom.cn> Change-Id: I9ead188d6409412b475b5f6add767cb58f1af6e0
2021-12-16af_xdp: mark API as stableBenoît Ganne1-6/+1
Type: improvement Change-Id: I55b080f994eafc4ecfe0e774d7cd05218d715526 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-12-14crypto-native: fix build error on Arm using clang-13Jieqiang Wang1-2/+2
Building VPP on Arm using clang-13 as compiler will fail with following error message. The root cause is the unmatched alignment of parameter key for functions aes128_key_expand/aes256_key_expand on aarch64. Fix this error by explicitly declaring parameter key as type u8x16u. [285/2593] ccache /home/snowball/tasks/benchmark_compilers/clang_13/bin/clang-13 --target=aarch64-linux-gnu -D_FORTIFY_SOURCE=2 -I/home/snowball/tasks/benchmark_compilers/vpp-clang-13/src -ICMakeFiles -I/home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins -ICMakeFiles/plugins -fPIC -g -fPIC -Werror -Wall -Wno-address-of-packed-member -O3 -fstack-protector -fno-common -march=armv8.1-a+crc+crypto -MD -MT CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o -MF CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o.d -o CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o -c /home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins/crypto_native/aes_cbc.c FAILED: CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o ccache /home/snowball/tasks/benchmark_compilers/clang_13/bin/clang-13 --target=aarch64-linux-gnu -D_FORTIFY_SOURCE=2 -I/home/snowball/tasks/benchmark_compilers/vpp-clang-13/src -ICMakeFiles -I/home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins -ICMakeFiles/plugins -fPIC -g -fPIC -Werror -Wall -Wno-address-of-packed-member -O3 -fstack-protector -fno-common -march=armv8.1-a+crc+crypto -MD -MT CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o -MF CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o.d -o CMakeFiles/plugins/crypto_native/CMakeFiles/crypto_native_armv8.dir/aes_cbc.c.o -c /home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins/crypto_native/aes_cbc.c In file included from /home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins/crypto_native/aes_cbc.c:22: /home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins/crypto_native/aes.h:415:40: error: passing 1-byte aligned argument to 16-byte aligned parameter 2 of 'aes128_key_expand' may result in an unaligned pointer access [-Werror,-Walign-mismatch] aes128_key_expand (key_schedule, (u8x16u const *) key); ^ /home/snowball/tasks/benchmark_compilers/vpp-clang-13/src/plugins/crypto_native/aes.h:421:40: error: passing 1-byte aligned argument to 16-byte aligned parameter 2 of 'aes256_key_expand' may result in an unaligned pointer access [-Werror,-Walign-mismatch] aes256_key_expand (key_schedule, (u8x16u const *) key); ^ 2 errors generated. Type: fix Fixes: 415b4b0bb ("crypto-native: refactor GCM code to use generic types") Signed-off-by: Jieqiang Wang <jieqiang.wang@arm.com> Reviewed-by: Lijian Zhang <lijian.zhang@arm.com> Reviewed-by: Tianyu Li <tianyu.li@arm.com> Change-Id: Ic99a63526031e60760929238922a6e4547388368
2021-12-14api: verify message size on receiptKlement Sekera2-2/+11
When a message is received, verify that it's sufficiently large to accomodate any VLAs within message. To do that, we need a way to calculate message size including any VLAs. This patch adds such funcionality to vppapigen and necessary C code to use those to validate message size on receipt. Drop messages which are malformed. Type: improvement Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: I2903aa21dee84be6822b064795ba314de46c18f4
2021-12-09dpdk: disable l4 csum offload for vmxnet3Florin Coras1-1/+4
TCP csum offload fails although udp seems to work. Type: fix Fixes: fa1fb60 Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ie0651887b09920365806eaad776b0d13059faee8
2021-12-08memif: fix the memory leak when memif cli getting wrong parameters inputsHan Wu1-4/+12
Type: fix Signed-off-by: Han Wu <wuhan9084@163.com> Change-Id: I0aeafd273b3d1d01df02d638c72461943f91ef90
2021-12-03interface: add multi tx-queues support for new tx infraMohsin Kazmi1-2/+2
Type: feature Change-Id: I231f782b3c56dc2b10321e4569ac7acdad1c11da Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2021-12-03api: refactor to use REPLY_MSG_ID_BASE #defineKlement Sekera10-50/+41
REPLY_MSG_ID_BASE is the standard way to define reply message id base, so this refactor makes all the files use that. This is a preparation patch for future safety add-ons which rely on REPLY_MACRO* parameters to be preprocessor tokens identifying the message instead, Type: refactor Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: Ibe3e056a3d9326d08af45bbcb25588b11e870141
2021-12-03fib: Fix the display (or lack of) for fib node types in dependent children listsNeale Ranns9-9/+11
Type: fix When registering a new FIB node type, no name was required on the API, and so no name was printed. Signed-off-by: Neale Ranns <neale@graphiant.com> Change-Id: I8a99cf29c194637a550061b0a5e9782ffe8b31dd
2021-12-02tests: add segment manager testsFilip Tehlar1-29/+25
Type: test Change-Id: Ic9fddc9fedd5140984c5901c4cac53dec022dcec Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2021-12-02perfmon: compile dispatch wrapper once for each number of countersDamjan Marion3-35/+27
A bit ugly, but generates faster and less noisy code which should be important for this particular use case. Type: improvement Change-Id: If2bba947dac33ffedb4236a5b3fb50fc783668e1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-12-02perfmon: refactor perf metric supportRay Kinsella4-189/+80
Refactoring perf metric support to remove branching on bundle type in the dispatch wrapper. This change includes caching the rdpmc index at perfmon_start(), so that the mmap_page.index doesn't need to be looked up each time. It also exclude the effects of mmap_page.index. This patch prepares the path for bundles that support general, fixed and metrics counters simulataneously. Type: refactor Signed-off-by: Ray Kinsella <mdr@ashroe.eu> Change-Id: I9c5b4917bd02fea960e546e8558452c4362eabc4
2021-11-30dpdk: cryptodev AES-CTR+SHA1 support addedPiotrX Kleski1-1/+4
Type: improvement This patch adds AES-CTR-128/192/256 + SHA1 linked algo support to dpdk cryptodev. Signed-off-by: PiotrX Kleski <piotrx.kleski@intel.com> Change-Id: Idc162b29f4075ef8be9577abd3daf6de05f84faa
2021-11-30dpdk-cryptodev: scalable session countDastin Wilski2-96/+143
Originally cryptodev allocates mempools for seesion and session private data during its initialization. Moreover the size of these mempools are fixed resulting in limited session count (up to value specified in CRYPTODEV_NB_SESSION macro). This patch allows for session count to scale up by allocating new mempools as they are needed during session creation. Type: improvement Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com> Change-Id: I6ae240b474d3089d3ff50ca5bc7ff48f149983db
2021-11-26api: add helper macros for native endianMohsin Kazmi4-30/+6
Type: improvement Change-Id: Ifa074dfd337f9cd68858468d34abf641fe7f247f Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2021-11-25dpdk: prefetch becomes prefetchwRay Kinsella1-4/+4
Changed dpdk-input prefetch of vlib_buffer_t to prefetchw. vlib_buffer_t was being prefetched without 'ownership', which may cause a stall when the buffer is subsequently written to. This saves 4 clocks a packet when the buffer is shared a cross cores, and has no impact when not sharing. Type: improvement Signed-off-by: Ray Kinsella <mdr@ashroe.eu> Change-Id: I317af2a38ef536022e68552351a8507861f62dad
2021-11-23misc: deprecate gbp and its dependentsNeale Ranns49-13942/+0
Type: improvement Signed-off-by: Neale Ranns <nranns@cisco.com> Signed-off-by: Benoît Ganne <bganne@cisco.com> Change-Id: I2f30a4f04fd9a8635ce2d259b5fd5b0c85cee8c3
2021-11-23vxlan: multiarch optimization of vxlanRay Kinsella2-4/+0
Fixing the mutliarch versions of vxlan, geneve and friends. Ensures that main struct is correctly sized for all multiarch permutations. Type: fix Fixes: 290526e3c Signed-off-by: Ray Kinsella <mdr@ashroe.eu> Change-Id: I7c4c435763a5dcb0c3b429cd4f361d373d480c03
2021-11-23dpdk: enable vmxnet3 l4 checksum offloadFlorin Coras1-0/+6
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ia25e671084dd2c0010c0577649bf51ba6495b6ac
2021-11-23ip: unlock_fib on if deleteNathan Skrzypczak1-26/+17
On interface delete we were not removing the lock taken by a previous ip_table_bind() call thus preventing the VRFs to be removed. Type: fix Change-Id: I11abbb51a09b45cd3390b23d5d601d029c5ea485 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-11-22wireguard: add local variable in handshake processGabriel Oginski1-2/+4
Originally handshake process gets pointer to value of index peer. In the meantime this pointer can be invalid due to resize hash table for wireguard and passed poison value to another function. The fixes add local variable to keep index of peer instead of value from pointer. Type: fix Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com> Change-Id: I1b2535c44b4f987d19077c75c778aaa5ed71a457
2021-11-22gso: implement gso segementation copy with checksumMohsin Kazmi1-3/+1
Type: improvement Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: Iec9dacde170533ca16e8117787e62da8af69ae96
2021-11-22dpdk: fix coverity warningKlement Sekera1-0/+2
Add a hint so that it's obvious that fall through in switch statement is intentional. Type: fix Fixes: 34c54dff5c Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: I12271227424761fb89b03a390f626c2ab466472c
2021-11-22snort: fix coverity warningKlement Sekera1-2/+11
Add error handling for incomplete read. Type: fix Fixes: 839b1473e9 Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: Ibf1b2f633793510244ea1aa6af0902021aeb67ad
2021-11-22snort: fix coverity warningKlement Sekera1-2/+2
Add a cast to avoid coverity warning about potential integer underflow. Type: fix Fixes: 839b1473e9 Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: Iae913e51c1e25aaeca6ce70438451c640d347383