git: 215fbb3974ab - stable/15 - ixl: verify flowid is valid before setting rsstype & flowid
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 29 Oct 2026 06:57:11 UTC
The branch stable/15 has been updated by kbowling:
URL: https://cgit.FreeBSD.org/src/commit/?id=215fbb3974ab218d943a973aef0c93cdc19f7e10
commit 215fbb3974ab218d943a973aef0c93cdc19f7e10
Author: Andrew Gallatin <gallatin@FreeBSD.org>
AuthorDate: 2026-01-05 17:02:23 +0000
Commit: Kevin Bowling <kbowling@FreeBSD.org>
CommitDate: 2026-10-29 06:54:44 +0000
ixl: verify flowid is valid before setting rsstype & flowid
According to section 8.3.2.2.1 of the XL710 datasheet,
FLTSTAT indicates if RSS hashing was used (or flow director
or nothing) to arrive at the flowid it is reporting.
We need to check this before reporting the flowid and setting the
rss type. Not checking this allows invalid flowids (0s) to be
reported for some TCP traffic (it seems to mostly impact incoming
connections). This leads to the inp flowid being 0, and egress
traffic being unbalanced (going to tx queue 0, and NIC 0 of an
lacp bundle).
Differential Revision: https://reviews.freebsd.org/D54442
Reviewed by: adrian, kbowling
Sponsored by: Netflix
(cherry picked from commit ac1cd655f647cfd8e8d8c08da00f41abfce212a1)
---
sys/dev/ixl/ixl_txrx.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/sys/dev/ixl/ixl_txrx.c b/sys/dev/ixl/ixl_txrx.c
index d015a93b5360..7ce1c24c814a 100644
--- a/sys/dev/ixl/ixl_txrx.c
+++ b/sys/dev/ixl/ixl_txrx.c
@@ -648,7 +648,7 @@ ixl_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri)
struct ixl_rx_queue *que = &vsi->rx_queues[ri->iri_qsidx];
struct rx_ring *rxr = &que->rxr;
union i40e_rx_desc *cur;
- u32 status, error;
+ u32 status, error, fltstat;
u16 plen;
u64 qword;
u8 ptype;
@@ -704,8 +704,12 @@ ixl_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri)
if ((scctx->isc_capenable & IFCAP_RXCSUM) != 0)
rxr->csum_errs += ixl_rx_checksum(ri, status, error, ptype);
- ri->iri_flowid = le32toh(cur->wb.qword0.hi_dword.rss);
- ri->iri_rsstype = ixl_ptype_to_hash(ptype);
+ fltstat = (status >> I40E_RX_DESC_STATUS_FLTSTAT_SHIFT);
+ if ((fltstat & I40E_RX_DESC_FLTSTAT_RSS_HASH) ==
+ I40E_RX_DESC_FLTSTAT_RSS_HASH) {
+ ri->iri_flowid = le32toh(cur->wb.qword0.hi_dword.rss);
+ ri->iri_rsstype = ixl_ptype_to_hash(ptype);
+ }
if (status & (1 << I40E_RX_DESC_STATUS_L2TAG1P_SHIFT)) {
ri->iri_vtag = le16toh(cur->wb.qword0.lo_dword.l2tag1);
ri->iri_flags |= M_VLANTAG;