This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 4f309eceba9fbf1254eb39120d184ca3f6543168 (commit)
from abfea01c9d5afe4d318db623b24ee00231057316 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 4f309eceba9fbf1254eb39120d184ca3f6543168
Author: Petri Savolainen <petri.savolainen(a)linaro.org>
Date: Wed Nov 7 10:44:00 2018 +0200
validation: crypto: capability call should not fail
Capability call should always succeed. It's possible that no
algorithms are supported, but also then the call should succeed.
Signed-off-by: Petri Savolainen <petri.savolainen(a)linaro.org>
Reviewed-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/test/validation/api/crypto/odp_crypto_test_inp.c b/test/validation/api/crypto/odp_crypto_test_inp.c
index 1e06761c..361e6ac9 100644
--- a/test/validation/api/crypto/odp_crypto_test_inp.c
+++ b/test/validation/api/crypto/odp_crypto_test_inp.c
@@ -647,8 +647,11 @@ static int check_alg_support(odp_cipher_alg_t cipher, odp_auth_alg_t auth)
{
odp_crypto_capability_t capability;
- if (odp_crypto_capability(&capability))
+ memset(&capability, 0, sizeof(odp_crypto_capability_t));
+ if (odp_crypto_capability(&capability)) {
+ fprintf(stderr, "odp_crypto_capability() failed\n");
return ODP_TEST_INACTIVE;
+ }
if (suite_context.packet) {
if (suite_context.op_mode == ODP_CRYPTO_SYNC &&
@@ -1571,6 +1574,7 @@ static int crypto_init(odp_instance_t *inst)
odp_pool_t pool;
odp_queue_t out_queue;
odp_pool_capability_t pool_capa;
+ odp_crypto_capability_t crypto_capa;
if (0 != odp_init_global(inst, NULL, NULL)) {
fprintf(stderr, "error: odp_init_global() failed.\n");
@@ -1582,6 +1586,11 @@ static int crypto_init(odp_instance_t *inst)
return -1;
}
+ if (odp_crypto_capability(&crypto_capa)) {
+ fprintf(stderr, "error: odp_crypto_capability() failed.\n");
+ return -1;
+ }
+
if (odp_pool_capability(&pool_capa) < 0) {
fprintf(stderr, "error: odp_pool_capability() failed.\n");
return -1;
-----------------------------------------------------------------------
Summary of changes:
test/validation/api/crypto/odp_crypto_test_inp.c | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
hooks/post-receive
--