DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] crypto/qat: fix build
@ 2023-01-12 19:30 Pablo de Lara
  2023-01-12 20:39 ` Thomas Monjalon
  2023-01-18 11:05 ` [PATCH v2] " Pablo de Lara
  0 siblings, 2 replies; 7+ messages in thread
From: Pablo de Lara @ 2023-01-12 19:30 UTC (permalink / raw)
  To: kai.ji, akhil.goyal; +Cc: dev, Pablo de Lara, stable

Instead of undefining AES_BLOCK_SIZE, define NO_COMPAT_IMB_API_053,
which prevents legacy macros like AES_BLOCK_SIZE from being defined
from IPSec MB library.

Fixes: 3227bc7138f5 ("crypto/qat: use intel-ipsec-mb for partial hash and AES")
Cc: stable@dpdk.org
Cc: kai.ji@intel.com

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 drivers/crypto/qat/qat_sym_session.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/crypto/qat/qat_sym_session.c b/drivers/crypto/qat/qat_sym_session.c
index 978ee49dce..7f18e9875d 100644
--- a/drivers/crypto/qat/qat_sym_session.c
+++ b/drivers/crypto/qat/qat_sym_session.c
@@ -10,6 +10,7 @@
 #include <openssl/evp.h>	/* Needed for bpi runt block processing */
 
 #ifdef RTE_QAT_LIBIPSECMB
+#define NO_COMPAT_IMB_API_053
 #if defined(RTE_ARCH_ARM)
 #include <ipsec-mb.h>
 #else
-- 
2.34.1


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

* Re: [PATCH] crypto/qat: fix build
  2023-01-12 19:30 [PATCH] crypto/qat: fix build Pablo de Lara
@ 2023-01-12 20:39 ` Thomas Monjalon
  2023-01-17  8:22   ` [EXT] " Akhil Goyal
  2023-01-18 11:05 ` [PATCH v2] " Pablo de Lara
  1 sibling, 1 reply; 7+ messages in thread
From: Thomas Monjalon @ 2023-01-12 20:39 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: kai.ji, akhil.goyal, dev, stable

12/01/2023 20:30, Pablo de Lara:
> Instead of undefining AES_BLOCK_SIZE, define NO_COMPAT_IMB_API_053,
> which prevents legacy macros like AES_BLOCK_SIZE from being defined
> from IPSec MB library.

Given we are discarding my first workaround,
your first sentence doesn't really make sense.
Please give more context, explain the conflict with OpenSSL,
and copy the error message.

Thanks

> Fixes: 3227bc7138f5 ("crypto/qat: use intel-ipsec-mb for partial hash and AES")
> Cc: stable@dpdk.org
> Cc: kai.ji@intel.com
> 
> Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>




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

* RE: [EXT] Re: [PATCH] crypto/qat: fix build
  2023-01-12 20:39 ` Thomas Monjalon
@ 2023-01-17  8:22   ` Akhil Goyal
  2023-01-18  9:51     ` De Lara Guarch, Pablo
  0 siblings, 1 reply; 7+ messages in thread
From: Akhil Goyal @ 2023-01-17  8:22 UTC (permalink / raw)
  To: Thomas Monjalon, Pablo de Lara; +Cc: kai.ji, akhil.goyal, dev, stable

> 12/01/2023 20:30, Pablo de Lara:
> > Instead of undefining AES_BLOCK_SIZE, define NO_COMPAT_IMB_API_053,
> > which prevents legacy macros like AES_BLOCK_SIZE from being defined
> > from IPSec MB library.
> 
> Given we are discarding my first workaround,
> your first sentence doesn't really make sense.
> Please give more context, explain the conflict with OpenSSL,
> and copy the error message.
> 
Hi Pablo,

Can you fix the description as suggested by Thomas?
I would like to take all the qat build fixes together.

Thanks.

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

* RE: [EXT] Re: [PATCH] crypto/qat: fix build
  2023-01-17  8:22   ` [EXT] " Akhil Goyal
@ 2023-01-18  9:51     ` De Lara Guarch, Pablo
  0 siblings, 0 replies; 7+ messages in thread
From: De Lara Guarch, Pablo @ 2023-01-18  9:51 UTC (permalink / raw)
  To: Akhil Goyal, Thomas Monjalon; +Cc: Ji, Kai, akhil.goyal, dev, stable



> -----Original Message-----
> From: Akhil Goyal <gakhil@marvell.com>
> Sent: Tuesday, January 17, 2023 8:23 AM
> To: Thomas Monjalon <thomas@monjalon.net>; De Lara Guarch, Pablo
> <pablo.de.lara.guarch@intel.com>
> Cc: Ji, Kai <kai.ji@intel.com>; akhil.goyal@marvell.com; dev@dpdk.org;
> stable@dpdk.org
> Subject: RE: [EXT] Re: [PATCH] crypto/qat: fix build
> 
> > 12/01/2023 20:30, Pablo de Lara:
> > > Instead of undefining AES_BLOCK_SIZE, define
> NO_COMPAT_IMB_API_053,
> > > which prevents legacy macros like AES_BLOCK_SIZE from being defined
> > > from IPSec MB library.
> >
> > Given we are discarding my first workaround, your first sentence
> > doesn't really make sense.
> > Please give more context, explain the conflict with OpenSSL, and copy
> > the error message.
> >
> Hi Pablo,
> 
> Can you fix the description as suggested by Thomas?
> I would like to take all the qat build fixes together.

Sure, will do.

Pablo

> 
> Thanks.

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

* [PATCH v2] crypto/qat: fix build
  2023-01-12 19:30 [PATCH] crypto/qat: fix build Pablo de Lara
  2023-01-12 20:39 ` Thomas Monjalon
@ 2023-01-18 11:05 ` Pablo de Lara
  2023-01-18 14:17   ` Ji, Kai
  1 sibling, 1 reply; 7+ messages in thread
From: Pablo de Lara @ 2023-01-18 11:05 UTC (permalink / raw)
  To: gakhil; +Cc: dev, Pablo de Lara, stable, kai.ji

When building QAT PMD, the following issue comes up:

intel-ipsec-mb.h:333: error: "AES_BLOCK_SIZE" redefined
  333 | #define AES_BLOCK_SIZE          IMB_AES_BLOCK_SIZE
In file included from drivers/crypto/qat/qat_sym_session.c:8:
/usr/include/openssl/aes.h:26: previous definition
   26 | # define AES_BLOCK_SIZE 16

By defining NO_COMPAT_IMB_API_053, it prevents legacy macros
like AES_BLOCK_SIZE from being defined from IPSec MB library,
avoiding the redefinition.

Fixes: 3227bc7138f5 ("crypto/qat: use intel-ipsec-mb for partial hash and AES")
Cc: stable@dpdk.org
Cc: kai.ji@intel.com

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
v2: reworded the commit message
---

 drivers/crypto/qat/qat_sym_session.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/crypto/qat/qat_sym_session.c b/drivers/crypto/qat/qat_sym_session.c
index 978ee49dce..7f18e9875d 100644
--- a/drivers/crypto/qat/qat_sym_session.c
+++ b/drivers/crypto/qat/qat_sym_session.c
@@ -10,6 +10,7 @@
 #include <openssl/evp.h>	/* Needed for bpi runt block processing */
 
 #ifdef RTE_QAT_LIBIPSECMB
+#define NO_COMPAT_IMB_API_053
 #if defined(RTE_ARCH_ARM)
 #include <ipsec-mb.h>
 #else
-- 
2.34.1


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

* RE: [PATCH v2] crypto/qat: fix build
  2023-01-18 11:05 ` [PATCH v2] " Pablo de Lara
@ 2023-01-18 14:17   ` Ji, Kai
  2023-01-19  9:35     ` Akhil Goyal
  0 siblings, 1 reply; 7+ messages in thread
From: Ji, Kai @ 2023-01-18 14:17 UTC (permalink / raw)
  To: De Lara Guarch, Pablo, gakhil; +Cc: dev, stable

Acked-by: Kai Ji <kai.ji@intel.com>

> -----Original Message-----
> From: De Lara Guarch, Pablo <pablo.de.lara.guarch@intel.com>
> Sent: Wednesday, January 18, 2023 11:06 AM
> To: gakhil@marvell.com
> Cc: dev@dpdk.org; De Lara Guarch, Pablo <pablo.de.lara.guarch@intel.com>;
> stable@dpdk.org; Ji, Kai <kai.ji@intel.com>
> Subject: [PATCH v2] crypto/qat: fix build
> 
> When building QAT PMD, the following issue comes up:
> 
> intel-ipsec-mb.h:333: error: "AES_BLOCK_SIZE" redefined
>   333 | #define AES_BLOCK_SIZE          IMB_AES_BLOCK_SIZE
> In file included from drivers/crypto/qat/qat_sym_session.c:8:
> /usr/include/openssl/aes.h:26: previous definition
>    26 | # define AES_BLOCK_SIZE 16
> 
> By defining NO_COMPAT_IMB_API_053, it prevents legacy macros like
> AES_BLOCK_SIZE from being defined from IPSec MB library, avoiding the
> redefinition.
> 
> Fixes: 3227bc7138f5 ("crypto/qat: use intel-ipsec-mb for partial hash
> and AES")
> Cc: stable@dpdk.org
> Cc: kai.ji@intel.com
> 
> Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
> ---
> v2: reworded the commit message
> ---
> 
>  drivers/crypto/qat/qat_sym_session.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/crypto/qat/qat_sym_session.c
> b/drivers/crypto/qat/qat_sym_session.c
> index 978ee49dce..7f18e9875d 100644
> --- a/drivers/crypto/qat/qat_sym_session.c
> +++ b/drivers/crypto/qat/qat_sym_session.c
> @@ -10,6 +10,7 @@
>  #include <openssl/evp.h>	/* Needed for bpi runt block processing */
> 
>  #ifdef RTE_QAT_LIBIPSECMB
> +#define NO_COMPAT_IMB_API_053
>  #if defined(RTE_ARCH_ARM)
>  #include <ipsec-mb.h>
>  #else
> --
> 2.34.1


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

* RE: [PATCH v2] crypto/qat: fix build
  2023-01-18 14:17   ` Ji, Kai
@ 2023-01-19  9:35     ` Akhil Goyal
  0 siblings, 0 replies; 7+ messages in thread
From: Akhil Goyal @ 2023-01-19  9:35 UTC (permalink / raw)
  To: Ji, Kai, De Lara Guarch, Pablo; +Cc: dev, stable

> Acked-by: Kai Ji <kai.ji@intel.com>
> 
> > Subject: [PATCH v2] crypto/qat: fix build
> >
> > When building QAT PMD, the following issue comes up:
> >
> > intel-ipsec-mb.h:333: error: "AES_BLOCK_SIZE" redefined
> >   333 | #define AES_BLOCK_SIZE          IMB_AES_BLOCK_SIZE
> > In file included from drivers/crypto/qat/qat_sym_session.c:8:
> > /usr/include/openssl/aes.h:26: previous definition
> >    26 | # define AES_BLOCK_SIZE 16
> >
> > By defining NO_COMPAT_IMB_API_053, it prevents legacy macros like
> > AES_BLOCK_SIZE from being defined from IPSec MB library, avoiding the
> > redefinition.
> >
> > Fixes: 3227bc7138f5 ("crypto/qat: use intel-ipsec-mb for partial hash
> > and AES")
> > Cc: stable@dpdk.org
> > Cc: kai.ji@intel.com
> >
> > Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Applied to dpdk-next-crypto

Thanks.

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

end of thread, other threads:[~2023-01-19  9:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-12 19:30 [PATCH] crypto/qat: fix build Pablo de Lara
2023-01-12 20:39 ` Thomas Monjalon
2023-01-17  8:22   ` [EXT] " Akhil Goyal
2023-01-18  9:51     ` De Lara Guarch, Pablo
2023-01-18 11:05 ` [PATCH v2] " Pablo de Lara
2023-01-18 14:17   ` Ji, Kai
2023-01-19  9:35     ` 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).