Skip to content

Commit

Permalink
test/crypto: fix session creation check
Browse files Browse the repository at this point in the history
[ upstream commit 142a8f4c578e420b916f84649873f99bad985412 ]

Fixing return value if session failure occurs
due to unsupported feature.

Fixes: eec136f ("aesni_gcm: add driver for AES-GCM crypto operations")

Signed-off-by: Tejasree Kondoj <ktejasree@marvell.com>
Acked-by: Anoob Joseph <anoobj@marvell.com>
Acked-by: Ciara Power <ciara.power@intel.com>
  • Loading branch information
Tejasree Kondoj authored and kevintraynor committed Jul 11, 2023
1 parent c4583cd commit 0428cfa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/test/test_cryptodev.c
Original file line number Diff line number Diff line change
Expand Up @@ -8256,7 +8256,7 @@ test_authenticated_encryption(const struct aead_test_data *tdata)
tdata->key.data, tdata->key.len,
tdata->aad.len, tdata->auth_tag.len,
tdata->iv.len);
if (retval < 0)
if (retval != TEST_SUCCESS)
return retval;

if (tdata->aad.len > MBUF_SIZE) {
Expand Down Expand Up @@ -10904,7 +10904,7 @@ test_authenticated_decryption_sessionless(
key, tdata->key.len,
tdata->aad.len, tdata->auth_tag.len,
tdata->iv.len);
if (retval < 0)
if (retval != TEST_SUCCESS)
return retval;

ut_params->op->sym->m_src = ut_params->ibuf;
Expand Down

0 comments on commit 0428cfa

Please sign in to comment.