summaryrefslogtreecommitdiff
path: root/crypto
diff options
context:
space:
mode:
authorCristian Stoica <cristian.stoica@freescale.com>2013-07-18 18:57:07 +0300
committerHerbert Xu <herbert@gondor.apana.org.au>2013-08-01 21:39:26 +1000
commit6fabc176e46b5082c70726178d7558d5f66b82f7 (patch)
tree8ee74154ea52e1f1fa84e3c6c56e35e1066f6053 /crypto
parent17f658c82918b2ba361fc195ccf924b92761b597 (diff)
downloadlinux-crypto-6fabc176e46b5082c70726178d7558d5f66b82f7.tar.gz
linux-crypto-6fabc176e46b5082c70726178d7558d5f66b82f7.zip
crypto: testmgr - remove double execution of the same test suite
This patch removes redundant execution of the same test suite in cases where alg and driver variables are the same (e.g. when alg_test is called from tcrypt_test) Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Reviewed-by: Horia Geanta <horia.geanta@freescale.com> Reviewed-by: Ruchika Gupta <ruchika.gupta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto')
-rw-r--r--crypto/testmgr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/testmgr.c b/crypto/testmgr.c
index 2f006070..e091ef6e 100644
--- a/crypto/testmgr.c
+++ b/crypto/testmgr.c
@@ -3234,7 +3234,7 @@ int alg_test(const char *driver, const char *alg, u32 type, u32 mask)
if (i >= 0)
rc |= alg_test_descs[i].test(alg_test_descs + i, driver,
type, mask);
- if (j >= 0)
+ if (j >= 0 && j != i)
rc |= alg_test_descs[j].test(alg_test_descs + j, driver,
type, mask);