DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] crypto/octeontx2: fix unaligned access to device memory
@ 2021-08-27  5:33 Anoob Joseph
  2021-09-02 11:25 ` Akhil Goyal
  0 siblings, 1 reply; 2+ messages in thread
From: Anoob Joseph @ 2021-08-27  5:33 UTC (permalink / raw)
  To: Akhil Goyal, Jerin Jacob
  Cc: Danny Patel, Ankur Dwivedi, Tejasree Kondoj, dev, Anoob Joseph

From: Danny Patel <dannyp@marvell.com>

Use otx2_mbox_memcpy() instead of memcpy() to prevent unaligned access.

Fixes: a0645ed0d6ef ("crypto/octeontx2: discover capabilities")
Cc: ktejasree@marvell.com

Signed-off-by: Danny Patel <dannyp@marvell.com>
Signed-off-by: Anoob Joseph <anoobj@marvell.com>
---
 drivers/crypto/octeontx2/otx2_cryptodev_mbox.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/octeontx2/otx2_cryptodev_mbox.c b/drivers/crypto/octeontx2/otx2_cryptodev_mbox.c
index 999f425..a635eb4 100644
--- a/drivers/crypto/octeontx2/otx2_cryptodev_mbox.c
+++ b/drivers/crypto/octeontx2/otx2_cryptodev_mbox.c
@@ -37,7 +37,7 @@ otx2_cpt_hardware_caps_get(const struct rte_cryptodev *dev,
 	}
 
 	vf->cpt_revision = rsp->cpt_revision;
-	memcpy(hw_caps, rsp->eng_caps,
+	otx2_mbox_memcpy(hw_caps, rsp->eng_caps,
 		sizeof(union cpt_eng_caps) * CPT_MAX_ENG_TYPES);
 
 	return 0;
-- 
2.7.4


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [dpdk-dev] [PATCH] crypto/octeontx2: fix unaligned access to device memory
  2021-08-27  5:33 [dpdk-dev] [PATCH] crypto/octeontx2: fix unaligned access to device memory Anoob Joseph
@ 2021-09-02 11:25 ` Akhil Goyal
  0 siblings, 0 replies; 2+ messages in thread
From: Akhil Goyal @ 2021-09-02 11:25 UTC (permalink / raw)
  To: Anoob Joseph, Jerin Jacob Kollanukkaran
  Cc: Danny Patel, Ankur Dwivedi, Tejasree Kondoj, dev, stable

> Use otx2_mbox_memcpy() instead of memcpy() to prevent unaligned access.
> 
> Fixes: a0645ed0d6ef ("crypto/octeontx2: discover capabilities")
> Cc: ktejasree@marvell.com
Cc: stable@dpdk.org

> 
> Signed-off-by: Danny Patel <dannyp@marvell.com>
> Signed-off-by: Anoob Joseph <anoobj@marvell.com>
> ---
Applied to dpdk-next-crypto

Thanks.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-09-02 11:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-27  5:33 [dpdk-dev] [PATCH] crypto/octeontx2: fix unaligned access to device memory Anoob Joseph
2021-09-02 11:25 ` 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).