* [dpdk-dev] [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation
@ 2021-10-20 11:06 Ciara Power
2021-10-20 11:12 ` Zhang, Roy Fan
2021-10-20 13:37 ` [dpdk-dev] [EXT] " Akhil Goyal
0 siblings, 2 replies; 3+ messages in thread
From: Ciara Power @ 2021-10-20 11:06 UTC (permalink / raw)
To: dev
Cc: roy.fan.zhang, gakhil, pablo.de.lara.guarch, thomas, Ciara Power,
piotrx.bronowski
The buffers used when processing a hash operation in the ZUC PMD should
be initialised to empty before use.
This fixes possible "may be used uninitialised" errors on compilation.
Fixes: e09b92e6474b ("drivers/crypto: move zuc PMD to IPsec-mb framework")
Cc: piotrx.bronowski@intel.com
Signed-off-by: Ciara Power <ciara.power@intel.com>
---
drivers/crypto/ipsec_mb/pmd_zuc.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/ipsec_mb/pmd_zuc.c b/drivers/crypto/ipsec_mb/pmd_zuc.c
index b542264069..2eae1d1ec7 100644
--- a/drivers/crypto/ipsec_mb/pmd_zuc.c
+++ b/drivers/crypto/ipsec_mb/pmd_zuc.c
@@ -138,11 +138,11 @@ process_zuc_hash_op(struct ipsec_mb_qp *qp, struct rte_crypto_op **ops,
{
unsigned int i;
uint8_t processed_ops = 0;
- uint8_t *src[ZUC_MAX_BURST];
+ uint8_t *src[ZUC_MAX_BURST] = { 0 };
uint32_t *dst[ZUC_MAX_BURST];
- uint32_t length_in_bits[ZUC_MAX_BURST];
- uint8_t *iv[ZUC_MAX_BURST];
- const void *hash_keys[ZUC_MAX_BURST];
+ uint32_t length_in_bits[ZUC_MAX_BURST] = { 0 };
+ uint8_t *iv[ZUC_MAX_BURST] = { 0 };
+ const void *hash_keys[ZUC_MAX_BURST] = { 0 };
struct zuc_session *sess;
struct zuc_qp_data *qp_data = ipsec_mb_get_qp_private_data(qp);
--
2.25.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation
2021-10-20 11:06 [dpdk-dev] [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation Ciara Power
@ 2021-10-20 11:12 ` Zhang, Roy Fan
2021-10-20 13:37 ` [dpdk-dev] [EXT] " Akhil Goyal
1 sibling, 0 replies; 3+ messages in thread
From: Zhang, Roy Fan @ 2021-10-20 11:12 UTC (permalink / raw)
To: Power, Ciara, dev
Cc: gakhil, De Lara Guarch, Pablo, thomas, Bronowski, PiotrX
> -----Original Message-----
> From: Power, Ciara <ciara.power@intel.com>
> Sent: Wednesday, October 20, 2021 12:06 PM
> To: dev@dpdk.org
> Cc: Zhang, Roy Fan <roy.fan.zhang@intel.com>; gakhil@marvell.com; De Lara
> Guarch, Pablo <pablo.de.lara.guarch@intel.com>; thomas@monjalon.net;
> Power, Ciara <ciara.power@intel.com>; Bronowski, PiotrX
> <piotrx.bronowski@intel.com>
> Subject: [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation
>
> The buffers used when processing a hash operation in the ZUC PMD should
> be initialised to empty before use.
> This fixes possible "may be used uninitialised" errors on compilation.
>
> Fixes: e09b92e6474b ("drivers/crypto: move zuc PMD to IPsec-mb
> framework")
> Cc: piotrx.bronowski@intel.com
>
> Signed-off-by: Ciara Power <ciara.power@intel.com>
> ---
Acked-by: Fan Zhang <roy.fan.zhang@intel.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [EXT] [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation
2021-10-20 11:06 [dpdk-dev] [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation Ciara Power
2021-10-20 11:12 ` Zhang, Roy Fan
@ 2021-10-20 13:37 ` Akhil Goyal
1 sibling, 0 replies; 3+ messages in thread
From: Akhil Goyal @ 2021-10-20 13:37 UTC (permalink / raw)
To: Ciara Power, dev
Cc: roy.fan.zhang, pablo.de.lara.guarch, thomas, piotrx.bronowski
> The buffers used when processing a hash operation in the ZUC PMD should
> be initialised to empty before use.
> This fixes possible "may be used uninitialised" errors on compilation.
>
> Fixes: e09b92e6474b ("drivers/crypto: move zuc PMD to IPsec-mb
> framework")
> Cc: piotrx.bronowski@intel.com
>
> Signed-off-by: Ciara Power <ciara.power@intel.com>
Squashed to the original patch.
Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-10-20 13:37 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-20 11:06 [dpdk-dev] [PATCH] crypto/ipsec_mb: fix ZUC PMD buffer initialisation Ciara Power
2021-10-20 11:12 ` Zhang, Roy Fan
2021-10-20 13:37 ` [dpdk-dev] [EXT] " Akhil Goyal
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).