Commit ea4006576945195ed35824acfb4007ca7cb78b70
1 parent
27300176d7
Exists in
master
and in
7 other branches
crypto: tcrypt - Fix module return code when testing by name
We should return 0/-ENOENT instead of 1/0 when testing by name. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff
crypto/tcrypt.c
... | ... | @@ -889,7 +889,7 @@ |
889 | 889 | |
890 | 890 | static int do_alg_test(const char *alg, u32 type) |
891 | 891 | { |
892 | - return crypto_has_alg(alg, type, CRYPTO_ALG_TYPE_MASK); | |
892 | + return crypto_has_alg(alg, type, CRYPTO_ALG_TYPE_MASK) ? 0 : -ENOENT; | |
893 | 893 | } |
894 | 894 | |
895 | 895 | static int __init tcrypt_mod_init(void) |