DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] common/mlx5: fix mlx5 build
@ 2020-07-19 11:51 Ali Alnubani
  2020-07-19 15:17 ` Raslan Darawsheh
  0 siblings, 1 reply; 7+ messages in thread
From: Ali Alnubani @ 2020-07-19 11:51 UTC (permalink / raw)
  To: dev; +Cc: suanmingm, Raslan Darawsheh

This fixes the following build errors by adding 2
missing header includes:

```
drivers/common/mlx5/linux/mlx5_glue.c: In function
    'mlx5_glue_destroy_flow_action':
drivers/common/mlx5/linux/mlx5_glue.c:187:2: error: implicit declaration
    of function 'mlx5_free' [-Werror=implicit-function-declaration]
  mlx5_free(action);
  ^
...
drivers/common/mlx5/linux/mlx5_glue.c:620:46: error: 'SOCKET_ID_ANY'
    undeclared (first use in this function)
  action = mlx5_malloc(0, sizeof(*action), 0, SOCKET_ID_ANY);
...
```

The build error reproduces on Ubuntu 16.04 with rdma-core version v22.1 and
with gcc version 5.4.0.

Fixes: 0e25e18bfba9 ("common/mlx5: convert control path memory to unified malloc")
Cc: suanmingm@mellanox.com

Signed-off-by: Ali Alnubani <alialnu@mellanox.com>
Signed-off-by: Raslan Darawsheh <rasland@mellanox.com>
---
 drivers/common/mlx5/linux/mlx5_glue.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/common/mlx5/linux/mlx5_glue.c b/drivers/common/mlx5/linux/mlx5_glue.c
index ea9c86b3a..fcf03e867 100644
--- a/drivers/common/mlx5/linux/mlx5_glue.c
+++ b/drivers/common/mlx5/linux/mlx5_glue.c
@@ -8,6 +8,7 @@
 #include <stddef.h>
 #include <stdint.h>
 #include <stdlib.h>
+#include <rte_memory.h>
 /*
  * Not needed by this file; included to work around the lack of off_t
  * definition for mlx5dv.h with unpatched rdma-core versions.
@@ -15,6 +16,7 @@
 #include <sys/types.h>
 
 #include "mlx5_glue.h"
+#include "../mlx5_malloc.h"
 
 static int
 mlx5_glue_fork_init(void)
-- 
2.27.0


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

end of thread, other threads:[~2020-07-20 12:24 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-19 11:51 [dpdk-dev] [PATCH] common/mlx5: fix mlx5 build Ali Alnubani
2020-07-19 15:17 ` Raslan Darawsheh
2020-07-20  8:24   ` David Marchand
2020-07-20  8:38     ` Raslan Darawsheh
2020-07-20  8:51       ` David Marchand
2020-07-20  8:59         ` Raslan Darawsheh
2020-07-20 12:23           ` David Marchand

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