summaryrefslogtreecommitdiffstats
path: root/vnet
AgeCommit message (Collapse)AuthorFilesLines
2016-04-08Add Rx and Tx statistics within nsh-vxlan-gpe nodeHongjun Ni3-26/+171
PatchSet2: Modify the code according to review comments. PatchSet3: modify sw_if_index1 in encap.c. Change-Id: Ic4d3ee19a0ba0fa10568e570a79a3cb85cfbc9ab Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-04-07Change encap-fib-id and decap-fib-id within create_nsh_vxlan_gpe_tunnel_commandHongjun Ni1-1/+1
Change-Id: Ied5275fcea21ae2e0b346931f9e2f520a73afd67 Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-04-07Add key.pad=0 within vnet_nsh_vxlan_gpe_add_del_tunnelHongjun Ni1-0/+1
Change-Id: Ieed704ed0c3d747afc9836671f2ea9cc396ee09d Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-04-07Change key.src=a->dst.as_u32 within vnet_nsh_vxlan_gpe_add_del_tunnelHongjun Ni1-1/+1
Change-Id: Ica062e532d116cc1806d73f2fa85db89402928a4 Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-04-07Enhance CLI/API Support for Bonded InterfaceJohn Lo6-31/+106
For interfaces which are slave links to a bounded interface, do not allow sub-interface creation nor interface state to be changed. Change "show interface" to display interface state as "bond-slave" for slave links to a bonded interface. Change "show hardware" to support a "bond" keyword and display slave links to a bonded interface. Change-Id: I4db3cae6985bcb1489ab16a07c72c5ee9b2f2dd3 Signed-off-by: John Lo <loj@cisco.com>
2016-04-07Classify node should pay attention to dynamically-added arcsDave Barach1-2/+2
Change-Id: I65bc03dbb5fedfc75f4ce7153eae116fe599730c Signed-off-by: Dave Barach <dbarach@cisco.com>
2016-04-06Fix ip4 udp encap length typeFlorin Coras1-2/+2
Change-Id: If666cda99a5fd92e904898ced40bcf2b5ac2d3a5 Signed-off-by: Florin Coras <fcoras@cisco.com>
2016-04-05host-interface admin down/up does not bring the interface upAlpesh Patel1-1/+9
Change-Id: I4c9ae5d88e885ccbc85b64cadc052563529c762d Signed-off-by: Alpesh Patel <apatel9191@hotmail.com>
2016-04-02Fix DPDK check in udp.hFlorin Coras1-2/+2
Change-Id: I4734b248f512e223703d234d28542257af1a8074 Signed-off-by: Florin Coras <fcoras@cisco.com>
2016-04-02LISP GPE: initial CP commit and DP improvementsFlorin Coras19-705/+5136
Control Plane ------------- In essence, this introduces basic support for map-request/reply processing, the logic to generate and consume such messages, including SMRs, a control-plane backend, consisting of an eid-table, locator and locator-set tables, and CLI to interact with it. Naturally, we can now serialize/deserialize LISP specific types: addresses, locators, mappings, messages. An important caveat is that IPv6 support is not complete, both for EIDs and RLOCs. Functionally, the DP forwards all packets it can't handle to the CP (lisp_cp_lookup node) which takes care of obtaining a mapping for the packet's destination from a pre-configured map-resolver using the LISP protocol. The CP then caches this information and programs the DP such that all new packets with the same destination (or within the covering prefix) are encapsulated to one of the locators retrieved in the mapping. Ingress traffic-engineering is not yet supported. Data Plane ---------- First of all, to enable punting to the CP, when LISP GPE is turned on a default route that points to lisp_cp_lookup is now inserted. The DP also exposes an API the CP can use to program forwarding for a given mapping. This mainly consists in allocating a tunnel and programming the FIB such that all packets destined to the mapping's prefix are forwarded to a lisp-gpe encapsulating node. Another important change done for lisp forwarding is that both source and destination IP addresses are considered when encapsulating a packet. To this end, a new FIB/mtrie is introduced as a second stage, src lookup, post dst lookup. The latter is still done in the IP FIB but for source-dest entries, in the dest adjacency the lookup_next_index points to a lisp lookup node and the rewrite_header.sw_if_index points to the src FIB. This is read by the lisp lookup node which then walks the src mtrie, finds the associated adjacency, marks the buffer with the index and forwards the packet to the appropriate next node (typically, lisp-gpe-encap). Change-Id: Ibdf52fdc1f89311854621403ccdd66f90e2522fd Signed-off-by: Florin Coras <fcoras@cisco.com>
2016-04-01Add option to link DPDK dynamicallyDamjan Marion2-77/+83
Change-Id: Ie2b47f9020c8260b199d141103318a0261e16832 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-04-01Add support for installing ipv4 routes via unresolved next hopDamjan Marion6-159/+393
Change-Id: I71f3ba0c8192fe0ac3b5b81fb1275b64ec02876a Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-29Add DPDK 16.04-rc2 supportDamjan Marion1-2/+2
Can be used by specifying DPDK_VERSION=16.04-rc2 in the make command line Change-Id: I657b44d7ca22f1ef57756e7703088020fab12bc6 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-29Support per-interface packet rx redirectionDave Barach2-1/+5
Change-Id: I8bb6124efa5665053620b48d11c8160472103c29 Signed-off-by: Dave Barach <dave@barachs.net>
2016-03-29Move classify_table_index under the unionDamjan Marion6-11/+16
Fields needed only by specific adj type should be shared. Change-Id: I59ee15a29d2f5f527f46910a1a63866b291734c7 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-29Adjacency allocatorDave Barach7-601/+344
Change-Id: Ieacbfa4dbbfd13b38eaa2d37f618f212cef4e492 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-29Increment MRU if hardware supports CRC strippingJurek Matuszewski1-3/+27
Change-Id: I46bd007c3c75e5fb872c1beba557e6140fa8d715 Signed-off-by: Todd Foggoa (tfoggoa) <tfoggoa@cisco.com>
2016-03-29Allow vlans to be programmed on 40GE VF interfacesTodd Foggoa (tfoggoa)1-2/+4
Change-Id: Ia3a1bf7cb482f0aa98628b23d88de01cf60c46a9 Signed-off-by: Todd Foggoa (tfoggoa) <tfoggoa@cisco.com>
2016-03-29Mark some show commands as mp safeTodd Foggoa (tfoggoa)1-1/+4
Change-Id: I92cd378370feeddf27832acde06f186fbdf64908 Signed-off-by: Todd Foggoa (tfoggoa) <tfoggoa@cisco.com>
2016-03-25iOAM trace configuration APIsShwetha2-5/+11
Change-Id: I6d31f0ddb812d148ad065e27775440d09f402def Signed-off-by: Shwetha <shwethab@cisco.com>
2016-03-25Use rte_mempool private data for storing vlib_buffer_tDamjan Marion12-54/+45
Change-Id: If3fc88a35bc0b736376113a39667caea42802ea1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-25Remove unnecesary clib_bitmap_set from af_packet input nodeDamjan Marion1-1/+0
Change-Id: I856fefd52efdfc0a3b8be8bafa3f3106267dfcf1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-24l2-rw: Packet rewrite feature for L2 bridgesPierre Pfister5-1/+690
This patch defines a new l2input feature: l2-rw It makes use of vnet_classify in order to match packets and applies mask/value changes depending on the matched classify entry. Change-Id: Ia98c128931e59195bf3ecb66721e155ff9049a2e Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-03-23Fix L2 flood packet replication interaction with VXLAN-tunnelJohn Lo1-17/+16
The check for input sw_if_index against output sw_if_index is not correct for the interface on the replication order after VXLAN tunnel because the encap code overwrite packet sw_if_index[VLIB_RX] with that of the VXLAN tunnel sw_if_index. The check should be done using sw_if_index[VLIB_RX] saved in the packet context. Change-Id: I175717221409977e80576e84dfe5362d1f6aed2f Signed-off-by: John Lo <loj@cisco.com>
2016-03-23Add dpdk vmxnet3 driver patch and init.c change to allow jumbo packetsJohn Lo1-17/+0
Change-Id: I9d7f8b9a0543d885ed10908b859d52a80bf89f56 Signed-off-by: John Lo <loj@cisco.com>
2016-03-22tapcli: Receive vector of packets and memory leak fixPierre Pfister2-148/+183
tapcli interfaces were creating single-packet frames. It now calls readv until the frame is full, or readv returns error EAGAIN. This is usefull when a significant amount of traffic flows through tap interfaces. This patch also fixes a memory leak by correctly initializing b->clone_count to zero. Change-Id: I15e435ba76d542be2f263274e76297425cd10243 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-03-21Unbreak build on gcc-5Damjan Marion1-1/+1
Change-Id: I0dc5f48ade786b60b34441c30f3de5b9f373d714 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-20vnet classifier debug CLI enhancementsDave Barach5-10/+234
Extensible next-index and opaque unformat function scheme. Added next-index-by-node-name and sw_if_index->opaque functions. Allow dynamic graph arcs to be added to ip4/6-inacl. Change-Id: Ie434335399a0708772eb82563a154df19c63b622 Signed-off-by: Dave Barach <dave@barachs.net>
2016-03-19* Added support to configure trace type as arangan3-60/+497
configuration parameter. This can be any combination of nodeid, interface indices, timestamp and appdata. This configuration is passed through packet header by encap node to all other nodes. Rewrite buffer is resized accordingly. Trace function modified accordingly. * Added CLI 'show ioam summary' command to display various configuration. * Added CLI 'clear ioam rewrite' Change-Id: Ide4c85f8b22561303df48519c5ea59668a300188 Signed-off-by: rangan <rangan@cisco.com>
2016-03-19cosmetic: indent codeDave Barach1-3/+1
Gerrit wouldn't merge the previous attempt, so let's just make the pain go away... Change-Id: Ia008d43f755b6e3a5f4c699de365d241bf361aa9 Signed-off-by: Dave Barach <dave@barachs.net>
2016-03-19Add llc_init in osi_init to ensure init order dependencyNagaprabhanjan Bellari1-0/+7
Change-Id: I5cb2a319384e49a072d75f3ea05e6fb92e381c23 Signed-off-by: Nagaprabhanjan Bellari <nagp.lists@gmail.com>
2016-03-18vnet_classify: Handle non-aligned vectors and various bugfixesPierre Pfister2-98/+136
classifier used to crash when packet data was not aligned. This commit also includes: - writer lock initialization bugfix - CLI help was missing opaque-index - ip_input_acl was applying the mask on buffer->data instead of packet head On a side note, my tests failed to show any improvements when using SSE. Further tests might be interesting to see if they actually perform better. Change-Id: Ic34eecd6a2226919121ffce2fe4324506deee52f Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-03-18Make adjacencies shareableDave Barach4-11/+233
Change-Id: I620871ca715b751d2e487f37341b7118797c9176 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-17Bring back p1.c so plugins can see DPDK symbolsTodd Foggoa2-95/+14
Change-Id: Ia450c9bc6d00fbd054d41a462366f826121d781d Signed-off-by: Todd Foggoa <tfoggoa@cisco.com>
2016-03-17Don't stop binding pci device if write to new_id failsDamjan Marion1-2/+0
In some cases write to new_id fails but binding is still possible. Change-Id: I1944eab4326a08e85e83cd5cd7379c6a4d03d98d Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-16af_packet: vec functions should not be used on poolDamjan Marion3-5/+5
Change-Id: Ifc67db0575a7517ac24519894996906ea44ead67 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-16Add vpp native linux kernel AF_PACKET interface supportDamjan Marion7-1/+917
This is 1st drop of VPP native driver for linux AF_PACKET. New CLI: create host-interface name <host-if-name> [hw-addr <mac-address>] References: - Documentation/networking/packet_mmap.txt in the Linux kernel tree - man 7 packet Known issues: - attaching to linux bridge doesn't work - it is not expected to work in multicore setup Change-Id: I1cb1c3d305f349759e90e76e25696718b73bd73d Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-14Declare node, hw_interface_class and device_class instances as externalDamjan Marion9-12/+12
This fixes issue observed on Ubuntu 16.04 where dynamic loader is not finding correct instance of specific structure. Change-Id: I618d0933c7e171b8a9b40495b36894785af7790a Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-14fix declaration of symbol of different sizeJean-Mickael Guerin27-64/+58
I got many warnings at the link step with gcc version 5.3.1 20160225 (Ubuntu 5.3.1-10ubuntu2): /usr/bin/ld: Warning: size of symbol `cop_input_node' changed from 112 in vnet/cop/.libs/cop.o to 168 in vnet/cop/.libs/node1.o /usr/bin/ld: Warning: size of symbol `ethernet_input_node' changed from 112 in vnet/.libs/interface.o to 136 in vnet/ethernet/.libs/node.o /usr/bin/ld: Warning: size of symbol `l2output_node' changed from 112 in vnet/l2/.libs/l2_efp_filter.o to 120 in vnet/l2/.libs/l2_output.o /usr/bin/ld: Warning: size of symbol `srp_input_node' changed from 112 in vnet/srp/.libs/format.o to 136 in vnet/srp/.libs/node.o /usr/bin/ld: Warning: size of symbol `vxlan_encap_node' changed from 112 in vnet/vxlan/.libs/vxlan.o to 128 in vnet/vxlan/.libs/encap.o /usr/bin/ld: Warning: size of symbol `vxlan_input_node' changed from 112 in vnet/vxlan/.libs/vxlan.o to 144 in vnet/vxlan/.libs/decap.o ... Looking at vlib_node_registration_t, I think the reason is that the char * next_nodes[] could be bigger where the variable is defined in .c file. We should mark global variables as external in header files. Some of them can be made static. Change-Id: Ieb6961fd08180c9a69e1d884852703f3eb23f23f Signed-off-by: Jean-Mickael Guerin <jean-mickael.guerin@6wind.com>
2016-03-14Better match vhost-user specification for live migrationYoann Desmouceaux2-2/+10
The specification requires logging of used vring writes to only happen when VHOST_VRING_F_LOG flag is present in VHOST_USER_SET_VRING_ADDR message; take that into account. Change-Id: I9bf4b9eb43a1783b39909b1a3ea1a3bdf50d91a8 Signed-off-by: Yoann Desmouceaux <ydesmouc@cisco.com>
2016-03-14Do not use hugepages if none are available.Stefan Kobza1-2/+2
In case socket-mem was set to <1024 and no 1G page long hupepages were available, the condition was evaluated in unexpected manner. In other words use_1g == 1, and that fails later in mount(). This patch makes sure this is prevented - if there are no pages_available, do not even try to use that pagesize. Change-Id: I30675aa017d97b99d84d5db926e62f0acb54deb6 Signed-off-by: Stefan Kobza <skobza@cisco.com>
2016-03-11Set hardware iface state for loopback interfacesPierre Pfister1-0/+10
So unless I have missed something, loopback interfaces are spawned hardware-down and never set up. This patch uses the same process as tapcli interfaces by mirroring sw state to hw state. Change-Id: I94198c1c880de773daccbb63ca8d32c4c7e26a74 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-03-09Fix IPv6 NDP and bridge BVI and restore NDP and ARP when BVI move is changed.Pierre Pfister1-3/+12
Both ARP and NDP need to be called when hi->output_node_index is changed. It does not look like a perfect solution though. Maybe an actual up-down call would be better... Change-Id: If2988d131e77f4fc522f34f3ffe2d5ba9c1d506c Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-03-07Fix longstanding cleanup-flag bugDave Barach1-12/+9
Change-Id: I9b325b454ef80ffff80a0b0e23b24e3313127376 Signed-off-by: Dave Barach <dave@barachs.net>
2016-03-07Packet filter control-plane API bugfixDave Barach1-4/+14
Don't complain about unknown fib-id's unless actually trying to use the indicated per-address-family fib. Change-Id: Ie8c28dbf7dac9c38193a02ff15a8529d0f90d99a Signed-off-by: Dave Barach <dave@barachs.net>
2016-03-04Allow dpdk linkstate and stat polling intervals to be set dynamically.Bud Grise2-5/+43
Change-Id: I6aa662e060f7ce01a4dd80ae2498dc91a8b65a8e Signed-off-by: Todd Foggoa (tfoggoa) <tfoggoa@cisco.com>
2016-03-04Modified ioam CLI syntax to conform with other CLIsrangan1-10/+10
Change-Id: I384d7b2cdbb63b5ca904db5a11c8b8748f7197b9 Signed-off-by: rangan <rangan@cisco.com>
2016-03-04Collect per Q stats for vhost-user interfaceShesha Sreenivasamurthy5-9/+87
Change-Id: I394960c300ff7a81c4c8e05afd5a4175e66666eb Signed-off-by: Shesha Sreenivasamurthy <shesha@cisco.com>
2016-03-04Use xxhash in map code when SSE4.2 not availableDamjan Marion1-1/+1
Change-Id: If4fb86cfeeaf35f3ae89946b437ce5160adbce94 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-03-03Change default L3 MTU to allow jumbo packets for non-DPDK interfaces.John Lo2-2/+2
Note that L3 MTU for DPDK interfaces is derived from DPDK port_conf in vnet/devices/dpdk/init.c. Change-Id: I9633a1887347a18d05598435baceb6a62cd7b19a Signed-off-by: John Lo <loj@cisco.com>