Lines Matching refs:cipher
583 struct skcipher_alg *cipher = crypto_skcipher_alg(tfm); in skcipher_setkey_unaligned() local
595 ret = cipher->setkey(tfm, alignbuffer, keylen); in skcipher_setkey_unaligned()
603 struct skcipher_alg *cipher = crypto_skcipher_alg(tfm); in crypto_skcipher_setkey() local
607 if (keylen < cipher->min_keysize || keylen > cipher->max_keysize) in crypto_skcipher_setkey()
613 err = cipher->setkey(tfm, key, keylen); in crypto_skcipher_setkey()
883 struct crypto_cipher *cipher = skcipher_cipher_simple(tfm); in skcipher_setkey_simple() local
885 crypto_cipher_clear_flags(cipher, CRYPTO_TFM_REQ_MASK); in skcipher_setkey_simple()
886 crypto_cipher_set_flags(cipher, crypto_skcipher_get_flags(tfm) & in skcipher_setkey_simple()
888 return crypto_cipher_setkey(cipher, key, keylen); in skcipher_setkey_simple()
896 struct crypto_cipher *cipher; in skcipher_init_tfm_simple() local
898 cipher = crypto_spawn_cipher(spawn); in skcipher_init_tfm_simple()
899 if (IS_ERR(cipher)) in skcipher_init_tfm_simple()
900 return PTR_ERR(cipher); in skcipher_init_tfm_simple()
902 ctx->cipher = cipher; in skcipher_init_tfm_simple()
910 crypto_free_cipher(ctx->cipher); in skcipher_exit_tfm_simple()