[dpdk-dev] [PATCH] ptpclient: enable timestamp offload support
Hemant Agrawal
hemant.agrawal at nxp.com
Tue Feb 23 07:14:12 CET 2021
This patch add support to enabled rx offload for timestamp.
It is required to be enabled for some pmds e.g. dpaa2
Signed-off-by: Gagandeep Singh <g.singh at nxp.com>
Signed-off-by: Hemant Agrawal <hemant.agrawal at nxp.com>
---
examples/ptpclient/ptpclient.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/examples/ptpclient/ptpclient.c b/examples/ptpclient/ptpclient.c
index 09968cdfc..33b297e37 100644
--- a/examples/ptpclient/ptpclient.c
+++ b/examples/ptpclient/ptpclient.c
@@ -197,6 +197,9 @@ port_init(uint16_t port, struct rte_mempool *mbuf_pool)
return retval;
}
+ if (dev_info.rx_offload_capa & DEV_RX_OFFLOAD_TIMESTAMP)
+ port_conf.rxmode.offloads |= DEV_RX_OFFLOAD_TIMESTAMP;
+
if (dev_info.tx_offload_capa & DEV_TX_OFFLOAD_MBUF_FAST_FREE)
port_conf.txmode.offloads |=
DEV_TX_OFFLOAD_MBUF_FAST_FREE;
--
2.17.1
More information about the dev
mailing list