summaryrefslogtreecommitdiffstats
path: root/src/plugins/avf
AgeCommit message (Collapse)AuthorFilesLines
2018-12-29avf: tx dequeue optimizationsDamjan Marion3-11/+34
Change-Id: I9d8fcf930132e832941e5678a9278a029e104dc3 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-12-29avf: chained buffers rx supportDamjan Marion4-44/+132
Change-Id: I76ba11441f0ab3d150cdd080919cda91eac60b01 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-12-28avf: chained buffers tx supportDamjan Marion2-104/+109
Change-Id: Ib573d45def80b4123d5623fda920e6cda1247638 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-12-26avf: optimize RX functionDamjan Marion3-100/+86
Change-Id: Icd1e9638cdb288e94196391a2c85f2eaaf65387e Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-12-23avf: optimize rx ring refillDamjan Marion1-76/+53
Change-Id: Id35089d6c73b35cd25fd01e07966a2c7e2ea367e Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-12-23avf: new ethernet-input supportDamjan Marion3-183/+44
Change-Id: I5511823f38ad56161b6a538f2d9e63459eded1eb Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-12-23avf: add option to specify interface nameDamjan Marion4-0/+11
Change-Id: I94591d5b103280f8df157819d423fef7ee89d4c8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-11-14Remove c-11 memcpy checks from perf-critical codeDave Barach2-21/+21
Change-Id: Id4f37f5d4a03160572954a416efa1ef9b3d79ad1 Signed-off-by: Dave Barach <dave@barachs.net>
2018-11-13vlib rename vlib_frame_args(...) to vlib_frame_scalar_args(..)Damjan Marion1-1/+1
Typically we have scalar_size == 0, so it doesn't matter but vlib_frame_args was providing pointer to scalar frame data, not vector data. To avoid future confusion function is renamed to vlib_frame_scalar_args(...) Change-Id: I48b75523b46d487feea24f3f3cb10c528dde516f Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-11-08vnet: store hw interface speed in kbps instead of using flagsDamjan Marion1-5/+7
Change-Id: Idd4471a3adf7023e48e85717f00c786b1dde0cca Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-11-08avf: update virtchnl header fileDamjan Marion1-18/+32
Change-Id: I755525d953605561477eeb2252ef38c60000c70a Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-23Numa-aware, growable physical memory allocator (pmalloc)Damjan Marion4-55/+68
Change-Id: Ic4c46bc733afae8bf0d8146623ed15633928de30 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-23c11 safe string handling supportDave Barach4-13/+13
Change-Id: Ied34720ca5a6e6e717eea4e86003e854031b6eab Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-22vlib: pci improvementsDamjan Marion2-16/+18
- logging - pass vlib_main_t to all APIs - open vfio container only when needed Change-Id: I897e53e0af3f91c3a99f0c827401d1c0ec2e478a Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-22vlib: introduce vlib_buffer_get_{pa,va,current_va,current_pa} inlinesDamjan Marion3-45/+40
Change-Id: I0b42ac6b05bc9910904a97924ea4bebc84507d4d Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-19avf: fix crash in rss key calculationDamjan Marion1-1/+1
Change-Id: Id13a0b6ed54885babf679f05207170e36709d9fa Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-09-27avf: may crash if failed to allocate buffers to ringSteven1-1/+1
In avf_rxq_refill, we invoke vlib_buffer_alloc_to_ring which may fill buffers from the end of the ring and continue to the beginning of the ring. If we fill some in the end and continue to fill some in the beginning, but does not have enough buffers to fill the whole request, n_alloc returns a value which is not equal to n_refill to indicate partial refill. We don't like partial refill and invoke vlib_buffer_free to get rid of the buffers that just got refilled. However, vlib_buffer_free API is to free the buffers from the slot continuously. It does not know how to free some from rxq->bufs[slot], and then continue to free the rest when it reaches the end of the ring. The fix is to use vlib_buffer_free_from_ring which is smart enough to figure that stuff out. Change-Id: I93c28e0b0d8d8f22c321d1a5912e00c27b4e2e8d Signed-off-by: Steven <sluong@cisco.com>
2018-09-24avf: rename interface nameDamjan Marion2-2/+2
Change-Id: I4a1dca92a69547f8b26e9aec7574332f39e43c37 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-09-24Trivial: Clean up some typos.Paul Vinciguerra2-3/+3
Change-Id: I085615fde1f966490f30ed5d32017b8b088cfd59 Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-09-04avf: fix random rss keyJakub Grajciar1-2/+2
Change-Id: I622cdb969ea489d333888b90c15ab57c1820e2db Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-08-30avf: RSS supportJakub Grajciar6-19/+80
Change-Id: I59b8f08789f0704d6768258348e938da67e5b15b Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-08-28avf: deal willth tx ring full properlyDamjan Marion3-11/+52
Change-Id: I0b38e129ee01d212463253e5526bfc2d60fd88af Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-28avf: add missing rx_redirect_to_node handlerDamjan Marion1-0/+20
Change-Id: If7fdcdef9a9e12fdf4b7af3c95e06602e39f1e10 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-27cmake: Fix plugins .h includesMohsin Kazmi1-0/+4
Change-Id: I90600d000afb02e8969f3c01bcf9e4b5c10a7d39 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-08-27cmake: add missing vat pluginsDamjan Marion1-0/+3
Change-Id: Ib61f0299c17c0f021408ab0a44c5b54f55f8a8ec Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-25cmake: improve add_vpp_plugin macroDamjan Marion1-4/+6
Change-Id: Iffd5c45ab242a919592a1f686f7f880936b68a1a Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-17CMake as an alternative to autotools (experimental)Damjan Marion1-0/+28
Change-Id: Ibc59323e849810531dd0963e85493efad3b86857 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-13Multiarch handling in different constructor macrosDamjan Marion1-2/+0
This significantly reduces need for ... in multiarch code. Simply constructor macros will jost create static unused entry if CLIB_MARCH_VARIANT is defined and that will be optimized out by compiler. Change-Id: I17d1c4ac0c903adcfadaa4a07de1b854c7ab14ac Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-11Multiversioning: Device (tx) function constructorMohsin Kazmi3-22/+3
Change-Id: I39f87ca161c891fb22462a23188982fef7c3243f Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-08-11avf: fix prefetch bugDamjan Marion1-1/+1
Change-Id: I4e774dc53b08746cd4ab42393f33676dcc78e791 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-08-03Fix typo in trace trajectory initDave Barach1-1/+1
plugin won't compile if VLIB_BUFFER_TRACE_TRAJECTORY is set. The quad loop was OK, bug in single loop only. Change-Id: I11262bf6a223680eeac7ed23238ceda425a02c1b Signed-off-by: Dave Barach <dave@barachs.net>
2018-08-03avf: add avf_create_reply_handler to avf_testJakub Grajciar1-1/+18
Change-Id: I2f376a777081da131110227e760ca0069438c918 Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-07-26avf: used tx queue should be enabledDamjan Marion2-2/+8
Change-Id: I51cc4522df2dd6682148a13e7e1903850b4b3d08 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-07-26avf: request queues supportJakub Grajciar3-3/+68
Change-Id: I3a4529ff8dae70da99ec95c39ddf788c9498f478 Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-07-26avf: fix interrupt modeDamjan Marion2-2/+25
- assign rx thread on interface create, not on admin up - keep interrupts unmasked all the time as they are needed for writeback - forward interrupt to graph dispatcher only if queue is in the interrupt mode Change-Id: I5cc5afe24960143bef08f12d59fbd80ae0c6ccf8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-07-25avf: api fixJakub Grajciar4-7/+25
avf_create_reply returns software index for the new interface Change-Id: I8a6b1a1985b072efafa24eb258b1f2cb1bea1110 Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-07-20avf: don't enable interrupts before interface is admin upDamjan Marion1-1/+0
Change-Id: I0fc19dd109e569f2c407a85e8fa32758e06676b8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-07-20avf: Support interrupt modeSteven2-1/+5
DBGvpp# set interface rx-mode AVF0/4/2/0 interrupt set interface rx-mode AVF0/4/2/0 interrupt DBGvpp# sh int rx sh int rx Thread 0 (vpp_main): node dpdk-input: FortyGigabitEthernet6/0/0 queue 0 (polling) node avf-input: AVF0/4/2/0 queue 0 (interrupt) DBGvpp# sh int addr sh int addr AVF0/4/2/0 (up): L3 133.1.1.10/24 FortyGigabitEthernet6/0/0 (dn): VirtualEthernet0/0/0 (up): L3 192.168.42.1/24 DBGvpp# clear run clear run DBGvpp# clear interfaces clear interfaces DBGvpp# sh int rx sh int rx Thread 0 (vpp_main): node dpdk-input: FortyGigabitEthernet6/0/0 queue 0 (polling) node avf-input: AVF0/4/2/0 queue 0 (interrupt) DBGvpp# ping 133.1.1.3 repeat 1 ping 133.1.1.3 repeat 1 64 bytes from 133.1.1.3: icmp_seq=1 ttl=64 time=.6237 ms Statistics: 1 sent, 1 received, 0% packet loss DBGvpp# sh int sh int Name Idx State MTU (L3/IP4/IP6/MPLS) Counter Count AVF0/4/2/0 5 up 9000/0/0/0 rx packets 1 rx bytes 98 tx packets 1 tx bytes 98 drops 1 ip4 1 FortyGigabitEthernet6/0/0 1 down 9000/0/0/0 VirtualEthernet0/0/0 2 up 9000/0/0/0 local0 0 down 9000/0/0/0 DBGvpp# sh run sh run Time 41.9, average vectors/node 1.00, last 128 main loops 0.00 per node 0.00 vector rates in 2.3858e-2, out 2.3858e-2, drop 2.3858e-2, punt 0.0000e0 Name State Calls Vectors Suspends Clocks Vectors/Call AVF0/4/2/0-output active 1 1 0 1.24e4 1.00 AVF0/4/2/0-tx active 1 1 0 4.28e4 1.00 api-rx-from-ring any wait 0 0 2 6.94e4 0.00 avf-input interrupt wa 1 1 0 1.09e4 1.00 avf-process any wait 0 0 47 1.01e4 0.00 ... DBGvpp# DBGvpp# set interface rx-mode AVF0/4/2/0 polling set interface rx-mode AVF0/4/2/0 polling DBGvpp# sh int rx sh int rx Thread 0 (vpp_main): node dpdk-input: FortyGigabitEthernet6/0/0 queue 0 (polling) node avf-input: AVF0/4/2/0 queue 0 (polling) DBGvpp# ping 133.1.1.3 repeat 1 ping 133.1.1.3 repeat 1 64 bytes from 133.1.1.3: icmp_seq=1 ttl=64 time=.2038 ms Statistics: 1 sent, 1 received, 0% packet loss DBGvpp# Change-Id: Ib7d2b505ae4bb74a052263af766ca37d9df7bfe4 Signed-off-by: Steven <sluong@cisco.com>
2018-07-11avoid using thread local storage for thread indexDamjan Marion1-1/+1
It is cheaper to get thread index from vlib_main_t if available... Change-Id: I4582e160d06d9d7fccdc54271912f0635da79b50 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-07-11avf: descriptor should be volatileDamjan Marion4-40/+60
Change-Id: I2cb4cf2167b6e958d2e57b461848a4a189e3fda0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-06-27avf: binary API and configurable RX/TX queue sizeJakub Grajciar9-12/+566
Change-Id: Ibd3a8d28d8f1df2bc14c42e48498f6ac26081192 Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-06-15avf: tx node fixesDamjan Marion1-9/+9
- missing RSV bit set in descriptor - wrong buffer offset Change-Id: I8b138266652a30a50e4541c6344e4fe3dec4d1ca Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-06-12avf: fix crash if device is busyJakub Grajciar1-1/+8
Change-Id: I170d78c8e5f7e16a264c9f226a09693109aece5e Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-06-09avf: properly cofigure RSS LUTDamjan Marion2-13/+40
Change-Id: I85cfab692ae0a72277ae561cdba7dcbc1f60aca3 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-06-09avf: add support for intel X722 NICsDamjan Marion1-0/+1
Change-Id: I3e07070eed4948e813ad1490963c7f8ef7f4262e Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-06-02AVF input node reworkDamjan Marion2-203/+334
Change-Id: Ib121b24935d5c706cfba6e4b6d321086a38cad91 Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-05-29Add VLIB_NODE_FN() macro to simplify multiversioning of node functionsDamjan Marion2-19/+3
Change-Id: Ibab5e27277f618ceb2d543b9d6a1a5f191e7d1db Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-05-22avf plugin: add support for loggingJakub Grajciar2-5/+14
Change-Id: Ic8c5b527395fc99f1e1a72e51f8d41c9b4f415df Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-04-04Doc updates prior to branchChris Luke1-1/+1
Change-Id: Ibcffee7d20dbb79720199bcd82d2353f39d5544f Signed-off-by: Chris Luke <chrisy@flirble.org>
2018-03-28avf: keep input node in disabled state unless neededDamjan Marion1-1/+1
Change-Id: I9a0105aa2373bd4db218851b1bbee50c6b6dfc7d Signed-off-by: Damjan Marion <damarion@cisco.com>