git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
crypto/openssl: fix HMAC supported key sizes
[dpdk.git]
/
drivers
/
crypto
/
openssl
/
rte_openssl_pmd_ops.c
diff --git
a/drivers/crypto/openssl/rte_openssl_pmd_ops.c
b/drivers/crypto/openssl/rte_openssl_pmd_ops.c
index
1f8a011
..
cec82ca
100644
(file)
--- a/
drivers/crypto/openssl/rte_openssl_pmd_ops.c
+++ b/
drivers/crypto/openssl/rte_openssl_pmd_ops.c
@@
-48,16
+48,15
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.algo = RTE_CRYPTO_AUTH_MD5_HMAC,
.block_size = 64,
.key_size = {
.algo = RTE_CRYPTO_AUTH_MD5_HMAC,
.block_size = 64,
.key_size = {
- .min =
64
,
+ .min =
1
,
.max = 64,
.max = 64,
- .increment =
0
+ .increment =
1
},
.digest_size = {
.min = 16,
.max = 16,
.increment = 0
},
},
.digest_size = {
.min = 16,
.max = 16,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-79,7
+78,6
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.max = 16,
.increment = 0
},
.max = 16,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-92,16
+90,15
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
.block_size = 64,
.key_size = {
.algo = RTE_CRYPTO_AUTH_SHA1_HMAC,
.block_size = 64,
.key_size = {
- .min =
64
,
+ .min =
1
,
.max = 64,
.max = 64,
- .increment =
0
+ .increment =
1
},
.digest_size = {
.min = 20,
.max = 20,
.increment = 0
},
},
.digest_size = {
.min = 20,
.max = 20,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-123,7
+120,6
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.max = 20,
.increment = 0
},
.max = 20,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-136,16
+132,15
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.algo = RTE_CRYPTO_AUTH_SHA224_HMAC,
.block_size = 64,
.key_size = {
.algo = RTE_CRYPTO_AUTH_SHA224_HMAC,
.block_size = 64,
.key_size = {
- .min =
64
,
+ .min =
1
,
.max = 64,
.max = 64,
- .increment =
0
+ .increment =
1
},
.digest_size = {
.min = 28,
.max = 28,
.increment = 0
},
},
.digest_size = {
.min = 28,
.max = 28,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-167,7
+162,6
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.max = 28,
.increment = 0
},
.max = 28,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-180,16
+174,15
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.algo = RTE_CRYPTO_AUTH_SHA256_HMAC,
.block_size = 64,
.key_size = {
.algo = RTE_CRYPTO_AUTH_SHA256_HMAC,
.block_size = 64,
.key_size = {
- .min =
64
,
+ .min =
1
,
.max = 64,
.max = 64,
- .increment =
0
+ .increment =
1
},
.digest_size = {
.min = 32,
.max = 32,
.increment = 0
},
},
.digest_size = {
.min = 32,
.max = 32,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-211,7
+204,6
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.max = 32,
.increment = 0
},
.max = 32,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-224,16
+216,15
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.algo = RTE_CRYPTO_AUTH_SHA384_HMAC,
.block_size = 128,
.key_size = {
.algo = RTE_CRYPTO_AUTH_SHA384_HMAC,
.block_size = 128,
.key_size = {
- .min = 1
28
,
+ .min = 1,
.max = 128,
.max = 128,
- .increment =
0
+ .increment =
1
},
.digest_size = {
.min = 48,
.max = 48,
.increment = 0
},
},
.digest_size = {
.min = 48,
.max = 48,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-255,7
+246,6
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.max = 48,
.increment = 0
},
.max = 48,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-268,16
+258,15
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.algo = RTE_CRYPTO_AUTH_SHA512_HMAC,
.block_size = 128,
.key_size = {
.algo = RTE_CRYPTO_AUTH_SHA512_HMAC,
.block_size = 128,
.key_size = {
- .min = 1
28
,
+ .min = 1,
.max = 128,
.max = 128,
- .increment =
0
+ .increment =
1
},
.digest_size = {
.min = 64,
.max = 64,
.increment = 0
},
},
.digest_size = {
.min = 64,
.max = 64,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-299,7
+288,6
@@
static const struct rte_cryptodev_capabilities openssl_pmd_capabilities[] = {
.max = 64,
.increment = 0
},
.max = 64,
.increment = 0
},
- .aad_size = { 0 },
.iv_size = { 0 }
}, }
}, }
.iv_size = { 0 }
}, }
}, }
@@
-599,7
+587,7
@@
openssl_pmd_qp_create_processed_ops_ring(struct openssl_qp *qp,
static int
openssl_pmd_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
const struct rte_cryptodev_qp_conf *qp_conf,
static int
openssl_pmd_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
const struct rte_cryptodev_qp_conf *qp_conf,
-
int socket_id
)
+
int socket_id, struct rte_mempool *session_pool
)
{
struct openssl_qp *qp = NULL;
{
struct openssl_qp *qp = NULL;
@@
-624,7
+612,7
@@
openssl_pmd_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
if (qp->processed_ops == NULL)
goto qp_setup_cleanup;
if (qp->processed_ops == NULL)
goto qp_setup_cleanup;
- qp->sess_mp =
dev->data->
session_pool;
+ qp->sess_mp = session_pool;
memset(&qp->stats, 0, sizeof(qp->stats));
memset(&qp->stats, 0, sizeof(qp->stats));