summaryrefslogtreecommitdiffstats
path: root/sys/dev/cxgbe
Commit message (Collapse)AuthorAgeFilesLines
* Switch some PCI register reads from using magic numbers to using the namesgavin2012-09-191-1/+1
| | | | | | defined in pcireg.h MFC after: 1 week
* Align the PCI Express #defines with the style used for the PCI-Xgavin2012-09-182-10/+10
| | | | | | | | | | | | | | | | | #defines. This also has the advantage that it makes the names more compact, iand also allows us to correct the non-uniform naming of the PCIM_LINK_* defines, making them all consistent amongst themselves. This is a mostly mechanical rename: s/PCIR_EXPRESS_/PCIER_/g s/PCIM_EXP_/PCIEM_/g s/PCIM_LINK_/PCIEM_LINK_/g When this is MFC'd, #defines will be added for the old names to assist out-of-tree drivers. Discussed with: jhb MFC after: 1 week
* Install interrupt handlers early, during attach, for the reasonnp2012-09-131-41/+67
| | | | | | explained in r239913 by jhb. MFC after: 1 week
* Use native FreeBSD facilities everywhere except the shared code in common/np2012-09-134-32/+27
| | | | MFC after: 1 week
* Update interface to firmware 1.6.2 and include the firmware in the driver.np2012-09-133-16/+7700
| | | | | Obtained from: Chelsio MFC after: 1 week
* Deal with the case where a syncache entry added by the TOE driver isnp2012-08-212-0/+21
| | | | | | evicted from the syncache but a later syncache_expand succeeds because of syncookies. The TOE driver has to resort to more direct means to install its hooks in the socket in this case.
* Avoid a NULL pointer dereference.np2012-08-211-2/+2
|
* Cannot hold a mutex around vm_fault_quick_hold_pages, so don't. Tweaknp2012-08-211-12/+22
| | | | some comments while here.
* Minor cleanup: use bitwise ops instead of pointless wrappers aroundnp2012-08-216-125/+81
| | | | setbit/clrbit.
* Correctly handle the case where an inp has already been dropped by the timenp2012-08-211-12/+9
| | | | | | the TOE driver reports that an active open failed. toe_connect_failed is supposed to handle this but it should be provided the inpcb instead of the tcpcb which may no longer be around.
* Support for TCP DDP (Direct Data Placement) in the T4 TOE module.np2012-08-179-51/+1485
| | | | | | | | | | | | Basically, this is automatic rx zero copy when feasible. TCP payload is DMA'd directly into the userspace buffer described by the uio submitted in soreceive by an application. - Works with sockets that are being handled by the TCP offload engine of a T4 chip (you need t4_tom.ko module loaded after cxgbe, and an "ifconfig +toe" on the cxgbe interface). - Does not require any modification to the application. - Not enabled by default. Use hw.t4nex.<X>.toe.ddp="1" to enable it.
* Initialize various DDP parameters in the main cxgbe(4) driver:np2012-08-163-12/+19
| | | | | | | | | | | | | | | | - Setup multiple DDP page sizes. When the driver attempts DDP it will try to combine physically contiguous pages into regions of these sizes. - Set the indicate size such that the payload carried in the indicate can be copied in the header mbuf (and the 16K rx buffer can be recycled). - Set DDP threshold to the max payload that the chip will coalesce and deliver to the driver (this is ~16K by default, which is also why the offload rx queue is backed by 16K buffers). If the chip is able to coalesce up to the max it's allowed to, it's a good sign that the peer is transmitting in bulk without any TCP PSH. MFC after: 2 weeks
* Make room for DDP page pods in the default configuration profile. Whilenp2012-08-161-3/+4
| | | | | | here, bump up the L2 table's size to 4K entries. MFC after: 2 weeks
* Add a routine (t4_set_tcb_field) to update arbitrary parts of a hardwarenp2012-08-164-5/+60
| | | | | | | | | TCB. Filters are programmed by modifying the TCB too (via a different routine) and the reply to any TCB update is delivered via a CPL_SET_TCB_RPL. Figure out whether the reply is for a filter-write or something else and route it appropriately. MFC after: 2 weeks
* Allow for a different handler for each type of firmware message.np2012-08-164-11/+52
| | | | MFC after: 2 weeks
* The size of the buffers in an Ethernet freelist has to be higher than thenp2012-08-151-5/+15
| | | | | | | | | | interface's MTU. Initialize such freelists with correct values. This wasn't a problem for common MTUs (1500 and 9000) as the buffers (2048 and 9216 in size) happened to have enough spare room. I ran into it when playing around with unusual MTUs. MFC after: 2 weeks
* if_iqdrops should include frames truncated within the chip.np2012-08-141-1/+2
| | | | MFC after: 2 weeks
* Convert some fixed parameters to tunables (with reasonable defaultnp2012-08-142-15/+94
| | | | | | | | | | | | values). - cong_drop specifies what to do on congestion: nothing, backpressure, or drop. - fl_pktshift specifies the padding before Ethernet payload. - fl_pad specifies the boundary upto which to pad Ethernet payload. - spg_len controls the length of the status page. MFC after: 2 weeks
* In sys/dev/cxgbe/firmware/t4fw_interface.h, change the enumdim2012-08-061-1/+1
| | | | | | | | 'fw_hdr_intfver' into an anonymous enum, which avoids a clang 3.2 warning about all the enum values being the same value. Reviewed by: np MFC after: 1 week
* Fix a bug in code that calculates the number of the first interruptnp2012-07-091-3/+5
| | | | | | | vector for a port. This affected the gigabit ports of T422 cards (the ones with 2x10G ports and 2x1G ports). MFC after: will check with re@
* Fix inverted test that resulted in incorrect multicast hw programming.np2012-07-031-1/+1
|
* Instruct the firmware not to provision resources for TCP offload if thenp2012-07-021-1/+7
| | | | | kernel is being built without TCP_OFFLOAD. But never override toecaps_allowed if it has been set manually.
* - Assign (don't OR) the CSUM_XXX bits to csum_flags in the rx checksum code.np2012-06-302-5/+5
| | | | | - Fix TSO/TSO4 mixup. - Add IFCAP_LINKSTATE to the available/enabled capabilities.
* cxgbe(4): support for IPv6 TSO and LRO.np2012-06-294-18/+60
| | | | Submitted by: bz (this is a modified version of that patch)
* cxgbe(4): support for IPv6 hardware checksumming (rx and tx).np2012-06-292-26/+57
|
* Allow cxgbe(4) running within a VM to attach to its devices that have beennp2012-06-261-19/+40
| | | | | | | | | | | | | | exported via PCI passthrough. - Do not check for a specific physical function (PF) before claiming a device. Different PFs have different device-ids so this check is redundant anyway. - Obtain the PF# from the WHOAMI register instead of pci_get_function(). - Setup the memory windows using the real BAR0 address, not what the VM says it is. Obtained from: Chelsio Communications
* Better way to determine the status page length and rx pad boundary.np2012-06-231-12/+17
|
* Do not allocate extra vectors when adapter is not TOEnp2012-06-222-8/+13
| | | | | | capable (or toecaps have been disallowed by the user). + one very minor unrelated cleanup in t4_sge.c
* Do not read registers with read side effects while performing a registernp2012-06-221-9/+11
| | | | dump for cxgbetool.
* cxgbe(4): update to firmware interface 1.5.2.0; updates to shared code.np2012-06-229-541/+2743
|
* - Updated TOE support in the kernel.np2012-06-1914-719/+4840
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Stateful TCP offload drivers for Terminator 3 and 4 (T3 and T4) ASICs. These are available as t3_tom and t4_tom modules that augment cxgb(4) and cxgbe(4) respectively. The cxgb/cxgbe drivers continue to work as usual with or without these extra features. - iWARP driver for Terminator 3 ASIC (kernel verbs). T4 iWARP in the works and will follow soon. Build-tested with make universe. 30s overview ============ What interfaces support TCP offload? Look for TOE4 and/or TOE6 in the capabilities of an interface: # ifconfig -m | grep TOE Enable/disable TCP offload on an interface (just like any other ifnet capability): # ifconfig cxgbe0 toe # ifconfig cxgbe0 -toe Which connections are offloaded? Look for toe4 and/or toe6 in the output of netstat and sockstat: # netstat -np tcp | grep toe # sockstat -46c | grep toe Reviewed by: bz, gnn Sponsored by: Chelsio communications. MFC after: ~3 months (after 9.1, and after ensuring MFC is feasible)
* MFp4 bz_ipv6_fast:bz2012-05-241-0/+1
| | | | | | | | | | | | | | | | | | | | | | Significantly update tcp_lro for mostly two things: 1) introduce basic support for IPv6 without extension headers. 2) try hard to also get the incremental checksum updates right, especially also in the IPv4 case for the IP and TCP header. Move variables around for better locality, factor things out into functions, allow checksum updates to be compiled out, ... Leave a few comments on further things to look at in the future, though that is not the full list. Update drivers with appropriate #includes as needed for IPv6 data type in LRO. Sponsored by: The FreeBSD Foundation Sponsored by: iXsystems Reviewed by: gnn (as part of the whole) MFC After: 3 days
* Change the default to not use packet counters to generate rx interrupts.np2012-04-302-5/+8
| | | | | | | | Rely solely on the timer based mechanism. Update man page to reflect this change. MFC after: 1 week
* Make sure that the firmware version is available innp2012-04-301-5/+11
| | | | | | | dev.t4nex.X.firmware_version even if the driver fails to attach properly. At least it'll be easy to tell what we're dealing with. MFC after: 1 week
* Use the non-sleeping variang of t4_wr_mbox in code that can be callednp2012-02-131-1/+1
| | | | | | with locks held. MFC after: 1 day
* Program the MAC exact match table in batches of 7 addresses atnp2012-02-081-11/+42
| | | | | | | a time when possible. This is more efficient than one at a time. Submitted by: gnn MFC after: 3 days
* Acquire the adapter lock before updating fields of the filter structure.np2012-02-071-10/+10
| | | | | Submitted by: gnn (different version) MFC after: 3 days
* Remove if_start from cxgb and cxgbe.np2012-02-071-21/+0
| | | | | Submitted by: jhb MFC after: 3 days
* cxgbe: reduce diffs with other branches.np2012-02-074-0/+28
| | | | | | Will help future MFCs from HEAD. MFC after: 3 days
* Many updates to cxgbe(4)np2011-12-1614-1831/+6153
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - Device configuration via plain text config file. Also able to operate when not attached to the chip as the master driver. - Generic "work request" queue that serves as the base for both ctrl and ofld tx queues. - Generic interrupt handler routine that can process any event on any kind of ingress queue (via a dispatch table). - A couple of new driver ioctls. cxgbetool can now install a firmware to the card ("loadfw" command) and can read the card's memory ("memdump" and "tcb" commands). - Lots of assorted information within dev.t4nex.X.misc.* This is primarily for debugging and won't show up in sysctl -a. - Code to manage the L2 tables on the chip. - Updates to cxgbe(4) man page to go with the tunables that have changed. - Updates to the shared code in common/ - Updates to the driver-firmware interface (now at fw 1.4.16.0) MFC after: 1 month
* Do not clobber the ingress queue's congestion setting.np2011-12-141-1/+1
| | | | MFC after: 1 month
* Do not define bool/true/false if the symbols already exist.mdf2011-12-121-0/+2
| | | | | MFC after: 2 weeks Sponsored by: Isilon Systems, LLC
* - There's no need to overwrite the default device method with the defaultmarius2011-11-221-5/+1
| | | | | | | | | | one. Interestingly, these are actually the default for quite some time (bus_generic_driver_added(9) since r52045 and bus_generic_print_child(9) since r52045) but even recently added device drivers do this unnecessarily. Discussed with: jhb, marcel - While at it, use DEVMETHOD_END. Discussed with: jhb - Also while at it, use __FBSDID.
* Mark all SYSCTL_NODEs static that have no corresponding SYSCTL_DECLs.ed2011-11-071-1/+2
| | | | | | The SYSCTL_NODE macro defines a list that stores all child-elements of that node. If there's no SYSCTL_DECL macro anywhere else, there's no reason why it shouldn't be static.
* - driver ioctl to get SGE context for any given queue.np2011-06-114-1/+85
| | | | | | - sysctls to display the context id, cidx, and pidx of all kinds of queues. MFC after: 3 days
* Cause backpressure (instead of dropping frames) on congestion.np2011-06-041-0/+2
| | | | MFC after: 3 days
* Allow lazy fill up of freelists.np2011-06-042-1/+10
| | | | MFC after: 3 days
* Provide hit-count with rest of the information about a filter.np2011-06-011-1/+19
| | | | MFC after: 1 week
* Firmware device log.np2011-05-311-0/+151
| | | | | | # sysctl dev.t4nex.0.devlog MFC after: mdf's sysctl+sbuf changes are MFC'd
* Update to firmware interface 1.3.10np2011-05-303-6/+235
| | | | MFC after: 1 week
OpenPOWER on IntegriCloud