The branch main has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=62c80d76f7dc960f430cb34f88c2a549612e3e93
commit 62c80d76f7dc960f430cb34f88c2a549612e3e93 Author: Kevin Bowling <[email protected]> AuthorDate: 2026-09-18 08:29:18 +0000 Commit: Kevin Bowling <[email protected]> CommitDate: 2026-09-18 23:26:53 +0000 bnxt: Initialize RSS with the common key Use rss_getkey() for the initial VNIC key instead of generating a per-attachment private key. Preserve the writable rss_key sysctl, its override lifetime, the hardware DMA representation, and all hash and indirection settings. Reviewed by: gallatin MFC after: 2 weeks Sponsored by: BBOX.io Differential Revision: https://reviews.freebsd.org/D59795 --- sys/dev/bnxt/bnxt_en/if_bnxt.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sys/dev/bnxt/bnxt_en/if_bnxt.c b/sys/dev/bnxt/bnxt_en/if_bnxt.c index 432dceb6bfb2..deb5a62347bd 100644 --- a/sys/dev/bnxt/bnxt_en/if_bnxt.c +++ b/sys/dev/bnxt/bnxt_en/if_bnxt.c @@ -47,6 +47,7 @@ #include <net/if_var.h> #include <net/ethernet.h> #include <net/iflib.h> +#include <net/rss_config.h> #define WANT_NATIVE_PCI_GET_SLOT #include <linux/pci.h> @@ -2893,7 +2894,9 @@ bnxt_attach_pre(if_ctx_t ctx) goto failed; } - arc4rand(softc->vnic_info.rss_hash_key, HW_HASH_KEY_SIZE, 0); + _Static_assert(HW_HASH_KEY_SIZE == RSS_KEYSIZE, + "RSS key size mismatch"); + rss_getkey(softc->vnic_info.rss_hash_key); softc->vnic_info.rss_hash_type = HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_IPV4 | HWRM_VNIC_RSS_CFG_INPUT_HASH_TYPE_TCP_IPV4 |
