Lines Matching defs:tfm
147 struct crypto_tfm *tfm = crypto_skcipher_tfm(atfm);
148 struct sec_alg_tfm_ctx *ctx = crypto_tfm_ctx(tfm);
227 static int sec_alg_skcipher_setkey(struct crypto_skcipher *tfm,
231 struct sec_alg_tfm_ctx *ctx = crypto_skcipher_ctx(tfm);
248 sec_alg_skcipher_init_context(tfm, key, keylen, alg);
253 static int sec_alg_skcipher_setkey_aes_ecb(struct crypto_skcipher *tfm,
272 return sec_alg_skcipher_setkey(tfm, key, keylen, alg);
275 static int sec_alg_skcipher_setkey_aes_cbc(struct crypto_skcipher *tfm,
294 return sec_alg_skcipher_setkey(tfm, key, keylen, alg);
297 static int sec_alg_skcipher_setkey_aes_ctr(struct crypto_skcipher *tfm,
316 return sec_alg_skcipher_setkey(tfm, key, keylen, alg);
319 static int sec_alg_skcipher_setkey_aes_xts(struct crypto_skcipher *tfm,
325 ret = xts_verify_key(tfm, key, keylen);
340 return sec_alg_skcipher_setkey(tfm, key, keylen, alg);
343 static int sec_alg_skcipher_setkey_des_ecb(struct crypto_skcipher *tfm,
346 return verify_skcipher_des_key(tfm, key) ?:
347 sec_alg_skcipher_setkey(tfm, key, keylen, SEC_C_DES_ECB_64);
350 static int sec_alg_skcipher_setkey_des_cbc(struct crypto_skcipher *tfm,
353 return verify_skcipher_des_key(tfm, key) ?:
354 sec_alg_skcipher_setkey(tfm, key, keylen, SEC_C_DES_CBC_64);
357 static int sec_alg_skcipher_setkey_3des_ecb(struct crypto_skcipher *tfm,
360 return verify_skcipher_des3_key(tfm, key) ?:
361 sec_alg_skcipher_setkey(tfm, key, keylen,
365 static int sec_alg_skcipher_setkey_3des_cbc(struct crypto_skcipher *tfm,
368 return verify_skcipher_des3_key(tfm, key) ?:
369 sec_alg_skcipher_setkey(tfm, key, keylen,
711 struct crypto_tfm *tfm = crypto_skcipher_tfm(atfm);
712 struct sec_alg_tfm_ctx *ctx = crypto_tfm_ctx(tfm);
872 static int sec_alg_skcipher_init(struct crypto_skcipher *tfm)
874 struct sec_alg_tfm_ctx *ctx = crypto_skcipher_ctx(tfm);
878 crypto_skcipher_set_reqsize(tfm, sizeof(struct sec_request));
890 static void sec_alg_skcipher_exit(struct crypto_skcipher *tfm)
892 struct sec_alg_tfm_ctx *ctx = crypto_skcipher_ctx(tfm);
903 static int sec_alg_skcipher_init_with_queue(struct crypto_skcipher *tfm)
905 struct sec_alg_tfm_ctx *ctx = crypto_skcipher_ctx(tfm);
908 ret = sec_alg_skcipher_init(tfm);
915 sec_alg_skcipher_exit(tfm);
923 static void sec_alg_skcipher_exit_with_queue(struct crypto_skcipher *tfm)
925 struct sec_alg_tfm_ctx *ctx = crypto_skcipher_ctx(tfm);
928 sec_alg_skcipher_exit(tfm);