The header files should have the minimum embedded includes.
The file pthread.h can logically be removed from
rte_per_lcore.h and rte_ethdev_core.h files.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Acked-by: Rosen Xu <rosen.xu@intel.com>
---
app/test/test_link_bonding.c | 2 ++
drivers/common/mlx5/mlx5_common.c | 1 +
drivers/common/mlx5/windows/mlx5_win_ext.h | 2 ++
drivers/net/bnxt/bnxt.h | 1 +
drivers/net/qede/base/bcm_osal.h | 1 +
drivers/raw/ifpga/base/opae_osdep.h | 1 +
drivers/vdpa/sfc/sfc_vdpa.c | 1 +
lib/eal/common/eal_common_options.c | 1 +
lib/eal/common/eal_common_trace.c | 1 +
lib/eal/common/malloc_mp.c | 1 +
lib/eal/freebsd/eal_alarm.c | 1 +
lib/eal/include/rte_per_lcore.h | 2 --
lib/eal/linux/eal_alarm.c | 1 +
lib/ethdev/ethdev_driver.c | 1 +
lib/ethdev/ethdev_driver.h | 2 ++
lib/ethdev/rte_ethdev_core.h | 2 --
lib/ethdev/rte_flow.c | 1 +
lib/eventdev/rte_event_eth_rx_adapter.c | 1 +
lib/vhost/vhost.c | 1 +
19 files changed, 20 insertions(+), 4 deletions(-)
@@ -10,8 +10,10 @@
#include <stdint.h>
#include <inttypes.h>
#include <errno.h>
+#include <pthread.h>
#include <sys/queue.h>
#include <sys/time.h>
+
#include <rte_cycles.h>
#include <rte_byteorder.h>
#include <rte_common.h>
@@ -5,6 +5,7 @@
#include <unistd.h>
#include <string.h>
#include <stdio.h>
+#include <pthread.h>
#include <rte_errno.h>
#include <rte_mempool.h>
@@ -5,6 +5,8 @@
#ifndef __MLX5_WIN_ETX_H__
#define __MLX5_WIN_ETX_H__
+#include <pthread.h>
+
#include "mlx5_prm.h"
#include "mlx5devx.h"
@@ -8,6 +8,7 @@
#include <inttypes.h>
#include <stdbool.h>
+#include <pthread.h>
#include <sys/queue.h>
#include <rte_pci.h>
@@ -8,6 +8,7 @@
#define __BCM_OSAL_H
#include <stdbool.h>
+#include <pthread.h>
#include <time.h>
#include <rte_bitops.h>
#include <rte_byteorder.h>
@@ -7,6 +7,7 @@
#include <string.h>
#include <stdbool.h>
+#include <pthread.h>
#ifdef RTE_LIB_EAL
#include "osdep_rte/osdep_generic.h"
@@ -4,6 +4,7 @@
#include <stdbool.h>
#include <stdint.h>
+#include <pthread.h>
#include <sys/queue.h>
#include <rte_common.h>
@@ -5,6 +5,7 @@
#include <stdlib.h>
#include <string.h>
+#include <pthread.h>
#ifndef RTE_EXEC_ENV_WINDOWS
#include <syslog.h>
#endif
@@ -4,6 +4,7 @@
#include <stdlib.h>
#include <fnmatch.h>
+#include <pthread.h>
#include <sys/queue.h>
#include <regex.h>
@@ -4,6 +4,7 @@
#include <stdlib.h>
#include <string.h>
+#include <pthread.h>
#include <sys/time.h>
#include <rte_errno.h>
@@ -4,6 +4,7 @@
#include <sys/types.h>
#include <sys/stat.h>
+#include <pthread.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
@@ -22,8 +22,6 @@
extern "C" {
#endif
-#include <pthread.h>
-
#ifdef RTE_TOOLCHAIN_MSVC
/**
* Macro to define a per lcore variable "var" of type "type", don't
@@ -5,6 +5,7 @@
#include <stdint.h>
#include <stdlib.h>
#include <errno.h>
+#include <pthread.h>
#include <sys/queue.h>
#include <sys/time.h>
#include <sys/timerfd.h>
@@ -3,6 +3,7 @@
*/
#include <stdlib.h>
+#include <pthread.h>
#include <rte_kvargs.h>
#include <rte_malloc.h>
@@ -18,6 +18,8 @@ extern "C" {
* use them.
*/
+#include <pthread.h>
+
#include <dev_driver.h>
#include <rte_compat.h>
#include <rte_ethdev.h>
@@ -5,8 +5,6 @@
#ifndef _RTE_ETHDEV_CORE_H_
#define _RTE_ETHDEV_CORE_H_
-#include <pthread.h>
-
/**
* @file
*
@@ -6,6 +6,7 @@
#include <errno.h>
#include <stddef.h>
#include <stdint.h>
+#include <pthread.h>
#include <rte_common.h>
#include <rte_errno.h>
@@ -4,6 +4,7 @@
*/
#include <ctype.h>
#include <stdlib.h>
+#include <pthread.h>
#if defined(LINUX)
#include <sys/epoll.h>
#endif
@@ -6,6 +6,7 @@
#include <linux/virtio_net.h>
#include <stdint.h>
#include <stdlib.h>
+#include <pthread.h>
#ifdef RTE_LIBRTE_VHOST_NUMA
#include <numa.h>
#include <numaif.h>