aboutsummaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2022-01-18dpdk: limit number of TX queues to max supportedDamjan Marion1-3/+17
Also improve logging.... Type: fix Change-Id: I3d3aee52cd45e59ecd6ce13bd516c66559638fec Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-18vlib: allow bigger scalar data sizeDamjan Marion1-1/+2
Type: improvement Change-Id: I1031c6ce80d90814edda7b52b11039874b95714f Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-18misc: fix coverity warningsDave Barach2-1/+7
Type: fix Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I8ea0193ebb2a721a0582451ffd64c4063ac6d233
2022-01-18linux-cp: fix possible null derefPim van Pelt1-0/+2
Found by coverity as defect id 243763 Signed-off-by: Pim van Pelt <pim@ipng.nl> Type: fix Change-Id: Idbada5528a1f2625f6498072d538edf306268b6d
2022-01-18virtio: remove admin-up flag during interface creationMohsin Kazmi2-4/+0
Type: fix During the interface creation time, (by default) admin-up flag is locally set for tap and virtio interfaces. While, in VPP the state of these interfaces are still admin-down. User needs to explicitly call 'set interface state <interface-name> up' to admin-up the newly created tap or virtio interface(s) in VPP. So, this behavior is inconsistent. This patch fixes the issue to have consistent behavior for given interface between local and global administration state. Change-Id: Ifd8904a09fbdbe7b386874ac3231dc0527064518 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2022-01-18srv6-mobile: Fix the coverity issueTetsuya Murakami1-2/+2
Type: fix Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com> Change-Id: I35c36401ce3ab59900be59a9abddba66f6399978
2022-01-18vnet: distinguish between max_frame_size and MTUDamjan Marion17-106/+148
Type: improvement Change-Id: I3659de6599f402c92e3855e3bf0e5e3388f2bea0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-17ipsec: IPSec interface correct drop w/ no protectionNeale Ranns3-8/+19
Type: improvement When an IPSec interface is first constructed, the end node of the feature arc is not changed, which means it is interface-output. This means that traffic directed into adjacencies on the link, that do not have protection (w/ an SA), drop like this: ... 00:00:01:111710: ip4-midchain tx_sw_if_index 4 dpo-idx 24 : ipv4 via 0.0.0.0 ipsec0: mtu:9000 next:6 flags:[] stacked-on: [@1]: dpo-drop ip4 flow hash: 0x00000000 00000000: 4500005c000100003f01cb8cac100202010101010800ecf40000000058585858 00000020: 58585858585858585858585858585858585858585858585858585858 00:00:01:111829: local0-output ipsec0 00000000: 4500005c000100003f01cb8cac100202010101010800ecf40000000058585858 00000020: 5858585858585858585858585858585858585858585858585858585858585858 00000040: 58585858585858585858585858585858585858585858585858585858c2cf08c0 00000060: 2a2c103cd0126bd8b03c4ec20ce2bd02dd77b3e3a4f49664 00:00:01:112017: error-drop rx:pg1 00:00:01:112034: drop local0-output: interface is down although that's a drop, no packets should go to local0, and we want all IPvX packets to go through ipX-drop. This change sets the interface's end-arc node to the appropriate drop node when the interface is created, and when the last protection is removed. The resulting drop is: ... 00:00:01:111504: ip4-midchain tx_sw_if_index 4 dpo-idx 24 : ipv4 via 0.0.0.0 ipsec0: mtu:9000 next:0 flags:[] stacked-on: [@1]: dpo-drop ip4 flow hash: 0x00000000 00000000: 4500005c000100003f01cb8cac100202010101010800ecf40000000058585858 00000020: 58585858585858585858585858585858585858585858585858585858 00:00:01:111533: ip4-drop ICMP: 172.16.2.2 -> 1.1.1.1 tos 0x00, ttl 63, length 92, checksum 0xcb8c dscp CS0 ecn NON_ECN fragment id 0x0001 ICMP echo_request checksum 0xecf4 id 0 00:00:01:111620: error-drop rx:pg1 00:00:01:111640: drop null-node: blackholed packets Signed-off-by: Neale Ranns <neale@graphiant.com> Change-Id: I7e7de23c541d9f1210a05e6984a688f1f821a155
2022-01-17interface: improve MTU handlingDamjan Marion8-47/+98
- per hw-interface-class handlers - ethernet set_mtu callback - driver can now refuse MTU change Type: improvement Change-Id: I3d37c9129930ebec7bb70caf4263025413873048 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-17vnet: introduce vnet_error()Damjan Marion9-175/+259
Decouples vnet return values from API return codes. New vnet_error() creates vnet_error_t whicgh contains both vnet function return value and return string. vnet_api_error() converts vlib_error_t constructed with vnet_error() to API return value. Type: improvement Change-Id: I17042954d48c010150fc1dfc5fce9330e8149e87 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-16vppinfra: bitops cleanupDamjan Marion10-145/+56
Type: refactor Change-Id: I7fa113e924640f9d798c1eb6ae64b9c0a9e2104c Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-15mactime: fix memory leakDave Barach1-1/+2
Type: fix Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I1ef5cb250ac1e35b9a5003597eda3d54d2e5ca73
2022-01-14dpdk: refactor device setupDamjan Marion7-540/+328
Type: improvement Change-Id: I9772088bca176fd0fdb162677ec55c59aa8f3adf Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-14dpdk: fix burst function outputDamjan Marion1-3/+3
Type: fix Fixes: 65105c95f Change-Id: I8dee4b560a49891f954d7eb8e79ea535cedeaa88 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12hsa: echo clients connect improvementsFlorin Coras2-19/+34
Do burst of connects with barrier held. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I7e6dcf097022b56d6880de0cba7b8492a938077b
2022-01-12hsa: cleanup echo client appFlorin Coras2-228/+268
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Iada49493635a9c3db8b725ca367d0d4ca5007357
2022-01-12hsa: allow large segments for echo appsFlorin Coras2-36/+13
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I4e60d83644878f7d267582c2497d785e0f6facc1
2022-01-12dpdk: bump to DPDK v21.11Damjan Marion5-17/+31
Type: feature This patch bumps dpdk version from 21.08 to 21.11 Change-Id: Id37fdba75f1ea4f4eac3c92226f3b1c539e1daca Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com> Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12dpdk: improve loggingDamjan Marion3-10/+49
Type: improvement Change-Id: If61d7409ff14b9f771c1dc8ec9f35e179cea7a28 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12dpdk: update packet offload flagsDamjan Marion2-41/+89
Type: improvement Change-Id: Ib2c55dd2a246a690b2089f5c0b88508f732281f2 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12session: pass tx buffers in bulk to transportsFlorin Coras6-22/+83
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I1025cccd784f80b557847f69c3ea1ada5c9de60d
2022-01-12perfmon: skipping bundle messageRay Kinsella1-1/+1
Change the skipping bundle message to debug Type: refactor Signed-off-by: Ray Kinsella <mdr@ashroe.eu> Change-Id: I942ff72bd9c26ccad923442fdedddf22ba75e117
2022-01-12dpdk: postpone updating runtime dataDamjan Marion1-1/+3
This prevents crash due to worker tread accessing device data while device vector is growing. Type: fix Change-Id: I5cf9f53ddbe97fe52db8fd431ea7c0e480f3d4bc Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12dpdk: use blunt force to skip irrelevant and confusing logsDamjan Marion1-1/+13
Type: improvement Change-Id: I2cd37f0c1a1ed33438bfa4b7590e5609e5094fc8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12dpdk: always display burst function nameDamjan Marion1-12/+10
Also change the way how we dig function pointer so it works with dpdk 21.11+ Type: improvement Change-Id: I38d5909eea9c2893651710bd45057b1635aa7b37 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-12ip: coverity illegal access in ip6_ext_header_walkOle Troan1-9/+2
*** CID 243670: Memory - illegal accesses (OVERRUN) /src/vnet/ip/ip6_packet.h: 713 in ip6_ext_header_walk() CID 243670: Memory - illegal accesses (OVERRUN) Overrunning array "res->eh" of 4 4-byte elements at element index 5 (byte offset 23) using index "i" (which evaluates to 5). Type: fix Fixes: 03092c1 Change-Id: I27e0435cf10534f3b41e11bf7a5629b5428b0651 Signed-off-by: Ole Troan <ot@cisco.com>
2022-01-12dpdk-cryptodev: run dequeue again in case of interrupt mode being usedDastin Wilski1-0/+6
Type: fix Change-Id: I7aa172e58c970c4971db6ef2ff5b199b7f3c0b99 Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com>
2022-01-12crypto: omit loop iterationDastin Wilski1-4/+6
This fix adds check that will omit loop iteration in case dequeue handler is zero. Type: fix Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com> Change-Id: I7526e3fe7d8c8da9662b4e9204efd5e2d8be1908
2022-01-11hsa: allow use of default port for vcl test appsFlorin Coras2-23/+28
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I30ec7af3baf56d74a5050ea9335053e6e12de630
2022-01-11linux-cp: Add VPP->Linux synchronizationPim van Pelt9-167/+743
Part 1 -- notes in https://ipng.ch/s/articles/2021/08/13/vpp-2.html Add the ability for VPP to copy out (sync) its state from the dataplane to Linux Interface Pairs, when they exist. Gated by a configuration flag (linux-cp { lcp-sync }), and by a CLI option to toggle on/off, synchronize the following events: - Interface state changes - Interface MTU changes - Interface IPv4/IPv6 address add/deletion In VPP, subints can have any link state and MTU, orthogonal to their phy. In Linux, setting admin-down on a phy forces its children to be down as well. Also, in Linux, MTU of children must not exceed that of the phy. Add a state synchronizer which walks over phy+subints to ensure Linux and VPP end up in the same consistent state. Part 2 -- notes in https://ipng.ch/s/articles/2021/08/15/vpp-3.html Add the ability for VPP to autocreate sub-interfaces of existing Linux Interface pairs. Gated by a configuration flag (linux-cp { lcp-auto-subint }), and by a CLI option to toggle on/off, synchronize the following event: - Sub-interface creation (dot1q, dot1ad, QinQ and QinAD) A few other changes: - Add two functions into netlink.[ch] to delete ip4 and ip6 addresses. - Remove a spurious logline (printing MTU) in netlink.c. - Resolve a TODO around vnet_sw_interface_supports_addressing() Type: improvement Signed-off-by: Pim van Pelt <pim@ipng.nl> Change-Id: I34fc070e80af4013be58d7a8cbf64296cc760e4e Signed-off-by: Pim van Pelt <pim@ipng.nl>
2022-01-11tls: ssl close only after all data drainedFlorin Coras1-2/+2
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ia77b26db61b6f58b4ff659f09192b4ea93ed50b4
2022-01-11vlib: fix the total len not including first buffer formatingMohsin Kazmi1-1/+1
Type: fix total len not including first buffer is in vlib_buffer_t second cacheline. It is not reset after the buffer has been consumed. It leads to printing garbage in packet trace for subsequent use of this buffer. This patch fixes the issue to only print when VLIB_BUFFER_NEXT_PRESENT flag is set. Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: Ied72308bdb907a5e1ca16d181f2add062807e968
2022-01-11dpdk: offloads cleanupDamjan Marion4-199/+122
Type: improvement Change-Id: Ibf43aa483548e6055e4b851ad893371d7af3b018 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-11misc: fix the uninitialization errorMohsin Kazmi2-2/+2
Type: fix | src/vppinfra/vector/toeplitz.c:69:9: error: ‘kv’ may be used uninitialized in this function [-Werror=maybe-uninitialized] | src/vppinfra/memcpy_x86_64.h:45:17: error: ‘*((void *)&key+16)’ may be used uninitialized in this function [-Werror=maybe-uninitialized] | *(u8x16u *) d = *(u8x16u *) s; | ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~ | src/vnet/gre/interface.c:356:20: note: ‘*((void *)&key+16)’ was declared here Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: I71614da2821ebda5200a0cb9437a7aad0c42fbb2
2022-01-11session: increase postponed mq message min sizeFlorin Coras2-1/+2
Reported by coverity Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ib1db0d120321b061f4c2c20117acdfb6e7dc0626
2022-01-10session: fix segment manager format coverity warningFlorin Coras1-3/+3
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ia32536a76aa3f92f80ee2cd027a9a010c19b861a
2022-01-10interface: refactor interface capabilities code, part 2Damjan Marion5-63/+65
Type: improvement Signed-off-by: Damjan Marion <damarion@cisco.com> Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: Ie595e69af8657b0ee18a84ac71c5d433108d9ef8
2022-01-10vrrp: vrrp in unicast mode,interface not add virtual ip addresssjinsh1-3/+0
Type: fix Signed-off-by: jinsh <jinsh11@chinatelecom.cn> Change-Id: Id80601bc753c59c4ea95ff5f74f9b15c40c01e35
2022-01-10session: allow pacer to send when bucket hits 0Florin Coras1-2/+2
So after bucket reset session can send max burst of bytes. Also, reset pacer bucket to 0 not min burst Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Iced8948c407e6647e6eb4caff5c62c06d45ce0bf
2022-01-10session: deschedule sessions with no data to sendFlorin Coras3-3/+26
This ensures the scheduler always tracks sessions that are descheduled, i.e., do not have events in the old io events list. When app retries to send, clear descheduled flag and potentially the pacer. Consequently, transports no longer need to reset the pacer when sessions are rescheduled after a long app tx pause. This also fixes a tcp bug whereby the pacer was reset too often when snd_una was equal to snd_nxt as there was no way to distinguish betwen app tx breaks and congestion. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id3cc6c98cd76299e15030e504380dcf3c04c5189
2022-01-10session: fix pacer bucket update castFlorin Coras1-2/+2
Make sure comparison is done between two i64 values. Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ief5706f2bd9415587994a5b665d5e380b8e14f68
2022-01-09dpdk: interface capabilities cleanupDamjan Marion4-24/+54
Type: improvement Change-Id: If5636d4376fb06da62f947c28b18c07b6ad21722 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-09dpdk: port type code cleanupDamjan Marion3-93/+34
Type: improvement Change-Id: I4ead18dee249a27b4dbb8bbf53b6238d91042890 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-09vppinfra: Check for NULL vec before the backwards iterationNeale Ranns1-4/+6
Type: improvement 'vec_end(v) - 1' does not yield a good starting point. Check for NULL vec before the loop, so the user does not have to. Signed-off-by: Neale Ranns <neale@graphiant.com> Change-Id: Ia174ec8095bc476853cce709a7048d7a3e3b377d
2022-01-09fib: multiple memory leaks upon deleting a VRF tableSteven Luong4-15/+25
fib_table->ft_locks name string for parsing the ip table add|del name <tag> command path list for ip4_specials in mfib mfib->fib_entry_by_dst_address[0..32] mfib entry path_ext, msrc->mfes_exts Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: Ia1e0cac577a73608ee1e4b1664b60a66322e81ce
2022-01-09dpdk: new mbuf flags in format functionDamjan Marion1-26/+26
Type: improvement Change-Id: I9022e29ebc0edb7946d374d6c3c45ee6962d725f Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-08dpdk: new flags formatDamjan Marion4-30/+64
introduced in DPDK 21.11 Type: improvement Change-Id: I8c845949dd904a2bf8fa4a91e2f3ae5d704f2283 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-01-07tcp: fix cubic cwnd accumulate use of bytes ackedFlorin Coras1-1/+1
Use what was provided instead of tc->bytes_acked Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I0ed736d2ee247e231fccdf4a969fcf6bc15b7978
2022-01-07bonding: memory leak on parsing bad CLI commandSteven Luong1-4/+10
When parsing bad "create bond" command, we should call unformat_free prior to return Type: fix Fixes: 9cd2d7a5a4fafadb65d772c48109d55d1e19d425 Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: I8f20a0e7f29de670e09633880d0aa50a51444e11
2022-01-07vmxnet3: memory leak on parsing bad CLI commandSteven Luong1-3/+5
When parsing bad "create interface vmxnet3" command, we should call unformat_free prior to return Type: fix Fixes: df7f8e8cffcc43531f7daeda44d436b60e538141 Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: I2663894c6cb8066ca2abb1c56f0ca46d0fef19f7