1.. SPDX-License-Identifier: GPL-2.0+ 2 3===================================== 4Meta Platforms Host Network Interface 5===================================== 6 7Firmware Versions 8----------------- 9 10fbnic has three components stored on the flash which are provided in one PLDM 11image: 12 131. fw - The control firmware used to view and modify firmware settings, request 14 firmware actions, and retrieve firmware counters outside of the data path. 15 This is the firmware which fbnic_fw.c interacts with. 162. bootloader - The firmware which validate firmware security and control basic 17 operations including loading and updating the firmware. This is also known 18 as the cmrt firmware. 193. undi - This is the UEFI driver which is based on the Linux driver. 20 21fbnic stores two copies of these three components on flash. This allows fbnic 22to fall back to an older version of firmware automatically in case firmware 23fails to boot. Version information for both is provided as running and stored. 24The undi is only provided in stored as it is not actively running once the Linux 25driver takes over. 26 27devlink dev info provides version information for all three components. In 28addition to the version the hg commit hash of the build is included as a 29separate entry. 30 31Statistics 32---------- 33 34TX MAC Interface 35~~~~~~~~~~~~~~~~ 36 37 - ``ptp_illegal_req``: packets sent to the NIC with PTP request bit set but routed to BMC/FW 38 - ``ptp_good_ts``: packets successfully routed to MAC with PTP request bit set 39 - ``ptp_bad_ts``: packets destined for MAC with PTP request bit set but aborted because of some error (e.g., DMA read error) 40 41TX Extension (TEI) Interface (TTI) 42~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 43 44 - ``tti_cm_drop``: control messages dropped at the TX Extension (TEI) Interface because of credit starvation 45 - ``tti_frame_drop``: packets dropped at the TX Extension (TEI) Interface because of credit starvation 46 - ``tti_tbi_drop``: packets dropped at the TX BMC Interface (TBI) because of credit starvation 47 48RXB (RX Buffer) Enqueue 49~~~~~~~~~~~~~~~~~~~~~~~ 50 51 - ``rxb_integrity_err[i]``: frames enqueued with integrity errors (e.g., multi-bit ECC errors) on RXB input i 52 - ``rxb_mac_err[i]``: frames enqueued with MAC end-of-frame errors (e.g., bad FCS) on RXB input i 53 - ``rxb_parser_err[i]``: frames experienced RPC parser errors 54 - ``rxb_frm_err[i]``: frames experienced signaling errors (e.g., missing end-of-packet/start-of-packet) on RXB input i 55 - ``rxb_drbo[i]_frames``: frames received at RXB input i 56 - ``rxb_drbo[i]_bytes``: bytes received at RXB input i 57 58RXB (RX Buffer) FIFO 59~~~~~~~~~~~~~~~~~~~~ 60 61 - ``rxb_fifo[i]_drop``: transitions into the drop state on RXB pool i 62 - ``rxb_fifo[i]_dropped_frames``: frames dropped on RXB pool i 63 - ``rxb_fifo[i]_ecn``: transitions into the ECN mark state on RXB pool i 64 - ``rxb_fifo[i]_level``: current occupancy of RXB pool i 65 66RXB (RX Buffer) Dequeue 67~~~~~~~~~~~~~~~~~~~~~~~ 68 69 - ``rxb_intf[i]_frames``: frames sent to the output i 70 - ``rxb_intf[i]_bytes``: bytes sent to the output i 71 - ``rxb_pbuf[i]_frames``: frames sent to output i from the perspective of internal packet buffer 72 - ``rxb_pbuf[i]_bytes``: bytes sent to output i from the perspective of internal packet buffer 73 74RPC (Rx parser) 75~~~~~~~~~~~~~~~ 76 77 - ``rpc_unkn_etype``: frames containing unknown EtherType 78 - ``rpc_unkn_ext_hdr``: frames containing unknown IPv6 extension header 79 - ``rpc_ipv4_frag``: frames containing IPv4 fragment 80 - ``rpc_ipv6_frag``: frames containing IPv6 fragment 81 - ``rpc_ipv4_esp``: frames with IPv4 ESP encapsulation 82 - ``rpc_ipv6_esp``: frames with IPv6 ESP encapsulation 83 - ``rpc_tcp_opt_err``: frames which encountered TCP option parsing error 84 - ``rpc_out_of_hdr_err``: frames where header was larger than parsable region 85 - ``ovr_size_err``: oversized frames 86 87Hardware Queues 88~~~~~~~~~~~~~~~ 89 901. RX DMA Engine: 91 92 - ``rde_[i]_pkt_err``: packets with MAC EOP, RPC parser, RXB truncation, or RDE frame truncation errors. These error are flagged in the packet metadata because of cut-through support but the actual drop happens once PCIE/RDE is reached. 93 - ``rde_[i]_pkt_cq_drop``: packets dropped because RCQ is full 94 - ``rde_[i]_pkt_bdq_drop``: packets dropped because HPQ or PPQ ran out of host buffer 95 96PCIe 97~~~~ 98 99The fbnic driver exposes PCIe hardware performance statistics through debugfs 100(``pcie_stats``). These statistics provide insights into PCIe transaction 101behavior and potential performance bottlenecks. 102 1031. PCIe Transaction Counters: 104 105 These counters track PCIe transaction activity: 106 - ``pcie_ob_rd_tlp``: Outbound read Transaction Layer Packets count 107 - ``pcie_ob_rd_dword``: DWORDs transferred in outbound read transactions 108 - ``pcie_ob_wr_tlp``: Outbound write Transaction Layer Packets count 109 - ``pcie_ob_wr_dword``: DWORDs transferred in outbound write 110 transactions 111 - ``pcie_ob_cpl_tlp``: Outbound completion TLP count 112 - ``pcie_ob_cpl_dword``: DWORDs transferred in outbound completion TLPs 113 1142. PCIe Resource Monitoring: 115 116 These counters indicate PCIe resource exhaustion events: 117 - ``pcie_ob_rd_no_tag``: Read requests dropped due to tag unavailability 118 - ``pcie_ob_rd_no_cpl_cred``: Read requests dropped due to completion 119 credit exhaustion 120 - ``pcie_ob_rd_no_np_cred``: Read requests dropped due to non-posted 121 credit exhaustion 122