diff options
author | mgovind <govindarajan.mohandoss@arm.com> | 2022-02-16 01:15:02 +0000 |
---|---|---|
committer | mgovind <govindarajan.mohandoss@arm.com> | 2022-02-16 01:15:02 +0000 |
commit | 6a51775d6cc3a4bf3189291f0d025238dbe7d72c (patch) | |
tree | faadcfc5ff87353b7eb0f5ccbbd9d277d9618c33 /src | |
parent | 3f03ca95b64f2d2b4a706242156bce1c65729b13 (diff) |
crypto: Fix for the crash in crypto
Fix for the crash when both crypto_native_plugin and DPDK QAT
are enabled in startup conf.
Type: fix
Signed-off-by: mgovind <govindarajan.mohandoss@arm.com>
Change-Id: Ib020ed7130a99080a093c70c06d47bcacd6d23b1
Diffstat (limited to 'src')
-rw-r--r-- | src/vnet/crypto/crypto.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vnet/crypto/crypto.c b/src/vnet/crypto/crypto.c index 9f437cfcd4b..93fd9742766 100644 --- a/src/vnet/crypto/crypto.c +++ b/src/vnet/crypto/crypto.c @@ -333,6 +333,8 @@ vnet_crypto_update_cm_dequeue_handlers (void) for (i = 0; i < VNET_CRYPTO_ASYNC_OP_N_IDS; i++) { otd = cm->async_opt_data + i; + if (otd->active_engine_index_async == ~0) + continue; e = cm->engines + otd->active_engine_index_async; if (!e->dequeue_handler) continue; @@ -345,6 +347,8 @@ vnet_crypto_update_cm_dequeue_handlers (void) { if (ei[0] == last_ei) continue; + if (ei[0] == ~0) + continue; e = cm->engines + ei[0]; vec_add1 (cm->dequeue_handlers, e->dequeue_handler); |