path: root/config
AgeCommit message (Collapse)Author
2019-06-28net/hinic: add build and doc filesZiyang Xuan
Add build and doc files along with hinic_pmd_ethdev.c which just includes PMD register and log initialization for compilation. Signed-off-by: Ziyang Xuan <> Reviewed-by: Ferruh Yigit <>
2019-06-26build: enable BSD features visibility for FreeBSDMarcin Smoczynski
When a component uses either XOPEN_SOURCE or POSIX_C_SOURCE macro explicitly in its build recipe, it restricts visibility of a non POSIX features subset, such as IANA protocol numbers (IPPROTO_* macros). Non standard features are enabled by default for DPDK both for Linux thanks to _GNU_SOURCE and for FreeBSD thanks to __BSD_VISIBLE. However using XOPEN_SOURCE or POSIX_(C_)SOURCE in a component causes __BSD_VISIBLE to be defined to 0 for FreeBSD, causing different feature sets visibility for Linux and FreeBSD. It restricts from using IPPROTO macros in public headers, such as rte_ip.h, despite the fact they are already widely used in sources. Add __BSD_VISIBLE macro specified unconditionally for FreeBSD targets which enforces feature sets visibility unification between Linux and FreeBSD. Add single -D_GNU_SOURCE to config/ as a project argument instead of adding separate directive for each project subtree. This patch solves the problem of build breaks for [1] on FreeBSD [2] following the discussion [3]. [1] [2] [3] Signed-off-by: Marcin Smoczynski <> Acked-by: Konstantin Ananyev <>
2019-06-25mempool/octeontx2: add build infra and device probeJerin Jacob
Add the make and meson based build infrastructure along with the mempool(NPA) device probe. Signed-off-by: Jerin Jacob <> Signed-off-by: Pavan Nikhilesh <>
2019-06-25common/octeontx2: add build infrastructure and HW definitionJerin Jacob
Add the make and meson based build infrastructure along with HW definition header file. This patch adds skeleton otx2_mbox.c file to make sure all header files are intact, subsequent patches add content to otx2_mbox.c This patch also updates CONFIG_RTE_MAX_VFIO_GROUPS value to 128 as the system can have up to 128 PFs/VFs. For octeontx2 meson build target, CONFIG_RTE_MAX_VFIO_GROUPS defined as 128 so no additional changes required. Signed-off-by: Jerin Jacob <> Signed-off-by: Pavan Nikhilesh <>
2019-06-20net/iavf: move compile time define to configurationLavanya Govindarajan
DEBUG_DUMP_DESC flag is commented out in IAVF Makefile and to enable it user needs to edit the Makefile. It is felt that this method is not good. Hence removing this flag from IAVF makefile and adding a flag CONFIG_RTE_LIBRTE_IAVF_DEBUG_DUMP_DESC to config/common_base. Signed-off-by: Lavanya Govindarajan <> Acked-by: Qi Zhang <>
2019-06-13net/memif: introduce memory interface PMDJakub Grajciar
Shared memory packet interface (memif) PMD allows for DPDK and any other client using memif (DPDK, VPP, libmemif) to communicate using shared memory. The created device transmits packets in a raw format. It can be used with Ethernet mode, IP mode, or Punt/Inject. At this moment, only Ethernet mode is supported in DPDK memif implementation. Memif is Linux only. Signed-off-by: Jakub Grajciar <> Reviewed-by: Ferruh Yigit <>
2019-06-04config: add Marvell ARMADA based on armv8-aLiron Himi
This patch introduces armada target to address difference in number of cores, no numa support Signed-off-by: Liron Himi <> Reviewed-by: Alan Winkowski <> Reviewed-by: Jerin Jacob <> Acked-by: Ruifeng Wang <> Acked-by: Gavin Hu <>
2019-06-04config: disable armv8 crypto extensionYongseok Koh
Per armv8 crypto extension support, make build always enable it by default as long as compiler supports the feature while meson build only enables it for 'default' machine of generic armv8 architecture. It is known that not all the armv8 platforms have the crypto extension. For example, Mellanox BlueField has a variant which doesn't have it. If crypto enabled binary runs on such a platform, rte_eal_init() fails. '+crypto' flag currently implies only '+aes' and '+sha2' and enabling it will generate the crypto instructions only when crypto intrinsics are used. For the devices supporting 8.2 crypto or newer, compiler could generate such instructions beyond intrinsics or asm code. For example, compiler can generate 3-way exclusive OR instructions if sha3 is supported. However, it has to be enabled by adding '+sha3' as of today. In DPDK, armv8 cryptodev is the only one which requires the crypto support. As it even uses external library of Marvell which is compiled out of DPDK with crypto support and there's run-time check for required cpuflags, crypto support can be disabled in DPDK. Cc: Signed-off-by: Yongseok Koh <> Acked-by: Jerin Jacob <> Tested-by: Dharmik Thakkar <> Reviewed-by: Honnappa Nagarahalli <>
2019-06-04eal/x86: check rdrand and rdseedBruce Richardson
The meson build never checked for the presence of rdrand and rdseed instructions, while make build never checked for rdseed. Ensure builds always have the appropriate checks - and therefore defines - for these instructions. For runtime, we also add in rdseed to the list of known bits returned from cpuid() instruction, so we can confirm its presence at application init time. Signed-off-by: Bruce Richardson <> Tested-by: Mattias Rönnblom <>
2019-06-04config: shorten code for x86 instruction detectionBruce Richardson
Rather than checking flag by flag individually, use a loop to make it easier to check new flags. Signed-off-by: Bruce Richardson <>
2019-06-04build: warn on unused parameterBruce Richardson
To improve code quality we want to turn on as many warnings as we can in the DPDK code, so turn on the "unused-parameter" warning in meson builds to match that of the make builds. To ensure correct compilation, disable the warning selectively for driver base code that otherwise would have issues. Signed-off-by: Bruce Richardson <> Acked-by: Luca Boccassi <>
2019-05-29kni: remove ethtool supportFerruh Yigit
Current design requires kernel drivers and they need to be probed by Linux up to some level so that they can be usable by DPDK for ethtool support, this requires maintaining the Linux drivers in DPDK. Also ethtool support is limited and hard, if not impossible, to expand to other PMDs. Since KNI ethtool support is not used commonly, if not used at all, removing the support for the sake of simplicity and maintenance. Signed-off-by: Ferruh Yigit <> Acked-by: Stephen Hemminger <> Acked-by: Neil Horman <> Acked-by: Thomas Monjalon <>
2019-05-02build: add libbsd to pkg-config file if enabledBruce Richardson
If libbsd is enabled in DPDK, the strlcpy and strlcat functions in rte_string_fns.h redirect to the varients in libbsd, only using the fallbacks if it is not enabled. Therefore, if libbsd is enabled, it needs to be called out as a DPDK dependency in the pkgconfig file. To ensure that we don't have undefined variables on non-Linux platforms, we can remove the linux condition around the libbsd check - no harm comes in looking for it on other OS, since it's an optional dependency. Signed-off-by: Bruce Richardson <> Acked-by: Luca Boccassi <>
2019-05-02build: fix ninja install on FreeBSDBruce Richardson
The post-install script to symlink the PMDs from their own PMD directory to the regular lib directory (so they would be found by ld at runtime) was using the "-r" flag to ln to create relative symlinks. This flag is unsupported by ln on FreeBSD causing the ninja install step to fail. Reworking the script to take the relative driver path as parameter removes the need for ln to calculate the relative path ensuring compatibility with FreeBSD. As part of the fix, we move the registration of the install script to the config/ file, from the top level one. This improves readability as the script takes as parameters the variables set in that file. Fixes: ed4d43d73e2b ("build: symlink drivers to library directory") Cc: Signed-off-by: Bruce Richardson <> Acked-by: Luca Boccassi <>
2019-05-02build: reduce indentation in meson checkFerruh Yigit
Just syntax change to reduce indentation, no functional change. Signed-off-by: Ferruh Yigit <> Acked-by: Bruce Richardson <>
2019-05-02build: fix crash by disabling AVX512 with binutils 2.31Ferruh Yigit
On Skylake platform, with native build, KNI kernel module crashes because of the corrupted values passed to kernel module. The corruption occurs because the userspace kni library works unexpectedly. Compiler [1] is using AVX512 instructions and generated binary is wrong [2]. It turned around gcc does its job correct, but gas is generating binary wrong. And expected binutils 2.30, 2.31 & 2.31.1 are affected. Issue has been fixed in binutils 2.32 with: Commit x86: don't mistakenly scale non-8-bit displacements AVX512 was already disabled with bintuils 2.30 [3], extending it to 2.31 & 2.31.1 too. [1] gcc (GCC) 8.3.1 20190223 (Red Hat 8.3.1-2) [2] gcc bug: [3] Bugzilla ID 97 has the details. Bugzilla ID: 249 Cc: Signed-off-by: Ferruh Yigit <> Acked-by: Bruce Richardson <>
2019-05-02build: fix meson binutils workaroundFerruh Yigit
The '-mno-avx512f' compiler flag is not passed to the compiler, detection of the binutils and setting flags works fine, but the flag itself not used by compiler. Removing the interim 'march_opt' variable and using directly 'machine_args' and setting '-mno-avx512f' to 'machine_args' Fixes: 566b4d7a968f ("build: fix meson check for binutils 2.30") Cc: Signed-off-by: Ferruh Yigit <> Acked-by: Bruce Richardson <>
2019-05-02rcu: add RCU library supporting QSBR mechanismHonnappa Nagarahalli
Add RCU library supporting quiescent state based memory reclamation method. This library helps identify the quiescent state of the reader threads so that the writers can free the memory associated with the lock less data structures. Signed-off-by: Honnappa Nagarahalli <> Reviewed-by: Steve Capper <> Reviewed-by: Gavin Hu <> Reviewed-by: Ola Liljedahl <> Acked-by: Paul E. McKenney <> Acked-by: Konstantin Ananyev <> Tested-by: Jerin Jacob <> Tested-by: Ruifeng Wang <> Tested-by: Hemant Agrawal <>
2019-04-19net/ipn3ke: add new driverRosen Xu
Add Intel FPGA Acceleration NIC IPN3KE ethdev PMD driver. Signed-off-by: Rosen Xu <> Signed-off-by: Andy Pei <> Signed-off-by: Dan Wei <>
2019-04-18config: add Mellanox BlueField for meson cross-compilationYongseok Koh
Mellanox BlueField is armv8 CPU having cortex-a72. The implementor ID is 0x41 (arm) and the primary part number is 0xd08 (cortex-a72). Signed-off-by: Yongseok Koh <> Acked-by: Jerin Jacob <>
2019-04-18config: change defaults of armv8Yongseok Koh
Current default cache line size for armv8 CPUs having Implementor ID of 0x41 is 128 bytes, changing it to 64 bytes. Also, the max number of lcores is changed to 16 from 256. Signed-off-by: Yongseok Koh <> Reviewed-by: Honnappa Nagarahalli <>
2019-04-17build: use default flags for default Arm machineLuca Boccassi
When building for generic distribution we need a stable baseline architecture, or depending on the build worker the result will vary. Force the default flags if the user explicitly sets machine=default at configuration time. Fixes: b1d48c41189a ("build: support ARM with meson") Cc: Signed-off-by: Luca Boccassi <> Acked-by: Bruce Richardson <> Acked-by: Pavan Nikhilesh <>
2019-04-17build: increase readability via shortcut variablesBruce Richardson
Define variables for "is_linux", "is_freebsd" and "is_windows" to make the code shorter for comparisons and more readable. Signed-off-by: Bruce Richardson <> Reviewed-by: David Marchand <> Acked-by: Luca Boccassi <>
2019-04-17build: simplify subdirectory detection for EALBruce Richardson
Within EAL we had a series of if statements for selecting the EAL directory to use. Now that the directory names match those of the OS's they are for we can instead just use a generated subdirectory name, shortening the code. To avoid strange errors, we still need to check for unsupported OS's, but do this check up-front in the config file. Signed-off-by: Bruce Richardson <> Reviewed-by: David Marchand <> Acked-by: Luca Boccassi <>
2019-04-15config: add octeontx2 machineJerin Jacob
Optimized configuration for Marvell octeontx2 SoC. Updated meson build to support Marvell octeontx2 SoC. Added meson cross build target for octeontx2. Signed-off-by: Jerin Jacob <> Signed-off-by: Pavan Nikhilesh <> Reviewed-by: Gavin Hu <>
2019-04-15config: add thunderx2 machineJerin Jacob
Optimized configuration for Marvell thunderx2 SoC. Updated meson build to support Marvell thunderx2 SoC. Added meson cross compile target. Product details are here: Signed-off-by: Jerin Jacob <> Signed-off-by: Pavan Nikhilesh <> Reviewed-by: Gavin Hu <>
2019-04-15meson: support Arm machine specific flagsPavan Nikhilesh
Currently, RTE_* flags are set based on the implementer ID but there might be some micro arch specific differences from the same vendor eg. CACHE_LINESIZE. Add support to set micro arch specific flags. Signed-off-by: Pavan Nikhilesh <> Signed-off-by: Jerin Jacob <>
2019-04-12net/nfb: add new netcope driverRastislav Cernay
Added new net driver for Netcope nfb cards Signed-off-by: Rastislav Cernay <>
2019-04-05net/af_xdp: introduce AF_XDP PMDXiaolong Ye
Add a new PMD driver for AF_XDP which is a proposed faster version of AF_PACKET interface in Linux. More info about AF_XDP, please refer to [1] [2]. This is the vanilla version PMD which just uses a raw buffer registered as the umem. [1] [2] Signed-off-by: Xiaolong Ye <> Reviewed-by: Ferruh Yigit <> Acked-by: Luca Boccassi <> Reviewed-by: Stephen Hemminger <>
2019-04-05config: increase maximum number of raw devices to 64Hemant Agrawal
The current value is 10, which is not sufficient for many use-cases. e.g. NXP LX2 with raw qdma devices can use 32-48 raw devices in some use-cases. So, making it to 64 to cover various cases. Signed-off-by: Hemant Agrawal <> Acked-by: Bruce Richardson <>
2019-04-04stack: introduce stack libraryGage Eads
The rte_stack library provides an API for configuration and use of a bounded stack of pointers. Push and pop operations are MT-safe, allowing concurrent access, and the interface supports pushing and popping multiple pointers at a time. The library's interface is modeled after another DPDK data structure, rte_ring, and its lock-based implementation is derived from the stack mempool handler. An upcoming commit will migrate the stack mempool handler to rte_stack. Signed-off-by: Gage Eads <> Reviewed-by: Olivier Matz <> Reviewed-by: Honnappa Nagarahalli <>
2019-04-02compress/qat: add dynamic SGL allocationTomasz Jozwiak
This patch adds dynamic SGL allocation instead of static one. The number of element in SGL can be adjusted in each operation depend of the request. Signed-off-by: Tomasz Jozwiak <> Acked-by: Fiona Trahe <>
2019-04-02crypto/qat: add asymmetric crypto PMDArek Kusztal
This patch adds Poll Mode Driver for asymmetric crypto functions of Intel QuickAssist Technology hardware. It contains plain driver with no functions implemented, specific algorithms will be introduced in separate patches. This patch depends on a QAT PF driver for device initialization. See the file docs/guides/cryptodevs/qat.rst for configuration details. Signed-off-by: Arek Kusztal <> Acked-by: Fiona Trahe <>
2019-04-03eal/windows: introduce Windows supportAnand Rawat
Added initial stub source files and required meson changes for Windows support. kernel/windows/meson is a stub file added to support Windows specific source in future releases. Signed-off-by: Pallavi Kadam <> Signed-off-by: Anand Rawat <> Reviewed-by: Jeff Shaw <> Reviewed-by: Ranjit Menon <> Acked-by: Harini Ramakrishnan <>
2019-03-27build: use version number from config fileBruce Richardson
Since we have the version number in a separate file at the root level, we should not need to duplicate this in rte_version.h too. Best approach here is to move the macros for specifying the year/month/etc. parts from the version header file to the build config file - leaving the other utility macros for e.g. printing the version string, where they are. For "make", this is done by having a little bit of awk parse the version file and pass the results through to the preprocessor for the config generation stage. For "meson", this is done by parsing the version and adding it to the standard dpdk_conf object. In both cases, we need to append a large number - in this case "99", previously 16 in original code - to the version number when we want to do version number comparisons. Without this, the release version e.g. 19.05.0 will compare as less than it's RC's e.g. 19.05.0-rc4. With it, the comparison is correct as " > 19.05.0-rc4.99". Signed-off-by: Bruce Richardson <> Acked-by: Luca Boccassi <> Acked-by: Thomas Monjalon <>
2019-03-27build: move meson version handling to config directoryBruce Richardson
To keep the top-level file as clean and clear as possible, we move the version handling to the config/ file, where the rest of the build configuration is already being set up. Signed-off-by: Bruce Richardson <> Acked-by: Luca Boccassi <>
2019-03-26build: remove meson warning for ArmJerin Jacob
Remove the following warning by comparing string to string. config/arm/ WARNING: Trying to compare values of different types (list, str) using ==. Fixes: c6e536e38437 ("build: add more implementers IDs and PNs for ARM") Cc: Signed-off-by: Jerin Jacob <> Acked-by: Luca Boccassi <>
2019-03-12mk: use linux and freebsd in config namesBruce Richardson
Rather than using linuxapp and bsdapp everywhere, we can change things to use the, more readable, terms "linux" and "freebsd" in our build configs. Rather than renaming the configs we can just duplicate the existing ones with the new names using symlinks, and use the new names exclusively internally. ["make showconfigs" also only shows the new names to keep the list short] The result is that backward compatibility is kept fully but any new builds or development can be done using the newer names, i.e. both "make config T=x86_64-native-linuxapp-gcc" and "T=x86_64-native-linux-gcc" work. Signed-off-by: Bruce Richardson <>
2019-03-12build: rename linuxapp to linux in meson cross filesBruce Richardson
Rename the cross files for meson compilation from having linuxapp in the name to just linux in the name. Signed-off-by: Bruce Richardson <>
2019-03-12build/freebsd: rename macro BSDPAPP to FREEBSDBruce Richardson
Rename the macro and all instances in DPDK code, but keep a copy of the old macro defined for legacy code linking against DPDK Signed-off-by: Bruce Richardson <>
2019-03-12build/linux: rename macro from LINUXAPP to LINUXBruce Richardson
Rename the macro to make things shorter and more comprehensible. For both meson and make builds, keep the old macro around for backward compatibility. Signed-off-by: Bruce Richardson <>
2019-03-01net/iavf: rename remaining avf stringsLeyi Rong
This is the main patch which renames the macros, functions, structs and any remaining strings in the iavf code. Signed-off-by: Leyi Rong <> Reviewed-by: Ferruh Yigit <>
2019-03-01build: support Cortex a55 and a76 platformsPhil Yang
Enable native/cross compiling for Cortex-A55 and Cortex-A76 on meson. Signed-off-by: Phil Yang <> Reviewed-by: Ola Liljedahl <> Reviewed-by: Gavin Hu <>
2019-03-01build: improve pcap dependency handlingLuca Boccassi
pcap has historically shipped a custom pcap-config binary tool which does the job of pkg-config. It was never compatible with cross compilation. Meson uses it when using dependency(), which then means cross compilation fails. Set pcap-config to empty in the meson cross compilation files so that Meson will not use it, and add a fallback in case dependency() fails. libpcap 1.9.0 finally ships a pkg-config file so everything will work out of the box in the future. Signed-off-by: Luca Boccassi <>
2019-02-27build: improve libbsd dependency handlingLuca Boccassi
Use dependency() instead of manual append to ldflags. Move libbsd inclusion to librte_eal, so that all other libraries and PMDs will inherit it. Signed-off-by: Luca Boccassi <> Acked-by: Bruce Richardson <>
2019-02-26build: add option to override max ethdev portsChas Williams
Allow users and packagers to override the default RTE_MAX_ETHPORTS. This adds a new meson option, max_ethports which defaults to the current value. Signed-off-by: Chas Williams <> Acked-by: Bruce Richardson <>
2019-02-26build: set RTE_ARCH_64 based on pointer sizeBruce Richardson
Rather than relying on the target machine architecture, use the size of a pointer from the compiler to determine if we are 64-bits or not. This allows correct behaviour when you pass -m32 as a compile option. It also allows us to use this value repeatedly throughout the repo rather than continually testing for the sizeof(void*). Signed-off-by: Bruce Richardson <> Tested-by: Luca Boccassi <> Acked-by: Luca Boccassi <>
2019-01-17build: fix meson check for binutils 2.30Harry van Haaren
This commit reworks the checks for binutils 2.30 and how the flags to disable AVX512F are passed to the compiler. Previously the #define for including AVX512 code was set, while the -mno-avx512f argument was given to the compiler. This would cause gcc to correctly refuse to emit AVX512 instructions, but the rte_memcpy code that includes AVX512 optimizations was being added to the build. The check for binutils check is now moved to x86 as it is irrelevant for other architectures, and the -mno-avx512f flag is passed to a march_opts array in meson. As the -mno-avx512 flag is added earlier in the build, the code in rte_memcpy is no longer attempted to be compiled. This commit also adds a message print in the meson configure stage to alert the user of the workaround being employed. Fixes: a32ca9a4ebc1 ("mk: fix scope of disabling AVX512F support") Signed-off-by: Harry van Haaren <> Tested-by: Ferruh Yigit <>
2019-01-14config: add static linkage of mlx dependencyThomas Monjalon
The libraries provided by rdma-core may be statically linked if enabling CONFIG_RTE_IBVERBS_LINK_STATIC in the make-based build. If CONFIG_RTE_BUILD_SHARED_LIB is disabled, the applications will embed the mlx PMDs with ibverbs and the mlx libraries. If CONFIG_RTE_BUILD_SHARED_LIB is enabled, the mlx PMDs will embed ibverbs and the mlx libraries. Support with meson may be added later. Signed-off-by: Thomas Monjalon <> Acked-by: Shahaf Shuler <>
2019-01-14config: gather options for dlopen mlx dependencyThomas Monjalon
Rename options CONFIG_RTE_LIBRTE_MLX4_DLOPEN_DEPS and CONFIG_RTE_LIBRTE_MLX5_DLOPEN_DEPS to a single option CONFIG_RTE_IBVERBS_LINK_DLOPEN. Rename meson option enable_driver_mlx_glue to ibverbs_link. There was no good reason for setting a different link option for mlx4 and mlx5. Having a single common option makes it easier to understand and unify make and meson systems. Signed-off-by: Thomas Monjalon <> Acked-by: Shahaf Shuler <>