Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F143658338
D53092.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D53092.diff
View Options
diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c
--- a/sys/dev/cxgbe/t4_main.c
+++ b/sys/dev/cxgbe/t4_main.c
@@ -57,9 +57,7 @@
#include <net/if_types.h>
#include <net/if_dl.h>
#include <net/if_vlan_var.h>
-#ifdef RSS
#include <net/rss_config.h>
-#endif
#include <netinet/in.h>
#include <netinet/ip.h>
#ifdef KERN_TLS
@@ -7035,7 +7033,6 @@
static void
write_global_rss_key(struct adapter *sc)
{
-#ifdef RSS
int i;
uint32_t raw_rss_key[RSS_KEYSIZE / sizeof(uint32_t)];
uint32_t rss_key[RSS_KEYSIZE / sizeof(uint32_t)];
@@ -7047,7 +7044,6 @@
rss_key[i] = htobe32(raw_rss_key[nitems(rss_key) - 1 - i]);
}
t4_write_rss_key(sc, &rss_key[0], -1, 1);
-#endif
}
/*
@@ -7127,7 +7123,6 @@
sc->flags &= ~FULL_INIT_DONE;
}
-#ifdef RSS
#define SUPPORTED_RSS_HASHTYPES (RSS_HASHTYPE_RSS_IPV4 | \
RSS_HASHTYPE_RSS_TCP_IPV4 | RSS_HASHTYPE_RSS_IPV6 | \
RSS_HASHTYPE_RSS_TCP_IPV6 | RSS_HASHTYPE_RSS_UDP_IPV4 | \
@@ -7190,7 +7185,6 @@
return (hashconfig);
}
-#endif
/*
* Idempotent.
@@ -7201,9 +7195,9 @@
struct adapter *sc = vi->adapter;
struct sge_rxq *rxq;
int rc, i, j;
+ int hashconfig = rss_gethashconfig();
#ifdef RSS
int nbuckets = rss_getnumbuckets();
- int hashconfig = rss_gethashconfig();
int extra;
#endif
@@ -7259,9 +7253,9 @@
return (rc);
}
-#ifdef RSS
vi->hashen = hashconfig_to_hashen(hashconfig);
+#ifdef RSS
/*
* We may have had to enable some hashes even though the global config
* wants them disabled. This is a potential problem that must be
@@ -7295,11 +7289,6 @@
CH_ALERT(vi, "UDP/IPv4 4-tuple hashing forced on.\n");
if (extra & RSS_HASHTYPE_RSS_UDP_IPV6)
CH_ALERT(vi, "UDP/IPv6 4-tuple hashing forced on.\n");
-#else
- vi->hashen = F_FW_RSS_VI_CONFIG_CMD_IP6FOURTUPEN |
- F_FW_RSS_VI_CONFIG_CMD_IP6TWOTUPEN |
- F_FW_RSS_VI_CONFIG_CMD_IP4FOURTUPEN |
- F_FW_RSS_VI_CONFIG_CMD_IP4TWOTUPEN | F_FW_RSS_VI_CONFIG_CMD_UDPEN;
#endif
rc = -t4_config_vi_rss(sc, sc->mbox, vi->viid, vi->hashen, vi->rss[0],
0, 0);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Feb 1, 4:47 AM (8 h, 23 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26017674
Default Alt Text
D53092.diff (1 KB)
Attached To
Mode
D53092: cxgbe: use newly exposed RSS hash key API rather than ad-hoc hashing
Attached
Detach File
Event Timeline
Log In to Comment