/drivers/crypto/bcm/ |
D | cipher.c | 325 cipher_parms.alg = ctx->cipher.alg; in handle_skcipher_req() 415 0, ctx->auth.alg, ctx->auth.mode, in handle_skcipher_req() 502 &iproc_priv.cipher_cnt[ctx->cipher.alg][ctx->cipher.mode]); in handle_skcipher_resp() 704 hash_parms.alg = ctx->auth.alg; in handle_ahash_req() 773 if (hash_parms.alg == HASH_ALG_AES) in handle_ahash_req() 778 digestsize = spu->spu_digest_size(ctx->digestsize, ctx->auth.alg, in handle_ahash_req() 788 hash_parms.pad_len = spu->spu_hash_pad_len(hash_parms.alg, in handle_ahash_req() 798 (hash_parms.alg != HASH_ALG_AES)) { in handle_ahash_req() 845 hash_parms.pad_len, ctx->auth.alg, in handle_ahash_req() 905 switch (ctx->auth.alg) { in spu_hmac_outer_hash() [all …]
|
D | util.c | 296 char *spu_alg_name(enum spu_cipher_alg alg, enum spu_cipher_mode mode) in spu_alg_name() argument 298 switch (alg) { in spu_alg_name() 359 u32 alg; in spu_debugfs_read() local 386 for (alg = 0; alg < CIPHER_ALG_LAST; alg++) { in spu_debugfs_read() 388 op_cnt = atomic_read(&ipriv->cipher_cnt[alg][mode]); in spu_debugfs_read() 393 spu_alg_name(alg, mode), op_cnt); in spu_debugfs_read() 400 for (alg = 0; alg < HASH_ALG_LAST; alg++) { in spu_debugfs_read() 401 op_cnt = atomic_read(&ipriv->hash_cnt[alg]); in spu_debugfs_read() 406 hash_alg_name[alg], op_cnt); in spu_debugfs_read() 415 for (alg = 0; alg < HASH_ALG_LAST; alg++) { in spu_debugfs_read() [all …]
|
/drivers/crypto/ccp/ |
D | ccp-crypto-aes-xts.c | 230 struct skcipher_alg *alg; in ccp_register_aes_xts_alg() local 239 alg = &ccp_alg->alg; in ccp_register_aes_xts_alg() 241 snprintf(alg->base.cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); in ccp_register_aes_xts_alg() 242 snprintf(alg->base.cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", in ccp_register_aes_xts_alg() 244 alg->base.cra_flags = CRYPTO_ALG_ASYNC | in ccp_register_aes_xts_alg() 248 alg->base.cra_blocksize = AES_BLOCK_SIZE; in ccp_register_aes_xts_alg() 249 alg->base.cra_ctxsize = sizeof(struct ccp_ctx); in ccp_register_aes_xts_alg() 250 alg->base.cra_priority = CCP_CRA_PRIORITY; in ccp_register_aes_xts_alg() 251 alg->base.cra_module = THIS_MODULE; in ccp_register_aes_xts_alg() 253 alg->setkey = ccp_aes_xts_setkey; in ccp_register_aes_xts_alg() [all …]
|
D | ccp-crypto-sha.c | 187 struct ccp_crypto_ahash_alg *alg = in ccp_sha_init() local 194 rctx->type = alg->type; in ccp_sha_init() 334 struct ccp_crypto_ahash_alg *alg = ccp_crypto_ahash_alg(tfm); in ccp_hmac_sha_cra_init() local 337 hmac_tfm = crypto_alloc_shash(alg->child_alg, 0, 0); in ccp_hmac_sha_cra_init() 340 alg->child_alg); in ccp_hmac_sha_cra_init() 416 struct ahash_alg *alg; in ccp_register_hmac_alg() local 431 alg = &ccp_alg->alg; in ccp_register_hmac_alg() 432 alg->setkey = ccp_sha_setkey; in ccp_register_hmac_alg() 434 halg = &alg->halg; in ccp_register_hmac_alg() 443 ret = crypto_register_ahash(alg); in ccp_register_hmac_alg() [all …]
|
D | ccp-crypto-des3.c | 39 struct ccp_crypto_skcipher_alg *alg = ccp_crypto_skcipher_alg(tfm); in ccp_des3_setkey() local 51 ctx->u.des3.mode = alg->mode; in ccp_des3_setkey() 183 struct skcipher_alg *alg; in ccp_register_des3_alg() local 195 alg = &ccp_alg->alg; in ccp_register_des3_alg() 196 *alg = *def->alg_defaults; in ccp_register_des3_alg() 197 snprintf(alg->base.cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); in ccp_register_des3_alg() 198 snprintf(alg->base.cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", in ccp_register_des3_alg() 200 alg->base.cra_blocksize = def->blocksize; in ccp_register_des3_alg() 201 alg->ivsize = def->ivsize; in ccp_register_des3_alg() 203 ret = crypto_register_skcipher(alg); in ccp_register_des3_alg() [all …]
|
D | ccp-crypto.h | 41 struct skcipher_alg alg; member 49 struct aead_alg alg; member 62 struct ahash_alg alg; member 68 struct akcipher_alg alg; member 74 struct skcipher_alg *alg = crypto_skcipher_alg(tfm); in ccp_crypto_skcipher_alg() local 76 return container_of(alg, struct ccp_crypto_skcipher_alg, alg); in ccp_crypto_skcipher_alg() 82 struct crypto_alg *alg = tfm->__crt_alg; in ccp_crypto_ahash_alg() local 85 ahash_alg = container_of(alg, struct ahash_alg, halg.base); in ccp_crypto_ahash_alg() 87 return container_of(ahash_alg, struct ccp_crypto_ahash_alg, alg); in ccp_crypto_ahash_alg()
|
D | ccp-crypto-aes-cmac.c | 260 struct ccp_crypto_ahash_alg *alg = in ccp_aes_cmac_setkey() local 281 ctx->u.aes.mode = alg->mode; in ccp_aes_cmac_setkey() 351 struct ahash_alg *alg; in ccp_register_aes_cmac_algs() local 363 alg = &ccp_alg->alg; in ccp_register_aes_cmac_algs() 364 alg->init = ccp_aes_cmac_init; in ccp_register_aes_cmac_algs() 365 alg->update = ccp_aes_cmac_update; in ccp_register_aes_cmac_algs() 366 alg->final = ccp_aes_cmac_final; in ccp_register_aes_cmac_algs() 367 alg->finup = ccp_aes_cmac_finup; in ccp_register_aes_cmac_algs() 368 alg->digest = ccp_aes_cmac_digest; in ccp_register_aes_cmac_algs() 369 alg->export = ccp_aes_cmac_export; in ccp_register_aes_cmac_algs() [all …]
|
D | ccp-crypto-aes.c | 40 struct ccp_crypto_skcipher_alg *alg = ccp_crypto_skcipher_alg(tfm); in ccp_aes_setkey() local 56 ctx->u.aes.mode = alg->mode; in ccp_aes_setkey() 313 struct skcipher_alg *alg; in ccp_register_aes_alg() local 325 alg = &ccp_alg->alg; in ccp_register_aes_alg() 326 *alg = *def->alg_defaults; in ccp_register_aes_alg() 327 snprintf(alg->base.cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); in ccp_register_aes_alg() 328 snprintf(alg->base.cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", in ccp_register_aes_alg() 330 alg->base.cra_blocksize = def->blocksize; in ccp_register_aes_alg() 331 alg->ivsize = def->ivsize; in ccp_register_aes_alg() 333 ret = crypto_register_skcipher(alg); in ccp_register_aes_alg() [all …]
|
D | ccp-crypto-aes-galois.c | 212 struct aead_alg *alg; in ccp_register_aes_aead() local 224 alg = &ccp_aead->alg; in ccp_register_aes_aead() 225 *alg = *def->alg_defaults; in ccp_register_aes_aead() 226 snprintf(alg->base.cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); in ccp_register_aes_aead() 227 snprintf(alg->base.cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", in ccp_register_aes_aead() 229 alg->base.cra_blocksize = def->blocksize; in ccp_register_aes_aead() 231 ret = crypto_register_aead(alg); in ccp_register_aes_aead() 234 alg->base.cra_name, ret); in ccp_register_aes_aead()
|
/drivers/staging/rtl8192u/ieee80211/ |
D | ieee80211_crypt.c | 101 struct ieee80211_crypto_alg *alg; in ieee80211_register_crypto_ops() local 106 alg = kzalloc(sizeof(*alg), GFP_KERNEL); in ieee80211_register_crypto_ops() 107 if (!alg) in ieee80211_register_crypto_ops() 110 alg->ops = ops; in ieee80211_register_crypto_ops() 113 list_add(&alg->list, &hcrypt->algs); in ieee80211_register_crypto_ops() 133 struct ieee80211_crypto_alg *alg = in ieee80211_unregister_crypto_ops() local 135 if (alg->ops == ops) { in ieee80211_unregister_crypto_ops() 136 list_del(&alg->list); in ieee80211_unregister_crypto_ops() 137 del_alg = alg; in ieee80211_unregister_crypto_ops() 164 struct ieee80211_crypto_alg *alg = in ieee80211_get_crypto_ops() local [all …]
|
/drivers/crypto/allwinner/sun4i-ss/ |
D | sun4i-ss-core.c | 38 .alg.hash = { 65 .alg.hash = { 91 .alg.crypto = { 113 .alg.crypto = { 134 .alg.crypto = { 156 .alg.crypto = { 177 .alg.crypto = { 199 .alg.crypto = { 222 .alg.rng = { 248 ss_algs[i].alg.crypto.base.cra_driver_name, in sun4i_ss_dbgfs_read() [all …]
|
D | sun4i-ss-prng.c | 8 struct rng_alg *alg = crypto_rng_alg(tfm); in sun4i_ss_prng_seed() local 10 algt = container_of(alg, struct sun4i_ss_alg_template, alg.rng); in sun4i_ss_prng_seed() 20 struct rng_alg *alg = crypto_rng_alg(tfm); in sun4i_ss_prng_generate() local 29 algt = container_of(alg, struct sun4i_ss_alg_template, alg.rng); in sun4i_ss_prng_generate()
|
/drivers/crypto/qce/ |
D | skcipher.c | 440 struct skcipher_alg *alg; in qce_skcipher_register_one() local 447 alg = &tmpl->alg.skcipher; in qce_skcipher_register_one() 449 snprintf(alg->base.cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); in qce_skcipher_register_one() 450 snprintf(alg->base.cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", in qce_skcipher_register_one() 453 alg->base.cra_blocksize = def->blocksize; in qce_skcipher_register_one() 454 alg->chunksize = def->chunksize; in qce_skcipher_register_one() 455 alg->ivsize = def->ivsize; in qce_skcipher_register_one() 456 alg->min_keysize = def->min_keysize; in qce_skcipher_register_one() 457 alg->max_keysize = def->max_keysize; in qce_skcipher_register_one() 458 alg->setkey = IS_3DES(def->flags) ? qce_des3_setkey : in qce_skcipher_register_one() [all …]
|
D | sha.c | 283 tmpl->alg.ahash.halg.digestsize); in qce_ahash_final() 320 tmpl->alg.ahash.halg.digestsize); in qce_ahash_digest() 454 struct ahash_alg *alg; in qce_ahash_register_one() local 464 alg = &tmpl->alg.ahash; in qce_ahash_register_one() 465 alg->init = qce_ahash_init; in qce_ahash_register_one() 466 alg->update = qce_ahash_update; in qce_ahash_register_one() 467 alg->final = qce_ahash_final; in qce_ahash_register_one() 468 alg->digest = qce_ahash_digest; in qce_ahash_register_one() 469 alg->export = qce_ahash_export; in qce_ahash_register_one() 470 alg->import = qce_ahash_import; in qce_ahash_register_one() [all …]
|
D | aead.c | 762 struct aead_alg *alg; in qce_aead_register_one() local 769 alg = &tmpl->alg.aead; in qce_aead_register_one() 771 snprintf(alg->base.cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); in qce_aead_register_one() 772 snprintf(alg->base.cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s", in qce_aead_register_one() 775 alg->base.cra_blocksize = def->blocksize; in qce_aead_register_one() 776 alg->chunksize = def->chunksize; in qce_aead_register_one() 777 alg->ivsize = def->ivsize; in qce_aead_register_one() 778 alg->maxauthsize = def->maxauthsize; in qce_aead_register_one() 780 alg->setkey = qce_aead_ccm_setkey; in qce_aead_register_one() 782 alg->setkey = qce_aead_setkey; in qce_aead_register_one() [all …]
|
/drivers/crypto/allwinner/sun8i-ce/ |
D | sun8i-ce-hash.c | 25 struct ahash_alg *alg = __crypto_ahash_alg(tfm->__crt_alg); in sun8i_ce_hash_crainit() local 31 algt = container_of(alg, struct sun8i_ce_alg_template, alg.hash); in sun8i_ce_hash_crainit() 46 if (algt->alg.hash.halg.statesize < crypto_ahash_statesize(op->fallback_tfm)) in sun8i_ce_hash_crainit() 47 algt->alg.hash.halg.statesize = crypto_ahash_statesize(op->fallback_tfm); in sun8i_ce_hash_crainit() 118 struct ahash_alg *alg = __crypto_ahash_alg(tfm->base.__crt_alg); in sun8i_ce_hash_final() local 128 algt = container_of(alg, struct sun8i_ce_alg_template, alg.hash); in sun8i_ce_hash_final() 156 struct ahash_alg *alg = __crypto_ahash_alg(tfm->base.__crt_alg); in sun8i_ce_hash_finup() local 168 algt = container_of(alg, struct sun8i_ce_alg_template, alg.hash); in sun8i_ce_hash_finup() 181 struct ahash_alg *alg = __crypto_ahash_alg(tfm->base.__crt_alg); in sun8i_ce_hash_digest_fb() local 193 algt = container_of(alg, struct sun8i_ce_alg_template, alg.hash); in sun8i_ce_hash_digest_fb() [all …]
|
D | sun8i-ce-core.c | 260 .alg.skcipher = { 287 .alg.skcipher = { 313 .alg.skcipher = { 340 .alg.skcipher = { 365 .alg.hash = { 395 .alg.hash = { 425 .alg.hash = { 455 .alg.hash = { 485 .alg.hash = { 515 .alg.hash = { [all …]
|
/drivers/crypto/allwinner/sun8i-ss/ |
D | sun8i-ss-core.c | 170 .alg.skcipher = { 197 .alg.skcipher = { 223 .alg.skcipher = { 250 .alg.skcipher = { 275 .alg.rng = { 294 .alg.hash = { 324 .alg.hash = { 354 .alg.hash = { 384 .alg.hash = { 430 ss_algs[i].alg.skcipher.base.cra_driver_name, in sun8i_ss_debugfs_show() [all …]
|
D | sun8i-ss-hash.c | 25 struct ahash_alg *alg = __crypto_ahash_alg(tfm->__crt_alg); in sun8i_ss_hash_crainit() local 31 algt = container_of(alg, struct sun8i_ss_alg_template, alg.hash); in sun8i_ss_hash_crainit() 46 if (algt->alg.hash.halg.statesize < crypto_ahash_statesize(op->fallback_tfm)) in sun8i_ss_hash_crainit() 47 algt->alg.hash.halg.statesize = crypto_ahash_statesize(op->fallback_tfm); in sun8i_ss_hash_crainit() 118 struct ahash_alg *alg = __crypto_ahash_alg(tfm->base.__crt_alg); in sun8i_ss_hash_final() local 128 algt = container_of(alg, struct sun8i_ss_alg_template, alg.hash); in sun8i_ss_hash_final() 156 struct ahash_alg *alg = __crypto_ahash_alg(tfm->base.__crt_alg); in sun8i_ss_hash_finup() local 168 algt = container_of(alg, struct sun8i_ss_alg_template, alg.hash); in sun8i_ss_hash_finup() 181 struct ahash_alg *alg = __crypto_ahash_alg(tfm->base.__crt_alg); in sun8i_ss_hash_digest_fb() local 193 algt = container_of(alg, struct sun8i_ss_alg_template, alg.hash); in sun8i_ss_hash_digest_fb() [all …]
|
/drivers/crypto/ |
D | talitos.c | 2259 } alg; member 2266 .alg.aead = { 2288 .alg.aead = { 2309 .alg.aead = { 2334 .alg.aead = { 2358 .alg.aead = { 2380 .alg.aead = { 2401 .alg.aead = { 2426 .alg.aead = { 2450 .alg.aead = { [all …]
|
/drivers/crypto/xilinx/ |
D | zynqmp-aes-gcm.c | 47 } alg; member 285 struct aead_alg *alg = crypto_aead_alg(aead); in zynqmp_aes_aead_encrypt() local 289 drv_ctx = container_of(alg, struct zynqmp_aead_drv_ctx, alg.aead); in zynqmp_aes_aead_encrypt() 298 struct aead_alg *alg = crypto_aead_alg(aead); in zynqmp_aes_aead_decrypt() local 302 drv_ctx = container_of(alg, struct zynqmp_aead_drv_ctx, alg.aead); in zynqmp_aes_aead_decrypt() 313 struct aead_alg *alg = crypto_aead_alg(aead); in zynqmp_aes_aead_init() local 315 drv_ctx = container_of(alg, struct zynqmp_aead_drv_ctx, alg.aead); in zynqmp_aes_aead_init() 322 tfm_ctx->fbk_cipher = crypto_alloc_aead(drv_ctx->alg.aead.base.cra_name, in zynqmp_aes_aead_init() 328 __func__, drv_ctx->alg.aead.base.cra_name); in zynqmp_aes_aead_init() 353 .alg.aead = { [all …]
|
/drivers/crypto/inside-secure/ |
D | safexcel_cipher.c | 50 enum safexcel_cipher_alg alg; member 92 if (ctx->alg == SAFEXCEL_CHACHA20) { in safexcel_skcipher_iv() 149 if (ctx->xcm == EIP197_XCM_MODE_GCM || ctx->alg == SAFEXCEL_CHACHA20) { in safexcel_aead_iv() 273 } else if (unlikely(ctx->alg == SAFEXCEL_CHACHA20 && in safexcel_aead_token() 301 if (likely(cryptlen || ctx->alg == SAFEXCEL_CHACHA20)) { in safexcel_aead_token() 412 const char *alg; in safexcel_aead_setkey() local 429 switch (ctx->alg) { in safexcel_aead_setkey() 467 alg = "safexcel-sha1"; in safexcel_aead_setkey() 470 alg = "safexcel-sha224"; in safexcel_aead_setkey() 473 alg = "safexcel-sha256"; in safexcel_aead_setkey() [all …]
|
D | safexcel_hash.c | 26 u32 alg; member 115 cdesc->control_data.control0 = ctx->alg; in safexcel_context_control() 293 ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_CRC32)) { in safexcel_handle_req_result() 780 if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_MD5) in safexcel_ahash_final() 783 else if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_SHA1) in safexcel_ahash_final() 786 else if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_SHA224) in safexcel_ahash_final() 789 else if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_SHA256) in safexcel_ahash_final() 792 else if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_SHA384) in safexcel_ahash_final() 795 else if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_SHA512) in safexcel_ahash_final() 798 else if (ctx->alg == CONTEXT_CONTROL_CRYPTO_ALG_SM3) { in safexcel_ahash_final() [all …]
|
/drivers/crypto/amcc/ |
D | crypto4xx_core.c | 945 struct skcipher_alg *alg = crypto_skcipher_alg(sk); in crypto4xx_sk_init() local 949 if (alg->base.cra_flags & CRYPTO_ALG_NEED_FALLBACK) { in crypto4xx_sk_init() 951 crypto_alloc_sync_skcipher(alg->base.cra_name, 0, in crypto4xx_sk_init() 957 amcc_alg = container_of(alg, struct crypto4xx_alg, alg.u.cipher); in crypto4xx_sk_init() 978 struct aead_alg *alg = crypto_aead_alg(tfm); in crypto4xx_aead_init() local 982 ctx->sw_cipher.aead = crypto_alloc_aead(alg->base.cra_name, 0, in crypto4xx_aead_init() 988 amcc_alg = container_of(alg, struct crypto4xx_alg, alg.u.aead); in crypto4xx_aead_init() 1008 struct crypto4xx_alg *alg; in crypto4xx_register_alg() local 1013 alg = kzalloc(sizeof(struct crypto4xx_alg), GFP_KERNEL); in crypto4xx_register_alg() 1014 if (!alg) in crypto4xx_register_alg() [all …]
|
/drivers/net/wireless/intel/ipw2x00/ |
D | libipw_wx.c | 511 const char *alg, *module; in libipw_wx_set_encodeext() local 532 if (idx != 0 && ext->alg != IW_ENCODE_ALG_WEP) in libipw_wx_set_encodeext() 542 ext->alg == IW_ENCODE_ALG_NONE) { in libipw_wx_set_encodeext() 567 switch (ext->alg) { in libipw_wx_set_encodeext() 569 alg = "WEP"; in libipw_wx_set_encodeext() 573 alg = "TKIP"; in libipw_wx_set_encodeext() 577 alg = "CCMP"; in libipw_wx_set_encodeext() 582 dev->name, ext->alg); in libipw_wx_set_encodeext() 587 ops = lib80211_get_crypto_ops(alg); in libipw_wx_set_encodeext() 590 ops = lib80211_get_crypto_ops(alg); in libipw_wx_set_encodeext() [all …]
|