summaryrefslogtreecommitdiff
path: root/sys/dev/ixl
diff options
context:
space:
mode:
authorSepherosa Ziehau <sephe@FreeBSD.org>2017-09-27 05:59:54 +0000
committerSepherosa Ziehau <sephe@FreeBSD.org>2017-09-27 05:59:54 +0000
commit03b04fd4f304512cd894f0a2d37940db3bed537c (patch)
tree889e371c6697cb48bb2683bf1f28aa9105e1a75b /sys/dev/ixl
parentfc572e261f8062081107636de595fb5146d8d8f2 (diff)
Notes
Diffstat (limited to 'sys/dev/ixl')
-rw-r--r--sys/dev/ixl/ixl_txrx.c38
1 files changed, 12 insertions, 26 deletions
diff --git a/sys/dev/ixl/ixl_txrx.c b/sys/dev/ixl/ixl_txrx.c
index 7872d0a4b925..3501ebc4cd50 100644
--- a/sys/dev/ixl/ixl_txrx.c
+++ b/sys/dev/ixl/ixl_txrx.c
@@ -1446,10 +1446,8 @@ static inline int
ixl_ptype_to_hash(u8 ptype)
{
struct i40e_rx_ptype_decoded decoded;
- u8 ex = 0;
decoded = decode_rx_desc_ptype(ptype);
- ex = decoded.outer_frag;
if (!decoded.known)
return M_HASHTYPE_OPAQUE_HASH;
@@ -1460,34 +1458,22 @@ ixl_ptype_to_hash(u8 ptype)
/* Note: anything that gets to this point is IP */
if (decoded.outer_ip_ver == I40E_RX_PTYPE_OUTER_IPV6) {
switch (decoded.inner_prot) {
- case I40E_RX_PTYPE_INNER_PROT_TCP:
- if (ex)
- return M_HASHTYPE_RSS_TCP_IPV6_EX;
- else
- return M_HASHTYPE_RSS_TCP_IPV6;
- case I40E_RX_PTYPE_INNER_PROT_UDP:
- if (ex)
- return M_HASHTYPE_RSS_UDP_IPV6_EX;
- else
- return M_HASHTYPE_RSS_UDP_IPV6;
- default:
- if (ex)
- return M_HASHTYPE_RSS_IPV6_EX;
- else
- return M_HASHTYPE_RSS_IPV6;
+ case I40E_RX_PTYPE_INNER_PROT_TCP:
+ return M_HASHTYPE_RSS_TCP_IPV6;
+ case I40E_RX_PTYPE_INNER_PROT_UDP:
+ return M_HASHTYPE_RSS_UDP_IPV6;
+ default:
+ return M_HASHTYPE_RSS_IPV6;
}
}
if (decoded.outer_ip_ver == I40E_RX_PTYPE_OUTER_IPV4) {
switch (decoded.inner_prot) {
- case I40E_RX_PTYPE_INNER_PROT_TCP:
- return M_HASHTYPE_RSS_TCP_IPV4;
- case I40E_RX_PTYPE_INNER_PROT_UDP:
- if (ex)
- return M_HASHTYPE_RSS_UDP_IPV4_EX;
- else
- return M_HASHTYPE_RSS_UDP_IPV4;
- default:
- return M_HASHTYPE_RSS_IPV4;
+ case I40E_RX_PTYPE_INNER_PROT_TCP:
+ return M_HASHTYPE_RSS_TCP_IPV4;
+ case I40E_RX_PTYPE_INNER_PROT_UDP:
+ return M_HASHTYPE_RSS_UDP_IPV4;
+ default:
+ return M_HASHTYPE_RSS_IPV4;
}
}
/* We should never get here!! */