#
318804 |
|
24-May-2017 |
np |
MFC r313346:
cxgbe/t4_tom: Fix CLIP entry refcounting on the passive side. Every IPv6 connection being handled by the TOE should have a reference on its CLIP entry.
Sponsored by: Chelsio Communications
|
#
313178 |
|
03-Feb-2017 |
jhb |
MFC 312906: Unregister CPL handlers for TOE-related messages when unloading TOM.
Sponsored by: Chelsio Communications
|
#
312525 |
|
20-Jan-2017 |
np |
MFC r312368: cxgbe/tom: Fix a case where do_pass_accept_req wasn't properly restoring the VNET.
|
#
312117 |
|
14-Jan-2017 |
np |
MFC r311569, r311657, and r311949.
r311569: Fix comment in t4_tom. No functional change.
r311657: cxgbe/t4_tom: Fix tid accounting. An offloaded IPv6 connection uses 2 tids, not 1, in the hardware.
r311949: cxgbe/tom: Add VIMAGE support to the TOE driver.
Active Open: - Save the socket's vnet at the time of the active open (t4_connect) and switch to it when processing the reply (do_act_open_rpl or do_act_establish).
Passive Open: - Save the listening socket's vnet in the driver's listen_ctx and switch to it when processing incoming SYNs for the socket. - Reject SYNs that arrive on an ifnet that's not in the same vnet as the listening socket.
CLIP (Compressed Local IPv6) table: - Add only those IPv6 addresses to the CLIP that are in a vnet associated with one of the card's ifnets.
Misc: - Set vnet from the toepcb when processing TCP state transitions. - The kernel sets the vnet when calling the driver's output routine so t4_push_frames runs in proper vnet context already. One exception is when incoming credits trigger tx within the driver's ithread. Set the vnet explicitly in do_fw4_ack for that case.
Sponsored by: Chelsio Communications
|
#
309560 |
|
05-Dec-2016 |
jhb |
MFC 305695,305696,305699,305702,305703,305713,305715,305827,305852,305906, 305908,306062,306063,306137,306138,306206,306216,306273,306295,306301, 306465,309302: Add support for adapters using the Terminator T6 ASIC.
305695: cxgbe(4): Set up fl_starve_threshold2 accurately for T6.
305696: cxgbe(4): Use correct macro for header length with T6 ASICs. This affects the transmit of the VF driver only.
305699: cxgbe(4): Update the pad_boundary calculation for T6, which has a different range of boundaries.
305702: cxgbe(4): Use smaller min/max bursts for fl descriptors with a T6.
305703: cxgbe(4): Deal with the slightly different SGE_STAT_CFG in T6.
305713: cxgbe(4): Add support for additional port types and link speeds.
305715: cxgbe(4): Catch up with the rename of tlscaps -> cryptocaps. TLS is one of the capabilities of the crypto engine in T6.
305827: cxgbe(4): Use the interface's viid to calculate the PF/VF/VFValid fields to use in tx work requests.
305852: cxgbe(4): Attach to cards with the Terminator 6 ASIC. T6 cards will come up as 't6nex' nexus devices with 'cc' ports hanging off them.
The T6 firmware and configuration files will be added as soon as they are released. For now the driver will try to work with whatever firmware and configuration is on the card's flash.
305906: cxgbe/t4_tom: The SMAC entry for a VI is at a different location in the T6.
305908: cxgbe/t4_tom: Update the active/passive open code to support T6. Data path works as-is.
306062: cxgbe(4): Show wcwr_stats for T6 cards.
306063: cxgbe(4): Setup congestion response for T6 rx queues.
306137: cxgbetool: Add T6 support to the SGE context decoder.
306138: Fix typo.
306206: cxgbe(4): Catch up with the different layout of WHOAMI in T6.
Note that the code moved below t4_prep_adapter() as part of this change because now it needs a working chip_id().
306216: cxgbe(4): Fix the output of the "tids" sysctl on T6.
306273: 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.
306295: cxgbe(4): Support SIOGIFXMEDIA so that ifconfig displays correct media for 25Gbps and 100Gbps ports. This should have been part of r305713, which is when the driver first started reporting extended media types.
306301: cxgbe(4): Use the port's top speed to figure out whether it is "high speed" or not (for the purpose of calculating the number of queues etc.) This does the right thing for 25Gbps and 100Gbps ports.
306465: cxgbe(4): Claim the T6 -DBG card.
309302: cxgbe(4): Include firmware for T6 cards in the driver. Update all firmwares to 1.16.12.0.
Sponsored by: Chelsio Communications
|
#
309442 |
|
02-Dec-2016 |
jhb |
MFC 302339: cxgbe(4): Changes to the CPL-handler registration mechanism and code related to "shared" CPLs.
a) Combine t4_set_tcb_field and t4_set_tcb_field_rpl into a single function. Allow callers to direct the response to any iq. Tidy up set_ulp_mode_iscsi while there to use names from t4_tcb.h instead of magic constants.
b) Remove all CPL handler tables from struct adapter. This reduces its size by around 2KB. All handlers are now registered at MOD_LOAD instead of attach or some kind of initialization/activation. The registration functions do not need an adapter parameter any more.
c) Add per-iq handlers to deal with CPLs whose destination cannot be determined solely from the opcode. There are 2 such CPLs in use right now: SET_TCB_RPL and L2T_WRITE_RPL. The base driver continues to send filter and L2T_WRITEs over the mgmtq and solicits the reply on fwq. t4_tom (including the DDP code) now uses the port's ctrlq to send L2T_WRITEs and SET_TCB_FIELDs and solicits the reply on an ofld_rxq. fwq and ofld_rxq have different handlers that know what kind of tid to expect in the reply. Update t4_write_l2e and callers to to support any wrq/iq combination.
Sponsored by: Chelsio Communications
|
#
309108 |
|
24-Nov-2016 |
jch |
MFC r286227, r286443:
r286227:
Decompose TCP INP_INFO lock to increase short-lived TCP connections scalability:
- The existing TCP INP_INFO lock continues to protect the global inpcb list stability during full list traversal (e.g. tcp_pcblist()).
- A new INP_LIST lock protects inpcb list actual modifications (inp allocation and free) and inpcb global counters.
It allows to use TCP INP_INFO_RLOCK lock in critical paths (e.g. tcp_input()) and INP_INFO_WLOCK only in occasional operations that walk all connections.
PR: 183659 Differential Revision: https://reviews.freebsd.org/D2599 Reviewed by: jhb, adrian Tested by: adrian, nitroboost-gmail.com Sponsored by: Verisign, Inc.
r286443:
Fix a kernel assertion issue introduced with r286227: Avoid too strict INP_INFO_RLOCK_ASSERT checks due to tcp_notify() being called from in6_pcbnotify().
Reported by: Larry Rosenman <ler@lerctr.org> Submitted by: markj, jch
|
#
308282 |
|
03-Nov-2016 |
jhb |
MFC 290175,290633,299206,300895,301898: Various TOE fixes.
290175: cxgbe/tom: decide whether to shove segments or not only if there is payload to transmit.
290633: cxgbe/t4_tom: add a knob to the default configuration file to tune the TOE for LAN operation. It is possible to set this to other values (cluster for networks with little loss and really tight RTTs, and wan for relatively large RTTs and/or lossy networks) depending on the environment in which the TOE is being used.
None of this affects plain NIC operation in any way.
299206: Set the correct vnet in TOE event handlers.
300895: cxgbe/t4_tom: Exempt RDMA connections from a TCP sanity test for now, to avoid panicking debug kernels.
t4_tom does not keep track of a connection once it switches to ULP mode iWARP. If the connection falls out of ULP mode the driver/hardware seq# etc. are out of sync. A better fix would be to figure out what the current seq# are, update the driver's state, and perform all sanity checks as usual.
301898: cxgbe/t4_tom: Fix inverted assertion in r300895. It is RDMA connections and not others that are allowed to fail the receive window check.
|
#
308154 |
|
31-Oct-2016 |
jhb |
MFC 291665,291685,291856,297467,302110,302263: Add support for VIs.
291665: 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.
291685: Fix build for !TCP_OFFLOAD case.
291856: Fix RSS build.
297467: Remove #ifdef's from various structures used in the cxgbe/cxl driver.
This provides a constant ABI and layout for these structures (especially struct adapter) avoiding some foot shooting.
302110: 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. ---------------------
302263: cxgbe(4): Do not bring up an interface when IFCAP_TOE is enabled on it. The interface's queues are functional after VI_INIT_DONE (which is short of interface-up) and that's all that's needed for t4_tom to communicate with the chip.
Relnotes: yes Sponsored by: Chelsio Communications
|
#
308071 |
|
28-Oct-2016 |
jhb |
MFC 272079,272080: cxgbe/tom: Update for syncache_add locking changes.
272079: cxgbe/tom: Catch up with r271119, syncache_add doesn't need tcbinfo lock.
272080: Update comment (missed this bit in r272079).
|
#
284089 |
|
06-Jun-2015 |
np |
MFC r278239 and r278374.
r278239: cxgbe(4): reserve id for iSCSI upper layer driver.
r278374: cxgbe(4): tidy up some of the interaction between the Upper Layer Drivers (ULDs) and the base if_cxgbe driver.
Track the per-adapter activation of ULDs in a new "active_ulds" field. This was done pretty arbitrarily before this change -- via TOM_INIT_DONE in adapter->flags for TOM, and the (1 << MAX_NPORTS) bit in adapter->offload_map for iWARP.
iWARP and hw-accelerated iSCSI rely on the TOE (supported by the TOM ULD). The rules are: a) If the iWARP and/or iSCSI ULDs are available when TOE is enabled then iWARP and/or iSCSI are enabled too. b) When the iWARP and iSCSI modules are loaded they go looking for adapters with TOE enabled and enable themselves on that adapter. c) You cannot deactivate or unload the TOM module from underneath iWARP or iSCSI. Any such attempt will fail with EBUSY.
|
#
270051 |
|
16-Aug-2014 |
bz |
MFC r266596:
Move the tcp_fields_to_host() and tcp_fields_to_net() (inline) functions to the tcp_var.h header file in order to avoid further duplication with upcoming commits.
Reviewed by: np
|
#
259804 |
|
24-Dec-2013 |
np |
MFC r259527:
Do not create a hardware IPv6 server if the listen address is not in6addr_any and is not in the CLIP table either. This fixes a reported TOE+IPv6 NULL-dereference panic in do_pass_open_rpl().
While here, stop creating hardware servers for any loopback address. It's just a waste of server tids.
|
#
284089 |
|
06-Jun-2015 |
np |
MFC r278239 and r278374.
r278239: cxgbe(4): reserve id for iSCSI upper layer driver.
r278374: cxgbe(4): tidy up some of the interaction between the Upper Layer Drivers (ULDs) and the base if_cxgbe driver.
Track the per-adapter activation of ULDs in a new "active_ulds" field. This was done pretty arbitrarily before this change -- via TOM_INIT_DONE in adapter->flags for TOM, and the (1 << MAX_NPORTS) bit in adapter->offload_map for iWARP.
iWARP and hw-accelerated iSCSI rely on the TOE (supported by the TOM ULD). The rules are: a) If the iWARP and/or iSCSI ULDs are available when TOE is enabled then iWARP and/or iSCSI are enabled too. b) When the iWARP and iSCSI modules are loaded they go looking for adapters with TOE enabled and enable themselves on that adapter. c) You cannot deactivate or unload the TOM module from underneath iWARP or iSCSI. Any such attempt will fail with EBUSY.
|
#
270051 |
|
16-Aug-2014 |
bz |
MFC r266596:
Move the tcp_fields_to_host() and tcp_fields_to_net() (inline) functions to the tcp_var.h header file in order to avoid further duplication with upcoming commits.
Reviewed by: np
|
#
259804 |
|
24-Dec-2013 |
np |
MFC r259527:
Do not create a hardware IPv6 server if the listen address is not in6addr_any and is not in the CLIP table either. This fixes a reported TOE+IPv6 NULL-dereference panic in do_pass_open_rpl().
While here, stop creating hardware servers for any loopback address. It's just a waste of server tids.
|