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