diff mbox series

[4/6] test/event_crypto: support to release the atomic ctxt

Message ID 20191001113339.21767-4-hemant.agrawal@nxp.com
State New
Headers show
Series [1/6] test/event_crypto: fix missing IV value for AES algo | expand

Commit Message

Hemant Agrawal Oct. 1, 2019, 11:33 a.m. UTC
The test cases uses ATOMIC queues. Once the packet is recived
it is required to release the ATOMIC ctxt, at least for the
HW based eventdevs. This patch makes empty dq call, which
in turn releases the atomic ctxt.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>

---
 app/test/test_event_crypto_adapter.c | 6 ++++++
 1 file changed, 6 insertions(+)

-- 
2.17.1
diff mbox series

Patch

diff --git a/app/test/test_event_crypto_adapter.c b/app/test/test_event_crypto_adapter.c
index 8d42462d8..b9e3a439e 100644
--- a/app/test/test_event_crypto_adapter.c
+++ b/app/test/test_event_crypto_adapter.c
@@ -357,6 +357,12 @@  send_op_recv_ev(struct rte_crypto_op *op)
 		rte_pause();
 
 	recv_op = ev.event_ptr;
+
+	/* In case of Atomic/Ordered Queue, call dequeue one more time
+	 * to release, if there is any atomic context to be freed
+	 */
+	rte_event_dequeue_burst(evdev, TEST_APP_PORT_ID, &ev, NUM, 0);
+
 #if PKT_TRACE
 	struct rte_mbuf *m = recv_op->sym->m_src;
 	rte_pktmbuf_dump(stdout, m, rte_pktmbuf_pkt_len(m));