[v2,3/5] crypto/ccp: fix CCP CPU authentication crash

Message ID 20191122064647.94171-1-asomalap@amd.com (mailing list archive)
State Accepted, archived
Delegated to: akhil goyal
Headers
Series [v2,1/5] doc: fix app usage in CCP guide |

Checks

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

Commit Message

AMARANATH SOMALAPURAM Nov. 22, 2019, 6:46 a.m. UTC
  From: Amaranath Somalapuram <asomalap@amd.com>

when ccp_auth_opt=1 is set and if authentication error occurred
ccp driver crash. The enqueue referance count nb_ops miss match
with dequeue nb_ops on authentication error

Fixes: e0d88a394e ("crypto/ccp: support run-time CPU based auth")
Cc: stable@dpdk.org

Signed-off-by: Amaranath Somalapuram <asomalap@amd.com>
---
 drivers/crypto/ccp/ccp_crypto.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/drivers/crypto/ccp/ccp_crypto.c b/drivers/crypto/ccp/ccp_crypto.c
index 19ae9153d..1837c8543 100644
--- a/drivers/crypto/ccp/ccp_crypto.c
+++ b/drivers/crypto/ccp/ccp_crypto.c
@@ -2738,7 +2738,7 @@  process_ops_to_enqueue(struct ccp_qp *qp,
 							 session, auth_ctx);
 				if (op[i]->status !=
 				    RTE_CRYPTO_OP_STATUS_SUCCESS)
-					continue;
+					CCP_LOG_ERR("RTE_CRYPTO_OP_STATUS_AUTH_FAILED");
 			} else
 				result = ccp_crypto_auth(op[i], cmd_q, b_info);