crypto: api - crypto_alg_mod_lookup either tested or untested
[pandora-kernel.git] / crypto / api.c
index efe77df..56b6e0e 100644 (file)
@@ -244,7 +244,7 @@ struct crypto_alg *crypto_alg_mod_lookup(const char *name, u32 type, u32 mask)
        struct crypto_alg *larval;
        int ok;
 
-       if (!(mask & CRYPTO_ALG_TESTED)) {
+       if (!((type | mask) & CRYPTO_ALG_TESTED)) {
                type |= CRYPTO_ALG_TESTED;
                mask |= CRYPTO_ALG_TESTED;
        }