Lines Matching refs:tfm

20 static int setkey_unaligned(struct crypto_cipher *tfm, const u8 *key,  in setkey_unaligned()  argument
23 struct cipher_alg *cia = crypto_cipher_alg(tfm); in setkey_unaligned()
24 unsigned long alignmask = crypto_cipher_alignmask(tfm); in setkey_unaligned()
36 ret = cia->cia_setkey(crypto_cipher_tfm(tfm), alignbuffer, keylen); in setkey_unaligned()
42 int crypto_cipher_setkey(struct crypto_cipher *tfm, in crypto_cipher_setkey() argument
45 struct cipher_alg *cia = crypto_cipher_alg(tfm); in crypto_cipher_setkey()
46 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_cipher_setkey()
52 return setkey_unaligned(tfm, key, keylen); in crypto_cipher_setkey()
54 return cia->cia_setkey(crypto_cipher_tfm(tfm), key, keylen); in crypto_cipher_setkey()
58 static inline void cipher_crypt_one(struct crypto_cipher *tfm, in cipher_crypt_one() argument
61 unsigned long alignmask = crypto_cipher_alignmask(tfm); in cipher_crypt_one()
62 struct cipher_alg *cia = crypto_cipher_alg(tfm); in cipher_crypt_one()
67 unsigned int bs = crypto_cipher_blocksize(tfm); in cipher_crypt_one()
72 fn(crypto_cipher_tfm(tfm), tmp, tmp); in cipher_crypt_one()
75 fn(crypto_cipher_tfm(tfm), dst, src); in cipher_crypt_one()
79 void crypto_cipher_encrypt_one(struct crypto_cipher *tfm, in crypto_cipher_encrypt_one() argument
82 cipher_crypt_one(tfm, dst, src, true); in crypto_cipher_encrypt_one()
86 void crypto_cipher_decrypt_one(struct crypto_cipher *tfm, in crypto_cipher_decrypt_one() argument
89 cipher_crypt_one(tfm, dst, src, false); in crypto_cipher_decrypt_one()
95 struct crypto_tfm *tfm = crypto_cipher_tfm(cipher); in crypto_clone_cipher() local
96 struct crypto_alg *alg = tfm->__crt_alg; in crypto_clone_cipher()
113 ntfm->crt_flags = tfm->crt_flags; in crypto_clone_cipher()