summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavan Nikhilesh <pbhagavatula@marvell.com>2019-11-11 18:49:10 +0530
committerFerruh Yigit <ferruh.yigit@intel.com>2019-11-11 16:15:37 +0100
commit4c634d7392fa7f330896544e2ca88a93b0d06d80 (patch)
treeeb974165c92111c052be4a00af7dea4d06be6a8a
parent5392ebc0e164a139ab9ff93d0c8c1a437a56c90a (diff)
downloaddpdk-4c634d7392fa7f330896544e2ca88a93b0d06d80.zip
dpdk-4c634d7392fa7f330896544e2ca88a93b0d06d80.tar.gz
dpdk-4c634d7392fa7f330896544e2ca88a93b0d06d80.tar.xz
examples/eventdev: add new Rx RSS hash offload
Since pipeline_generic uses `rte_mbuf::hash::rss` add the new Rx offload flag `DEV_RX_OFFLOAD_RSS_HASH` to inform PMD to copy the RSS hash result into the mbuf. Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
-rw-r--r--examples/eventdev_pipeline/pipeline_worker_generic.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/examples/eventdev_pipeline/pipeline_worker_generic.c b/examples/eventdev_pipeline/pipeline_worker_generic.c
index 0058ba7..42ff4ee 100644
--- a/examples/eventdev_pipeline/pipeline_worker_generic.c
+++ b/examples/eventdev_pipeline/pipeline_worker_generic.c
@@ -314,6 +314,9 @@ port_init(uint8_t port, struct rte_mempool *mbuf_pool)
port_conf.txmode.offloads |=
DEV_TX_OFFLOAD_MBUF_FAST_FREE;
+ if (dev_info.rx_offload_capa & DEV_RX_OFFLOAD_RSS_HASH)
+ port_conf.rxmode.offloads |= DEV_RX_OFFLOAD_RSS_HASH;
+
rx_conf = dev_info.default_rxconf;
rx_conf.offloads = port_conf.rxmode.offloads;