[v3,1/4] lib/cryptodev: add rsa priv key feature flag
Checks
Commit Message
Add feature flag to reflect RSA private key
operation support using quintuple (crt) or
exponent type key. if PMD support both,
then it should set both.
App should query cryptodev feature flag to check
if Sign and Decryt with CRT keys or exponent is
supported, thus call operation with relevant
key type.
Signed-off-by: Ayuj Verma <ayverma@marvell.com>
Signed-off-by: Shally Verma <shallyv@marvell.com>
---
lib/librte_cryptodev/rte_cryptodev.c | 4 ++++
lib/librte_cryptodev/rte_cryptodev.h | 4 ++++
2 files changed, 8 insertions(+)
@@ -486,6 +486,10 @@ struct rte_cryptodev_sym_session_pool_private_data {
return "CPU_ARM_CE";
case RTE_CRYPTODEV_FF_SECURITY:
return "SECURITY_PROTOCOL";
+ case RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_EXP:
+ return "RSA_PRIV_OP_KEY_EXP";
+ case RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_QT:
+ return "RSA_PRIV_OP_KEY_QT";
default:
return NULL;
}
@@ -438,6 +438,10 @@ struct rte_cryptodev_asym_capability_idx {
/**< Utilises ARM CPU Cryptographic Extensions */
#define RTE_CRYPTODEV_FF_SECURITY (1ULL << 16)
/**< Support Security Protocol Processing */
+#define RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_EXP (1ULL << 17)
+/**< Support RSA Private Key OP with exponent */
+#define RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_QT (1ULL << 18)
+/**< Support RSA Private Key OP with CRT (quintuple) Keys */
/**