[v2,2/4] net/hns3: fix lack of Rx RSS hash in ol flags
diff mbox series

Message ID 1572007025-43391-3-git-send-email-xavier.huwei@huawei.com
State Accepted, archived
Delegated to: Ferruh Yigit
Headers show
Series
  • some fixes for hns3 PMD driver
Related show

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Wei Hu (Xavier) Oct. 25, 2019, 12:37 p.m. UTC
This patch adds PKT_RX_RSS_HASH flag to rx packet's ol_flags
to repair the bug that hns3 pmd driver doesn't set
PKT_RX_RSS_HASH flag. In hns3 network engine RSS is always
enabled.

Fixes: bba636698316 ("net/hns3: support Rx/Tx and related operations")

Signed-off-by: Hao Chen <chenhao164@huawei.com>
Signed-off-by: Wei Hu (Xavier) <xavier.huwei@huawei.com>
---
 drivers/net/hns3/hns3_rxtx.c | 1 +
 1 file changed, 1 insertion(+)

Patch
diff mbox series

diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c
index 1e8283a..1de238b 100644
--- a/drivers/net/hns3/hns3_rxtx.c
+++ b/drivers/net/hns3/hns3_rxtx.c
@@ -977,6 +977,7 @@  hns3_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 		first_seg->pkt_len = pkt_len;
 		first_seg->port = rxq->port_id;
 		first_seg->hash.rss = rte_le_to_cpu_32(rxdp->rx.rss_hash);
+		first_seg->ol_flags |= PKT_RX_RSS_HASH;
 		if (unlikely(hns3_get_bit(bd_base_info, HNS3_RXD_LUM_B))) {
 			first_seg->hash.fdir.hi =
 				rte_le_to_cpu_32(rxdp->rx.fd_id);