The rte_reciprocal header file used standard __rte_always_inline from rte_common.h but does not include that header file, leading to compiler errors when the reciprocal header is included alone. Fixes: 6d45659eacb8 ("eal: add u64-bit variant for reciprocal divide") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/rte_reciprocal.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/rte_reciprocal.h b/lib/librte_eal/include/rte_reciprocal.h index 63e16fde0a..4a59be30a8 100644 --- a/lib/librte_eal/include/rte_reciprocal.h +++ b/lib/librte_eal/include/rte_reciprocal.h @@ -26,6 +26,7 @@ #define _RTE_RECIPROCAL_H_ #include <stdint.h> +#include <rte_common.h> struct rte_reciprocal { uint32_t m; -- 2.27.0
The telemetry header file uses the rte_cpuset_t type, but does not include any header providing that type. Include rte_os.h to provide the necessary type. Fixes: febbebf7f255 ("telemetry: keep threads separate from data plane") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_telemetry/rte_telemetry.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_telemetry/rte_telemetry.h b/lib/librte_telemetry/rte_telemetry.h index 4693275c24..561c6b1658 100644 --- a/lib/librte_telemetry/rte_telemetry.h +++ b/lib/librte_telemetry/rte_telemetry.h @@ -5,6 +5,7 @@ #include <stdint.h> #include <sched.h> #include <rte_compat.h> +#include <rte_os.h> #ifndef _RTE_TELEMETRY_H_ #define _RTE_TELEMETRY_H_ -- 2.27.0
The define for RTE_ETH_FLOW_MAX is defined in rte_ethdev.h, so that header should be included in rte_eth_ctrl.h to allow it to be compiled independently. Fixes: 7fa96d696f2c ("ethdev: unification of flow types") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_ethdev/rte_eth_ctrl.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_ethdev/rte_eth_ctrl.h b/lib/librte_ethdev/rte_eth_ctrl.h index 1cca522fa3..8a50dbfef9 100644 --- a/lib/librte_ethdev/rte_eth_ctrl.h +++ b/lib/librte_ethdev/rte_eth_ctrl.h @@ -9,6 +9,7 @@ #include <rte_common.h> #include <rte_ether.h> #include "rte_flow.h" +#include "rte_ethdev.h" /** * @deprecated Please use rte_flow API instead of this legacy one. -- 2.27.0
Add in the missing includes into the header file for c11 memory model, so it can be compiled up independently of the other headers. Fixes: 39368ebfc606 ("ring: introduce C11 memory model barrier option") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_ring/rte_ring_c11_mem.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/librte_ring/rte_ring_c11_mem.h b/lib/librte_ring/rte_ring_c11_mem.h index 0fb73a3371..12caf06a31 100644 --- a/lib/librte_ring/rte_ring_c11_mem.h +++ b/lib/librte_ring/rte_ring_c11_mem.h @@ -10,6 +10,10 @@ #ifndef _RTE_RING_C11_MEM_H_ #define _RTE_RING_C11_MEM_H_ +#include <stdint.h> +#include <rte_common.h> +#include <rte_ring_core.h> + static __rte_always_inline void update_tail(struct rte_ring_headtail *ht, uint32_t old_val, uint32_t new_val, uint32_t single, uint32_t enqueue) -- 2.27.0
The Geneve protocol header file is missing the rte_byteorder.h header. Fixes: ea0e711b8ae0 ("app/testpmd: add GENEVE parsing") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_net/rte_geneve.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_net/rte_geneve.h b/lib/librte_net/rte_geneve.h index bb67724c31..7c3d477dcb 100644 --- a/lib/librte_net/rte_geneve.h +++ b/lib/librte_net/rte_geneve.h @@ -11,6 +11,7 @@ * GENEVE-related definitions */ #include <stdint.h> +#include <rte_byteorder.h> #ifdef __cplusplus extern "C" { -- 2.27.0
The rte_mbuf_dyn.h header file uses a number of types and macros without including the required header files to get the definitions of those macros/types. Similarly, the rte_mbuf_core.h file was missing an include for rte_byteorder.h header. Fixes: 4958ca3a443a ("mbuf: support dynamic fields and flags") Fixes: 3eb860b08eb7 ("mbuf: move definitions into a separate file") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_mbuf/rte_mbuf_core.h | 1 + lib/librte_mbuf/rte_mbuf_dyn.h | 3 +++ 2 files changed, 4 insertions(+) diff --git a/lib/librte_mbuf/rte_mbuf_core.h b/lib/librte_mbuf/rte_mbuf_core.h index 567551deab..34e892f21b 100644 --- a/lib/librte_mbuf/rte_mbuf_core.h +++ b/lib/librte_mbuf/rte_mbuf_core.h @@ -18,6 +18,7 @@ #include <stdint.h> #include <rte_compat.h> +#include <rte_byteorder.h> #include <generic/rte_atomic.h> #ifdef __cplusplus diff --git a/lib/librte_mbuf/rte_mbuf_dyn.h b/lib/librte_mbuf/rte_mbuf_dyn.h index d88e7bacc5..1286a5ccf7 100644 --- a/lib/librte_mbuf/rte_mbuf_dyn.h +++ b/lib/librte_mbuf/rte_mbuf_dyn.h @@ -66,7 +66,10 @@ * - any name that does not start with "rte_" in an application */ +#include <stdio.h> +#include <stdint.h> #include <sys/types.h> +#include <rte_compat.h> /** * Maximum length of the dynamic field or flag string. */ -- 2.27.0
The rte_compat.h header file must be included to get the definition of __rte_experimental. Fixes: f030bff72f81 ("bitrate: add free function") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_bitratestats/rte_bitrate.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_bitratestats/rte_bitrate.h b/lib/librte_bitratestats/rte_bitrate.h index 4865929e8f..7e34529687 100644 --- a/lib/librte_bitratestats/rte_bitrate.h +++ b/lib/librte_bitratestats/rte_bitrate.h @@ -6,6 +6,7 @@ #define _RTE_BITRATE_H_ #include <stdint.h> +#include <rte_compat.h> #ifdef __cplusplus extern "C" { -- 2.27.0
The standard integer types, and the size_t types are missing their required header includes in the rib header file. Fixes: 5a5793a5ffa2 ("rib: add RIB library") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_rib/rte_rib.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/librte_rib/rte_rib.h b/lib/librte_rib/rte_rib.h index f80752e5bd..6253860523 100644 --- a/lib/librte_rib/rte_rib.h +++ b/lib/librte_rib/rte_rib.h @@ -18,6 +18,8 @@ * Level compressed tree implementation for IPv4 Longest Prefix Match */ +#include <stdlib.h> +#include <stdint.h> #include <rte_compat.h> #ifdef __cplusplus -- 2.27.0
The vhost header files were missing definitions from headers to allow them to be compiled up individually. Fixes: d7280c9fffcb ("vhost: support selective datapath") Fixes: a49f758d1170 ("vhost: split vDPA header file") Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_vhost/rte_vdpa.h | 2 ++ lib/librte_vhost/rte_vdpa_dev.h | 1 + lib/librte_vhost/rte_vhost_crypto.h | 7 +++++++ 3 files changed, 10 insertions(+) diff --git a/lib/librte_vhost/rte_vdpa.h b/lib/librte_vhost/rte_vdpa.h index f074ec0c4a..1437f400bf 100644 --- a/lib/librte_vhost/rte_vdpa.h +++ b/lib/librte_vhost/rte_vdpa.h @@ -11,6 +11,8 @@ * Device specific vhost lib */ +#include <stdint.h> + /** Maximum name length for statistics counters */ #define RTE_VDPA_STATS_NAME_SIZE 64 diff --git a/lib/librte_vhost/rte_vdpa_dev.h b/lib/librte_vhost/rte_vdpa_dev.h index a60183f780..bfada387b0 100644 --- a/lib/librte_vhost/rte_vdpa_dev.h +++ b/lib/librte_vhost/rte_vdpa_dev.h @@ -8,6 +8,7 @@ #include <stdbool.h> #include "rte_vhost.h" +#include "rte_vdpa.h" #define RTE_VHOST_QUEUE_ALL UINT16_MAX diff --git a/lib/librte_vhost/rte_vhost_crypto.h b/lib/librte_vhost/rte_vhost_crypto.h index c809c46a21..2a27a35892 100644 --- a/lib/librte_vhost/rte_vhost_crypto.h +++ b/lib/librte_vhost/rte_vhost_crypto.h @@ -5,6 +5,13 @@ #ifndef _VHOST_CRYPTO_H_ #define _VHOST_CRYPTO_H_ +#include <stdint.h> +#include <rte_compat.h> + +/* pre-declare structs to avoid including full headers */ +struct rte_mempool; +struct rte_crypto_op; + #define VHOST_CRYPTO_MBUF_POOL_SIZE (8192) #define VHOST_CRYPTO_MAX_BURST_SIZE (64) #define VHOST_CRYPTO_MAX_DATA_SIZE (4096) -- 2.27.0
The rte_ipsec_sad.h header used the standard uintXX_t types, but did not include stdint.h header for them. Fixes: 401633d9c112 ("ipsec: add inbound SAD API") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_ipsec/rte_ipsec_sad.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_ipsec/rte_ipsec_sad.h b/lib/librte_ipsec/rte_ipsec_sad.h index 3e67ab1e4b..66c703ff3a 100644 --- a/lib/librte_ipsec/rte_ipsec_sad.h +++ b/lib/librte_ipsec/rte_ipsec_sad.h @@ -7,6 +7,7 @@ #define _RTE_IPSEC_SAD_H_ #include <rte_compat.h> +#include <stdint.h> /** * @file rte_ipsec_sad.h -- 2.27.0
Add stdint.h to get definitions of standard integer types Fixes: 39e927248416 ("fib: add FIB library") Fixes: 40d41a8a7b34 ("fib: support IPv6") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_fib/rte_fib.h | 1 + lib/librte_fib/rte_fib6.h | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/librte_fib/rte_fib.h b/lib/librte_fib/rte_fib.h index fef0749525..352c5e00ad 100644 --- a/lib/librte_fib/rte_fib.h +++ b/lib/librte_fib/rte_fib.h @@ -19,6 +19,7 @@ * for IPv4 Longest Prefix Match */ +#include <stdint.h> #include <rte_compat.h> #ifdef __cplusplus diff --git a/lib/librte_fib/rte_fib6.h b/lib/librte_fib/rte_fib6.h index 668bffb2ba..60213f3372 100644 --- a/lib/librte_fib/rte_fib6.h +++ b/lib/librte_fib/rte_fib6.h @@ -19,6 +19,7 @@ * for IPv6 Longest Prefix Match */ +#include <stdint.h> #include <rte_compat.h> #ifdef __cplusplus -- 2.27.0
The rte_lru_x86.h header, included from the main rte_lru.h header, uses the RTE_CC_IS_GNU macro from rte_common.h but fails to include that header file. Fixes: 0c9a5735a947 ("eal: fix compiler detection in public headers") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_table/rte_lru_x86.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_table/rte_lru_x86.h b/lib/librte_table/rte_lru_x86.h index 0e24906c2c..38476d956e 100644 --- a/lib/librte_table/rte_lru_x86.h +++ b/lib/librte_table/rte_lru_x86.h @@ -12,6 +12,7 @@ extern "C" { #include <stdint.h> #include <rte_config.h> +#include <rte_common.h> #ifndef RTE_TABLE_HASH_LRU_STRATEGY #define RTE_TABLE_HASH_LRU_STRATEGY 2 -- 2.27.0
The stdio.h header needs to be included to get the definition of the FILE type. Fixes: b32c0a2c5e4c ("pipeline: add SWX table update high level API") Fixes: 3ca60ceed79a ("pipeline: add SWX pipeline specification file") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_pipeline/rte_swx_ctl.h | 1 + lib/librte_pipeline/rte_swx_pipeline.h | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/librte_pipeline/rte_swx_ctl.h b/lib/librte_pipeline/rte_swx_ctl.h index bab1894944..32815b69e2 100644 --- a/lib/librte_pipeline/rte_swx_ctl.h +++ b/lib/librte_pipeline/rte_swx_ctl.h @@ -15,6 +15,7 @@ extern "C" { #include <stddef.h> #include <stdint.h> +#include <stdio.h> #include <rte_compat.h> diff --git a/lib/librte_pipeline/rte_swx_pipeline.h b/lib/librte_pipeline/rte_swx_pipeline.h index d0a3439edf..f0a2cef777 100644 --- a/lib/librte_pipeline/rte_swx_pipeline.h +++ b/lib/librte_pipeline/rte_swx_pipeline.h @@ -15,6 +15,7 @@ extern "C" { #include <stddef.h> #include <stdint.h> +#include <stdio.h> #include <rte_compat.h> -- 2.27.0
The global variable "tel_met_data" was declared in a header file, rather than in a C file, leading to duplicate definitions if more than one C file included the header. Fixes: c5b7197f662e ("telemetry: move some functions to metrics library") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_metrics/rte_metrics_telemetry.c | 2 ++ lib/librte_metrics/rte_metrics_telemetry.h | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/librte_metrics/rte_metrics_telemetry.c b/lib/librte_metrics/rte_metrics_telemetry.c index 901cbeb0a3..b8ee56ef01 100644 --- a/lib/librte_metrics/rte_metrics_telemetry.c +++ b/lib/librte_metrics/rte_metrics_telemetry.c @@ -13,6 +13,8 @@ #include "rte_metrics.h" #include "rte_metrics_telemetry.h" +struct telemetry_metrics_data tel_met_data; + int metrics_log_level; /* Logging Macros */ diff --git a/lib/librte_metrics/rte_metrics_telemetry.h b/lib/librte_metrics/rte_metrics_telemetry.h index 3435a55425..5dbb32ca0c 100644 --- a/lib/librte_metrics/rte_metrics_telemetry.h +++ b/lib/librte_metrics/rte_metrics_telemetry.h @@ -34,8 +34,6 @@ struct telemetry_metrics_data { int metrics_register_done; }; -struct telemetry_metrics_data tel_met_data; - __rte_experimental int32_t rte_metrics_tel_reg_all_ethdev(int *metrics_register_done, int *reg_index_list); -- 2.27.0
The rte_compat header file is needed for the '__rte_experimental' macro. Fixes: f00708c2aa53 ("node: add IPv4 rewrite and lookup control") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_node/rte_node_ip4_api.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_node/rte_node_ip4_api.h b/lib/librte_node/rte_node_ip4_api.h index eb9ebd5f89..46d0d8976b 100644 --- a/lib/librte_node/rte_node_ip4_api.h +++ b/lib/librte_node/rte_node_ip4_api.h @@ -21,6 +21,7 @@ extern "C" { #endif #include <rte_common.h> +#include <rte_compat.h> /** * IP4 lookup next nodes. -- 2.27.0
The "includes" variable in the app/meson.build file was ignored when building the executable, meaning that apps couldn't pass additional include paths directly back. Fix this to align with drivers and libs. Fixes: fa036e70d794 ("app: generalize meson build") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- app/meson.build | 1 + 1 file changed, 1 insertion(+) diff --git a/app/meson.build b/app/meson.build index eb74f215a3..b6f2a6f56e 100644 --- a/app/meson.build +++ b/app/meson.build @@ -60,6 +60,7 @@ foreach app:apps c_args: cflags, link_whole: link_libs, dependencies: dep_objs, + include_directories: includes, install_rpath: join_paths(get_option('prefix'), driver_install_path), install: true) -- 2.27.0
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
On Thu, Jan 14, 2021 at 12:07 PM Bruce Richardson
<bruce.richardson@intel.com> wrote:
>
> Add in the missing includes into the header file for c11 memory model,
> so it can be compiled up independently of the other headers.
>
> Fixes: 39368ebfc606 ("ring: introduce C11 memory model barrier option")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> lib/librte_ring/rte_ring_c11_mem.h | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/lib/librte_ring/rte_ring_c11_mem.h b/lib/librte_ring/rte_ring_c11_mem.h
> index 0fb73a3371..12caf06a31 100644
> --- a/lib/librte_ring/rte_ring_c11_mem.h
> +++ b/lib/librte_ring/rte_ring_c11_mem.h
> @@ -10,6 +10,10 @@
> #ifndef _RTE_RING_C11_MEM_H_
> #define _RTE_RING_C11_MEM_H_
>
> +#include <stdint.h>
> +#include <rte_common.h>
> +#include <rte_ring_core.h>
> +
This header is never directly included, like rte_ring_generic.h.
I'd rather flag it as not being checked.
--
David Marchand
> > On Thu, Jan 14, 2021 at 12:07 PM Bruce Richardson > <bruce.richardson@intel.com> wrote: > > > > Add in the missing includes into the header file for c11 memory model, > > so it can be compiled up independently of the other headers. > > > > Fixes: 39368ebfc606 ("ring: introduce C11 memory model barrier option") > > Cc: stable@dpdk.org > > > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> > > --- > > lib/librte_ring/rte_ring_c11_mem.h | 4 ++++ > > 1 file changed, 4 insertions(+) > > > > diff --git a/lib/librte_ring/rte_ring_c11_mem.h b/lib/librte_ring/rte_ring_c11_mem.h > > index 0fb73a3371..12caf06a31 100644 > > --- a/lib/librte_ring/rte_ring_c11_mem.h > > +++ b/lib/librte_ring/rte_ring_c11_mem.h > > @@ -10,6 +10,10 @@ > > #ifndef _RTE_RING_C11_MEM_H_ > > #define _RTE_RING_C11_MEM_H_ > > > > +#include <stdint.h> > > +#include <rte_common.h> > > +#include <rte_ring_core.h> > > + > > This header is never directly included, like rte_ring_generic.h. > I'd rather flag it as not being checked. Yep, it is sort of 'internal' header that we need to keep public, because of inlined ring enqueue/dequeue functions. > > > -- > David Marchand
The rte_reciprocal header file used standard __rte_always_inline from rte_common.h but does not include that header file, leading to compiler errors when the reciprocal header is included alone. Similarly, rte_thread.h was missing the compat header to get the __rte_experimental macro definition. Fixes: 6d45659eacb8 ("eal: add u64-bit variant for reciprocal divide") Fixes: b1fd151267e6 ("eal: add generic thread-local-storage functions") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/rte_reciprocal.h | 1 + lib/librte_eal/include/rte_thread.h | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/librte_eal/include/rte_reciprocal.h b/lib/librte_eal/include/rte_reciprocal.h index 63e16fde0a..4a59be30a8 100644 --- a/lib/librte_eal/include/rte_reciprocal.h +++ b/lib/librte_eal/include/rte_reciprocal.h @@ -26,6 +26,7 @@ #define _RTE_RECIPROCAL_H_ #include <stdint.h> +#include <rte_common.h> struct rte_reciprocal { uint32_t m; diff --git a/lib/librte_eal/include/rte_thread.h b/lib/librte_eal/include/rte_thread.h index f1ae2d32cc..e640ea1857 100644 --- a/lib/librte_eal/include/rte_thread.h +++ b/lib/librte_eal/include/rte_thread.h @@ -3,6 +3,7 @@ */ #include <rte_os.h> +#include <rte_compat.h> #ifndef _RTE_THREAD_H_ #define _RTE_THREAD_H_ -- 2.27.0
The telemetry header file uses the rte_cpuset_t type, but does not include any header providing that type. Include rte_os.h to provide the necessary type. Fixes: febbebf7f255 ("telemetry: keep threads separate from data plane") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_telemetry/rte_telemetry.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_telemetry/rte_telemetry.h b/lib/librte_telemetry/rte_telemetry.h index 4693275c24..561c6b1658 100644 --- a/lib/librte_telemetry/rte_telemetry.h +++ b/lib/librte_telemetry/rte_telemetry.h @@ -5,6 +5,7 @@ #include <stdint.h> #include <sched.h> #include <rte_compat.h> +#include <rte_os.h> #ifndef _RTE_TELEMETRY_H_ #define _RTE_TELEMETRY_H_ -- 2.27.0
The define for RTE_ETH_FLOW_MAX is defined in rte_ethdev.h, so that header should be included in rte_eth_ctrl.h to allow it to be compiled independently. Fixes: 7fa96d696f2c ("ethdev: unification of flow types") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_ethdev/rte_eth_ctrl.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_ethdev/rte_eth_ctrl.h b/lib/librte_ethdev/rte_eth_ctrl.h index 1cca522fa3..8a50dbfef9 100644 --- a/lib/librte_ethdev/rte_eth_ctrl.h +++ b/lib/librte_ethdev/rte_eth_ctrl.h @@ -9,6 +9,7 @@ #include <rte_common.h> #include <rte_ether.h> #include "rte_flow.h" +#include "rte_ethdev.h" /** * @deprecated Please use rte_flow API instead of this legacy one. -- 2.27.0
The Geneve protocol header file is missing the rte_byteorder.h header. Fixes: ea0e711b8ae0 ("app/testpmd: add GENEVE parsing") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_net/rte_geneve.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_net/rte_geneve.h b/lib/librte_net/rte_geneve.h index bb67724c31..7c3d477dcb 100644 --- a/lib/librte_net/rte_geneve.h +++ b/lib/librte_net/rte_geneve.h @@ -11,6 +11,7 @@ * GENEVE-related definitions */ #include <stdint.h> +#include <rte_byteorder.h> #ifdef __cplusplus extern "C" { -- 2.27.0
The rte_mbuf_dyn.h header file uses a number of types and macros without including the required header files to get the definitions of those macros/types. Similarly, the rte_mbuf_core.h file was missing an include for rte_byteorder.h header. Fixes: 4958ca3a443a ("mbuf: support dynamic fields and flags") Fixes: 3eb860b08eb7 ("mbuf: move definitions into a separate file") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_mbuf/rte_mbuf_core.h | 1 + lib/librte_mbuf/rte_mbuf_dyn.h | 3 +++ 2 files changed, 4 insertions(+) diff --git a/lib/librte_mbuf/rte_mbuf_core.h b/lib/librte_mbuf/rte_mbuf_core.h index 567551deab..34e892f21b 100644 --- a/lib/librte_mbuf/rte_mbuf_core.h +++ b/lib/librte_mbuf/rte_mbuf_core.h @@ -18,6 +18,7 @@ #include <stdint.h> #include <rte_compat.h> +#include <rte_byteorder.h> #include <generic/rte_atomic.h> #ifdef __cplusplus diff --git a/lib/librte_mbuf/rte_mbuf_dyn.h b/lib/librte_mbuf/rte_mbuf_dyn.h index fc4eee71d0..f42deed012 100644 --- a/lib/librte_mbuf/rte_mbuf_dyn.h +++ b/lib/librte_mbuf/rte_mbuf_dyn.h @@ -66,7 +66,10 @@ * - any name that does not start with "rte_" in an application */ +#include <stdio.h> +#include <stdint.h> #include <sys/types.h> +#include <rte_compat.h> #ifdef __cplusplus extern "C" { -- 2.27.0
The rte_compat.h header file must be included to get the definition of __rte_experimental. Fixes: f030bff72f81 ("bitrate: add free function") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_bitratestats/rte_bitrate.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_bitratestats/rte_bitrate.h b/lib/librte_bitratestats/rte_bitrate.h index 4865929e8f..7e34529687 100644 --- a/lib/librte_bitratestats/rte_bitrate.h +++ b/lib/librte_bitratestats/rte_bitrate.h @@ -6,6 +6,7 @@ #define _RTE_BITRATE_H_ #include <stdint.h> +#include <rte_compat.h> #ifdef __cplusplus extern "C" { -- 2.27.0
The standard integer types, and the size_t types are missing their required header includes in the rib header file. Fixes: 5a5793a5ffa2 ("rib: add RIB library") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_rib/rte_rib.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/librte_rib/rte_rib.h b/lib/librte_rib/rte_rib.h index f80752e5bd..6253860523 100644 --- a/lib/librte_rib/rte_rib.h +++ b/lib/librte_rib/rte_rib.h @@ -18,6 +18,8 @@ * Level compressed tree implementation for IPv4 Longest Prefix Match */ +#include <stdlib.h> +#include <stdint.h> #include <rte_compat.h> #ifdef __cplusplus -- 2.27.0
The vhost header files were missing definitions from headers to allow them to be compiled up individually. Fixes: d7280c9fffcb ("vhost: support selective datapath") Fixes: a49f758d1170 ("vhost: split vDPA header file") Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_vhost/rte_vdpa.h | 2 ++ lib/librte_vhost/rte_vdpa_dev.h | 1 + lib/librte_vhost/rte_vhost_crypto.h | 7 +++++++ 3 files changed, 10 insertions(+) diff --git a/lib/librte_vhost/rte_vdpa.h b/lib/librte_vhost/rte_vdpa.h index f074ec0c4a..1437f400bf 100644 --- a/lib/librte_vhost/rte_vdpa.h +++ b/lib/librte_vhost/rte_vdpa.h @@ -11,6 +11,8 @@ * Device specific vhost lib */ +#include <stdint.h> + /** Maximum name length for statistics counters */ #define RTE_VDPA_STATS_NAME_SIZE 64 diff --git a/lib/librte_vhost/rte_vdpa_dev.h b/lib/librte_vhost/rte_vdpa_dev.h index a60183f780..bfada387b0 100644 --- a/lib/librte_vhost/rte_vdpa_dev.h +++ b/lib/librte_vhost/rte_vdpa_dev.h @@ -8,6 +8,7 @@ #include <stdbool.h> #include "rte_vhost.h" +#include "rte_vdpa.h" #define RTE_VHOST_QUEUE_ALL UINT16_MAX diff --git a/lib/librte_vhost/rte_vhost_crypto.h b/lib/librte_vhost/rte_vhost_crypto.h index c809c46a21..2a27a35892 100644 --- a/lib/librte_vhost/rte_vhost_crypto.h +++ b/lib/librte_vhost/rte_vhost_crypto.h @@ -5,6 +5,13 @@ #ifndef _VHOST_CRYPTO_H_ #define _VHOST_CRYPTO_H_ +#include <stdint.h> +#include <rte_compat.h> + +/* pre-declare structs to avoid including full headers */ +struct rte_mempool; +struct rte_crypto_op; + #define VHOST_CRYPTO_MBUF_POOL_SIZE (8192) #define VHOST_CRYPTO_MAX_BURST_SIZE (64) #define VHOST_CRYPTO_MAX_DATA_SIZE (4096) -- 2.27.0
The rte_ipsec_sad.h header used the standard uintXX_t types, but did not include stdint.h header for them. Fixes: 401633d9c112 ("ipsec: add inbound SAD API") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_ipsec/rte_ipsec_sad.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_ipsec/rte_ipsec_sad.h b/lib/librte_ipsec/rte_ipsec_sad.h index 3e67ab1e4b..66c703ff3a 100644 --- a/lib/librte_ipsec/rte_ipsec_sad.h +++ b/lib/librte_ipsec/rte_ipsec_sad.h @@ -7,6 +7,7 @@ #define _RTE_IPSEC_SAD_H_ #include <rte_compat.h> +#include <stdint.h> /** * @file rte_ipsec_sad.h -- 2.27.0
Add stdint.h to get definitions of standard integer types Fixes: 39e927248416 ("fib: add FIB library") Fixes: 40d41a8a7b34 ("fib: support IPv6") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_fib/rte_fib.h | 1 + lib/librte_fib/rte_fib6.h | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/librte_fib/rte_fib.h b/lib/librte_fib/rte_fib.h index fef0749525..352c5e00ad 100644 --- a/lib/librte_fib/rte_fib.h +++ b/lib/librte_fib/rte_fib.h @@ -19,6 +19,7 @@ * for IPv4 Longest Prefix Match */ +#include <stdint.h> #include <rte_compat.h> #ifdef __cplusplus diff --git a/lib/librte_fib/rte_fib6.h b/lib/librte_fib/rte_fib6.h index 668bffb2ba..60213f3372 100644 --- a/lib/librte_fib/rte_fib6.h +++ b/lib/librte_fib/rte_fib6.h @@ -19,6 +19,7 @@ * for IPv6 Longest Prefix Match */ +#include <stdint.h> #include <rte_compat.h> #ifdef __cplusplus -- 2.27.0
The rte_lru_x86.h header, included from the main rte_lru.h header, uses the RTE_CC_IS_GNU macro from rte_common.h but fails to include that header file. Fixes: 0c9a5735a947 ("eal: fix compiler detection in public headers") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_table/rte_lru_x86.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_table/rte_lru_x86.h b/lib/librte_table/rte_lru_x86.h index 0e24906c2c..38476d956e 100644 --- a/lib/librte_table/rte_lru_x86.h +++ b/lib/librte_table/rte_lru_x86.h @@ -12,6 +12,7 @@ extern "C" { #include <stdint.h> #include <rte_config.h> +#include <rte_common.h> #ifndef RTE_TABLE_HASH_LRU_STRATEGY #define RTE_TABLE_HASH_LRU_STRATEGY 2 -- 2.27.0
The stdio.h header needs to be included to get the definition of the FILE type. Fixes: b32c0a2c5e4c ("pipeline: add SWX table update high level API") Fixes: 3ca60ceed79a ("pipeline: add SWX pipeline specification file") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_pipeline/rte_swx_ctl.h | 1 + lib/librte_pipeline/rte_swx_pipeline.h | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/librte_pipeline/rte_swx_ctl.h b/lib/librte_pipeline/rte_swx_ctl.h index bab1894944..32815b69e2 100644 --- a/lib/librte_pipeline/rte_swx_ctl.h +++ b/lib/librte_pipeline/rte_swx_ctl.h @@ -15,6 +15,7 @@ extern "C" { #include <stddef.h> #include <stdint.h> +#include <stdio.h> #include <rte_compat.h> diff --git a/lib/librte_pipeline/rte_swx_pipeline.h b/lib/librte_pipeline/rte_swx_pipeline.h index d0a3439edf..f0a2cef777 100644 --- a/lib/librte_pipeline/rte_swx_pipeline.h +++ b/lib/librte_pipeline/rte_swx_pipeline.h @@ -15,6 +15,7 @@ extern "C" { #include <stddef.h> #include <stdint.h> +#include <stdio.h> #include <rte_compat.h> -- 2.27.0
The global variable "tel_met_data" was declared in a header file, rather than in a C file, leading to duplicate definitions if more than one C file included the header. Fixes: c5b7197f662e ("telemetry: move some functions to metrics library") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_metrics/rte_metrics_telemetry.c | 2 ++ lib/librte_metrics/rte_metrics_telemetry.h | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/librte_metrics/rte_metrics_telemetry.c b/lib/librte_metrics/rte_metrics_telemetry.c index 901cbeb0a3..b8ee56ef01 100644 --- a/lib/librte_metrics/rte_metrics_telemetry.c +++ b/lib/librte_metrics/rte_metrics_telemetry.c @@ -13,6 +13,8 @@ #include "rte_metrics.h" #include "rte_metrics_telemetry.h" +struct telemetry_metrics_data tel_met_data; + int metrics_log_level; /* Logging Macros */ diff --git a/lib/librte_metrics/rte_metrics_telemetry.h b/lib/librte_metrics/rte_metrics_telemetry.h index 3435a55425..5dbb32ca0c 100644 --- a/lib/librte_metrics/rte_metrics_telemetry.h +++ b/lib/librte_metrics/rte_metrics_telemetry.h @@ -34,8 +34,6 @@ struct telemetry_metrics_data { int metrics_register_done; }; -struct telemetry_metrics_data tel_met_data; - __rte_experimental int32_t rte_metrics_tel_reg_all_ethdev(int *metrics_register_done, int *reg_index_list); -- 2.27.0
The rte_compat header file is needed for the '__rte_experimental' macro. Fixes: f00708c2aa53 ("node: add IPv4 rewrite and lookup control") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_node/rte_node_ip4_api.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_node/rte_node_ip4_api.h b/lib/librte_node/rte_node_ip4_api.h index eb9ebd5f89..46d0d8976b 100644 --- a/lib/librte_node/rte_node_ip4_api.h +++ b/lib/librte_node/rte_node_ip4_api.h @@ -21,6 +21,7 @@ extern "C" { #endif #include <rte_common.h> +#include <rte_compat.h> /** * IP4 lookup next nodes. -- 2.27.0
The "includes" variable in the app/meson.build file was ignored when building the executable, meaning that apps couldn't pass additional include paths directly back. Fix this to align with drivers and libs. Fixes: fa036e70d794 ("app: generalize meson build") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- app/meson.build | 1 + 1 file changed, 1 insertion(+) diff --git a/app/meson.build b/app/meson.build index 903117b866..87fc195dbf 100644 --- a/app/meson.build +++ b/app/meson.build @@ -66,6 +66,7 @@ foreach app:apps link_args: ldflags, link_whole: link_libs, dependencies: dep_objs, + include_directories: includes, install_rpath: join_paths(get_option('prefix'), driver_install_path), install: true) -- 2.27.0
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
> -----Original Message----- > From: Richardson, Bruce <bruce.richardson@intel.com> > Sent: Friday, January 15, 2021 11:11 AM > To: dev@dpdk.org > Cc: david.marchand@redhat.com; Richardson, Bruce <bruce.richardson@intel.com>; stable@dpdk.org; Ananyev, Konstantin > <konstantin.ananyev@intel.com>; Iremonger, Bernard <bernard.iremonger@intel.com>; Medvedkin, Vladimir > <vladimir.medvedkin@intel.com>; Akhil Goyal <akhil.goyal@nxp.com> > Subject: [PATCH v2 09/19] ipsec: fix missing header include > > The rte_ipsec_sad.h header used the standard uintXX_t types, but did not > include stdint.h header for them. > > Fixes: 401633d9c112 ("ipsec: add inbound SAD API") > Cc: stable@dpdk.org > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> > --- > lib/librte_ipsec/rte_ipsec_sad.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/lib/librte_ipsec/rte_ipsec_sad.h b/lib/librte_ipsec/rte_ipsec_sad.h > index 3e67ab1e4b..66c703ff3a 100644 > --- a/lib/librte_ipsec/rte_ipsec_sad.h > +++ b/lib/librte_ipsec/rte_ipsec_sad.h > @@ -7,6 +7,7 @@ > #define _RTE_IPSEC_SAD_H_ > > #include <rte_compat.h> > +#include <stdint.h> > > /** > * @file rte_ipsec_sad.h > -- Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com> > 2.27.0
On 15/01/2021 11:10, Bruce Richardson wrote:
> The standard integer types, and the size_t types are missing their
> required header includes in the rib header file.
>
> Fixes: 5a5793a5ffa2 ("rib: add RIB library")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> lib/librte_rib/rte_rib.h | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/lib/librte_rib/rte_rib.h b/lib/librte_rib/rte_rib.h
> index f80752e5bd..6253860523 100644
> --- a/lib/librte_rib/rte_rib.h
> +++ b/lib/librte_rib/rte_rib.h
> @@ -18,6 +18,8 @@
> * Level compressed tree implementation for IPv4 Longest Prefix Match
> */
>
> +#include <stdlib.h>
> +#include <stdint.h>
> #include <rte_compat.h>
>
> #ifdef __cplusplus
>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
--
Regards,
Vladimir
On 15/01/2021 11:10, Bruce Richardson wrote:
> The rte_ipsec_sad.h header used the standard uintXX_t types, but did not
> include stdint.h header for them.
>
> Fixes: 401633d9c112 ("ipsec: add inbound SAD API")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> lib/librte_ipsec/rte_ipsec_sad.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/lib/librte_ipsec/rte_ipsec_sad.h b/lib/librte_ipsec/rte_ipsec_sad.h
> index 3e67ab1e4b..66c703ff3a 100644
> --- a/lib/librte_ipsec/rte_ipsec_sad.h
> +++ b/lib/librte_ipsec/rte_ipsec_sad.h
> @@ -7,6 +7,7 @@
> #define _RTE_IPSEC_SAD_H_
>
> #include <rte_compat.h>
> +#include <stdint.h>
>
> /**
> * @file rte_ipsec_sad.h
>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
--
Regards,
Vladimir
On 15/01/2021 11:10, Bruce Richardson wrote:
> Add stdint.h to get definitions of standard integer types
>
> Fixes: 39e927248416 ("fib: add FIB library")
> Fixes: 40d41a8a7b34 ("fib: support IPv6")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> lib/librte_fib/rte_fib.h | 1 +
> lib/librte_fib/rte_fib6.h | 1 +
> 2 files changed, 2 insertions(+)
>
> diff --git a/lib/librte_fib/rte_fib.h b/lib/librte_fib/rte_fib.h
> index fef0749525..352c5e00ad 100644
> --- a/lib/librte_fib/rte_fib.h
> +++ b/lib/librte_fib/rte_fib.h
> @@ -19,6 +19,7 @@
> * for IPv4 Longest Prefix Match
> */
>
> +#include <stdint.h>
> #include <rte_compat.h>
>
> #ifdef __cplusplus
> diff --git a/lib/librte_fib/rte_fib6.h b/lib/librte_fib/rte_fib6.h
> index 668bffb2ba..60213f3372 100644
> --- a/lib/librte_fib/rte_fib6.h
> +++ b/lib/librte_fib/rte_fib6.h
> @@ -19,6 +19,7 @@
> * for IPv6 Longest Prefix Match
> */
>
> +#include <stdint.h>
> #include <rte_compat.h>
>
> #ifdef __cplusplus
>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
--
Regards,
Vladimir
Hi Bruce,
Just a one nit, please put <stdint.h> before rte_ includes.
On 15/01/2021 11:37, Medvedkin, Vladimir wrote:
>
>
> On 15/01/2021 11:10, Bruce Richardson wrote:
>> The rte_ipsec_sad.h header used the standard uintXX_t types, but did not
>> include stdint.h header for them.
>>
>> Fixes: 401633d9c112 ("ipsec: add inbound SAD API")
>> Cc: stable@dpdk.org
>>
>> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
>> ---
>> lib/librte_ipsec/rte_ipsec_sad.h | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/lib/librte_ipsec/rte_ipsec_sad.h
>> b/lib/librte_ipsec/rte_ipsec_sad.h
>> index 3e67ab1e4b..66c703ff3a 100644
>> --- a/lib/librte_ipsec/rte_ipsec_sad.h
>> +++ b/lib/librte_ipsec/rte_ipsec_sad.h
>> @@ -7,6 +7,7 @@
>> #define _RTE_IPSEC_SAD_H_
>> #include <rte_compat.h>
>> +#include <stdint.h>
>> /**
>> * @file rte_ipsec_sad.h
>>
>
> Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
>
--
Regards,
Vladimir
On Fri, Jan 15, 2021 at 11:45:11AM +0000, Medvedkin, Vladimir wrote: > Hi Bruce, > > Just a one nit, please put <stdint.h> before rte_ includes. > Good point, I'll fix if I do a V3. > On 15/01/2021 11:37, Medvedkin, Vladimir wrote: > > > > > > On 15/01/2021 11:10, Bruce Richardson wrote: > > > The rte_ipsec_sad.h header used the standard uintXX_t types, but did not > > > include stdint.h header for them. > > > > > > Fixes: 401633d9c112 ("ipsec: add inbound SAD API") > > > Cc: stable@dpdk.org > > > > > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> > > > --- > > > lib/librte_ipsec/rte_ipsec_sad.h | 1 + > > > 1 file changed, 1 insertion(+) > > > > > > diff --git a/lib/librte_ipsec/rte_ipsec_sad.h > > > b/lib/librte_ipsec/rte_ipsec_sad.h > > > index 3e67ab1e4b..66c703ff3a 100644 > > > --- a/lib/librte_ipsec/rte_ipsec_sad.h > > > +++ b/lib/librte_ipsec/rte_ipsec_sad.h > > > @@ -7,6 +7,7 @@ > > > #define _RTE_IPSEC_SAD_H_ > > > #include <rte_compat.h> > > > +#include <stdint.h> > > > /** > > > * @file rte_ipsec_sad.h > > > > > > > Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com> > > > > -- > Regards, > Vladimir
<snip> > > Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. > > Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") > Cc: stable@dpdk.org > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com> > --- > lib/librte_eal/include/generic/rte_mcslock.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/lib/librte_eal/include/generic/rte_mcslock.h > b/lib/librte_eal/include/generic/rte_mcslock.h > index d370bef17a..9f323bd2a2 100644 > --- a/lib/librte_eal/include/generic/rte_mcslock.h > +++ b/lib/librte_eal/include/generic/rte_mcslock.h > @@ -22,6 +22,7 @@ > #include <rte_lcore.h> > #include <rte_common.h> > #include <rte_pause.h> > +#include <rte_branch_prediction.h> > > /** > * The rte_mcslock_t type. > -- > 2.27.0
On 1/15/21 2:10 PM, Bruce Richardson wrote:
> The define for RTE_ETH_FLOW_MAX is defined in rte_ethdev.h, so that
> header should be included in rte_eth_ctrl.h to allow it to be compiled
> independently.
>
> Fixes: 7fa96d696f2c ("ethdev: unification of flow types")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
On 1/15/21 2:10 PM, Bruce Richardson wrote:
> The rte_mbuf_dyn.h header file uses a number of types and macros without
> including the required header files to get the definitions of those
> macros/types. Similarly, the rte_mbuf_core.h file was missing an
> include for rte_byteorder.h header.
>
> Fixes: 4958ca3a443a ("mbuf: support dynamic fields and flags")
> Fixes: 3eb860b08eb7 ("mbuf: move definitions into a separate file")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Acked-by: Ophir Munk <ophirmu@nvidia.com>
> -----Original Message-----
> From: Bruce Richardson <bruce.richardson@intel.com>
> Sent: Friday, January 15, 2021 1:11 PM
> To: dev@dpdk.org
> Cc: david.marchand@redhat.com; Bruce Richardson
> <bruce.richardson@intel.com>; stable@dpdk.org; Olivier Matz
> <olivier.matz@6wind.com>; Ophir Munk <ophirmu@mellanox.com>; Ferruh
> Yigit <ferruh.yigit@intel.com>
> Subject: [PATCH v2 04/19] net: fix missing header include
>
> The Geneve protocol header file is missing the rte_byteorder.h header.
>
> Fixes: ea0e711b8ae0 ("app/testpmd: add GENEVE parsing")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> lib/librte_net/rte_geneve.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/lib/librte_net/rte_geneve.h b/lib/librte_net/rte_geneve.h index
> bb67724c31..7c3d477dcb 100644
> --- a/lib/librte_net/rte_geneve.h
> +++ b/lib/librte_net/rte_geneve.h
> @@ -11,6 +11,7 @@
> * GENEVE-related definitions
> */
> #include <stdint.h>
> +#include <rte_byteorder.h>
>
> #ifdef __cplusplus
> extern "C" {
> --
> 2.27.0
On 1/15/21 12:10 PM, Bruce Richardson wrote:
> The vhost header files were missing definitions from headers to allow
> them to be compiled up individually.
>
> Fixes: d7280c9fffcb ("vhost: support selective datapath")
> Fixes: a49f758d1170 ("vhost: split vDPA header file")
> Fixes: 939066d96563 ("vhost/crypto: add public function implementation")
> Cc: stable@dpdk.org
>
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> lib/librte_vhost/rte_vdpa.h | 2 ++
> lib/librte_vhost/rte_vdpa_dev.h | 1 +
> lib/librte_vhost/rte_vhost_crypto.h | 7 +++++++
> 3 files changed, 10 insertions(+)
>
> diff --git a/lib/librte_vhost/rte_vdpa.h b/lib/librte_vhost/rte_vdpa.h
> index f074ec0c4a..1437f400bf 100644
> --- a/lib/librte_vhost/rte_vdpa.h
> +++ b/lib/librte_vhost/rte_vdpa.h
> @@ -11,6 +11,8 @@
> * Device specific vhost lib
> */
>
> +#include <stdint.h>
> +
> /** Maximum name length for statistics counters */
> #define RTE_VDPA_STATS_NAME_SIZE 64
>
> diff --git a/lib/librte_vhost/rte_vdpa_dev.h b/lib/librte_vhost/rte_vdpa_dev.h
> index a60183f780..bfada387b0 100644
> --- a/lib/librte_vhost/rte_vdpa_dev.h
> +++ b/lib/librte_vhost/rte_vdpa_dev.h
> @@ -8,6 +8,7 @@
> #include <stdbool.h>
>
> #include "rte_vhost.h"
> +#include "rte_vdpa.h"
>
> #define RTE_VHOST_QUEUE_ALL UINT16_MAX
>
> diff --git a/lib/librte_vhost/rte_vhost_crypto.h b/lib/librte_vhost/rte_vhost_crypto.h
> index c809c46a21..2a27a35892 100644
> --- a/lib/librte_vhost/rte_vhost_crypto.h
> +++ b/lib/librte_vhost/rte_vhost_crypto.h
> @@ -5,6 +5,13 @@
> #ifndef _VHOST_CRYPTO_H_
> #define _VHOST_CRYPTO_H_
>
> +#include <stdint.h>
> +#include <rte_compat.h>
> +
> +/* pre-declare structs to avoid including full headers */
> +struct rte_mempool;
> +struct rte_crypto_op;
> +
> #define VHOST_CRYPTO_MBUF_POOL_SIZE (8192)
> #define VHOST_CRYPTO_MAX_BURST_SIZE (64)
> #define VHOST_CRYPTO_MAX_DATA_SIZE (4096)
>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Thanks,
Maxime
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
Include 'rte_branch_prediction.h' to get the likely/unlikely macro definitions. Fixes: 2173f3333b61 ("mcslock: add MCS queued lock implementation") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com> --- lib/librte_eal/include/generic/rte_mcslock.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/include/generic/rte_mcslock.h b/lib/librte_eal/include/generic/rte_mcslock.h index d370bef17a..9f323bd2a2 100644 --- a/lib/librte_eal/include/generic/rte_mcslock.h +++ b/lib/librte_eal/include/generic/rte_mcslock.h @@ -22,6 +22,7 @@ #include <rte_lcore.h> #include <rte_common.h> #include <rte_pause.h> +#include <rte_branch_prediction.h> /** * The rte_mcslock_t type. -- 2.27.0
Clang does not have an "error" attribute for functions, so for marking internal functions we need to check for the error attribute, and provide a fallback if it is not present. For clang, we can use "diagnose_if" attribute, similarly checking for its presence before use. Fixes: fba5af82adc8 ("eal: add internal ABI tag definition") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> --- lib/librte_eal/include/rte_compat.h | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/lib/librte_eal/include/rte_compat.h b/lib/librte_eal/include/rte_compat.h index 4cd8f68d68..2718612cce 100644 --- a/lib/librte_eal/include/rte_compat.h +++ b/lib/librte_eal/include/rte_compat.h @@ -19,12 +19,23 @@ __attribute__((section(".text.experimental"))) #endif -#ifndef ALLOW_INTERNAL_API +#ifndef __has_attribute +/* if no has_attribute assume no support for attribute too */ +#define __has_attribute(x) 0 +#endif + +#if !defined ALLOW_INTERNAL_API && __has_attribute(error) /* For GCC */ #define __rte_internal \ __attribute__((error("Symbol is not public ABI"), \ section(".text.internal"))) +#elif !defined ALLOW_INTERNAL_API && __has_attribute(diagnose_if) /* For clang */ + +#define __rte_internal \ +__attribute__((diagnose_if(1, "Symbol is not public ABI", "error"), \ +section(".text.internal"))) + #else #define __rte_internal \ -- 2.27.0
The rte_rib6 header was using RTE_MIN macro from rte_common.h but not including the header file. Fixes: f7e861e21c46 ("rib: support IPv6") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com> --- lib/librte_rib/rte_rib6.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_rib/rte_rib6.h b/lib/librte_rib/rte_rib6.h index b5e10569b9..dbd52928a2 100644 --- a/lib/librte_rib/rte_rib6.h +++ b/lib/librte_rib/rte_rib6.h @@ -20,6 +20,7 @@ #include <rte_memcpy.h> #include <rte_compat.h> +#include <rte_common.h> #ifdef __cplusplus extern "C" { -- 2.27.0