1d933e97fSStephen Hurd.\" Copyright (c) 2016 Broadcom, All Rights Reserved. 2d933e97fSStephen Hurd.\" The term Broadcom refers to Broadcom Limited and/or its subsidiaries 3d933e97fSStephen Hurd.\" 4d933e97fSStephen Hurd.\" Redistribution and use in source and binary forms, with or without 5d933e97fSStephen Hurd.\" modification, are permitted provided that the following conditions 6d933e97fSStephen Hurd.\" are met: 7d933e97fSStephen Hurd.\" 8d933e97fSStephen Hurd.\" 1. Redistributions of source code must retain the above copyright 9d933e97fSStephen Hurd.\" notice, this list of conditions and the following disclaimer. 10d933e97fSStephen Hurd.\" 2. Redistributions in binary form must reproduce the above copyright 11d933e97fSStephen Hurd.\" notice, this list of conditions and the following disclaimer in the 12d933e97fSStephen Hurd.\" documentation and/or other materials provided with the distribution. 13d933e97fSStephen Hurd.\" 14d933e97fSStephen Hurd.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS' 15d933e97fSStephen Hurd.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 16d933e97fSStephen Hurd.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 17d933e97fSStephen Hurd.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 18d933e97fSStephen Hurd.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 19d933e97fSStephen Hurd.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 20d933e97fSStephen Hurd.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 21d933e97fSStephen Hurd.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 22d933e97fSStephen Hurd.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 23d933e97fSStephen Hurd.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 24d933e97fSStephen Hurd.\" THE POSSIBILITY OF SUCH DAMAGE. 25d933e97fSStephen Hurd.\" 26d933e97fSStephen Hurd.\" $FreeBSD$ 27d933e97fSStephen Hurd.\" 28*c75f49f7SKonstantin Belousov.Dd January 30, 2019 29d933e97fSStephen Hurd.Dt BNXT 4 30d933e97fSStephen Hurd.Os 31d933e97fSStephen Hurd.Sh NAME 32d933e97fSStephen Hurd.Nm bnxt 33d933e97fSStephen Hurd.Nd "Broadcom NetXtreme-C/NetXtreme-E Family Ethernet driver" 34d933e97fSStephen Hurd.Sh SYNOPSIS 35d933e97fSStephen HurdTo compile this driver into the kernel, 36d933e97fSStephen Hurdplace the following lines in your 37d933e97fSStephen Hurdkernel configuration file: 38d933e97fSStephen Hurd.Bd -ragged -offset indent 39*c75f49f7SKonstantin Belousov.Cd "device iflib" 40d933e97fSStephen Hurd.Cd "device bnxt" 41d933e97fSStephen Hurd.Ed 42d933e97fSStephen Hurd.Pp 43d933e97fSStephen HurdAlternatively, to load the driver as a 44d933e97fSStephen Hurdmodule at boot time, place the following line in 45d933e97fSStephen Hurd.Xr loader.conf 5 : 46d933e97fSStephen Hurd.Bd -literal -offset indent 47d933e97fSStephen Hurdif_bnxt_load="YES" 48d933e97fSStephen Hurd.Ed 49d933e97fSStephen Hurd.Sh DESCRIPTION 50d933e97fSStephen HurdThe 51d933e97fSStephen Hurd.Nm 52d933e97fSStephen Hurddriver provides support for various NICs based on the Broadcom BCM57301/2/4, 53d933e97fSStephen Hurdand BCM57402/4/6 Ethernet controller chips. 54d933e97fSStephen Hurd.Pp 55d933e97fSStephen HurdFor more information on configuring this device, see 56d933e97fSStephen Hurd.Xr ifconfig 8 . 57d933e97fSStephen Hurd.Sh HARDWARE 58d933e97fSStephen HurdThe 59d933e97fSStephen Hurd.Nm 60d933e97fSStephen Hurddriver provides support for various NICs based on the Broadcom NetXtreme-C and 61d933e97fSStephen HurdNetXtreme-E families of Gigabit Ethernet controller chips, including the 62d933e97fSStephen Hurdfollowing: 63d933e97fSStephen Hurd.Pp 64d933e97fSStephen Hurd.Bl -bullet -compact 65d933e97fSStephen Hurd.It 66d933e97fSStephen HurdBroadcom BCM57301 NetXtreme-C 10Gb Ethernet Controller 67d933e97fSStephen Hurd.It 68d933e97fSStephen HurdBroadcom BCM57302 NetXtreme-C 10Gb/25Gb Ethernet Controller 69d933e97fSStephen Hurd.It 70d933e97fSStephen HurdBroadcom BCM57304 NetXtreme-C 10Gb/25Gb/40Gb/50Gb Ethernet Controller 71d933e97fSStephen Hurd.It 72cb980c3dSStephen HurdBroadcom BCM57304 NetXtreme-C Ethernet Virtual Function 73cb980c3dSStephen Hurd.It 74cb980c3dSStephen HurdBroadcom BCM57314 NetXtreme-C Ethernet Virtual Function 75cb980c3dSStephen Hurd.It 76d933e97fSStephen HurdBroadcom BCM57402 NetXtreme-E 10Gb Ethernet Controller 77d933e97fSStephen Hurd.It 78cb980c3dSStephen HurdBroadcom BCM57402 NetXtreme-E Ethernet Partition 79cb980c3dSStephen Hurd.It 80d933e97fSStephen HurdBroadcom BCM57404 NetXtreme-E 10Gb/25Gb Ethernet Controller 81d933e97fSStephen Hurd.It 82cb980c3dSStephen HurdBroadcom BCM57404 NetXtreme-E Ethernet Virtual Function 83d933e97fSStephen Hurd.It 84d933e97fSStephen HurdBroadcom BCM57404 NetXtreme-E Partition 85d933e97fSStephen Hurd.It 86cb980c3dSStephen HurdBroadcom BCM57406 NetXtreme-E 10GBASE-T Ethernet Controller 87cb980c3dSStephen Hurd.It 88d933e97fSStephen HurdBroadcom BCM57406 NetXtreme-E Partition 89d933e97fSStephen Hurd.It 90cb980c3dSStephen HurdBroadcom BCM57407 NetXtreme-E 10GBase-T Ethernet Controller 91cb980c3dSStephen Hurd.It 92d933e97fSStephen HurdBroadcom BCM57407 NetXtreme-E 25Gb Ethernet Controller 93d933e97fSStephen Hurd.It 94cb980c3dSStephen HurdBroadcom BCM57407 NetXtreme-E Partition 95d933e97fSStephen Hurd.It 96cb980c3dSStephen HurdBroadcom BCM57412 NetXtreme-E Partition 97cb980c3dSStephen Hurd.It 98cb980c3dSStephen HurdBroadcom BCM57414 NetXtreme-E Ethernet Virtual Function 99cb980c3dSStephen Hurd.It 100cb980c3dSStephen HurdBroadcom BCM57414 NetXtreme-E Partition 101cb980c3dSStephen Hurd.It 102cb980c3dSStephen HurdBroadcom BCM57416 NetXtreme-E Partition 103cb980c3dSStephen Hurd.It 104cb980c3dSStephen HurdBroadcom BCM57417 NetXtreme-E Ethernet Partition 105cb980c3dSStephen Hurd.It 106cb980c3dSStephen HurdBroadcom BCM57454 NetXtreme-E 10Gb/25Gb/40Gb/50Gb/100Gb Ethernet 107d933e97fSStephen Hurd.El 108d933e97fSStephen Hurd.Sh SYSCTL VARIABLES 109d933e97fSStephen HurdThese variables must be set before loading the driver, either via 110d933e97fSStephen Hurd.Xr loader.conf 5 111d933e97fSStephen Hurdor through the use of 112d933e97fSStephen Hurd.Xr kenv 1 . 113d933e97fSStephen HurdThese are provided by the 1147049547cSStephen Hurd.Xr iflib 4 115d933e97fSStephen Hurdframework, and might be better documented there. 116d933e97fSStephen Hurd.Bl -tag -width indent 117d933e97fSStephen Hurd.It Va dev.bnxt.X.iflib.override_nrxds 118d933e97fSStephen HurdOverride the number of RX descriptors for each queue. 119d933e97fSStephen HurdThe value is a comma separated list of three positive integers: the size of the 120d933e97fSStephen Hurdcompletion ring, 121d933e97fSStephen Hurdthe size of the receive ring, and the size of the aggregation ring respectively. 122d933e97fSStephen HurdThe completion ring should be at least the size of the aggregation ring plus 123d933e97fSStephen Hurdfour times the size of the receive ring. 124d933e97fSStephen HurdThese numbers must be powers of two, and zero means to use the default. 125d933e97fSStephen HurdDefaults to 0,0,0. 126d933e97fSStephen Hurd.It Va dev.bnxt.X.iflib.override_ntxds 127d933e97fSStephen HurdOverride the number of TX descriptors for each queue. 128d933e97fSStephen HurdThe value is a comma separated list of two positive integers: the size of the 129d933e97fSStephen Hurdcompletion ring, and the size of the transmit ring respectively. 130d933e97fSStephen HurdThe completion ring should be at least twice the size of the transmit ring. 131d933e97fSStephen HurdThese numbers must be powers of two, and zero means to use the default. 132d933e97fSStephen HurdDefaults to 0,0. 133d933e97fSStephen Hurd.It Va override_qs_enable 134d933e97fSStephen HurdWhen set, allows the number of transmit and receive queues to be different. 135d933e97fSStephen HurdIf not set, the lower of the number of TX or RX queues will be used for both. 136d933e97fSStephen Hurd.It Va override_nrxqs 137d933e97fSStephen HurdSet the number of RX queues. 138d933e97fSStephen HurdIf zero, the number of RX queues is derived from the number of cores on the 139d933e97fSStephen Hurdsocket connected to the controller. 140d933e97fSStephen HurdDefaults to 0. 141d933e97fSStephen Hurd.It Va override_ntxqs 142d933e97fSStephen HurdSet the number of TX queues. 143d933e97fSStephen HurdIf zero, the number of TX queues is derived from the number of cores on the 144d933e97fSStephen Hurdsocket connected to the controller. 145d933e97fSStephen Hurd.El 146d933e97fSStephen Hurd.Pp 147d933e97fSStephen HurdThese 148d933e97fSStephen Hurd.Xr sysctl 8 149d933e97fSStephen Hurdvariables can be changed at any time: 150d933e97fSStephen Hurd.Bl -tag -width indent 151d933e97fSStephen Hurd.It Va dev.bnxt.X.vlan_only 152d933e97fSStephen HurdRequire that incoming frames must have a VLAN tag on them that matches one that 153d933e97fSStephen Hurdis configured for the NIC. 154d933e97fSStephen HurdNormally, both frames that have a matching VLAN tag and frames that have no 155d933e97fSStephen HurdVLAN tag are accepted. 156d933e97fSStephen HurdDefaults to 0. 157d933e97fSStephen Hurd.It Va dev.bnxt.X.vlan_strip 158d933e97fSStephen HurdWhen non-zero the NIC strips VLAN tags on receive. 159d933e97fSStephen HurdDefaults to 0. 160d933e97fSStephen Hurd.It Va dev.bnxt.X.rx_stall 161d933e97fSStephen HurdEnable buffering rather than dropping frames when there are no available host 162d933e97fSStephen HurdRX buffers for DMA. 163d933e97fSStephen HurdDefaults to 0. 164d933e97fSStephen Hurd.It Va dev.bnxt.X.rss_type 165d933e97fSStephen HurdComma-separated list of RSS hash types to support. 166d933e97fSStephen HurdDefault is all types. 167d933e97fSStephen HurdDefaults to ipv4,tcp_ipv4,udp_ipv4,ipv6,tcp_ipv6,udp_ipv6. 168d933e97fSStephen Hurd.It Va dev.bnxt.X.rss_key 169d933e97fSStephen HurdCurrent RSS key. 170d933e97fSStephen HurdDefaults to a randomly generated value which is generated for each device 171d933e97fSStephen Hurdduring attach. 172d933e97fSStephen Hurd.It Va dev.bnxt.X.ver.hwrm_min_ver 173d933e97fSStephen HurdMinimum HWRM (HardWare Resource Manager) firmware API to support. 174d933e97fSStephen HurdIf the firmware implements an older version, a warning will be printed, and the 175d933e97fSStephen Hurdfirmware should be upgraded. 176d933e97fSStephen HurdDefaults to 1.2.2. 177d933e97fSStephen Hurd.El 178d933e97fSStephen Hurd.Pp 179d933e97fSStephen HurdThese 180d933e97fSStephen Hurd.Xr sysctl 8 181d933e97fSStephen Hurdvariables are read-only: 182d933e97fSStephen Hurd.Bl -tag -width indent 183d933e97fSStephen Hurd.It Va dev.bnxt.X.if_name 184d933e97fSStephen HurdCurrent interface name of the device. 185d933e97fSStephen HurdThis will normally be 186d933e97fSStephen Hurd.Va bnxtX , 187d933e97fSStephen Hurdbut this can be changed using 188d933e97fSStephen Hurd.Cm ifconfig name . 189443788c2SChristian BruefferThis sysctl allows correlating an interface with a child of 190443788c2SChristian Brueffer.Va dev.bnxt . 191d933e97fSStephen Hurd.It Va dev.bnxt.X.nvram.* 192d933e97fSStephen HurdInformation about the NVRAM device which contains the device firmware. 193d933e97fSStephen Hurd.It Va dev.bnxt.X.ver.* 194d933e97fSStephen HurdVersion-related information about the device and firmware: 195d933e97fSStephen Hurd.It Va dev.bnxt.X.ver.hwrm_if 196d933e97fSStephen HurdSupported HWRM API version of the currently running firmware. 197d933e97fSStephen Hurd.It Va dev.bnxt.X.ver.driver_hwrm_if 198d933e97fSStephen HurdHWRM API version the driver was built to support. 199d933e97fSStephen Hurd.It Va dev.bnxt.X.hwstats.* 200d933e97fSStephen HurdPer-queue statistics tracked by the hardware. 201cb980c3dSStephen Hurd.It Va dev.bnxt.X.hwstats.port_stats.* 202cb980c3dSStephen HurdPer-port statistics tracked by the hardware. 203d933e97fSStephen Hurd.It Va dev.bnxt.X.hwstats.rxq0.drop_pkts 204d933e97fSStephen HurdNumber of packets dropped by hardware on queue zero. 205d933e97fSStephen HurdThis number might seem high, but the count includes packets dropped due to 206d933e97fSStephen Hurdincorrect destination MAC, unsubscribed multicast address, and other normal 207d933e97fSStephen Hurdreasons to ignore Ethernet frames. 208cb980c3dSStephen Hurd.It Va dev.bnxt.X.hwstats.rxq0.tpa_* 209cb980c3dSStephen Hurdstatistics related to HW LRO. 210cb980c3dSStephen Hurd.It Va dev.bnxt.X.hw_lro.* 211cb980c3dSStephen HurdEnable / Disable HW LRO feature. Defaults to disable. 212cb980c3dSStephen HurdEnabling HW LRO could cause issues when forwarding is enabled on host. 213cb980c3dSStephen Hurd.It Va dev.bnxt.X.fc 214cb980c3dSStephen HurdEnable / Disable Flow Control feature. Defaults to Enable 215d933e97fSStephen Hurd.El 216d933e97fSStephen Hurd.Sh DIAGNOSTICS 217d933e97fSStephen Hurd.Bl -diag 218d933e97fSStephen Hurd.It "bnxt%d: %s command returned %s error." 219d933e97fSStephen HurdDevice firmware rejected a command from the driver. 220d933e97fSStephen HurdThere might be a driver/firmware HWRM API mismatch. 221443788c2SChristian Brueffer.It "bnxt%d: Timeout sending %s (timeout: %d) seq %d" 222d933e97fSStephen HurdDevice firmware unresponsive. 223d933e97fSStephen HurdA PCI device reset is likely needed. 224443788c2SChristian Brueffer.It "bnxt%d: Timeout sending %s (timeout: %d) msg {0x%x 0x%x} len:%d v: %d" 225d933e97fSStephen HurdPartial firmware response. 226d933e97fSStephen HurdA PCI device reset is likely needed. 227d933e97fSStephen Hurd.Pp 228d933e97fSStephen HurdAs of this writing, the system must be rebooted to initiate a PCI device reset. 229d933e97fSStephen Hurd.El 230d933e97fSStephen Hurd.Sh SEE ALSO 231d933e97fSStephen Hurd.Xr altq 4 , 232d933e97fSStephen Hurd.Xr arp 4 , 233443788c2SChristian Brueffer.Xr iflib 4 , 234d933e97fSStephen Hurd.Xr netintro 4 , 235d933e97fSStephen Hurd.Xr ng_ether 4 , 236d933e97fSStephen Hurd.Xr vlan 4 , 237443788c2SChristian Brueffer.Xr ifconfig 8 238d933e97fSStephen Hurd.Sh HISTORY 239d933e97fSStephen HurdThe 240d933e97fSStephen Hurd.Nm 241d933e97fSStephen Hurddevice driver first appeared in 2421e0358deSGlen Barber.Fx 11.1 . 243d933e97fSStephen Hurd.Sh AUTHORS 244443788c2SChristian Brueffer.An -nosplit 245d933e97fSStephen HurdThe 246d933e97fSStephen Hurd.Nm 247d933e97fSStephen Hurddriver was written by 248cb980c3dSStephen Hurd.An Jack Vogel Aq Mt jfvogel@gmail.com 249cb980c3dSStephen Hurdand 250cb980c3dSStephen Hurd.An Stephen Hurd Aq Mt shurd@freebsd.org , 251d933e97fSStephen Hurdand is currently maintained by 252cb980c3dSStephen Hurd.An Broadcom Limited Aq Mt freebsd.pdl@broadcom.com . 253