git.droids-corp.org
/
dpdk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
966b43f
)
crypto/octeontx: reset session private data
author
Ankur Dwivedi
<adwivedi@marvell.com>
Fri, 3 Jul 2020 05:41:39 +0000
(11:11 +0530)
committer
Thomas Monjalon
<thomas@monjalon.net>
Wed, 8 Jul 2020 16:16:16 +0000
(18:16 +0200)
This patch sets the first 32 bytes of session private data
to zero. This prevents garbage data to be used in code logic.
Signed-off-by: Ankur Dwivedi <adwivedi@marvell.com>
drivers/crypto/octeontx/otx_cryptodev_ops.c
patch
|
blob
|
history
diff --git
a/drivers/crypto/octeontx/otx_cryptodev_ops.c
b/drivers/crypto/octeontx/otx_cryptodev_ops.c
index
265e10e
..
8f58fe2
100644
(file)
--- a/
drivers/crypto/octeontx/otx_cryptodev_ops.c
+++ b/
drivers/crypto/octeontx/otx_cryptodev_ops.c
@@
-252,6
+252,9
@@
sym_session_configure(int driver_id, struct rte_crypto_sym_xform *xform,
return -ENOMEM;
}
+ memset(priv, 0, sizeof(struct cpt_sess_misc) +
+ offsetof(struct cpt_ctx, fctx));
+
misc = priv;
for ( ; xform != NULL; xform = xform->next) {