xref: /freebsd/share/man/man4/sfxge.4 (revision 22cf89c938886d14f5796fc49f9f020c23ea8eaf)
1.\" Copyright (c) 2011-2016 Solarflare Communications Inc.
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions are met:
6.\"
7.\" 1. Redistributions of source code must retain the above copyright notice,
8.\"    this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright notice,
10.\"    this list of conditions and the following disclaimer in the documentation
11.\"    and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
14.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
15.\" THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
16.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
17.\" CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
18.\" EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
19.\" PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
20.\" OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
21.\" WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
22.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
23.\" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24.\"
25.\" The views and conclusions contained in the software and documentation are
26.\" those of the authors and should not be interpreted as representing official
27.\" policies, either expressed or implied, of the FreeBSD Project.
28.\"
29.Dd February 22, 2015
30.Dt SFXGE 4
31.Os
32.Sh NAME
33.Nm sfxge
34.Nd "Solarflare 10Gb Ethernet adapter driver"
35.Sh SYNOPSIS
36To compile this driver into the kernel,
37place the following lines in your
38kernel configuration file:
39.Bd -ragged -offset indent
40.Cd "device sfxge"
41.Ed
42.Pp
43To load the driver as a
44module at boot time, place the following line in
45.Xr loader.conf 5 :
46.Bd -literal -offset indent
47sfxge_load="YES"
48.Ed
49.Sh DESCRIPTION
50The
51.Nm
52driver provides support for 10Gb Ethernet adapters based on
53Solarflare SFC9000 and XtremeScale X2 family controllers.
54The driver supports jumbo
55frames, transmit/receive checksum offload, TCP Segmentation Offload
56(TSO), Large Receive Offload (LRO), VLAN checksum offload, VLAN TSO,
57and Receive Side Scaling (RSS) using MSI-X interrupts.
58.Pp
59The driver allocates 1 receive queue, transmit queue, event queue and
60IRQ per CPU up to a maximum of 64.
61IRQ affinities should be spread out using
62.Xr cpuset 1 .
63Interrupt moderation may be controlled through the sysctl
64.Va dev.sfxge.%d.int_mod
65(units are microseconds).
66.Pp
67For more information on configuring this device, see
68.Xr ifconfig 8 .
69.Pp
70A large number of MAC, PHY and data path statistics are available
71under the sysctl
72.Va dev.sfxge.%d.stats .
73The adapter's VPD
74fields including its serial number are available under the sysctl
75.Va dev.sfxge.%d.vpd .
76.Sh HARDWARE
77The
78.Nm
79driver supports all 10Gb Ethernet adapters based on Solarflare SFC9000
80family controllers.
81.Sh LOADER TUNABLES
82Tunables can be set at the
83.Xr loader 8
84prompt before booting the kernel or stored in
85.Xr loader.conf 5 .
86Actual values can be obtained using
87.Xr sysctl 8 .
88.Bl -tag -width indent
89.It Va hw.sfxge.rx_ring
90The maximum number of descriptors in a receive queue ring.
91Supported values are: 512, 1024, 2048 and 4096.
92.It Va hw.sfxge.tx_ring
93The maximum number of descriptors in a transmit queue ring.
94Supported values are: 512, 1024, 2048 and 4096.
95.It Va hw.sfxge.tx_dpl_get_max
96The maximum length of the deferred packet
97.Dq get-list
98for queued transmit packets (TCP and non-TCP), used only if the transmit
99queue lock can be acquired.
100If a packet is dropped, the
101.Va tx_get_overflow
102counter is incremented and the local sender receives ENOBUFS.
103The value must be greater than 0.
104.It Va hw.sfxge.tx_dpl_get_non_tcp_max
105The maximum number of non-TCP packets in the deferred packet
106.Dq get-list
107, used only if the transmit queue lock can be acquired.
108If a packet is dropped, the
109.Va tx_get_non_tcp_overflow
110counter is incremented and the local sender receives ENOBUFS.
111The value must be greater than 0.
112.It Va hw.sfxge.tx_dpl_put_max
113The maximum length of the deferred packet
114.Dq put-list
115for queued transmit
116packets, used if the transmit queue lock cannot be acquired.
117If a packet is dropped, the
118.Va tx_put_overflow
119counter is incremented and the local sender receives ENOBUFS.
120The value must be greater than or equal to 0.
121.It Va hw.sfxge.tso_fw_assisted
122Bitmask to enable/disable usage of FW-assisted TSO version if supported
123by NIC firmware.
124FATSOv1 (bit 0) and FATSOv2 (bit 1) are supported.
125All enabled by default.
126.It Va hw.sfxge.N.max_rss_channels
127The maximum number of allocated RSS channels for the Nth adapter.
128If set to 0 or unset, the number of channels is determined by the number
129of CPU cores.
130.It Va hw.sfxge.lro.table_size
131Size of the LRO hash table.
132Must be a power of 2.
133A larger table means we can accelerate a larger number of streams.
134.It Va hw.sfxge.lro.chain_max
135The maximum length of a hash chain.
136If chains get too long then the lookup time increases and may exceed
137the benefit of LRO.
138.It Va hw.sfxge.lro.idle_ticks
139The maximum time (in ticks) that a connection can be idle before it's LRO
140state is discarded.
141.It Va hw.sfxge.lro.slow_start_packets
142Number of packets with payload that must arrive in-order before a connection
143is eligible for LRO.
144The idea is we should avoid coalescing segments when the sender is in
145slow-start because reducing the ACK rate can damage performance.
146.It Va hw.sfxge.lro.loss_packets
147Number of packets with payload that must arrive in-order following loss
148before a connection is eligible for LRO.
149The idea is we should avoid coalescing segments when the sender is recovering
150from loss, because reducing the ACK rate can damage performance.
151.It Va hw.sfxge.mcdi_logging
152Enable logging of MCDI protocol messages  (only available if enabled at compile-time).
153.It Va hw.sfxge.N.mcdi_logging
154Enable or disable logging of MCDI protocol messages on a per-port basis.
155The default for each port will be the value of
156.Va hw.sfxge.mcdi_logging.
157The logging may also be enabled or disabled after the driver is loaded using the sysctl
158.Va dev.sfxge.%d.mcdi_logging.
159.It Va hw.sfxge.stats_update_period_ms
160Period in milliseconds to refresh interface statistics from hardware.
161The accepted range is 0 to 65535, the default is 1000 (1 second).
162Use zero value to disable periodic statistics update.
163Supported on SFN8xxx series adapters with firmware v6.2.1.1033 and later and
164SFN5xxx, SFN6xxx and XtremeScale X2xxx series adapters.
165SFN7xxx series adapters and sfN8xxx series with earlier firmware use a
166fixed 1000 milliseconds statistics update period.
167The period may also be changed after the driver is loaded using the sysctl
168.Va dev.sfxge.%d.stats_update_period_ms .
169.El
170.Sh SUPPORT
171For general information and support,
172go to the Solarflare support website at:
173.Pa https://support.solarflare.com .
174.Sh SEE ALSO
175.Xr cpuset 1 ,
176.Xr arp 4 ,
177.Xr netintro 4 ,
178.Xr ng_ether 4 ,
179.Xr vlan 4 ,
180.Xr ifconfig 8
181.Sh AUTHORS
182The
183.Nm
184driver was written by
185.An Philip Paeps
186and
187.An Solarflare Communications, Inc.
188