DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] crypto/dpaa2_sec: fix build with clang 3.4.2
@ 2019-10-31 14:05 Ciara Power
  2019-11-01  5:25 ` Hemant Agrawal
  2019-11-01 21:34 ` Thomas Monjalon
  0 siblings, 2 replies; 3+ messages in thread
From: Ciara Power @ 2019-10-31 14:05 UTC (permalink / raw)
  To: dev, akhil.goyal; +Cc: Ciara Power, hemant.agrawal

Building with clang 3.4.2 caused the following error:

  CC dpaa2_sec_dpseci.o
In file included from /dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c:40:
In file included from /dpdk/drivers/common/dpaax/caamflib/desc/ipsec.h:11:
In file included from /dpdk/drivers/common/dpaax/caamflib/rta.h:11:
In file included from .../common/dpaax/caamflib/rta/sec_run_time_asm.h:14:
/dpdk/drivers/common/dpaax/compat.h:108:18:
error: redefinition of typedef 'dma_addr_t' is a C11 feature
[-Werror,-Wtypedef-redefinition]
typedef uint64_t        dma_addr_t;
                        ^
/dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c:37:18:
note: previous definition is here
typedef uint64_t        dma_addr_t;
                        ^
1 error generated.

The dma_addr_t was defined in the common compat.h file, and does not
need to be redefined.

The meson build include directories list was updated to enable the
definition in the common compat.h file be used.

Fixes: 8c83f28cc8a4 ("common/dpaax: move OF library from DPAA bus")
Cc: hemant.agrawal@nxp.com

Signed-off-by: Ciara Power <ciara.power@intel.com>

---
The commit referenced adds the common/dpaax path to Makefiles as an include
path, meaning the common/dpaax/compat.h file is included instead of
common/dpaax/caamflib/compat.h by the other files.
Is this the intended header file to be included?
---
 drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c | 3 ---
 drivers/crypto/dpaa2_sec/meson.build        | 2 +-
 2 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
index 52e522e4a..add3b9ea6 100644
--- a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
+++ b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
@@ -33,9 +33,6 @@
 #include "dpaa2_sec_event.h"
 #include "dpaa2_sec_logs.h"
 
-/* Required types */
-typedef uint64_t	dma_addr_t;
-
 /* RTA header files */
 #include <desc/ipsec.h>
 #include <desc/pdcp.h>
diff --git a/drivers/crypto/dpaa2_sec/meson.build b/drivers/crypto/dpaa2_sec/meson.build
index 1b749186c..9d1b170be 100644
--- a/drivers/crypto/dpaa2_sec/meson.build
+++ b/drivers/crypto/dpaa2_sec/meson.build
@@ -14,4 +14,4 @@ sources = files('dpaa2_sec_dpseci.c',
 
 allow_experimental_apis = true
 
-includes += include_directories('mc', '../../common/dpaax/caamflib')
+includes += include_directories('mc', '../../common/dpaax', '../../common/dpaax/caamflib')
-- 
2.17.1


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

* Re: [dpdk-dev] [PATCH] crypto/dpaa2_sec: fix build with clang 3.4.2
  2019-10-31 14:05 [dpdk-dev] [PATCH] crypto/dpaa2_sec: fix build with clang 3.4.2 Ciara Power
@ 2019-11-01  5:25 ` Hemant Agrawal
  2019-11-01 21:34 ` Thomas Monjalon
  1 sibling, 0 replies; 3+ messages in thread
From: Hemant Agrawal @ 2019-11-01  5:25 UTC (permalink / raw)
  To: Ciara Power, dev, Akhil Goyal

Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>

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

* Re: [dpdk-dev] [PATCH] crypto/dpaa2_sec: fix build with clang 3.4.2
  2019-10-31 14:05 [dpdk-dev] [PATCH] crypto/dpaa2_sec: fix build with clang 3.4.2 Ciara Power
  2019-11-01  5:25 ` Hemant Agrawal
@ 2019-11-01 21:34 ` Thomas Monjalon
  1 sibling, 0 replies; 3+ messages in thread
From: Thomas Monjalon @ 2019-11-01 21:34 UTC (permalink / raw)
  To: Ciara Power; +Cc: dev, akhil.goyal, hemant.agrawal

31/10/2019 15:05, Ciara Power:
> Building with clang 3.4.2 caused the following error:
> 
>   CC dpaa2_sec_dpseci.o
> In file included from /dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c:40:
> In file included from /dpdk/drivers/common/dpaax/caamflib/desc/ipsec.h:11:
> In file included from /dpdk/drivers/common/dpaax/caamflib/rta.h:11:
> In file included from .../common/dpaax/caamflib/rta/sec_run_time_asm.h:14:
> /dpdk/drivers/common/dpaax/compat.h:108:18:
> error: redefinition of typedef 'dma_addr_t' is a C11 feature
> [-Werror,-Wtypedef-redefinition]
> typedef uint64_t        dma_addr_t;
>                         ^
> /dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c:37:18:
> note: previous definition is here
> typedef uint64_t        dma_addr_t;
>                         ^
> 1 error generated.
> 
> The dma_addr_t was defined in the common compat.h file, and does not
> need to be redefined.
> 
> The meson build include directories list was updated to enable the
> definition in the common compat.h file be used.
> 
> Fixes: 8c83f28cc8a4 ("common/dpaax: move OF library from DPAA bus")
> Cc: hemant.agrawal@nxp.com
> 
> Signed-off-by: Ciara Power <ciara.power@intel.com>

Applied, thanks




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

end of thread, other threads:[~2019-11-01 21:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-31 14:05 [dpdk-dev] [PATCH] crypto/dpaa2_sec: fix build with clang 3.4.2 Ciara Power
2019-11-01  5:25 ` Hemant Agrawal
2019-11-01 21:34 ` Thomas Monjalon

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).