diff options
| author | Andrew Gallatin <gallatin@FreeBSD.org> | 2025-11-22 14:29:33 +0000 |
|---|---|---|
| committer | Andrew Gallatin <gallatin@FreeBSD.org> | 2025-11-22 14:29:33 +0000 |
| commit | d2790dc77ef667d3477017b37db85378ce0bca8c (patch) | |
| tree | 7869bdf9c3a6889fbfff932eab47254c0e085661 | |
| parent | dd615b57df62e2fa858569d66164dcd1ef840c94 (diff) | |
iavf: use newly exposed RSS hash key API rather than ad-hoc hashing
Differential Revision: https://reviews.freebsd.org/D53095
Sponsored by: Netflix
| -rw-r--r-- | sys/dev/iavf/iavf_lib.c | 10 | ||||
| -rw-r--r-- | sys/dev/iavf/iavf_lib.h | 2 |
2 files changed, 0 insertions, 12 deletions
diff --git a/sys/dev/iavf/iavf_lib.c b/sys/dev/iavf/iavf_lib.c index 433d31904ea4..8596cf71bfff 100644 --- a/sys/dev/iavf/iavf_lib.c +++ b/sys/dev/iavf/iavf_lib.c @@ -1079,9 +1079,7 @@ iavf_config_rss_reg(struct iavf_sc *sc) u64 set_hena = 0, hena; int i, j, que_id; u32 rss_seed[IAVF_RSS_KEY_SIZE_REG]; -#ifdef RSS u32 rss_hash_config; -#endif /* Don't set up RSS if using a single queue */ if (IAVF_NRXQS(vsi) == 1) { @@ -1091,19 +1089,14 @@ iavf_config_rss_reg(struct iavf_sc *sc) return; } -#ifdef RSS /* Fetch the configured RSS key */ rss_getkey((uint8_t *) &rss_seed); -#else - iavf_get_default_rss_key(rss_seed); -#endif /* Fill out hash function seed */ for (i = 0; i < IAVF_RSS_KEY_SIZE_REG; i++) wr32(hw, IAVF_VFQF_HKEY(i), rss_seed[i]); /* Enable PCTYPES for RSS: */ -#ifdef RSS rss_hash_config = rss_gethashconfig(); if (rss_hash_config & RSS_HASHTYPE_RSS_IPV4) set_hena |= ((u64)1 << IAVF_FILTER_PCTYPE_NONF_IPV4_OTHER); @@ -1119,9 +1112,6 @@ iavf_config_rss_reg(struct iavf_sc *sc) set_hena |= ((u64)1 << IAVF_FILTER_PCTYPE_NONF_IPV6_TCP); if (rss_hash_config & RSS_HASHTYPE_RSS_UDP_IPV6) set_hena |= ((u64)1 << IAVF_FILTER_PCTYPE_NONF_IPV6_UDP); -#else - set_hena = IAVF_DEFAULT_RSS_HENA_XL710; -#endif hena = (u64)rd32(hw, IAVF_VFQF_HENA(0)) | ((u64)rd32(hw, IAVF_VFQF_HENA(1)) << 32); hena |= set_hena; diff --git a/sys/dev/iavf/iavf_lib.h b/sys/dev/iavf/iavf_lib.h index 48c0f4560e5a..955f5c69288b 100644 --- a/sys/dev/iavf/iavf_lib.h +++ b/sys/dev/iavf/iavf_lib.h @@ -42,9 +42,7 @@ #include <sys/malloc.h> #include <sys/stdarg.h> #include <sys/sysctl.h> -#ifdef RSS #include <net/rss_config.h> -#endif #include "iavf_debug.h" #include "iavf_osdep.h" |
