aboutsummaryrefslogtreecommitdiffstats
path: root/src/vpp
AgeCommit message (Collapse)AuthorFilesLines
2018-08-23CMake: Add Cmake support for VatMohsin Kazmi1-4/+14
Change-Id: I3e8efce9eacba46ec9913d4024d66f00fe326095 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-08-21CMake: stats clients depend on the .api header generationNeale Ranns1-0/+2
Change-Id: I5bdc57a8dd13ef34799052cc642fc45b78bafdc6 Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
2018-08-17CMake as an alternative to autotools (experimental)Damjan Marion1-0/+87
Change-Id: Ibc59323e849810531dd0963e85493efad3b86857 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-17l2: arp termination dumpMohsin Kazmi1-0/+10
VPP-1368 Change-Id: I6373f76ba87184a91b517712eafb4ee1f5cea59e Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-07-26VPP-1359 Wrong vl_msg_idLukasz Majczak1-1/+1
Wrong vl_msg_id set in vl_api_stats_get_poller_delay_t_handler while reporting stats delay. Change-Id: I7d6ad14359e41c717b976390c58e254e3602e0ff Signed-off-by: Lukasz Majczak <lma@semihalf.com>
2018-07-24Create a unit-test pluginDave Barach1-30/+0
Move the tcp unit test to the plugin Add a bihash unit test and a "make test" program to call it Adjust framework.py to load the plugin, which is disabled by default Change-Id: Ic229d386a56a9d28dbd54974f231149053ca8f93 Signed-off-by: Dave Barach <dave@barachs.net>
2018-07-18Add config option to use dlmalloc instead of mheapDave Barach2-3/+3
Configure w/ --enable-dlmalloc, see .../build-data/platforms/vpp.mk src/vppinfra/dlmalloc.[ch] are slightly modified versions of the well-known Doug Lea malloc. Main advantage: dlmalloc mspaces have no inherent size limit. Change-Id: I19b3f43f3c65bcfb82c1a265a97922d01912446e Signed-off-by: Dave Barach <dave@barachs.net>
2018-07-13Improve the "show version" commandDave Barach1-5/+82
Add "show version cmdline" to display the command line Add doxygen tags to the source code Change-Id: I0205b373062fd88f176d9c8086d89d7784a5172f Signed-off-by: Dave Barach <dave@barachs.net>
2018-07-13STATS fix memory leak in stat_client.cDave Cornejo1-0/+3
continue statement in case bypasses cleaning up of unserialized node Change-Id: I0103d31df2eed3ed04d7cdcdfb790f4d9a376336 Signed-off-by: Dave Cornejo <dcornejo@netgate.com>
2018-07-12stats-segment: add startup node serialization optionFlorin Coras2-1/+7
Node serialization is turned off by default. To enable it do: statseg {serialize-nodes on} Change-Id: I53bba3cab517bd3ba90eba52d94b3ebb16870141 Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-07-11threads: fix issue with setting main-core to 0Damjan Marion1-1/+2
Change-Id: Id3ccfcfa2a88cf7aa106f1202af7cd677de32575 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-07-05add stat segment size configurationDave Barach2-1/+29
Change-Id: I395ff9c91d670a9f9e50dc1b030e0412b7234de5 Signed-off-by: Dave Barach <dave@barachs.net>
2018-07-03Set main thread affinity before main heap is allocatedDamjan Marion1-0/+21
Change-Id: I524909570fc1736f51fd437d6d30566c461139bd Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-06-29VPP-1324 SIGSEGV vl_msg_api_handler_with_vm_node()Lukasz Majczak2-11/+21
Increase local arrays sizes to the correct number and gather missing statistics. Change-Id: If44d43f258730e9a18f50fb59fc526c214d2be8a Signed-off-by: Lukasz Majczak <lma@semihalf.com>
2018-06-25tw: add light weight timer update functionFlorin Coras1-3/+3
Because it avoids pool putting/getting the timer, this function is somewhat faster than stopping and restarting a timer. Change-Id: Id99ed9d356b0b1f7e12facfe8da193e1cd30b3ec Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-06-21BIER neighbor statsNeale Ranns3-47/+207
Change-Id: I2f638f1932b4aeddf2408c06d1b8393551675b72 Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
2018-06-19Driver level time-based src mac filterDave Barach1-0/+1
Change-Id: I062d7653e00d77e73a61d8841e01ab4a159b6404 Signed-off-by: Dave Barach <dbarach@cisco.com>
2018-06-19Fixed bugs in SRv6 APIPablo Camarillo1-15/+15
Jira ticket VPP-1196 Jira ticket VPP-1081 Jira ticket VPP-1078 Jira ticket VPP-1217 Change-Id: Id7e85229cae1017acb0aa4ca63ced334e6dafb8d Signed-off-by: pcamaril <pcamaril@cisco.com> Signed-off-by: Pablo Camarillo <pcamaril@cisco.com> Signed-off-by: pcamaril <pcamaril@cisco.com> Signed-off-by: Michal Cmarada <michal.cmarada@pantheon.tech>
2018-06-15STATS: Separate socket for fd exchange.Ole Troan5-162/+96
stats { interval <no> socket-name <name> | default } Where the default socket is in /run/vpp/stats.sock Change-Id: Idd501b328c662804d4ccd58034b0ea6b8aa1f89a Signed-off-by: Ole Troan <ot@cisco.com>
2018-06-15STATS: Add more hierarchy to counters.Ole Troan2-12/+10
Put error counters under node_index. /err/<node-name>/<error-name> E.g: /err/ip4-lookup/Hash table collisions /err/ip6-rewrite/Buffer allocation error Error names are not globally unique, and this allows for walking all errors for a particular node. Put interface counters under the directory /if. E.g. /if/rx Put system counters under the directory /sys. E.g. /sys/vector_rate Change-Id: I5b794d16698f61bcb2063a8cd77a7c4ae36419b8 Signed-off-by: Ole Troan <ot@cisco.com>
2018-06-14Use __attribute__((weak)) references where necessaryDave Barach3-8/+7
It should be possible to use vlib without the vlibmemory library, etc. Change-Id: Ic2316b93d7dbb728fb4ff42a3ca8b0d747c9425e Signed-off-by: Dave Barach <dave@barachs.net>
2018-06-13Stat segment / client: show run" works nowDave Barach6-57/+280
Seems to have minimal-to-zero performance consequences. Data appears accurate: result match the debug CLI output. Checked at low rates, 27 MPPS sprayed across two worker threads. Change-Id: I09ede5150b88a91547feeee448a2854997613004 Signed-off-by: Dave Barach <dave@barachs.net>
2018-06-13vxlan:offload RX floweyal bari1-0/+15
ip4 vxlan cli/api (using flow infra) to create flows and enable them on different hardware (currently tested with i40e) to offload a vxlan tunnel onto hw: set flow-offload vxlan hw TwentyFiveGigabitEthernet3/0/0 rx vxlan_tunnel1 to remove offload: set flow-offload vxlan hw TwentyFiveGigabitEthernet3/0/0 rx vxlan_tunnel1 del TODO:ipv6 handling Change-Id: I70e61f792ef8e3f007d03d7df70e97ea4725b101 Signed-off-by: Eyal Bari <ebari@cisco.com>
2018-06-11MTU: Software interface / Per-protocol MTU supportOle Troan1-3/+3
This patch separates setting of hardware interfaec and software interface MTU. Software MTU is L2 payload MTU (i.e. not including L2 header). Per-protocol MTU for IPv4, IPv6 and MPLS can also be set. Currently only IP4, IP6 are enabled in adjacency / rewrite code. Documentation in src/vnet/MTU.md Change-Id: Iee2fd6f0bbc8210748dd8e073ab9fab87d323690 Signed-off-by: Ole Troan <ot@cisco.com>
2018-06-10Don't use foreach_vlib_main macro w/out barrier syncDave Barach1-4/+8
It should be OK to scrape dispatch stats without forcing a barrier sync. Scrape the stats manually. We'll see what happens. Change-Id: Ia20b51ea12ed81cce76e1801401bad0edd0645bb Signed-off-by: Dave Barach <dave@barachs.net>
2018-06-08Add reaper functions to want events APIs (VPP-1304)Neale Ranns1-14/+66
Change-Id: Iaeb52d94cb6da63ee93af7c1cf2dade6046cba1d Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-06-08export counters in a memfd segmentDave Barach6-11/+932
also export per-node error counters directory entries implement object types Change-Id: I8ce8e0a754e1be9de895c44ed9be6533b4ecef0f Signed-off-by: Dave Barach <dave@barachs.net>
2018-06-07DHCP Client DumpNeale Ranns1-4/+4
- use types on the DHCP API so that the same data is sent in comfing messages and in dumps - add the DHCP client dump API - update VOM to refelct API changes - rename VOM class dhcp_config* dhcp_client* - the VOM dhcp_client class maintains the lease data (which it reads on a dump) for clients to read Change-Id: I2a43463937cbd80c01d45798e74b21288d8b8ead Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
2018-06-04Fix API trace dump for tapv2Milan Lenco1-3/+3
Change-Id: Ib092da61ba037ea30c6f38ea692ef9f1ca0cd8e7 Signed-off-by: Milan Lenco <milan.lenco@pantheon.tech>
2018-05-29af_packet: Add support for dump interfacesMohsin Kazmi1-0/+11
Change-Id: I8d8ecc80edb7665125ba625a3ce7b30d2dea88f0 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-05-25ARP proxy dumpsNeale Ranns1-4/+5
Change-Id: I8335ebf266becf2f42bb3f28a17dfed8d9b08f97 Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-05-11Periodic scan and probe of IP neighbors to maintain neighbor poolsJohn Lo1-0/+33
Scan IPv4 and IPv6 neigbor pool entries once a minute to keep them up to date. The neighbor of an entry is probed if its time-stamp is older than 1 minute. If the neighbor respond, its time-stamp will be updated. If there is no response from a neighbor, its entry will be deleted when the time-stamp of the entry become more than 4 minutes old. Static neighbor entries are not probed nor deleted. Implemented CLI and API to enable and disable priodic scan of IPv4, IPv6 or both types of IP neighbors. CLI is "ip scan-neighbor" and API is "ip_scan_neighbor_enable_disable". Other IP neighbor scan parameters can also be changed from their defaults via the CLI/API. Change-Id: Id1a0a934ace15d03db845aa698bcbb9cdabebfcd Signed-off-by: John Lo <loj@cisco.com>
2018-05-04Harmonize vec/pool_get_aligned object sizes and alignment requestsDave Barach1-1/+1
Object sizes must evenly divide alignment requests, or vice versa. Otherwise, only the first object will be aligned as requested. Three choices: add CLIB_CACHE_LINE_ALIGN_MARK(align_me) at the end of structures, manually pad to an even divisor or multiple of the alignment request, or use plain vectors/pools. static assert for enforcement. Change-Id: I41aa6ff1a58267301d32aaf4b9cd24678ac1c147 Signed-off-by: Dave Barach <dbarach@cisco.com>
2018-04-27VAT for qos_record_enable_disable APIIgor Mikhailov (imichail)1-2/+17
Change-Id: I2b418b9aefe298e4e6190cbe2e220a657f688cda Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
2018-04-24mem-leak in stats handling (VPP-1250)Neale Ranns1-4/+18
Change-Id: I55f978c84a56bc089e5657c528195b6c84409364 Signed-off-by: Neale Ranns <neale.ranns@cisco.com> (cherry picked from commit df53f5fda277a035984f1de4474f0b58ae15b114)
2018-04-16Implement ip_probe_neighbor APIJohn Lo1-0/+16
Add API support similar to VPP CLI "ip probe-neighbor" except API call is asynch and will not wait, as the CLI does, for address resolution of probed neighbor. The API client can use the APIs want_ip4_arp_events or want_ip6_nd_events to get notified of the desired address resolution event. Change-Id: Ieab58abe75b5cc7f5185b3b91418b6362f8992d3 Signed-off-by: John Lo <loj@cisco.com>
2018-04-12Fixes for 'make UNATTENDED=yes CC=clang CXX=clang verify'Neale Ranns1-1/+1
Change-Id: I994649761fe2e66e12ae0e49a84fb1d0a966ddfb Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-04-09Autodetect plugin pathDamjan Marion2-12/+58
dpdk plugin self-disables if there are no hugepages available Change-Id: Ib286e1a370deeb21248e6e961573ef9c68759b4c Signed-off-by: Damjan Marion <damarion@cisco.com> Signed-off-by: Dave Barach <dave@barachs.net>
2018-04-04Detailed stats collection featureNeale Ranns1-12/+20
Use device-input and interface-output feautre arcs to collect unicast, multicast and broadcast states for RX and TX resp. Since these feature arcs are present only for 'physical' interfaces (i.e. not su-interfaces) counter collection is supported only on parent interface types. Change-Id: I915c235e336b0fc3a3c3de918f95dd674e4e0e4e Signed-off-by: Neale Ranns <nranns@cisco.com> Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-03-30Updated sample startup.conf with supported plugin config options.Maciek Konstantynowicz1-10/+19
Change-Id: Id2884a4c2208b4382fce56019b11e4b7fdc4275b Signed-off-by: Maciek Konstantynowicz <mkonstan@cisco.com>
2018-03-21bond: Add bonding driver and LACP protocolSteven1-0/+84
Add bonding driver to support creation of bond interface which composes of multiple slave interfaces. The slave interfaces could be physical interfaces, or just any virtual interfaces. For example, memif interfaces. The syntax to create a bond interface is create bond mode <lacp | xor | acitve-backup | broadcast | round-robin> To enslave an interface to the bond interface, enslave interface TenGigabitEthernet6/0/0 to BondEthernet0 Please see src/plugins/lacp/lacp_doc.md for more examples and additional options. LACP is a control plane protocol which manages and monitors the status of the slave interfaces. The protocol is part of 802.3ad standard. This patch implements LACPv1. LACPv2 is not supported. To enable LACP on the bond interface, specify "mode lacp" when the bond interface is created. The syntax to enslave a slave interface is the same as other bonding modes. Change-Id: I06581d3b87635972f9f0e1ec50b67560fc13e26c Signed-off-by: Steven <sluong@cisco.com>
2018-03-21UDP Encap countersNeale Ranns3-2/+183
Change-Id: Ib5639981dca0b11b2d62acf2c0963cc95c380f70 Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-03-16stats: allow configuring poller delayKlement Sekera2-3/+98
This introduces a startup config option for configuring stats poller delay. Use `stats { interval <seconds> }` to configure the delay at startup. The default value remains unchanged - 10 seconds. Change-Id: If12cb1f7f6f1f8ecfa461561bc77847cdf260388 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2018-03-13Rationalize plugin symbol error reportingDave Barach1-2/+6
Change-Id: I64f2b2007f30fc1c6bd2990ba0d7ccbcd43cdb38 Signed-off-by: Dave Barach <dave@barachs.net>
2018-03-09Coordinate known Ethernet speeds with Linux kernel and DPDKLee Roberts1-0/+18
Linux kernel and DPDK recognize the following Ethernet speeds: 10M, 100M, 1G, 2.5G, 5G, 10G, 20G, 25G, 40G, 50G, 56G and 100G. Add consistent Ethernet speeds to VPP. Change-Id: I4cfcf378fb34425c1206db5aa2f6bdcc66e0a6ab Signed-off-by: Lee Roberts <lee.roberts@hpe.com>
2018-03-06API: Add service definitions for events and singleton messages (second attempt)Marek Gradzki2-0/+100
Based on https://gerrit.fd.io/r/#/c/10920/ Updates service definition in stats.api with correct reply message names. Change-Id: I3282bee5304e667e23bc1fab3f43d967a50d880d Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
2018-03-05Revert "API: Add service definitions for events and singleton messages."Ole Trøan2-100/+0
This reverts commit f7b7fa53b7eaec81d8c00c1023fb7d01f1f9761f. Change-Id: I87496342943248e94f01ada31459f387c0a3a610 Signed-off-by: Ole Troan <ot@cisco.com>
2018-03-05API: Add service definitions for events and singleton messages.Ole Troan2-0/+100
Change-Id: I7de987c30b263d43521e6280c5273f30b5f6e11c Signed-off-by: Ole Troan <ot@cisco.com>
2018-03-02tapv2: CLI and binary API fixesSteven1-1/+1
1. When interface create encouners an error (see test below), the same id cannot be used again. This is due to hash_set is called too early in the function. After the hash entry is set, there are different errors may cause the interface create to be aborted. But we didn't remove the hash entry when error is encountered. The fix is to move the hash_set call near the end which has no more "goto error" DBGvpp# create tap id 1 rx-ring-size 1021 tx-ring-size 1021 create tap id 1 rx-ring-size 1021 tx-ring-size 1021 create tap: ring size must be power of 2 DBGvpp# create tap id 1 rx-ring-size 1024 tx-ring-size 1024 create tap id 1 rx-ring-size 1024 tx-ring-size 1024 create tap: interface already exists DBGvpp# 2. multiple issues exist with api_format.c with the below command binary-api tap_create_v2 id 4 hw-addr 90:e2:ba:76:cf:2f rx-ring-size 1024 tx-ring-size 1024 - hw_addr is not taken due to the test for random mac is inverted - id is an integer, not a string - integer values were not converted to network format Change-Id: I5a669d702a80ad158517df46f0ab089e4d0d692e Signed-off-by: Steven <sluong@cisco.com>
2018-02-15Optimize GRE Tunnel and add support for ERSPAN encapJohn Lo1-1/+7
Change GRE tunnel to use the interface type where the same encap node is used as output node for all GRE tunnels, instead of having dedicated output and tx node for each tunnel. This allows for more efficient tunnel creation and deletion at scale tested at 1000's of GRE tunnels. Add support for ERSPAN encap as another tunnel type, in addition to the existing L3 and TEB types. The GRE ERSPAN encap supported is type 2 thus GRE encap need to include sequence number and GRE- ERSPAN tunnel can be created with user secified ERSPAN session ID. The GRE tunnel lookup hash key is updated to inclue tunnel type and session ID, in addition to SIP/DIP and FIB index. Thus, GRE-ERSPAN tunnel can be created, with the appropriate session ID, to be used as output interface for SPAN config to send mirrored packets. Change interface naming so that all GRE tunnels, irrespective of tunnel type, uses "greN" where N is the instance number. Removed interface reuse on tunnel creation and deletion to enable unfied tunnel interface name. Add support of user specified instance on GRE tunnel creation. Thus, N in the "greN" interface name can optionally be specified by user via CLI/API. Optimize GRE tunnel encap DPO stacking to bypass load-balance DPO node since packet output on GRE tunnel always belong to the same flow after 5-tupple hash. Change-Id: Ifa83915744a1a88045c998604777cc3583f4da52 Signed-off-by: John Lo <loj@cisco.com>