aboutsummaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2019-08-22tests: move plugin tests to src/plugins/*/testDave Wallace33-0/+30164
- Relocate plugin tests for 'make test' into src/plugins/*/test so that plugin test cases are co-located with the plugin source code. Type: refactor Signed-off-by: Dave Wallace <dwallacelf@gmail.com> Change-Id: I503e6a43528e14981799b735fa65674155713f67 Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2019-08-22dns: make the dns name resolver a pluginDave Barach16-393/+767
Type: refactor Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I823c2cd307a4613653a2d20f564dda062d4da31b
2019-08-22avf: properly set irq queue masksDamjan Marion1-1/+2
Type: fix Fixes: ae91180 Change-Id: I9c55c3fdf41089d337b998e2e28abb23d81525ef Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-08-22nat: handoff traffic matching for dynamic NATFilip Varga9-222/+493
Type: feature Change-Id: I5c5af6f9acb340cc674323305104b8ce23e6d21d Signed-off-by: Filip Varga <fivarga@cisco.com>
2019-08-22ip: fix merge issueKlement Sekera1-2/+0
Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: Idd64b0b3eedb7179f6d316b66cea8160ad577990 Type: fix Fixes: 630ab5846bceddf8d663e9f488a2dc0378949827 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2019-08-22vlib: fix null pointer crash on strncmpSteven Luong1-2/+2
Program received signal SIGSEGV, Segmentation fault. 0x00007ffff4b71de0 in __strncmp_sse42 () from /lib64/libc.so.6 (gdb) up up vm=0x7ffff6664d40 <vlib_global_main>, addr=0x7fffb4bec6d0, ids=0x7fffb31675f0 <avf_pci_device_ids>, handle=0x7fffb4bec594) at /usr/src/debug/vpp-20.01/src/vlib/linux/pci.c:1250 1250 if (strncmp ("vfio-pci", (char *) di->driver_name, 8) == 0) (gdb) p di p di $1 = (vlib_pci_device_info_t *) 0x7fffb6446164 (gdb) p di->driver_name p di->driver_name $2 = (u8 *) 0x0 (gdb) driver_name may be null. strncmp is not forgiving. Change to use C11 safeC version. Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: I1777a5966ceee7409d7bde86c30b14dc75534a5a
2019-08-22hsa: fix http responseBenoît Ganne1-1/+1
http_ok is a const null-terminated string, not a vector. Type: fix Fixes: 844a36d1a6 Change-Id: Ide1a23506d9f43cd33c3a4b8ba11658c67fbecc8 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-08-22sr: fix sr_set_encap_source replyVratko Polak1-1/+1
Can we get a reply macro that would avoid such copypaste errors? Type: fix Change-Id: I753efb1d82fced668c27f2e44b0318bfd31c0a23 Signed-off-by: Vratko Polak <vrpolak@cisco.com>
2019-08-21vcl: fix ldp_set_app_name overflowBenoît Ganne1-5/+2
In case of overflow, we null-terminate the parameter ('app_name') instead of ldp global name ('ldp->app_name'). Moreover, snprintf() always safely null-terminate the destination string even in case of overflow. Type: fix Fixes: 048b1d6ab7 Change-Id: I4d8b0e020a228e982b6699d652b341c5afe92993 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-08-21tcp: add option for always on event loggingFlorin Coras8-185/+371
Type: feature Add option to always compile in debugging infra. Debug verbosity can be controlled via configuration updatable via cli. Compile time inclusion and configuration of event logging verbosity is still available in order to minimize event logging impact. Change-Id: I9d946efe9fa4204fdace1adb1d6588c97b5ae758 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-08-21avf: print queue id in packet traceDamjan Marion3-4/+6
Type: feature Change-Id: If3deb26b9ee3b9e677c9dc50789bf81fe6c11dee Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-08-21dns: add basic functional "make test" caseDave Barach1-0/+4
Type: test Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I88e93b510d8d4f7b59f3e630539dc7e0264afa47
2019-08-21dpdk: bump DPDK version to 19.08Damjan Marion3-7/+4
Type: feature Change-Id: I16b8cdf0b6af6715a5f01ad84365a8c8a1b76237 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-08-21avf: fix init when num_rx_queues > num_tx_queuesDamjan Marion1-4/+4
Type: fix Fixes: ae91180 Change-Id: Id93b0f4d23ad7022e341e305bbd93ef2fff5787d Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-08-21tcp: default to debug disabledFlorin Coras1-1/+1
Type:fix Change-Id: Ib5c33f0bdb3a8b1c2585135fcc8c07b151e47df3 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-08-21misc: missing ntohl for bond_slave's custom dumpSteven Luong1-2/+2
sw_if_index argument is u32 and it needs to be converted to host order for format in custom dump, a very highly sophisticated stuff. Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: Ie6d49a17e4411df5d567dbb2a7c95993dceda31b
2019-08-20tls: Add C API for TLS openssl to set enginePing Yu9-10/+436
Type: feature Parameters of the engine can be set by C API. After this patch, it is easier to integrate TLS into CSIT test. Change-Id: I063cabf613aabbfad831727551579328705afb41 Signed-off-by: Ping Yu <ping.yu@intel.com>
2019-08-20vppapigen: remove support for legacy typedefsPaul Vinciguerra27-120/+53
vppapigen has remapped legacy to typedefs behind the scenes for some time now. - update .api files to use new style typedefs. - issue error on 'typeonly define' in .api files - remove unneeded macros redefining vl_noop_handler Type: refactor Change-Id: I7a8c4a6dafacee6a131f95cd0e9b03a8c60dea8b Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2019-08-20ip: reassembly: send packet out on correct workerKlement Sekera2-92/+287
Note which worker received fragment with offset zero and use this worker to send out the reassembled packet. Type: fix Change-Id: I1d3cee16788db3b230682525239c0100d51dc380 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2019-08-20vlib: create unix runtime directoryOle Troan2-8/+29
Ensure the runtime directory is created at startup. Default /run/vpp Type: fix Fixes: I53d70939c8125d04a365ac51a6cbf8926dc52adf Change-Id: I6d70364ea756b86768c4dd1f6a9383238ed275c8 Signed-off-by: Ole Troan <ot@cisco.com>
2019-08-20fix pcap_write functionJack Xu6-4/+13
when use pcap cli to capture pcakets into two files rx01.pcap && rx02.pcap, the first time: 1)pcap rx trace on max 100 intfc any file rx01.pcap 2)......the process of capture data to buffer...... 3)pcap rx trace off the second time: 4)pcap rx trace on max 100 intfc any file rx02.pcap 5)......the process of capture data to buffer...... 6)pcap rx trace off the pcap_write function bug in this two lines pm->n_packets_captured = 0; if (pm->n_packets_captured >= pm->n_packets_to_capture) referring to calling pcap_close() will result in that the twice pcap cli both writes the packets into rx01.pcap, but nothing into rx02.pcap. Beside, the rx02.pcap file will not be created. solution: separate the pcap_close() out of pcap_write() Change-Id: Iedeb46f9cf0a4cb12449fd75a4014f95f3bb3fa8 Signed-off-by: Jack Xu <jack.c.xu@ericsson.com>
2019-08-20api: Cleanup APIs interface.apiJakub Grajciar9-250/+333
Use of consistent API types for interface.api Type: fix Change-Id: I88206d7d0907cffd564031f73c9a996df2e5e21a Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2019-08-20tcp: forward conn resets through tcp-outputFlorin Coras1-32/+20
Type: refactor Change-Id: I5718853d89ebeae9d66be975a803a3674bec5986 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-08-20vppapigen: remove python2 supportPaul Vinciguerra1-28/+30
vppapigen has been running under python3 for months. Remove the python2 conditional code. In case of an error, explicitly log and return non-0. Type: refactor Change-Id: I20a73e0f2cb875aab6441959a85a35e88c9f8250 Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2019-08-19dns: handle multiple replies for single requestsDave Barach3-59/+121
The world is a mess. A single DNS request may yield multiple, subtly different responses; all with the same DNS protocol-level ID. Last response wins in terms of what ends up in the cache. First response wins in terms of the response sent to the client. Hard to do otherwise since we have no clue that more than one answer will be forthcoming. Type: fix Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I3175a40eb1fea237048d16b852a430f5ab51eaef
2019-08-19hsa: move udp_echo to vpp_echoNathan Skrzypczak3-1262/+183
Type: refactor Change-Id: I9b8bc4e54bfae9fa3ed367d4a9676fb09c27fb2a Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-08-19hsa: move tcp_echo to vpp_echoNathan Skrzypczak3-1420/+144
Type: refactor Change-Id: Ic23859a1686eff2ae4d08a86b69ff4813498459e Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-08-19quic: fix rx_callback refactoringNathan Skrzypczak1-1/+1
* check_quic_client_connected might allocate ctx and invalidate our pointer Type: fix Change-Id: I885ca5a1a6db9a7765c9047a7df9cdf66c94f1cb Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-08-19vppapigen map: raise ValueError when fieldname is python keywordPaul Vinciguerra3-6/+10
When working on the lb api, one of the field names was chosen as 'as' (application server). Since 'as' is a python keyword, the field was renamed to _1 in vpp_papi. This changeset instead fails early with a descriptive message, hopefully saving others time troubleshooting the issue. ValueError: Fieldname 'as' is a python keyword and is not accessible via the python API. Type: feature Change-Id: Ib048d97de0e392645540092e356cf8989848c947 Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2019-08-19dpdk: fix ipsec coverity warningMatthew Smith1-2/+4
Type: fix Fixes: 5025d40a1134272ab57c3c3f10311e31a65cd63c Update the expression for a conditional block which should be executed when an encrypted packet will be sent via IPv6. Coverity was complaining that a NULL pointer could be dereferenced. It is unclear whether that ever would have actually happened, but the updated expression should quell the warning and should more accurately detect whether the block for IPv6 should be executed. Change-Id: I731cad1f982e8f55bd44e6e05e98eff96f1957bb Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2019-08-19vlib: fix vlib_buffer_main_init_numa_node memory leak.Guanghua Zhang1-3/+8
Type: fix Signed-off-by: Guanghua Zhang <ghzhang@fiberhome.com> Change-Id: I8252ed2555f5af6db2f12dc7c30e41cc1ec7dde0
2019-08-19build: fix vpp compilation failure on ThunderX2 and AmpJianlin Lv1-1/+1
fix compile issue that caused by enabling "-mtune=thunderx2t99" flag during compilation, such as "/opt/vpp-agent/dev/vpp/src/vnet/interface_stats.c:164:1: internal compiler error: Segmentation fault" Type: fix Change-Id: Iaf9f80a6c203a7e5b6a40523f14a62bb37091c92 Signed-off-by: Jianlin Lv <Jianlin.Lv@arm.com>
2019-08-19vppinfra: Update "show cpu" output for AArch64 chipsNitin Saxena1-15/+18
- Allow "Microarch model(family)" row to show PASS revison as either string (like A0, B0) or number (like 1.0, 2.0). - Fix part number for Marvell CN96XX Change-Id: Ie01a3960c4e5e481be354dc8bb60f744e5c65737 Signed-off-by: Nitin Saxena <nsaxena@marvell.com>
2019-08-19ip: leverage existing vlib_buffer_advanceZhiyong Yang1-6/+3
The function ip4_rewrite_inline_with_gso can leverage the existing vlib_buffer_advance to simplify code. Type: fix Change-Id: I25d943dc78aba2f67654385cf3f693eb01e0210e Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
2019-08-19nsh: rewrite nsh_output_inlineZhiyong Yang1-32/+30
Type: style Change-Id: I0c870eddb427efa26cd5b52daf12b13c3927976a Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
2019-08-19rdma: add support for MAC changesBenoît Ganne2-1/+35
Type: feature Change-Id: I5803b52d12e56f2ccc1316e89ece6f1c5898810a Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-08-19dpdk: add TSO support in dpdk plugin.Chenmin Sun3-1/+44
Type: feature You can enable tso in starup.conf like this: dev 0000:86:00.0{ tso on } TSO is disabled by default. Change-Id: Ifdbaf5322f768c384aa54e532d7bf45e810ca01c Signed-off-by: Chenmin Sun <chenmin.sun@intel.com>
2019-08-19dpdk: QAT devices update, add c4xxx and xeon d15xxJim Thompson1-1/+2
Type: feature Change-Id: I21f8f4563f5545a684b2666f7410847e0f7bc403 Signed-off-by: Jim Thompson <jim@netgate.com>
2019-08-19devices: skip checksum calculation if guest supports checksum offloadSteven Luong1-3/+7
Set VNET_HW_INTERFACE_FLAG_SUPPORTS_TX_L4_CKSUM_OFFLOAD for the interface to skip checksum calculation if guest supports checksum offload. Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: Ie933c3462394f07580ef7f2bec1d2eb3b075bd0c
2019-08-19rdma: add support for input feature arcsBenoît Ganne1-29/+35
Input feature arcs enable functions such as l2patch or bonding. Type: feature Change-Id: Ie333c9b8f7ea20f8a3a409a9a06367807e215a57 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-08-19session: add explicit reset apiFlorin Coras6-6/+72
Type: feature This can be used to forcefully close a session. It's only available to builtin applications for now. Transports must support the reset api otherwise normal close is used. Change-Id: I5e6d681cbc4c8045385e293e0e9d86fa2bf45849 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-08-19tcp: set cc_algo on connection allocFlorin Coras3-6/+19
Type: feature Change-Id: Ie00329b11e26cab5db64b9c006171d283854c8ef Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-08-19tcp: allow cc algos to set pacing rateFlorin Coras2-8/+15
Type: feature Change-Id: Ie7f0f5d2a476d401ede567e422abb953b2bb4a78 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-08-17gso: fix l3 and l4 header offset in case of tagged interfaceMohsin Kazmi2-0/+28
previously, PG and virtio interfaces calculate wrong l3 and l4 header offset. This patch fixes this issue. Type: fix Ticket: VPP-1739 Change-Id: I5ba978e464babeb65e0711e1027320d46b3b9932 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2019-08-17gso: fix the segmentation to use current_data offsetMohsin Kazmi1-15/+16
Type: fix Ticket: VPP-1740 Change-Id: If3e34b5b8260e4c50af338895066c2c96f4603af Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2019-08-17bonding lacp: deleting virtual interface which was enslaved may cause crashSteven Luong5-46/+66
Virtual interfaces may be part of the bonding like physical interfaces. The difference is virtual interfaces may disappear dynamically. As an example, the following CLI sequence may crash the debug image create vhost-user socket /tmp/sock1 create bond mode lacp bond add BondEthernet0 VirtualEthernet0/0/0 delete vhost-user VirtualEhernet0/0/0 Notice the virtual interface is deleted without first doing bond delete. The proper order is to first remove the slave interface from the bond prior to deleting the virtual interface as shown below. But we should handle it anyway. create vhost-user socket /tmp/sock1 create bond mode lacp bond add BondEthernet0 VirtualEthernet0/0/0 bond del VirtualEthernet0/0/0 <----- delete vhost-user VirtualEhernet0/0/0 The fix is to register for VNET_SW_INTERFACE_ADD_DEL_FUNCTION and remove the slave interface from the bond if the to-be-deleted interface is part of the bond. We check the interface that it is actually up before we send the lacp pdu. Up means both hw and sw admin up. Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: If4d2da074338b16aab0df54e00d719e55c45221a
2019-08-16acl: fix stats-segment counters validation on acl updateAndrew Yourtchenko2-8/+46
The stats-segment validation/clear logic for acl counters was wrong, fix it. Also add the code to the unittests to cover that case, add a vat command to enable/disable counters, clean up the unnecessary endian conversion and remove the stray clib_warning() Change-Id: I421297a92e4aeb885c468c72a97cec25981df615 Type: fix Ticket: VPP-1744 Fixes: f995c7122ba0d024b17bc3232e8edd18d5e25088 Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com> (cherry picked from commit 4c945dacb9ff9da731301feb26b1edb4ac00e8bd)
2019-08-16devices: vhost-user crashes displaying show trace for deleted interfaceSteven Luong1-6/+10
After the trace is collected and if the interface is then deleted, show trace may crash for the debug image. This is due to the additional check in pool_elt_at_index() to make sure that the block is not free. The fix is to do the check in vhost format trace and return "interface deleted" Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: I0744f913ba6146609663443f408d784067880f93
2019-08-16hsa: Refactor quic_echo to allow other protocolsNathan Skrzypczak9-2322/+2884
Type: refactor Change-Id: Iaef9091e1d057110530255e644fad1c298418966 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-08-16tcp: fix cc algo name parsingFlorin Coras1-1/+1
Type: fix The initial config parser passed a pointer to the field algo id field in tcp main. Because the field is a u8 and it was interpreted as a uword, it ended up overwrting other tcp configuration fields. Change-Id: Ie9020051c8fca40e14cf42a9888daa87360e5038 Signed-off-by: Florin Coras <fcoras@cisco.com>