[PATCH 19.11] net/mlx5: fix netlink header path
Ali Alnubani
alialnu at nvidia.com
Tue Mar 29 15:00:51 CEST 2022
Use netlink.h provided by the kernel headers instead
of adding a dependency on the headers provided by the libnl package,
which weren't being found in some cases, even with libnl-3 and
libnl-route-3 libs installed via the package manager.
Also see usage in netlink(3).
Resolves the build error:
drivers/net/mlx5/mlx5.h:15:10:
fatal error: netlink/netlink.h: No such file or directory
The error reproduces on Ubuntu 16.04/18.04/20.04, openSUSE Leap 15.3,
and CentOS 7/8. It reproduces with Make and Meson.
Fixes: 7bd18f45ed47 ("common/mlx5: add Netlink event helpers")
Cc: dkozlyuk at nvidia.com
Signed-off-by: Ali Alnubani <alialnu at nvidia.com>
---
drivers/net/mlx5/mlx5.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5/mlx5.h
index 1cf5f41689..9f6b355182 100644
--- a/drivers/net/mlx5/mlx5.h
+++ b/drivers/net/mlx5/mlx5.h
@@ -12,7 +12,7 @@
#include <limits.h>
#include <net/if.h>
#include <netinet/in.h>
-#include <netlink/netlink.h>
+#include <linux/netlink.h>
#include <sys/queue.h>
/* Verbs header. */
--
2.25.1
More information about the stable
mailing list