/linux/include/crypto/ |
H A D | aead.h | 140 int (*setkey)(struct crypto_aead *tfm, const u8 *key, 142 int (*setauthsize)(struct crypto_aead *tfm, unsigned int authsize); 145 int (*init)(struct crypto_aead *tfm); 146 void (*exit)(struct crypto_aead *tfm); 162 static inline struct crypto_aead *__crypto_aead_cast(struct crypto_tfm *tfm) in __crypto_aead_cast() argument 164 return container_of(tfm, struct crypto_aead, base); in __crypto_aead_cast() 183 static inline struct crypto_tfm *crypto_aead_tfm(struct crypto_aead *tfm) in crypto_aead_tfm() argument 185 return &tfm->base; in crypto_aead_tfm() 194 static inline void crypto_free_aead(struct crypto_aead *tfm) in crypto_free_aead() argument 196 crypto_destroy_tfm(tfm, crypto_aead_tfm(tfm)); in crypto_free_aead() [all …]
|
H A D | kpp.h | 78 int (*set_secret)(struct crypto_kpp *tfm, const void *buffer, 83 unsigned int (*max_size)(struct crypto_kpp *tfm); 85 int (*init)(struct crypto_kpp *tfm); 86 void (*exit)(struct crypto_kpp *tfm); 114 static inline struct crypto_tfm *crypto_kpp_tfm(struct crypto_kpp *tfm) in crypto_kpp_tfm() argument 116 return &tfm->base; in crypto_kpp_tfm() 124 static inline struct crypto_kpp *__crypto_kpp_tfm(struct crypto_tfm *tfm) in __crypto_kpp_tfm() argument 126 return container_of(tfm, struct crypto_kpp, base); in __crypto_kpp_tfm() 129 static inline struct kpp_alg *crypto_kpp_alg(struct crypto_kpp *tfm) in crypto_kpp_alg() argument 131 return __crypto_kpp_alg(crypto_kpp_tfm(tfm)->__crt_alg); in crypto_kpp_alg() [all …]
|
H A D | rng.h | 44 int (*generate)(struct crypto_rng *tfm, 47 int (*seed)(struct crypto_rng *tfm, const u8 *seed, unsigned int slen); 48 void (*set_ent)(struct crypto_rng *tfm, const u8 *data, 94 static inline struct crypto_tfm *crypto_rng_tfm(struct crypto_rng *tfm) in crypto_rng_tfm() argument 96 return &tfm->base; in crypto_rng_tfm() 112 static inline struct rng_alg *crypto_rng_alg(struct crypto_rng *tfm) in crypto_rng_alg() argument 114 return __crypto_rng_alg(crypto_rng_tfm(tfm)->__crt_alg); in crypto_rng_alg() 123 static inline void crypto_free_rng(struct crypto_rng *tfm) in crypto_free_rng() argument 125 crypto_destroy_tfm(tfm, crypto_rng_tfm(tfm)); in crypto_free_rng() 142 static inline int crypto_rng_generate(struct crypto_rng *tfm, in crypto_rng_generate() argument [all …]
|
H A D | acompress.h | 106 static inline struct crypto_tfm *crypto_acomp_tfm(struct crypto_acomp *tfm) in crypto_acomp_tfm() argument 108 return &tfm->base; in crypto_acomp_tfm() 117 static inline struct crypto_acomp *__crypto_acomp_tfm(struct crypto_tfm *tfm) in __crypto_acomp_tfm() argument 119 return container_of(tfm, struct crypto_acomp, base); in __crypto_acomp_tfm() 123 struct crypto_acomp *tfm) in crypto_comp_alg_common() argument 125 return __crypto_comp_alg_common(crypto_acomp_tfm(tfm)->__crt_alg); in crypto_comp_alg_common() 128 static inline unsigned int crypto_acomp_reqsize(struct crypto_acomp *tfm) in crypto_acomp_reqsize() argument 130 return tfm->reqsize; in crypto_acomp_reqsize() 134 struct crypto_acomp *tfm) in acomp_request_set_tfm() argument 136 req->base.tfm = crypto_acomp_tfm(tfm); in acomp_request_set_tfm() [all …]
|
H A D | cryptd.h | 29 struct crypto_skcipher *cryptd_skcipher_child(struct cryptd_skcipher *tfm); 31 bool cryptd_skcipher_queued(struct cryptd_skcipher *tfm); 32 void cryptd_free_skcipher(struct cryptd_skcipher *tfm); 39 struct crypto_ahash *tfm) in __cryptd_ahash_cast() argument 41 return (struct cryptd_ahash *)tfm; in __cryptd_ahash_cast() 47 struct crypto_shash *cryptd_ahash_child(struct cryptd_ahash *tfm); 50 bool cryptd_ahash_queued(struct cryptd_ahash *tfm); 51 void cryptd_free_ahash(struct cryptd_ahash *tfm); 58 struct crypto_aead *tfm) in __cryptd_aead_cast() argument 60 return (struct cryptd_aead *)tfm; in __cryptd_aead_cast() [all …]
|
/linux/security/integrity/ima/ |
H A D | ima_crypto.c | 88 struct crypto_shash *tfm = ima_shash_tfm; in ima_alloc_tfm() local 95 return tfm; in ima_alloc_tfm() 98 if (ima_algo_array[i].tfm && ima_algo_array[i].algo == algo) in ima_alloc_tfm() 99 return ima_algo_array[i].tfm; in ima_alloc_tfm() 101 tfm = crypto_alloc_shash(hash_algo_name[algo], 0, 0); in ima_alloc_tfm() 102 if (IS_ERR(tfm)) { in ima_alloc_tfm() 103 rc = PTR_ERR(tfm); in ima_alloc_tfm() 107 return tfm; in ima_alloc_tfm() 157 ima_algo_array[i].tfm = ima_shash_tfm; in ima_init_crypto() 161 ima_algo_array[i].tfm = ima_alloc_tfm(algo); in ima_init_crypto() [all …]
|
/linux/include/linux/ |
H A D | crypto.h | 174 struct crypto_tfm *tfm; member 236 int (*cia_setkey)(struct crypto_tfm *tfm, const u8 *key, 238 void (*cia_encrypt)(struct crypto_tfm *tfm, u8 *dst, const u8 *src); 239 void (*cia_decrypt)(struct crypto_tfm *tfm, u8 *dst, const u8 *src); 254 int (*coa_compress)(struct crypto_tfm *tfm, const u8 *src, 256 int (*coa_decompress)(struct crypto_tfm *tfm, const u8 *src, 365 int (*cra_init)(struct crypto_tfm *tfm); 366 void (*cra_exit)(struct crypto_tfm *tfm); 429 void (*exit)(struct crypto_tfm *tfm); 445 void crypto_destroy_tfm(void *mem, struct crypto_tfm *tfm); [all …]
|
/linux/include/crypto/internal/ |
H A D | scompress.h | 34 void *(*alloc_ctx)(struct crypto_scomp *tfm); 35 void (*free_ctx)(struct crypto_scomp *tfm, void *ctx); 36 int (*compress)(struct crypto_scomp *tfm, const u8 *src, 39 int (*decompress)(struct crypto_scomp *tfm, const u8 *src, 54 static inline struct crypto_scomp *__crypto_scomp_tfm(struct crypto_tfm *tfm) in __crypto_scomp_tfm() argument 56 return container_of(tfm, struct crypto_scomp, base); in __crypto_scomp_tfm() 59 static inline struct crypto_tfm *crypto_scomp_tfm(struct crypto_scomp *tfm) in crypto_scomp_tfm() argument 61 return &tfm->base; in crypto_scomp_tfm() 64 static inline void crypto_free_scomp(struct crypto_scomp *tfm) in crypto_free_scomp() argument 66 crypto_destroy_tfm(tfm, crypto_scomp_tfm(tfm)); in crypto_free_scomp() [all …]
|
H A D | cipher.h | 37 static inline struct crypto_cipher *__crypto_cipher_cast(struct crypto_tfm *tfm) in __crypto_cipher_cast() argument 39 return (struct crypto_cipher *)tfm; in __crypto_cipher_cast() 66 static inline struct crypto_tfm *crypto_cipher_tfm(struct crypto_cipher *tfm) in crypto_cipher_tfm() argument 68 return &tfm->base; in crypto_cipher_tfm() 75 static inline void crypto_free_cipher(struct crypto_cipher *tfm) in crypto_free_cipher() argument 77 crypto_free_tfm(crypto_cipher_tfm(tfm)); in crypto_free_cipher() 109 static inline unsigned int crypto_cipher_blocksize(struct crypto_cipher *tfm) in crypto_cipher_blocksize() argument 111 return crypto_tfm_alg_blocksize(crypto_cipher_tfm(tfm)); in crypto_cipher_blocksize() 114 static inline unsigned int crypto_cipher_alignmask(struct crypto_cipher *tfm) in crypto_cipher_alignmask() argument 116 return crypto_tfm_alg_alignmask(crypto_cipher_tfm(tfm)); in crypto_cipher_alignmask() [all …]
|
H A D | des.h | 26 static inline int crypto_des_verify_key(struct crypto_tfm *tfm, const u8 *key) in crypto_des_verify_key() argument 33 if (crypto_tfm_get_flags(tfm) & CRYPTO_TFM_REQ_FORBID_WEAK_KEYS) in crypto_des_verify_key() 91 static inline int crypto_des3_ede_verify_key(struct crypto_tfm *tfm, in crypto_des3_ede_verify_key() argument 95 crypto_tfm_get_flags(tfm) & in crypto_des3_ede_verify_key() 99 static inline int verify_skcipher_des_key(struct crypto_skcipher *tfm, in verify_skcipher_des_key() argument 102 return crypto_des_verify_key(crypto_skcipher_tfm(tfm), key); in verify_skcipher_des_key() 105 static inline int verify_skcipher_des3_key(struct crypto_skcipher *tfm, in verify_skcipher_des3_key() argument 108 return crypto_des3_ede_verify_key(crypto_skcipher_tfm(tfm), key); in verify_skcipher_des3_key() 111 static inline int verify_aead_des_key(struct crypto_aead *tfm, const u8 *key, in verify_aead_des_key() argument 116 return crypto_des_verify_key(crypto_aead_tfm(tfm), key); in verify_aead_des_key() [all …]
|
/linux/crypto/ |
H A D | cipher.c | 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 [all …]
|
H A D | shash.c | 19 int shash_no_setkey(struct crypto_shash *tfm, const u8 *key, in shash_no_setkey() argument 26 static void shash_set_needkey(struct crypto_shash *tfm, struct shash_alg *alg) in shash_set_needkey() argument 29 crypto_shash_set_flags(tfm, CRYPTO_TFM_NEED_KEY); in shash_set_needkey() 32 int crypto_shash_setkey(struct crypto_shash *tfm, const u8 *key, in crypto_shash_setkey() argument 35 struct shash_alg *shash = crypto_shash_alg(tfm); in crypto_shash_setkey() 38 err = shash->setkey(tfm, key, keylen); in crypto_shash_setkey() 40 shash_set_needkey(tfm, shash); in crypto_shash_setkey() 44 crypto_shash_clear_flags(tfm, CRYPTO_TFM_NEED_KEY); in crypto_shash_setkey() 52 return crypto_shash_alg(desc->tfm)->update(desc, data, len); in crypto_shash_update() 58 return crypto_shash_alg(desc->tfm)->final(desc, out); in crypto_shash_final() [all …]
|
H A D | jitterentropy-kcapi.c | 109 SHASH_DESC_ON_STACK(desc, hash_state_desc->tfm); in jent_hash_time() 114 desc->tfm = hash_state_desc->tfm; in jent_hash_time() 116 if (sizeof(intermediary) != crypto_shash_digestsize(desc->tfm)) { in jent_hash_time() 196 struct crypto_shash *tfm; member 200 static void jent_kcapi_cleanup(struct crypto_tfm *tfm) in jent_kcapi_cleanup() argument 202 struct jitterentropy *rng = crypto_tfm_ctx(tfm); in jent_kcapi_cleanup() 212 if (rng->tfm) in jent_kcapi_cleanup() 213 crypto_free_shash(rng->tfm); in jent_kcapi_cleanup() 214 rng->tfm = NULL; in jent_kcapi_cleanup() 222 static int jent_kcapi_init(struct crypto_tfm *tfm) in jent_kcapi_init() argument [all …]
|
H A D | cryptd.c | 141 refcnt = crypto_tfm_ctx(request->tfm); in cryptd_enqueue_request() 187 static inline struct cryptd_queue *cryptd_get_queue(struct crypto_tfm *tfm) in cryptd_get_queue() argument 189 struct crypto_instance *inst = crypto_tfm_alg_instance(tfm); in cryptd_get_queue() 270 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(req); in cryptd_skcipher_complete() local 271 struct cryptd_skcipher_ctx *ctx = crypto_skcipher_ctx(tfm); in cryptd_skcipher_complete() 285 crypto_free_skcipher(tfm); in cryptd_skcipher_complete() 316 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(req); in cryptd_skcipher_enqueue() local 320 queue = cryptd_get_queue(crypto_skcipher_tfm(tfm)); in cryptd_skcipher_enqueue() 339 static int cryptd_skcipher_init_tfm(struct crypto_skcipher *tfm) in cryptd_skcipher_init_tfm() argument 341 struct skcipher_instance *inst = skcipher_alg_instance(tfm); in cryptd_skcipher_init_tfm() [all …]
|
H A D | api.c | 365 static void crypto_exit_ops(struct crypto_tfm *tfm) in crypto_exit_ops() argument 367 const struct crypto_type *type = tfm->__crt_alg->cra_type; in crypto_exit_ops() 369 if (type && tfm->exit) in crypto_exit_ops() 370 tfm->exit(tfm); in crypto_exit_ops() 409 struct crypto_tfm *tfm; in __crypto_alloc_tfmgfp() local 413 tfm_size = sizeof(*tfm) + crypto_ctxsize(alg, type, mask); in __crypto_alloc_tfmgfp() 414 tfm = kzalloc(tfm_size, gfp); in __crypto_alloc_tfmgfp() 415 if (tfm == NULL) in __crypto_alloc_tfmgfp() 418 tfm->__crt_alg = alg; in __crypto_alloc_tfmgfp() 419 refcount_set(&tfm->refcnt, 1); in __crypto_alloc_tfmgfp() [all …]
|
H A D | lskcipher.c | 21 struct crypto_tfm *tfm) in __crypto_lskcipher_cast() argument 23 return container_of(tfm, struct crypto_lskcipher, base); in __crypto_lskcipher_cast() 32 static int lskcipher_setkey_unaligned(struct crypto_lskcipher *tfm, in lskcipher_setkey_unaligned() argument 35 unsigned long alignmask = crypto_lskcipher_alignmask(tfm); in lskcipher_setkey_unaligned() 36 struct lskcipher_alg *cipher = crypto_lskcipher_alg(tfm); in lskcipher_setkey_unaligned() 48 ret = cipher->setkey(tfm, alignbuffer, keylen); in lskcipher_setkey_unaligned() 53 int crypto_lskcipher_setkey(struct crypto_lskcipher *tfm, const u8 *key, in crypto_lskcipher_setkey() argument 56 unsigned long alignmask = crypto_lskcipher_alignmask(tfm); in crypto_lskcipher_setkey() 57 struct lskcipher_alg *cipher = crypto_lskcipher_alg(tfm); in crypto_lskcipher_setkey() 63 return lskcipher_setkey_unaligned(tfm, key, keylen); in crypto_lskcipher_setkey() [all …]
|
H A D | bpf_crypto_skcipher.c | 13 static void bpf_crypto_lskcipher_free_tfm(void *tfm) in bpf_crypto_lskcipher_free_tfm() argument 15 crypto_free_lskcipher(tfm); in bpf_crypto_lskcipher_free_tfm() 23 static int bpf_crypto_lskcipher_setkey(void *tfm, const u8 *key, unsigned int keylen) in bpf_crypto_lskcipher_setkey() argument 25 return crypto_lskcipher_setkey(tfm, key, keylen); in bpf_crypto_lskcipher_setkey() 28 static u32 bpf_crypto_lskcipher_get_flags(void *tfm) in bpf_crypto_lskcipher_get_flags() argument 30 return crypto_lskcipher_get_flags(tfm); in bpf_crypto_lskcipher_get_flags() 33 static unsigned int bpf_crypto_lskcipher_ivsize(void *tfm) in bpf_crypto_lskcipher_ivsize() argument 35 return crypto_lskcipher_ivsize(tfm); in bpf_crypto_lskcipher_ivsize() 38 static unsigned int bpf_crypto_lskcipher_statesize(void *tfm) in bpf_crypto_lskcipher_statesize() argument 40 return crypto_lskcipher_statesize(tfm); in bpf_crypto_lskcipher_statesize() [all …]
|
H A D | des_generic.c | 19 static int des_setkey(struct crypto_tfm *tfm, const u8 *key, in des_setkey() argument 22 struct des_ctx *dctx = crypto_tfm_ctx(tfm); in des_setkey() 27 if (crypto_tfm_get_flags(tfm) & CRYPTO_TFM_REQ_FORBID_WEAK_KEYS) in des_setkey() 37 static void crypto_des_encrypt(struct crypto_tfm *tfm, u8 *dst, const u8 *src) in crypto_des_encrypt() argument 39 const struct des_ctx *dctx = crypto_tfm_ctx(tfm); in crypto_des_encrypt() 44 static void crypto_des_decrypt(struct crypto_tfm *tfm, u8 *dst, const u8 *src) in crypto_des_decrypt() argument 46 const struct des_ctx *dctx = crypto_tfm_ctx(tfm); in crypto_des_decrypt() 51 static int des3_ede_setkey(struct crypto_tfm *tfm, const u8 *key, in des3_ede_setkey() argument 54 struct des3_ede_ctx *dctx = crypto_tfm_ctx(tfm); in des3_ede_setkey() 59 if (crypto_tfm_get_flags(tfm) & CRYPTO_TFM_REQ_FORBID_WEAK_KEYS) in des3_ede_setkey() [all …]
|
/linux/fs/verity/ |
H A D | hash_algs.c | 46 struct crypto_shash *tfm; in fsverity_get_hash_alg() local 57 if (likely(smp_load_acquire(&alg->tfm) != NULL)) in fsverity_get_hash_alg() 62 if (alg->tfm != NULL) in fsverity_get_hash_alg() 65 tfm = crypto_alloc_shash(alg->name, 0, 0); in fsverity_get_hash_alg() 66 if (IS_ERR(tfm)) { in fsverity_get_hash_alg() 67 if (PTR_ERR(tfm) == -ENOENT) { in fsverity_get_hash_alg() 76 alg->name, PTR_ERR(tfm)); in fsverity_get_hash_alg() 77 alg = ERR_CAST(tfm); in fsverity_get_hash_alg() 82 if (WARN_ON_ONCE(alg->digest_size != crypto_shash_digestsize(tfm))) in fsverity_get_hash_alg() 84 if (WARN_ON_ONCE(alg->block_size != crypto_shash_blocksize(tfm))) in fsverity_get_hash_alg() [all …]
|
/linux/net/mac80211/ |
H A D | aes_cmac.c | 25 void ieee80211_aes_cmac(struct crypto_shash *tfm, const u8 *aad, in ieee80211_aes_cmac() argument 28 SHASH_DESC_ON_STACK(desc, tfm); in ieee80211_aes_cmac() 32 desc->tfm = tfm; in ieee80211_aes_cmac() 49 void ieee80211_aes_cmac_256(struct crypto_shash *tfm, const u8 *aad, in ieee80211_aes_cmac_256() argument 52 SHASH_DESC_ON_STACK(desc, tfm); in ieee80211_aes_cmac_256() 55 desc->tfm = tfm; in ieee80211_aes_cmac_256() 74 struct crypto_shash *tfm; in ieee80211_aes_cmac_key_setup() local 76 tfm = crypto_alloc_shash("cmac(aes)", 0, 0); in ieee80211_aes_cmac_key_setup() 77 if (!IS_ERR(tfm)) { in ieee80211_aes_cmac_key_setup() 78 int err = crypto_shash_setkey(tfm, key, key_len); in ieee80211_aes_cmac_key_setup() [all …]
|
H A D | aead_api.c | 18 int aead_encrypt(struct crypto_aead *tfm, u8 *b_0, u8 *aad, size_t aad_len, in aead_encrypt() argument 21 size_t mic_len = crypto_aead_authsize(tfm); in aead_encrypt() 24 int reqsize = sizeof(*aead_req) + crypto_aead_reqsize(tfm); in aead_encrypt() 40 aead_request_set_tfm(aead_req, tfm); in aead_encrypt() 50 int aead_decrypt(struct crypto_aead *tfm, u8 *b_0, u8 *aad, size_t aad_len, in aead_decrypt() argument 53 size_t mic_len = crypto_aead_authsize(tfm); in aead_decrypt() 56 int reqsize = sizeof(*aead_req) + crypto_aead_reqsize(tfm); in aead_decrypt() 75 aead_request_set_tfm(aead_req, tfm); in aead_decrypt() 89 struct crypto_aead *tfm; in aead_key_setup_encrypt() local 92 tfm = crypto_alloc_aead(alg, 0, CRYPTO_ALG_ASYNC); in aead_key_setup_encrypt() [all …]
|
H A D | aes_gmac.c | 17 int ieee80211_aes_gmac(struct crypto_aead *tfm, const u8 *aad, u8 *nonce, in ieee80211_aes_gmac() argument 23 int reqsize = sizeof(*aead_req) + crypto_aead_reqsize(tfm); in ieee80211_aes_gmac() 59 aead_request_set_tfm(aead_req, tfm); in ieee80211_aes_gmac() 72 struct crypto_aead *tfm; in ieee80211_aes_gmac_key_setup() local 75 tfm = crypto_alloc_aead("gcm(aes)", 0, CRYPTO_ALG_ASYNC); in ieee80211_aes_gmac_key_setup() 76 if (IS_ERR(tfm)) in ieee80211_aes_gmac_key_setup() 77 return tfm; in ieee80211_aes_gmac_key_setup() 79 err = crypto_aead_setkey(tfm, key, key_len); in ieee80211_aes_gmac_key_setup() 81 err = crypto_aead_setauthsize(tfm, GMAC_MIC_LEN); in ieee80211_aes_gmac_key_setup() 83 return tfm; in ieee80211_aes_gmac_key_setup() [all …]
|
/linux/drivers/crypto/inside-secure/ |
H A D | safexcel_cipher.c | 374 struct crypto_tfm *tfm = crypto_skcipher_tfm(ctfm); in safexcel_skcipher_aes_setkey() local 375 struct safexcel_cipher_ctx *ctx = crypto_tfm_ctx(tfm); in safexcel_skcipher_aes_setkey() 405 struct crypto_tfm *tfm = crypto_aead_tfm(ctfm); in safexcel_aead_setkey() local 406 struct safexcel_cipher_ctx *ctx = crypto_tfm_ctx(tfm); in safexcel_aead_setkey() 682 struct safexcel_cipher_ctx *ctx = crypto_tfm_ctx(base->tfm); in safexcel_send_req() 923 struct safexcel_cipher_ctx *ctx = crypto_tfm_ctx(base->tfm); in safexcel_handle_inv_result() 1004 struct crypto_aead *tfm = crypto_aead_reqtfm(req); in safexcel_aead_handle_result() local 1015 req->cryptlen + crypto_aead_authsize(tfm), in safexcel_aead_handle_result() 1025 struct safexcel_cipher_ctx *ctx = crypto_tfm_ctx(base->tfm); in safexcel_cipher_send_inv() 1043 struct safexcel_cipher_ctx *ctx = crypto_tfm_ctx(req->base.tfm); in safexcel_skcipher_send() [all …]
|
/linux/drivers/crypto/allwinner/sun4i-ss/ |
H A D | sun4i-ss-cipher.c | 17 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(areq); in sun4i_ss_opti_poll() local 18 struct sun4i_tfm_ctx *op = crypto_skcipher_ctx(tfm); in sun4i_ss_opti_poll() 20 unsigned int ivsize = crypto_skcipher_ivsize(tfm); in sun4i_ss_opti_poll() 38 struct skcipher_alg *alg = crypto_skcipher_alg(tfm); in sun4i_ss_opti_poll() 150 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(areq); in sun4i_ss_cipher_poll_fallback() local 151 struct sun4i_tfm_ctx *op = crypto_skcipher_ctx(tfm); in sun4i_ss_cipher_poll_fallback() 154 struct skcipher_alg *alg = crypto_skcipher_alg(tfm); in sun4i_ss_cipher_poll_fallback() 178 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(areq); in sun4i_ss_cipher_poll() local 179 struct sun4i_tfm_ctx *op = crypto_skcipher_ctx(tfm); in sun4i_ss_cipher_poll() 184 unsigned int ivsize = crypto_skcipher_ivsize(tfm); in sun4i_ss_cipher_poll() [all …]
|
/linux/fs/smb/server/ |
H A D | crypto_ctx.c | 34 crypto_free_shash(shash->tfm); in free_shash() 41 struct crypto_aead *tfm = NULL; in alloc_aead() local 45 tfm = crypto_alloc_aead("gcm(aes)", 0, 0); in alloc_aead() 48 tfm = crypto_alloc_aead("ccm(aes)", 0, 0); in alloc_aead() 55 if (IS_ERR(tfm)) { in alloc_aead() 56 pr_err("Failed to alloc encrypt aead : %ld\n", PTR_ERR(tfm)); in alloc_aead() 60 return tfm; in alloc_aead() 65 struct crypto_shash *tfm = NULL; in alloc_shash_desc() local 70 tfm = crypto_alloc_shash("hmac(md5)", 0, 0); in alloc_shash_desc() 73 tfm = crypto_alloc_shash("hmac(sha256)", 0, 0); in alloc_shash_desc() [all …]
|