| /kernel/linux/linux-5.10/drivers/crypto/ccp/ |
| D | ccp-crypto-rsa.c | 3 * AMD Cryptographic Coprocessor (CCP) RSA crypto API support 15 #include <crypto/internal/rsa.h> 52 req->dst_len = rctx->cmd.u.rsa.key_size >> 3; in ccp_rsa_complete() 61 return ctx->u.rsa.n_len; in ccp_rsa_maxsize() 75 rctx->cmd.u.rsa.key_size = ctx->u.rsa.key_len; /* in bits */ in ccp_rsa_crypt() 77 rctx->cmd.u.rsa.exp = &ctx->u.rsa.e_sg; in ccp_rsa_crypt() 78 rctx->cmd.u.rsa.exp_len = ctx->u.rsa.e_len; in ccp_rsa_crypt() 80 rctx->cmd.u.rsa.exp = &ctx->u.rsa.d_sg; in ccp_rsa_crypt() 81 rctx->cmd.u.rsa.exp_len = ctx->u.rsa.d_len; in ccp_rsa_crypt() 83 rctx->cmd.u.rsa.mod = &ctx->u.rsa.n_sg; in ccp_rsa_crypt() [all …]
|
| /kernel/linux/linux-6.6/drivers/crypto/ccp/ |
| D | ccp-crypto-rsa.c | 3 * AMD Cryptographic Coprocessor (CCP) RSA crypto API support 15 #include <crypto/internal/rsa.h> 52 req->dst_len = rctx->cmd.u.rsa.key_size >> 3; in ccp_rsa_complete() 61 return ctx->u.rsa.n_len; in ccp_rsa_maxsize() 75 rctx->cmd.u.rsa.key_size = ctx->u.rsa.key_len; /* in bits */ in ccp_rsa_crypt() 77 rctx->cmd.u.rsa.exp = &ctx->u.rsa.e_sg; in ccp_rsa_crypt() 78 rctx->cmd.u.rsa.exp_len = ctx->u.rsa.e_len; in ccp_rsa_crypt() 80 rctx->cmd.u.rsa.exp = &ctx->u.rsa.d_sg; in ccp_rsa_crypt() 81 rctx->cmd.u.rsa.exp_len = ctx->u.rsa.d_len; in ccp_rsa_crypt() 83 rctx->cmd.u.rsa.mod = &ctx->u.rsa.n_sg; in ccp_rsa_crypt() [all …]
|
| /kernel/linux/linux-6.6/drivers/crypto/caam/ |
| D | caampkc.h | 17 * caam_priv_key_form - CAAM RSA private key representation 18 * CAAM RSA private key may have either of three forms. 22 * n the RSA modulus 23 * d the RSA private exponent 27 * p the first prime factor of the RSA modulus n 28 * q the second prime factor of the RSA modulus n 29 * d the RSA private exponent 33 * p the first prime factor of the RSA modulus n 34 * q the second prime factor of the RSA modulus n 49 * caam_rsa_key - CAAM RSA key structure. Keys are allocated in DMA zone. [all …]
|
| D | pdb.h | 481 /* RSA Protocol Data Block */ 500 * RSA Encrypt Protocol Data Block 504 * @n_dma: dma address of RSA modulus 505 * @e_dma: dma address of RSA public exponent 520 * RSA Decrypt PDB - Private Key Form #1 524 * @n_dma: dma address of RSA modulus 525 * @d_dma: dma address of RSA private exponent 538 * RSA Decrypt PDB - Private Key Form #2 542 * @d_dma : dma address of RSA private exponent 543 * @p_dma : dma address of RSA prime factor p of RSA modulus n [all …]
|
| D | caampkc.c | 122 /* RSA Job Completion handler */ 417 dev_err(dev, "Unable to map RSA modulus memory\n"); in set_rsa_pub_pdb() 423 dev_err(dev, "Unable to map RSA public exponent memory\n"); in set_rsa_pub_pdb() 468 dev_err(dev, "Unable to map RSA private exponent memory\n"); in set_rsa_priv_f1_pdb() 511 dev_err(dev, "Unable to map RSA private exponent memory\n"); in set_rsa_priv_f2_pdb() 517 dev_err(dev, "Unable to map RSA prime factor p memory\n"); in set_rsa_priv_f2_pdb() 523 dev_err(dev, "Unable to map RSA prime factor q memory\n"); in set_rsa_priv_f2_pdb() 529 dev_err(dev, "Unable to map RSA tmp1 memory\n"); in set_rsa_priv_f2_pdb() 535 dev_err(dev, "Unable to map RSA tmp2 memory\n"); in set_rsa_priv_f2_pdb() 588 dev_err(dev, "Unable to map RSA prime factor p memory\n"); in set_rsa_priv_f3_pdb() [all …]
|
| /kernel/linux/linux-5.10/drivers/crypto/caam/ |
| D | caampkc.h | 18 * caam_priv_key_form - CAAM RSA private key representation 19 * CAAM RSA private key may have either of three forms. 23 * n the RSA modulus 24 * d the RSA private exponent 28 * p the first prime factor of the RSA modulus n 29 * q the second prime factor of the RSA modulus n 30 * d the RSA private exponent 34 * p the first prime factor of the RSA modulus n 35 * q the second prime factor of the RSA modulus n 50 * caam_rsa_key - CAAM RSA key structure. Keys are allocated in DMA zone. [all …]
|
| D | pdb.h | 481 /* RSA Protocol Data Block */ 500 * RSA Encrypt Protocol Data Block 504 * @n_dma: dma address of RSA modulus 505 * @e_dma: dma address of RSA public exponent 520 * RSA Decrypt PDB - Private Key Form #1 524 * @n_dma: dma address of RSA modulus 525 * @d_dma: dma address of RSA private exponent 538 * RSA Decrypt PDB - Private Key Form #2 542 * @d_dma : dma address of RSA private exponent 543 * @p_dma : dma address of RSA prime factor p of RSA modulus n [all …]
|
| D | caampkc.c | 116 /* RSA Job Completion handler */ 408 dev_err(dev, "Unable to map RSA modulus memory\n"); in set_rsa_pub_pdb() 414 dev_err(dev, "Unable to map RSA public exponent memory\n"); in set_rsa_pub_pdb() 459 dev_err(dev, "Unable to map RSA private exponent memory\n"); in set_rsa_priv_f1_pdb() 502 dev_err(dev, "Unable to map RSA private exponent memory\n"); in set_rsa_priv_f2_pdb() 508 dev_err(dev, "Unable to map RSA prime factor p memory\n"); in set_rsa_priv_f2_pdb() 514 dev_err(dev, "Unable to map RSA prime factor q memory\n"); in set_rsa_priv_f2_pdb() 520 dev_err(dev, "Unable to map RSA tmp1 memory\n"); in set_rsa_priv_f2_pdb() 526 dev_err(dev, "Unable to map RSA tmp2 memory\n"); in set_rsa_priv_f2_pdb() 579 dev_err(dev, "Unable to map RSA prime factor p memory\n"); in set_rsa_priv_f3_pdb() [all …]
|
| D | pkc_desc.c | 13 /* Descriptor for RSA Public operation */ 26 /* Descriptor for RSA Private operation - Private Key Form #1 */ 39 /* Descriptor for RSA Private operation - Private Key Form #2 */ 56 /* Descriptor for RSA Private operation - Private Key Form #3 */
|
| /kernel/linux/linux-5.10/include/crypto/internal/ |
| D | rsa.h | 3 * RSA internal helpers 13 * rsa_key - RSA key structure 14 * @n : RSA modulus raw byte stream 15 * @e : RSA public exponent raw byte stream 16 * @d : RSA private exponent raw byte stream 17 * @p : RSA prime factor p of n raw byte stream 18 * @q : RSA prime factor q of n raw byte stream 19 * @dp : RSA exponent d mod (p - 1) raw byte stream 20 * @dq : RSA exponent d mod (q - 1) raw byte stream 21 * @qinv : RSA CRT coefficient q^(-1) mod p raw byte stream [all …]
|
| /kernel/linux/linux-6.6/include/crypto/internal/ |
| D | rsa.h | 3 * RSA internal helpers 13 * rsa_key - RSA key structure 14 * @n : RSA modulus raw byte stream 15 * @e : RSA public exponent raw byte stream 16 * @d : RSA private exponent raw byte stream 17 * @p : RSA prime factor p of n raw byte stream 18 * @q : RSA prime factor q of n raw byte stream 19 * @dp : RSA exponent d mod (p - 1) raw byte stream 20 * @dq : RSA exponent d mod (q - 1) raw byte stream 21 * @qinv : RSA CRT coefficient q^(-1) mod p raw byte stream [all …]
|
| /kernel/linux/linux-5.10/drivers/crypto/hisilicon/hpre/ |
| D | hpre_crypto.c | 7 #include <crypto/internal/rsa.h> 81 struct hpre_rsa_ctx rsa; member 92 struct akcipher_request *rsa; member 402 areq = req->areq.rsa; in hpre_rsa_cb() 457 h_req->areq.rsa = akreq; in hpre_msg_request_set() 728 akcipher_request_set_tfm(req, ctx->rsa.soft_tfm); in hpre_rsa_enc() 734 if (unlikely(!ctx->rsa.pubkey)) in hpre_rsa_enc() 742 msg->key = cpu_to_le64(ctx->rsa.dma_pubkey); in hpre_rsa_enc() 776 akcipher_request_set_tfm(req, ctx->rsa.soft_tfm); in hpre_rsa_dec() 782 if (unlikely(!ctx->rsa.prikey)) in hpre_rsa_dec() [all …]
|
| /kernel/linux/linux-5.10/drivers/crypto/qat/qat_common/ |
| D | qat_asym_algs.c | 4 #include <crypto/internal/rsa.h> 116 struct qat_rsa_input_params rsa; member 120 struct qat_rsa_output_params rsa; member 129 struct qat_rsa_ctx *rsa; member 133 struct akcipher_request *rsa; member 511 struct akcipher_request *areq = req->areq.rsa; in qat_rsa_cb() 512 struct device *dev = &GET_DEV(req->ctx.rsa->inst->accel_dev); in qat_rsa_cb() 519 dma_free_coherent(dev, req->ctx.rsa->key_sz, req->src_align, in qat_rsa_cb() 520 req->in.rsa.enc.m); in qat_rsa_cb() 522 dma_unmap_single(dev, req->in.rsa.enc.m, req->ctx.rsa->key_sz, in qat_rsa_cb() [all …]
|
| /kernel/linux/linux-5.10/drivers/net/ethernet/intel/ixgbe/ |
| D | ixgbe_ipsec.c | 396 struct rx_sa *rsa; in ixgbe_ipsec_find_rx_state() local 400 hash_for_each_possible_rcu(ipsec->rx_sa_list, rsa, hlist, in ixgbe_ipsec_find_rx_state() 402 if (rsa->mode & IXGBE_RXTXMOD_VF) in ixgbe_ipsec_find_rx_state() 404 if (spi == rsa->xs->id.spi && in ixgbe_ipsec_find_rx_state() 405 ((ip4 && *daddr == rsa->xs->id.daddr.a4) || in ixgbe_ipsec_find_rx_state() 406 (!ip4 && !memcmp(daddr, &rsa->xs->id.daddr.a6, in ixgbe_ipsec_find_rx_state() 407 sizeof(rsa->xs->id.daddr.a6)))) && in ixgbe_ipsec_find_rx_state() 408 proto == rsa->xs->id.proto) { in ixgbe_ipsec_find_rx_state() 409 ret = rsa->xs; in ixgbe_ipsec_find_rx_state() 589 struct rx_sa rsa; in ixgbe_ipsec_add_sa() local [all …]
|
| /kernel/linux/linux-6.6/drivers/crypto/intel/qat/qat_common/ |
| D | qat_asym_algs.c | 4 #include <crypto/internal/rsa.h> 117 struct qat_rsa_input_params rsa; member 121 struct qat_rsa_output_params rsa; member 130 struct qat_rsa_ctx *rsa; member 134 struct akcipher_request *rsa; member 516 struct akcipher_request *areq = req->areq.rsa; in qat_rsa_cb() 517 struct device *dev = &GET_DEV(req->ctx.rsa->inst->accel_dev); in qat_rsa_cb() 523 dma_unmap_single(dev, req->in.rsa.enc.m, req->ctx.rsa->key_sz, in qat_rsa_cb() 528 areq->dst_len = req->ctx.rsa->key_sz; in qat_rsa_cb() 529 dma_unmap_single(dev, req->out.rsa.enc.c, req->ctx.rsa->key_sz, in qat_rsa_cb() [all …]
|
| /kernel/linux/linux-6.6/drivers/net/ethernet/intel/ixgbe/ |
| D | ixgbe_ipsec.c | 396 struct rx_sa *rsa; in ixgbe_ipsec_find_rx_state() local 400 hash_for_each_possible_rcu(ipsec->rx_sa_list, rsa, hlist, in ixgbe_ipsec_find_rx_state() 402 if (rsa->mode & IXGBE_RXTXMOD_VF) in ixgbe_ipsec_find_rx_state() 404 if (spi == rsa->xs->id.spi && in ixgbe_ipsec_find_rx_state() 405 ((ip4 && *daddr == rsa->xs->id.daddr.a4) || in ixgbe_ipsec_find_rx_state() 406 (!ip4 && !memcmp(daddr, &rsa->xs->id.daddr.a6, in ixgbe_ipsec_find_rx_state() 407 sizeof(rsa->xs->id.daddr.a6)))) && in ixgbe_ipsec_find_rx_state() 408 proto == rsa->xs->id.proto) { in ixgbe_ipsec_find_rx_state() 409 ret = rsa->xs; in ixgbe_ipsec_find_rx_state() 595 struct rx_sa rsa; in ixgbe_ipsec_add_sa() local [all …]
|
| /kernel/linux/linux-6.6/drivers/net/ethernet/intel/ixgbevf/ |
| D | ipsec.c | 183 struct rx_sa *rsa; in ixgbevf_ipsec_find_rx_state() local 186 hash_for_each_possible_rcu(ipsec->rx_sa_list, rsa, hlist, in ixgbevf_ipsec_find_rx_state() 188 if (spi == rsa->xs->id.spi && in ixgbevf_ipsec_find_rx_state() 189 ((ip4 && *daddr == rsa->xs->id.daddr.a4) || in ixgbevf_ipsec_find_rx_state() 190 (!ip4 && !memcmp(daddr, &rsa->xs->id.daddr.a6, in ixgbevf_ipsec_find_rx_state() 191 sizeof(rsa->xs->id.daddr.a6)))) && in ixgbevf_ipsec_find_rx_state() 192 proto == rsa->xs->id.proto) { in ixgbevf_ipsec_find_rx_state() 193 ret = rsa->xs; in ixgbevf_ipsec_find_rx_state() 290 struct rx_sa rsa; in ixgbevf_ipsec_add_sa() local 305 memset(&rsa, 0, sizeof(rsa)); in ixgbevf_ipsec_add_sa() [all …]
|
| /kernel/linux/linux-5.10/drivers/net/ethernet/intel/ixgbevf/ |
| D | ipsec.c | 183 struct rx_sa *rsa; in ixgbevf_ipsec_find_rx_state() local 186 hash_for_each_possible_rcu(ipsec->rx_sa_list, rsa, hlist, in ixgbevf_ipsec_find_rx_state() 188 if (spi == rsa->xs->id.spi && in ixgbevf_ipsec_find_rx_state() 189 ((ip4 && *daddr == rsa->xs->id.daddr.a4) || in ixgbevf_ipsec_find_rx_state() 190 (!ip4 && !memcmp(daddr, &rsa->xs->id.daddr.a6, in ixgbevf_ipsec_find_rx_state() 191 sizeof(rsa->xs->id.daddr.a6)))) && in ixgbevf_ipsec_find_rx_state() 192 proto == rsa->xs->id.proto) { in ixgbevf_ipsec_find_rx_state() 193 ret = rsa->xs; in ixgbevf_ipsec_find_rx_state() 284 struct rx_sa rsa; in ixgbevf_ipsec_add_sa() local 299 memset(&rsa, 0, sizeof(rsa)); in ixgbevf_ipsec_add_sa() [all …]
|
| /kernel/linux/linux-6.6/drivers/crypto/hisilicon/hpre/ |
| D | hpre_crypto.c | 11 #include <crypto/internal/rsa.h> 124 struct hpre_rsa_ctx rsa; member 139 struct akcipher_request *rsa; member 467 areq = req->areq.rsa; in hpre_rsa_cb() 532 h_req->areq.rsa = akreq; in hpre_msg_request_set() 805 akcipher_request_set_tfm(req, ctx->rsa.soft_tfm); in hpre_rsa_enc() 811 if (unlikely(!ctx->rsa.pubkey)) in hpre_rsa_enc() 819 msg->key = cpu_to_le64(ctx->rsa.dma_pubkey); in hpre_rsa_enc() 853 akcipher_request_set_tfm(req, ctx->rsa.soft_tfm); in hpre_rsa_dec() 859 if (unlikely(!ctx->rsa.prikey)) in hpre_rsa_dec() [all …]
|
| /kernel/linux/linux-5.10/crypto/ |
| D | rsa.c | 2 /* RSA asymmetric public-key algorithm [RFC3447] 10 #include <crypto/internal/rsa.h> 242 static struct akcipher_alg rsa = { variable 250 .cra_name = "rsa", 251 .cra_driver_name = "rsa-generic", 262 err = crypto_register_akcipher(&rsa); in rsa_init() 268 crypto_unregister_akcipher(&rsa); in rsa_init() 278 crypto_unregister_akcipher(&rsa); in rsa_exit() 283 MODULE_ALIAS_CRYPTO("rsa"); 285 MODULE_DESCRIPTION("RSA generic algorithm");
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/i915/gt/uc/ |
| D | intel_guc_fw.c | 43 /* Copy RSA signature from the fw image to HW for verification */ 47 u32 rsa[UOS_RSA_SCRATCH_COUNT]; in guc_xfer_rsa() local 51 copied = intel_uc_fw_copy_rsa(guc_fw, rsa, sizeof(rsa)); in guc_xfer_rsa() 52 GEM_BUG_ON(copied < sizeof(rsa)); in guc_xfer_rsa() 55 intel_uncore_write(uncore, UOS_RSA_SCRATCH(i), rsa[i]); in guc_xfer_rsa() 129 * by the DMA engine in one operation, whereas the RSA signature is in intel_guc_fw_upload()
|
| /kernel/linux/linux-6.6/Documentation/devicetree/bindings/crypto/ |
| D | aspeed,ast2600-acry.yaml | 7 title: ASPEED ACRY ECDSA/RSA Hardware Accelerator Engines 13 The ACRY ECDSA/RSA engines is designed to accelerate the throughput 14 of ECDSA/RSA signature and verification. Basically, ACRY can be 15 divided into two independent engines - ECC Engine and RSA Engine.
|
| /kernel/linux/linux-6.6/drivers/crypto/aspeed/ |
| D | Kconfig | 51 bool "Enable Aspeed ACRY RSA Engine" 56 Select here to enable Aspeed ECC/RSA Engine (ACRY) 57 RSA driver. 58 Supports 256 bits to 4096 bits RSA encryption/decryption
|
| D | aspeed-acry.c | 7 #include <crypto/internal/rsa.h> 40 #define ASPEED_ACRY_RSA_KEY_LEN 0x058 /* ACRY RSA Exp/Mod Key Length (Bits) */ 44 /* rsa trigger */ 48 /* rsa dma cmd */ 53 /* rsa key len */ 62 #define ASPEED_ACRY_RSA_MAX_KEY_LEN 512 /* ACRY RSA maximum key length (Bytes) */ 339 dev_err(acry_dev->dev, "RSA engine error!\n"); in aspeed_acry_rsa_transfer() 406 /* Trigger RSA engines */ in aspeed_acry_rsa_trigger() 498 dev_err(acry_dev->dev, "rsa parse key failed, ret:0x%x\n", in aspeed_acry_rsa_setkey() 526 dev_err(acry_dev->dev, "rsa set key failed\n"); in aspeed_acry_rsa_setkey() [all …]
|
| /kernel/linux/linux-6.6/crypto/ |
| D | rsa.c | 2 /* RSA asymmetric public-key algorithm [RFC3447] 11 #include <crypto/internal/rsa.h> 352 static struct akcipher_alg rsa = { variable 360 .cra_name = "rsa", 361 .cra_driver_name = "rsa-generic", 372 err = crypto_register_akcipher(&rsa); in rsa_init() 378 crypto_unregister_akcipher(&rsa); in rsa_init() 388 crypto_unregister_akcipher(&rsa); in rsa_exit() 393 MODULE_ALIAS_CRYPTO("rsa"); 395 MODULE_DESCRIPTION("RSA generic algorithm");
|