git: a571b56421b1 - stable/15 - ena: use newly exposed RSS hash key API rather than ad-hoc hashing
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 29 Oct 2026 06:35:13 UTC
The branch stable/15 has been updated by kbowling:
URL: https://cgit.FreeBSD.org/src/commit/?id=a571b56421b1f212a62d1a8b023e6f0cab150ef2
commit a571b56421b1f212a62d1a8b023e6f0cab150ef2
Author: Andrew Gallatin <gallatin@FreeBSD.org>
AuthorDate: 2025-11-22 14:29:34 +0000
Commit: Kevin Bowling <kbowling@FreeBSD.org>
CommitDate: 2026-10-29 06:26:40 +0000
ena: use newly exposed RSS hash key API rather than ad-hoc hashing
Differential Revision: https://reviews.freebsd.org/D53100
Reviewed by: akiyano_amazon.com
(cherry picked from commit 96cde0b9e6068cd4c3aaebd86764b34afec1b624)
---
sys/dev/ena/ena_datapath.c | 4 ----
sys/dev/ena/ena_rss.c | 2 --
sys/dev/ena/ena_rss.h | 2 --
3 files changed, 8 deletions(-)
diff --git a/sys/dev/ena/ena_datapath.c b/sys/dev/ena/ena_datapath.c
index 1fe1209a77d4..b58779e51fc3 100644
--- a/sys/dev/ena/ena_datapath.c
+++ b/sys/dev/ena/ena_datapath.c
@@ -34,9 +34,7 @@
#ifdef DEV_NETMAP
#include "ena_netmap.h"
#endif /* DEV_NETMAP */
-#ifdef RSS
#include <net/rss_config.h>
-#endif /* RSS */
#include <netinet6/ip6_var.h>
@@ -349,7 +347,6 @@ ena_rx_hash_mbuf(struct ena_ring *rx_ring, struct ena_com_rx_ctx *ena_rx_ctx,
if (likely(ENA_FLAG_ISSET(ENA_FLAG_RSS_ACTIVE, adapter))) {
mbuf->m_pkthdr.flowid = ena_rx_ctx->hash;
-#ifdef RSS
/*
* Hardware and software RSS are in agreement only when both are
* configured to Toeplitz algorithm. This driver configures
@@ -360,7 +357,6 @@ ena_rx_hash_mbuf(struct ena_ring *rx_ring, struct ena_com_rx_ctx *ena_rx_ctx,
M_HASHTYPE_SET(mbuf, M_HASHTYPE_OPAQUE_HASH);
return;
}
-#endif
if (ena_rx_ctx->frag &&
(ena_rx_ctx->l3_proto != ENA_ETH_IO_L3_PROTO_UNKNOWN)) {
diff --git a/sys/dev/ena/ena_rss.c b/sys/dev/ena/ena_rss.c
index b7706e33065d..88fb3c902f5d 100644
--- a/sys/dev/ena/ena_rss.c
+++ b/sys/dev/ena/ena_rss.c
@@ -125,7 +125,6 @@ ena_rss_init_default(struct ena_adapter *adapter)
}
-#ifdef RSS
uint8_t rss_algo = rss_gethashalgo();
if (rss_algo == RSS_HASH_TOEPLITZ) {
uint8_t hash_key[RSS_KEYSIZE];
@@ -133,7 +132,6 @@ ena_rss_init_default(struct ena_adapter *adapter)
rss_getkey(hash_key);
rc = ena_rss_set_hash(ena_dev, hash_key);
} else
-#endif
rc = ena_com_fill_hash_function(ena_dev, ENA_ADMIN_TOEPLITZ,
NULL, ENA_HASH_KEY_SIZE, 0x0);
if (unlikely((rc != 0) && (rc != EOPNOTSUPP))) {
diff --git a/sys/dev/ena/ena_rss.h b/sys/dev/ena/ena_rss.h
index d2706deef8ca..d1236ef26c33 100644
--- a/sys/dev/ena/ena_rss.h
+++ b/sys/dev/ena/ena_rss.h
@@ -37,9 +37,7 @@
#include <sys/types.h>
#include "ena.h"
-#ifdef RSS
#include <net/rss_config.h>
-#endif
#define ENA_RX_RSS_MSG_RECORD_SZ 8