|
Revision tags: release/12.2.0, release/11.4.0, release/12.1.0, release/11.3.0 |
|
| #
8b3adb27 |
| 30-Apr-2019 |
Navdeep Parhar <[email protected]> |
MFC r340375 (by jch@):
cxgbe/netmap: Fix cxgbe netmap when interface is DOWN
A kernel panic can occur if the cxgbe interface is DOWN when activating netmap. This patch prevents the driver from free
MFC r340375 (by jch@):
cxgbe/netmap: Fix cxgbe netmap when interface is DOWN
A kernel panic can occur if the cxgbe interface is DOWN when activating netmap. This patch prevents the driver from freeing up cxgbe netmap resources when they have not been allocated.
Submitted by: Nicolas Witkowski <[email protected]> Reviewed by: np Sponsored by: Verisign, Inc. Differential Revision: https://reviews.freebsd.org/D17802
show more ...
|
| #
ca3f2cbd |
| 27-Mar-2019 |
Navdeep Parhar <[email protected]> |
MFC r339717, r339749, and r339809.
r339717: cxgbe(4): Allow "pass" filters to distribute matching traffic using a subset of a VI's RSS indirection table.
This makes it possible to make groups out o
MFC r339717, r339749, and r339809.
r339717: cxgbe(4): Allow "pass" filters to distribute matching traffic using a subset of a VI's RSS indirection table.
This makes it possible to make groups out of rx queues and steer different kinds of traffic to different groups. For example, an interface with 8 rx queues could have all non-TCP traffic delivered to queues 0-3 and all TCP traffic to queues 4-7.
Note that it is already possible for filters to steer traffic to a particular queue or to distribute it using the full indirection table (much like normal rx does).
Sponsored by: Chelsio Communications
r339749: cxgbe(4): Add a knob to split the rx queues for a netmap enabled interface into two groups. Filters can be used to match traffic and distribute it across a group.
hw.cxgbe.nm_split_rss
Sponsored by: Chelsio Communications
r339809: cxgbetool(8): Add a subaction (tcbrss <n>) that can be used with "pass" action to distribute traffic using the half of the VI's RSS indirection table.
The value specified should either be the start of the VI's RSS slice (available at dev.<ifname>.<inst>.rss_base since r339700) or the midpoint (rss_base + rss_size/2). The traffic that hits the filter will use the first or second half of the indirection table respectively. The indirection table can be populated in different ways to achieve different kinds of traffic/load distributions. For example, r339749 allows a netmap interface to have half the rx queues in the first half of the table and the rest in the other.
Sponsored by: Chelsio Communications
show more ...
|
| #
c71b9952 |
| 27-Mar-2019 |
Navdeep Parhar <[email protected]> |
MFC r339705:
cxgbe(4): Update the VI's default queue when netmap is enabled/disabled.
Sponsored by: Chelsio Communications
|
| #
71b898e2 |
| 06-Mar-2019 |
John Baldwin <[email protected]> |
MFC 341098: Add read-only sysctls for all tunables in the cxgbe(4) driver.
|
|
Revision tags: release/12.0.0 |
|
| #
9cd9cae6 |
| 01-Dec-2018 |
Vincenzo Maffione <[email protected]> |
MFC r341145
cxgbe: revert r309725
After the fix contained in r341144, cxgbe does not need anymore to set the IFCAP_NETMAP flag manually.
Differential Revision: https://reviews.freebsd.org/D17987
|
| #
da6e3387 |
| 21-Aug-2018 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Be explicit about ignoring the return value of cmpset in some cases.
Reported by: Coverity (CIDs 1009398, 1009400, 1009401, 1357325, 1394783). All false positives. Sponsored by: Chelsio C
cxgbe(4): Be explicit about ignoring the return value of cmpset in some cases.
Reported by: Coverity (CIDs 1009398, 1009400, 1009401, 1357325, 1394783). All false positives. Sponsored by: Chelsio Communications
show more ...
|
| #
3098bcfc |
| 11-Aug-2018 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Create two variants of service_iq, one for queues with freelists and one for those without.
MFH: 3 weeks Sponsored by: Chelsio Communications
|
| #
2d73ac5e |
| 09-Aug-2018 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Add a sysctl to control the tx credit reclaim mechanism for netmap tx queues. There is no change in default behavior.
Sponsored by: Chelsio Communications
|
|
Revision tags: release/11.2.0 |
|
| #
0afe96c7 |
| 15-Jun-2018 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Add a hw.cxgbe.starve_fl sysctl that can be used to starve the freelists of netmap receive queues. This is primarily to test various congestion scenarios in the chip.
Sponsored by: Chelsi
cxgbe(4): Add a hw.cxgbe.starve_fl sysctl that can be used to starve the freelists of netmap receive queues. This is primarily to test various congestion scenarios in the chip.
Sponsored by: Chelsio Communications
show more ...
|
| #
31f494cd |
| 15-Jun-2018 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Track the number of received frames separately from the number of descriptors processed. Add the ability to gather a certain maximum number of frames in the driver's rx before waking up ne
cxgbe(4): Track the number of received frames separately from the number of descriptors processed. Add the ability to gather a certain maximum number of frames in the driver's rx before waking up netmap rx. If there aren't enough frames then netmap rx will be woken up as usual.
hw.cxgbe.nm_rx_nframes
Sponsored by: Chelsio Communications
show more ...
|
| #
2ff91c17 |
| 12-Apr-2018 |
Vincenzo Maffione <[email protected]> |
netmap: align codebase to the current upstream (commit id 3fb001303718146)
Changelist: - Turn tx_rings and rx_rings arrays into arrays of pointers to kring structs. This patch includes fix
netmap: align codebase to the current upstream (commit id 3fb001303718146)
Changelist: - Turn tx_rings and rx_rings arrays into arrays of pointers to kring structs. This patch includes fixes for ixv, ixl, ix, re, cxgbe, iflib, vtnet and ptnet drivers to cope with the change. - Generalize the nm_config() callback to accept a struct containing many parameters. - Introduce NKR_FAKERING to support buffers sharing (used for netmap pipes) - Improved API for external VALE modules. - Various bug fixes and improvements to the netmap memory allocator, including support for externally (userspace) allocated memory. - Refactoring of netmap pipes: now linked rings share the same netmap buffers, with a separate set of kring pointers (rhead, rcur, rtail). Buffer swapping does not need to happen anymore. - Large refactoring of the control API towards an extensible solution; the goal is to allow the addition of more commands and extension of existing ones (with new options) without the need of hacks or the risk of running out of configuration space. A new NIOCCTRL ioctl has been added to handle all the requests of the new control API, which cover all the functionalities so far supported. The netmap API bumps from 11 to 12 with this patch. Full backward compatibility is provided for the old control command (NIOCREGIF), by means of a new netmap_legacy module. Many parts of the old netmap.h header has now been moved to netmap_legacy.h (included by netmap.h).
Approved by: hrs (mentor)
show more ...
|
| #
7cb7c6e3 |
| 20-Feb-2018 |
Navdeep Parhar <[email protected]> |
Catch up with the removal of nktr_slot_flags from upstream netmap. No functional impact intended.
Submitted by: Vincenzo Maffione <[email protected]>
|
| #
f549e352 |
| 22-Dec-2017 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Do not forward interrupts to queues with freelists. This leaves the firmware event queue (fwq) as the only queue that can take interrupts for others.
This simplifies cfg_itype_and_nqueues
cxgbe(4): Do not forward interrupts to queues with freelists. This leaves the firmware event queue (fwq) as the only queue that can take interrupts for others.
This simplifies cfg_itype_and_nqueues and queue allocation in the driver at the cost of a little (never?) used configuration. It also allows service_iq to be split into two specialized variants in the future.
MFC after: 2 months Sponsored by: Chelsio Communications
show more ...
|
|
Revision tags: release/10.4.0, release/11.1.0 |
|
| #
a8c4fcb9 |
| 15-Jun-2017 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Fix per-queue netmap operation.
Do not attempt to initialize netmap queues that are already initialized or aren't supposed to be initialized. Similarly, do not free queues that are not i
cxgbe(4): Fix per-queue netmap operation.
Do not attempt to initialize netmap queues that are already initialized or aren't supposed to be initialized. Similarly, do not free queues that are not initialized or aren't supposed to be freed.
PR: 217156 Sponsored by: Chelsio Communications
show more ...
|
| #
b8c1ffef |
| 09-Dec-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): netmap does not set IFCAP_NETMAP in an ifnet's if_capabilities any more (since r307394). Do it in the driver instead.
MFC after: 1 week
|
|
Revision tags: release/11.0.1 |
|
| #
3cdfcb51 |
| 23-Sep-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Fix netmap with T6, which doesn't encapsulate SGE_EGR_UPDATE message inside a FW_MSG. The base NIC already deals with updates in either form.
Sponsored by: Chelsio Communications
|
|
Revision tags: release/11.0.0 |
|
| #
8c0ca00b |
| 21-Sep-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Setup congestion response for T6 rx queues.
|
| #
ed7e5640 |
| 11-Sep-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Use smaller min/max bursts for fl descriptors with a T6.
Sponsored by: Chelsio Communications
|
| #
315048f2 |
| 01-Aug-2016 |
John Baldwin <[email protected]> |
Store the offset of the KDOORBELL and GTS registers in the softc.
VF devices use a different register layout than PF devices. Storing the offset in a value in the softc allows code to be shared bet
Store the offset of the KDOORBELL and GTS registers in the softc.
VF devices use a different register layout than PF devices. Storing the offset in a value in the softc allows code to be shared between the PF and VF drivers.
Reviewed by: np Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D7389
show more ...
|
| #
62291463 |
| 23-Jun-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Merge netmap support from the ncxgbe/ncxl interfaces to the vcxgbe/vcxl interfaces and retire the 'n' interfaces. The main cxgbe/cxl interfaces and tunables related to them are not affecte
cxgbe(4): Merge netmap support from the ncxgbe/ncxl interfaces to the vcxgbe/vcxl interfaces and retire the 'n' interfaces. The main cxgbe/cxl interfaces and tunables related to them are not affected by any of this and will continue to operate as usual.
The driver used to create an additional 'n' interface for every cxgbe/cxl interface if "device netmap" was in the kernel. The 'n' interface shared the wire with the main interface but was otherwise autonomous (with its own MAC address, etc.). It did not have normal tx/rx but had a specialized netmap-only data path. r291665 added another set of virtual interfaces (the 'v' interfaces) to the driver. These had normal tx/rx but no netmap support.
This revision consolidates the features of both the interfaces into the 'v' interface which now has a normal data path, TOE support, and native netmap support. The 'v' interfaces need to be created explicitly with the hw.cxgbe.num_vis tunable. This means "device netmap" will not result in the automatic creation of any virtual interfaces.
The following tunables can be used to override the default number of queues allocated for each 'v' interface. nofld* = 0 will disable TOE on the virtual interface and nnm* = 0 to will disable native netmap support.
# number of normal NIC queues hw.cxgbe.ntxq_vi hw.cxgbe.nrxq_vi
# number of TOE queues hw.cxgbe.nofldtxq_vi hw.cxgbe.nofldrxq_vi
# number of netmap queues hw.cxgbe.nnmtxq_vi hw.cxgbe.nnmrxq_vi
hw.cxgbe.nnm{t,r}xq{10,1}g tunables have been removed.
--- tl;dr version --- The workflow for netmap on cxgbe starting with FreeBSD 11 is: 1) "device netmap" in the kernel config. 2) "hw.cxgbe.num_vis=2" in loader.conf. num_vis > 2 is ok too, you'll end up with multiple autonomous netmap-capable interfaces for every port. 3) "dmesg | grep vcxl | grep netmap" to verify that the interface has netmap queues. 4) Use any of the 'v' interfaces for netmap. pkt-gen -i vcxl<n>... . One major improvement is that the netmap interface has a normal data path as expected. 5) Just ignore the cxl interfaces if you want to use netmap only. No need to bring them up. The vcxl interfaces are completely independent and everything should just work. ---------------------
Approved by: re@ (gjb@) Relnotes: Yes Sponsored by: Chelsio Communications
show more ...
|
| #
4ed3c0e7 |
| 30-Apr-2016 |
Pedro F. Giffuni <[email protected]> |
sys: Make use of our rounddown() macro when sys/param.h is available.
No functional change.
|
|
Revision tags: release/10.3.0 |
|
| #
90e7434a |
| 08-Mar-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Add a struct sge_params to store per-adapter SGE parameters. Move the code that reads all the parameters to t4_init_sge_params in the shared code. Use these per-adapter values instead of g
cxgbe(4): Add a struct sge_params to store per-adapter SGE parameters. Move the code that reads all the parameters to t4_init_sge_params in the shared code. Use these per-adapter values instead of globals.
Sponsored by: Chelsio Communications
show more ...
|
| #
d1205d09 |
| 04-Mar-2016 |
Navdeep Parhar <[email protected]> |
cxgbe(4): Very basic T6 awareness. This is part of ongoing work to update to the latest internal shared code.
- Add a chip_params structure to keep track of hardware constants for all generations
cxgbe(4): Very basic T6 awareness. This is part of ongoing work to update to the latest internal shared code.
- Add a chip_params structure to keep track of hardware constants for all generations of Terminators handled by cxgbe. - Update t4_hw_pci_read_cfg4 to work with T6. - Update the hardware debug sysctls (hidden within dev.<tNnex>.<n>.misc.*) to work with T6. Most of the changes are in the decoders for the CIM logic analyzer and the MPS TCAM. - Acquire the regwin lock around indirect register accesses.
Obtained from: Chelsio Communications Sponsored by: Chelsio Communications
show more ...
|
| #
fe2ebb76 |
| 03-Dec-2015 |
John Baldwin <[email protected]> |
Add support for configuring additional virtual interfaces (VIs) on a port.
Each virtual interface has its own MAC address, queues, and statistics. The dedicated netmap interfaces (ncxgbeX / ncxlX) w
Add support for configuring additional virtual interfaces (VIs) on a port.
Each virtual interface has its own MAC address, queues, and statistics. The dedicated netmap interfaces (ncxgbeX / ncxlX) were already implemented as additional VIs on each port. This change allows additional non-netmap interfaces to be configured on each port. Additional virtual interfaces use the naming scheme vcxgbeX or vcxlX.
Additional VIs are enabled by setting the hw.cxgbe.num_vis tunable to a value greater than 1 before loading the cxgbe(4) or cxl(4) driver. NB: The first VI on each port is the "main" interface (cxgbeX or cxlX).
T4/T5 NICs provide a limited number of MAC addresses for each physical port. As a result, a maximum of six VIs can be configured on each port (including the "main" interface and the netmap interface when netmap is enabled).
One user-visible result is that when netmap is enabled, packets received or transmitted via the netmap interface are no longer counted in the stats for the "main" interface, but are not accounted to the netmap interface.
The netmap interfaces now also have a new-bus device and export various information sysctl nodes via dev.n(cxgbe|cxl).X.
The cxgbetool 'clearstats' command clears the stats for all VIs on the specified port along with the port's stats. There is currently no way to clear the stats of an individual VI.
Reviewed by: np MFC after: 1 month Sponsored by: Chelsio
show more ...
|
|
Revision tags: release/10.2.0 |
|
| #
847bf383 |
| 10-Jul-2015 |
Luigi Rizzo <[email protected]> |
Sync netmap sources with the version in our private tree. This commit contains large contributions from Giuseppe Lettieri and Stefano Garzarella, is partly supported by grants from Verisign and Cisco
Sync netmap sources with the version in our private tree. This commit contains large contributions from Giuseppe Lettieri and Stefano Garzarella, is partly supported by grants from Verisign and Cisco, and brings in the following:
- fix zerocopy monitor ports and introduce copying monitor ports (the latter are lower performance but give access to all traffic in parallel with the application)
- exclusive open mode, useful to implement solutions that recover from crashes of the main netmap client (suggested by Patrick Kelsey)
- revised memory allocator in preparation for the 'passthrough mode' (ptnetmap) recently presented at bsdcan. ptnetmap is described in S. Garzarella, G. Lettieri, L. Rizzo; Virtual device passthrough for high speed VM networking, ACM/IEEE ANCS 2015, Oakland (CA) May 2015 http://info.iet.unipi.it/~luigi/research.html
- fix rx CRC handing on ixl
- add module dependencies for netmap when building drivers as modules
- minor simplifications to device-specific routines (*txsync, *rxsync)
- general code cleanup (remove unused variables, introduce macros to access rings and remove duplicate code,
Applications do not need to be recompiled, unless of course they want to use the new features (monitors and exclusive open).
Those willing to try this code on stable/10 can just update the sys/dev/netmap/*, sys/net/netmap* with the version in HEAD and apply the small patches to individual device drivers.
MFC after: 1 month Sponsored by: (partly) Verisign, Cisco
show more ...
|