[dpdk-stable] patch 'crypto/dpaa_sec: affine the thread portal affinity' has been queued to stable release 20.11.2

Xueming Li xuemingl at nvidia.com
Sat Jun 12 01:03:06 CEST 2021


Hi,

FYI, your patch has been queued to stable release 20.11.2

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/14/21. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/steevenlee/dpdk

This queued commit can be viewed at:
https://github.com/steevenlee/dpdk/commit/39b13992e9cf6fce1ee2faf84bdd850a40861768

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 39b13992e9cf6fce1ee2faf84bdd850a40861768 Mon Sep 17 00:00:00 2001
From: Hemant Agrawal <hemant.agrawal at nxp.com>
Date: Mon, 3 May 2021 14:09:53 +0530
Subject: [PATCH] crypto/dpaa_sec: affine the thread portal affinity
Cc: Luca Boccassi <bluca at debian.org>

[ upstream commit 22629f05f8832358d01872414e0e30c2c81e43d4 ]

DPAA requires the I/O shall be done in a HW portal context only.
The portal affinity is currently only being done in session create
and config APIs with the assumption that same thread will be used
for IO. This is causing issue.
This patch add support during I/O to check the HW portal affinity
and affine portal- if not affined already.

Fixes: 9a984458f755 ("crypto/dpaa_sec: rewrite Rx/Tx path")

Signed-off-by: Hemant Agrawal <hemant.agrawal at nxp.com>
---
 drivers/crypto/dpaa_sec/dpaa_sec.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/crypto/dpaa_sec/dpaa_sec.c b/drivers/crypto/dpaa_sec/dpaa_sec.c
index 44c742738f..a958d00b46 100644
--- a/drivers/crypto/dpaa_sec/dpaa_sec.c
+++ b/drivers/crypto/dpaa_sec/dpaa_sec.c
@@ -1716,6 +1716,13 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
 	uint32_t index, flags[DPAA_SEC_BURST] = {0};
 	struct qman_fq *inq[DPAA_SEC_BURST];
 
+	if (unlikely(!DPAA_PER_LCORE_PORTAL)) {
+		if (rte_dpaa_portal_init((void *)0)) {
+			DPAA_SEC_ERR("Failure in affining portal");
+			return 0;
+		}
+	}
+
 	while (nb_ops) {
 		frames_to_send = (nb_ops > DPAA_SEC_BURST) ?
 				DPAA_SEC_BURST : nb_ops;
@@ -1916,6 +1923,13 @@ dpaa_sec_dequeue_burst(void *qp, struct rte_crypto_op **ops,
 	uint16_t num_rx;
 	struct dpaa_sec_qp *dpaa_qp = (struct dpaa_sec_qp *)qp;
 
+	if (unlikely(!DPAA_PER_LCORE_PORTAL)) {
+		if (rte_dpaa_portal_init((void *)0)) {
+			DPAA_SEC_ERR("Failure in affining portal");
+			return 0;
+		}
+	}
+
 	num_rx = dpaa_sec_deq(dpaa_qp, ops, nb_ops);
 
 	dpaa_qp->rx_pkts += num_rx;
-- 
2.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-06-12 06:53:58.985728900 +0800
+++ 0092-crypto-dpaa_sec-affine-the-thread-portal-affinity.patch	2021-06-12 06:53:56.430000000 +0800
@@ -1 +1 @@
-From 22629f05f8832358d01872414e0e30c2c81e43d4 Mon Sep 17 00:00:00 2001
+From 39b13992e9cf6fce1ee2faf84bdd850a40861768 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Luca Boccassi <bluca at debian.org>
+
+[ upstream commit 22629f05f8832358d01872414e0e30c2c81e43d4 ]
@@ -14 +16,0 @@
-Cc: stable at dpdk.org
@@ -22 +24 @@
-index 43363ba6ba..19d4684e24 100644
+index 44c742738f..a958d00b46 100644
@@ -25 +27 @@
-@@ -1717,6 +1717,13 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
+@@ -1716,6 +1716,13 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
@@ -39 +41 @@
-@@ -1917,6 +1924,13 @@ dpaa_sec_dequeue_burst(void *qp, struct rte_crypto_op **ops,
+@@ -1916,6 +1923,13 @@ dpaa_sec_dequeue_burst(void *qp, struct rte_crypto_op **ops,


More information about the stable mailing list