Skip to contentSkip to conversation

config: change ABI versioning for global

PATCH In review Marcin Baran 11 participants 131 messages Sep 30, 2019 – Nov 22, 2019 Page 1 of 4

Subsystems (9)
lore
Share & tools
lore
#0 lore raw

PATCH 1/8 config: change ABI versioning for global

The libraries should be maintained using global ABI versioning. The changes includes adding global ABI version support for both makefile and meson build system. Experimental libraries should be marked as 0.

---
 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  3 ++-
 drivers/meson.build    | 20 ++++++++++++++------
 lib/meson.build        | 18 +++++++++++++-----
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 19 +++++++++++--------
 7 files changed, 43 insertions(+), 22 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c130..78ce69977 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 000000000..9a7c1e503
@@ -0,0 +1 @@
+20.0
config/meson.build +2 -1
index 2bafea530..16ad8968d 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and libraries
 # depending on the configuration options
 pver = meson.project_version().split('.')
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+major_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())
drivers/meson.build +14 -6
index 2ed2e9541..5c5fe87c7 100644
@@ -110,9 +110,20 @@ foreach class:dpdk_driver_classes
 					output: out_filename,
 					depends: [pmdinfogen, tmp_lib])
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/@2@_version.map'.format(
+					meson.current_source_dir(),
+					drv_path, lib_name)
+
+			if is_windows
+				version_map = '\\'.join(version_map.split('/'))
+			endif
+
+			is_experimental = run_command(is_experimental_cmd,
+				files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
 				lib_version = major_version
 				so_version = major_version
@@ -128,9 +139,6 @@ foreach class:dpdk_driver_classes
 				install: true)
 
 			# now build the shared driver
-			version_map = '@0@/@1@/@2@_version.map'.format(
-					meson.current_source_dir(),
-					drv_path, lib_name)
 			shared_lib = shared_library(lib_name,
 				sources,
 				objects: objs,
lib/meson.build +13 -5
index e5ff83893..3892c16e8 100644
@@ -97,9 +97,19 @@ foreach l:libraries
 				cflags += '-DALLOW_EXPERIMENTAL_API'
 			endif
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/rte_@2@_version.map'.format(
+					meson.current_source_dir(), dir_name, name)
+
+			if is_windows
+				version_map = '\\'.join(version_map.split('/'))
+			endif
+
+			is_experimental = run_command(is_experimental_cmd,
+					files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
 				lib_version = major_version
 				so_version = major_version
@@ -120,8 +130,6 @@ foreach l:libraries
 			# then use pre-build objects to build shared lib
 			sources = []
 			objs += static_lib.extract_all_objects(recursive: false)
-			version_map = '@0@/@1@/rte_@2@_version.map'.format(
-					meson.current_source_dir(), dir_name, name)
 			implib = dir_name + '.dll.a'
 
 			def_file = custom_target(name + '_def',
meson_options.txt +0 -2
index 448f3e63d..000e38fd9 100644
@@ -28,8 +28,6 @@ option('max_lcores', type: 'integer', value: 128,
 	description: 'maximum number of cores/threads supported by EAL')
 option('max_numa_nodes', type: 'integer', value: 4,
 	description: 'maximum number of NUMA nodes supported by EAL')
-option('per_library_versions', type: 'boolean', value: true,
-	description: 'true: each lib gets its own version number, false: DPDK version used for each lib')
 option('tests', type: 'boolean', value: true,
 	description: 'build unit tests')
 option('use_hpet', type: 'boolean', value: false,
mk/rte.lib.mk +11 -8
index 4df8849a0..f84161c6d 100644
@@ -11,20 +11,23 @@ EXTLIB_BUILD ?= n
 # VPATH contains at least SRCDIR
 VPATH += $(SRCDIR)
 
-ifneq ($(CONFIG_RTE_MAJOR_ABI),)
-ifneq ($(LIBABIVER),)
-LIBABIVER := $(CONFIG_RTE_MAJOR_ABI)
+ifeq ($(OS), Windows_NT)
+search_cmd = findstr
+print_cmd = more
+else
+search_cmd = grep
+print_cmd = cat
 endif
+
+ifneq ($(shell $(search_cmd) "^DPDK_" $(SRCDIR)/$(EXPORT_MAP)),)
+LIBABIVER := $(shell $(print_cmd) $(RTE_SRCDIR)/config/ABI_VERSION)
+else
+LIBABIVER := 0
 endif
 
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
 LIB := $(patsubst %.a,%.so.$(LIBABIVER),$(LIB))
 ifeq ($(EXTLIB_BUILD),n)
-ifeq ($(CONFIG_RTE_MAJOR_ABI),)
-ifeq ($(CONFIG_RTE_NEXT_ABI),y)
-LIB := $(LIB).1
-endif
-endif
 CPU_LDFLAGS += --version-script=$(SRCDIR)/$(EXPORT_MAP)
 endif
 endif
Signature · 1 line
2.22.0.windows.1
#1 lore raw

PATCH 2/8 buildtools: scripts for updating symbols abi version

From: Pawel Modrak <[email protected]>

The scripts updates version number for binding symbols and version map files.

---
 buildtools/update_default_symbol_abi.py |  57 ++++++++++++
 buildtools/update_version_map_abi.py    | 110 ++++++++++++++++++++++++
 2 files changed, 167 insertions(+)
 create mode 100755 buildtools/update_default_symbol_abi.py
 create mode 100755 buildtools/update_version_map_abi.py
buildtools/update_default_symbol_abi.py new file +57 -0
new file mode 100755
index 000000000..6fe60d8cd
@@ -0,0 +1,57 @@
+#!/usr/bin/env python
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+from __future__ import print_function
+import sys
+import argparse
+import re
+
+def setup_options():
+    arg_parser = argparse.ArgumentParser(description='Update default bind symbol abi version.')
+    arg_parser.add_argument('map_file', metavar='map_file', type=str, nargs=1,
+                    help='path to source file (pattern: *.c)')
+    arg_parser.add_argument('dst_abi_version', metavar='dst_abi_version', type=str, nargs=1,
+                    help='target ABI version (pattern: DPDK_*)')
+    arg_parser.add_argument('-v', '--verbose', action='store_true', help='print changes')
+
+    return arg_parser.parse_args()
+
+def replace_abi(f_in, abi_version_number, verbose):
+    source_file_content = []
+
+    for ln_no, ln in enumerate(f_in, 1):
+            if re.search("^BIND_DEFAULT_SYMBOL\(.*", ln):
+                source_file_content += [re.sub(", [0-9]{1,2}\.[0-9]{1,2}\);$", ", " + abi_version_number + ");", ln)]
+                if verbose:
+                    print(f_in.name + ":" + str(ln_no) + ": " + ln[:-1] + " -> " + source_file_content[-1][:-1])
+            elif re.search("^VERSION_SYMBOL\(.*", ln):
+                if verbose:
+                    print(f_in.name + ":" + str(ln_no) + ": " + ln[:-1] + " -> " + "[DELETED]")
+            else:
+                source_file_content += [ln]
+
+    return source_file_content
+
+def main(args):
+    params = setup_options()
+
+    if not params.map_file[0].endswith('.c') or \
+            not params.dst_abi_version[0].startswith('DPDK_'):
+        print('Wrong pattern for input files!\n')
+        arg_parser.print_help()
+        return 1
+
+    abi_version_number = params.dst_abi_version[0][5:]
+    source_file_content = []
+
+    with open(params.map_file[0]) as f_in:
+        source_file_content = replace_abi(f_in, abi_version_number, params.verbose)
+
+    with open(params.map_file[0], 'w') as f_out:
+        f_out.writelines(source_file_content)
+
+    return 0
+
+if __name__ == "__main__":
+    sys.exit(main(sys.argv))
buildtools/update_version_map_abi.py new file +110 -0

110 lines not on this page · raw message

Signature · 1 line
2.22.0.windows.1
#2 lore raw

PATCH 3/8 buildtools: add ABI versioning check script

In reply to Marcin Baran

The script 'check-abi-version.sh' should be used
to check whether built libraries are versioned
with correct ABI number (provided ABI, provided
ABI+1 or EXPERIMENTAL).

---
 buildtools/check-abi-version.sh | 46 +++++++++++++++++++++++++++++++++
 buildtools/update_abi.sh        | 41 +++++++++++++++++++++++++++++
 2 files changed, 87 insertions(+)
 create mode 100755 buildtools/check-abi-version.sh
 create mode 100755 buildtools/update_abi.sh
buildtools/check-abi-version.sh new file +46 -0
new file mode 100755
index 000000000..ead25c080
@@ -0,0 +1,46 @@
+#!/bin/sh
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+# Check whether library symbols have correct
+# version (provided ABI number or provided ABI
+# number + 1 or EXPERIMENTAL).
+# Args:
+#   $1: path of the library .so file
+#   $2: ABI major version number to check
+#       (defaults to ABI_VERSION file value)
+
+if [ -z "$1" ]; then
+    echo "Script checks whether library symbols have"
+    echo "correct version (ABI_VER/ABI_VER+1/EXPERIMENTAL)"
+    echo "Usage:"
+    echo "  $0 SO_FILE_PATH [ABI_VER]"
+    exit 1
+fi
+
+LIB="$1"
+DEFAULT_ABI=$(cat "$(dirname \
+            $(readlink -f $0))/../config/ABI_VERSION" | \
+            cut -d'.' -f 1)
+ABIVER="DPDK_${2-$DEFAULT_ABI}"
+NEXT_ABIVER="DPDK_$((${2-$DEFAULT_ABI}+1))"
+
+ret=0
+
+for SYM in `objdump -TC --section=.text ${LIB} | \
+            grep -e "DPDK\|EXPERIMENTAL" | \
+            awk '{print $(NF-1) "-" $NF}'`
+do
+    version=$(echo $SYM | cut -d'-' -f 1)
+    symbol=$(echo $SYM | cut -d'-' -f 2)
+    case $version in (*"$ABIVER"*|*"$NEXT_ABIVER"*|"EXPERIMENTAL")
+        ;;
+    (*)
+        echo "Warning: symbol $symbol ($version) should be annotated " \
+             "as ABI version $ABIVER / $NEXT_ABIVER, or EXPERIMENTAL."
+        ret=1
+    ;;
+    esac
+done
+
+exit $ret
buildtools/update_abi.sh new file +41 -0

41 lines not on this page · raw message

Signature · 1 line
2.22.0.windows.1
#3 lore raw

Re: [dpdk-dev] [PATCH 3/8] buildtools: add ABI versioning check script

Quoted 5 lines · Marcin Baran

The script 'check-abi-version.sh' should be used to check whether built libraries are versioned with correct ABI number (provided ABI, provided ABI+1 or EXPERIMENTAL).

Quoted 9 lines
---
 buildtools/check-abi-version.sh | 46 +++++++++++++++++++++++++++++++++
 buildtools/update_abi.sh        | 41 +++++++++++++++++++++++++++++
 2 files changed, 87 insertions(+)
 create mode 100755 buildtools/check-abi-version.sh
 create mode 100755 buildtools/update_abi.sh

This patch also includes an "update_abi.sh" script, which is not referred to in the log. It should probably have it's own patch and explanation.

[Also, one script name uses "-" between words, the other "_", maybe standardize]

#4 lore raw

PATCH 4/8 build: change ABI version to 20.0

In reply to Marcin Baran

From: Pawel Modrak <[email protected]>

Merge all vesions in linker version script files to DPDK_20.0. Use version 20.0 as default version in source files.

---
 .../rte_pmd_bbdev_fpga_lte_fec_version.map    |   5 +-
 .../null/rte_pmd_bbdev_null_version.map       |   3 +-
 .../rte_pmd_bbdev_turbo_sw_version.map        |   3 +-
 drivers/bus/dpaa/rte_bus_dpaa_version.map     |  98 ++--
 drivers/bus/fslmc/rte_bus_fslmc_version.map   | 153 +++----
 drivers/bus/ifpga/rte_bus_ifpga_version.map   |  14 +-
 drivers/bus/pci/rte_bus_pci_version.map       |   4 +-
 drivers/bus/vdev/rte_bus_vdev_version.map     |  12 +-
 drivers/bus/vmbus/rte_bus_vmbus_version.map   |  12 +-
 drivers/common/cpt/rte_common_cpt_version.map |   3 +-
 .../common/dpaax/rte_common_dpaax_version.map |   6 +-
 .../common/mvep/rte_common_mvep_version.map   |   5 +-
 .../octeontx/rte_common_octeontx_version.map  |   5 +-
 .../rte_common_octeontx2_version.map          |  18 +-
 .../compress/isal/rte_pmd_isal_version.map    |   3 +-
 .../rte_pmd_octeontx_compress_version.map     |   3 +-
 drivers/compress/qat/rte_pmd_qat_version.map  |   3 +-
 .../compress/zlib/rte_pmd_zlib_version.map    |   3 +-
 .../aesni_gcm/rte_pmd_aesni_gcm_version.map   |   3 +-
 .../aesni_mb/rte_pmd_aesni_mb_version.map     |   3 +-
 .../crypto/armv8/rte_pmd_armv8_version.map    |   3 +-
 .../caam_jr/rte_pmd_caam_jr_version.map       |   2 +-
 drivers/crypto/ccp/rte_pmd_ccp_version.map    |   2 +-
 .../dpaa2_sec/rte_pmd_dpaa2_sec_version.map   |  10 +-
 .../dpaa_sec/rte_pmd_dpaa_sec_version.map     |   2 +-
 .../crypto/kasumi/rte_pmd_kasumi_version.map  |   3 +-
 .../crypto/mvsam/rte_pmd_mvsam_version.map    |   3 +-
 .../null/rte_pmd_null_crypto_version.map      |   3 +-
 .../rte_pmd_octeontx_crypto_version.map       |   2 +-
 .../openssl/rte_pmd_openssl_version.map       |   3 +-
 .../rte_pmd_crypto_scheduler_version.map      |  18 +-
 .../crypto/snow3g/rte_pmd_snow3g_version.map  |   3 +-
 .../virtio/rte_pmd_virtio_crypto_version.map  |   3 +-
 drivers/crypto/zuc/rte_pmd_zuc_version.map    |   3 +-
 .../event/dpaa/rte_pmd_dpaa_event_version.map |   2 +-
 .../dpaa2/rte_pmd_dpaa2_event_version.map     |   3 +-
 .../event/dsw/rte_pmd_dsw_event_version.map   |   3 +-
 .../rte_pmd_octeontx_event_version.map        |   3 +-
 .../rte_pmd_octeontx2_event_version.map       |   4 +-
 .../event/opdl/rte_pmd_opdl_event_version.map |   3 +-
 .../rte_pmd_skeleton_event_version.map        |   2 +-
 drivers/event/sw/rte_pmd_sw_event_version.map |   3 +-
 .../bucket/rte_mempool_bucket_version.map     |   2 +-
 .../mempool/dpaa/rte_mempool_dpaa_version.map |   4 +-
 .../dpaa2/rte_mempool_dpaa2_version.map       |  12 +-
 .../octeontx/rte_mempool_octeontx_version.map |   3 +-
 .../rte_mempool_octeontx2_version.map         |   6 +-
 .../mempool/ring/rte_mempool_ring_version.map |   2 +-
 .../stack/rte_mempool_stack_version.map       |   2 +-
 .../af_packet/rte_pmd_af_packet_version.map   |   2 +-
 drivers/net/af_xdp/rte_pmd_af_xdp_version.map |   3 +-
 drivers/net/ark/rte_pmd_ark_version.map       |   4 +-
 .../net/atlantic/rte_pmd_atlantic_version.map |  12 +-
 drivers/net/avp/rte_pmd_avp_version.map       |   3 +-
 drivers/net/axgbe/rte_pmd_axgbe_version.map   |   3 +-
 drivers/net/bnx2x/rte_pmd_bnx2x_version.map   |   2 +-
 drivers/net/bnxt/rte_pmd_bnxt_version.map     |   6 +-
 drivers/net/bonding/rte_pmd_bond_version.map  |  47 +-
 drivers/net/cxgbe/rte_pmd_cxgbe_version.map   |   2 +-
 drivers/net/dpaa/rte_pmd_dpaa_version.map     |  11 +-
 drivers/net/dpaa2/rte_pmd_dpaa2_version.map   |  13 +-
 drivers/net/e1000/rte_pmd_e1000_version.map   |   2 +-
 drivers/net/ena/rte_pmd_ena_version.map       |   2 +-
 drivers/net/enetc/rte_pmd_enetc_version.map   |   2 +-
 drivers/net/enic/rte_pmd_enic_version.map     |   2 +-
 .../net/failsafe/rte_pmd_failsafe_version.map |   2 +-
 drivers/net/fm10k/rte_pmd_fm10k_version.map   |   2 +-
 drivers/net/hinic/rte_pmd_hinic_version.map   |   2 +-
 drivers/net/i40e/rte_pmd_i40e_version.map     |  65 +--
 drivers/net/iavf/rte_pmd_iavf_version.map     |   2 +-
 drivers/net/ice/rte_pmd_ice_version.map       |   2 +-
 drivers/net/ifc/rte_pmd_ifc_version.map       |   2 +-
 drivers/net/ipn3ke/rte_pmd_ipn3ke_version.map |   2 +-
 drivers/net/ixgbe/rte_pmd_ixgbe_version.map   |  63 +--
 drivers/net/kni/rte_pmd_kni_version.map       |   2 +-
 .../net/liquidio/rte_pmd_liquidio_version.map |   2 +-
 drivers/net/memif/rte_pmd_memif_version.map   |   4 +-
 drivers/net/mlx4/rte_pmd_mlx4_version.map     |   2 +-
 drivers/net/mlx5/rte_pmd_mlx5_version.map     |   3 +-
 drivers/net/mvneta/rte_pmd_mvneta_version.map |   3 +-
 drivers/net/mvpp2/rte_pmd_mvpp2_version.map   |   3 +-
 drivers/net/netvsc/rte_pmd_netvsc_version.map |   3 +-
 drivers/net/nfb/rte_pmd_nfb_version.map       |   2 +-
 drivers/net/nfp/rte_pmd_nfp_version.map       |   3 +-
 drivers/net/null/rte_pmd_null_version.map     |   2 +-
 .../net/octeontx/rte_pmd_octeontx_version.map |  10 +-
 .../octeontx2/rte_pmd_octeontx2_version.map   |   2 +-
 drivers/net/pcap/rte_pmd_pcap_version.map     |   2 +-
 drivers/net/qede/rte_pmd_qede_version.map     |   2 +-
 drivers/net/ring/rte_pmd_ring_version.map     |  10 +-
 drivers/net/sfc/rte_pmd_sfc_version.map       |   2 +-
 .../net/softnic/rte_pmd_softnic_version.map   |   3 +-
 .../net/szedata2/rte_pmd_szedata2_version.map |   3 +-
 drivers/net/tap/rte_pmd_tap_version.map       |   2 +-
 .../net/thunderx/rte_pmd_thunderx_version.map |   2 +-
 .../rte_pmd_vdev_netvsc_version.map           |   2 +-
 drivers/net/vhost/rte_pmd_vhost_version.map   |   9 +-
 drivers/net/virtio/rte_pmd_virtio_version.map |   2 +-
 .../net/vmxnet3/rte_pmd_vmxnet3_version.map   |   2 +-
 .../rte_rawdev_dpaa2_cmdif_version.map        |   2 +-
 .../rte_rawdev_dpaa2_qdma_version.map         |   6 +-
 .../raw/ifpga/rte_rawdev_ifpga_version.map    |   2 +-
 drivers/raw/ioat/rte_rawdev_ioat_version.map  |   2 +-
 drivers/raw/ntb/rte_rawdev_ntb_version.map    |   4 +-
 .../rte_rawdev_octeontx2_dma_version.map      |   2 +-
 .../skeleton/rte_rawdev_skeleton_version.map  |   2 +-
 lib/librte_acl/rte_acl_version.map            |   4 +-
 lib/librte_bbdev/rte_bbdev_version.map        |   1 -
 .../rte_bitratestats_version.map              |   4 +-
 lib/librte_bpf/rte_bpf_version.map            |   1 -
 lib/librte_cfgfile/rte_cfgfile_version.map    |  34 +-
 lib/librte_cmdline/rte_cmdline_version.map    |  10 +-
 .../rte_compressdev_version.map               |  13 +-
 .../rte_cryptodev_version.map                 | 107 ++---
 lib/librte_distributor/rte_distributor.c      |  18 +-
 lib/librte_distributor/rte_distributor_v20.c  |   9 -
 .../rte_distributor_version.map               |  16 +-
 lib/librte_eal/rte_eal_version.map            | 428 +++++++-----------
 lib/librte_efd/rte_efd_version.map            |   4 +-
 lib/librte_ethdev/rte_ethdev_version.map      | 212 +++------
 lib/librte_eventdev/rte_eventdev_version.map  | 130 ++----
 .../rte_flow_classify_version.map             |   1 -
 lib/librte_gro/rte_gro_version.map            |   4 +-
 lib/librte_gso/rte_gso_version.map            |   4 +-
 lib/librte_hash/rte_hash_version.map          |  45 +-
 lib/librte_ip_frag/rte_ip_frag_version.map    |  11 +-
 lib/librte_ipsec/rte_ipsec_version.map        |   1 -
 lib/librte_jobstats/rte_jobstats_version.map  |  10 +-
 lib/librte_kni/rte_kni_version.map            |   3 +-
 lib/librte_kvargs/rte_kvargs_version.map      |   6 +-
 .../rte_latencystats_version.map              |   4 +-
 lib/librte_lpm/rte_lpm.c                      |  21 +-
 lib/librte_lpm/rte_lpm6.c                     |  12 +-
 lib/librte_lpm/rte_lpm_version.map            |  35 +-
 lib/librte_mbuf/rte_mbuf_version.map          |  40 +-
 lib/librte_member/rte_member_version.map      |   4 +-
 lib/librte_mempool/rte_mempool_version.map    |  45 +-
 lib/librte_meter/rte_meter_version.map        |  12 +-
 lib/librte_metrics/rte_metrics_version.map    |   3 +-
 lib/librte_net/rte_net_version.map            |  26 +-
 lib/librte_pci/rte_pci_version.map            |   4 +-
 lib/librte_pdump/rte_pdump_version.map        |   4 +-
 lib/librte_pipeline/rte_pipeline_version.map  |  39 +-
 lib/librte_port/rte_port_version.map          |  64 +--
 lib/librte_power/rte_power_version.map        |  25 +-
 lib/librte_rawdev/rte_rawdev_version.map      |   6 +-
 lib/librte_rcu/rte_rcu_version.map            |   1 -
 lib/librte_reorder/rte_reorder_version.map    |  10 +-
 lib/librte_ring/rte_ring_version.map          |  12 +-
 lib/librte_sched/rte_sched_version.map        |  15 +-
 lib/librte_security/rte_security_version.map  |   3 +-
 lib/librte_stack/rte_stack_version.map        |   1 -
 lib/librte_table/rte_table_version.map        |   4 +-
 .../rte_telemetry_version.map                 |   1 -
 lib/librte_timer/rte_timer.c                  |  15 +-
 lib/librte_timer/rte_timer_version.map        |  13 +-
 lib/librte_vhost/rte_vhost_version.map        |  79 +---
 157 files changed, 840 insertions(+), 1567 deletions(-)
drivers/baseband/fpga_lte_fec/rte_pmd_bbdev_fpga_lte_fec_version.map +3 -2
index e92327075..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_19.08 {
-    local: *;
+DPDK_20.0 {
+
+	local: *;
 };
drivers/baseband/null/rte_pmd_bbdev_null_version.map +2 -1
index 58b94270d..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/baseband/turbo_sw/rte_pmd_bbdev_turbo_sw_version.map +2 -1
index 58b94270d..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/bus/dpaa/rte_bus_dpaa_version.map +35 -63

156 lines not on this page · raw message

drivers/bus/fslmc/rte_bus_fslmc_version.map +59 -94

203 lines not on this page · raw message

drivers/bus/ifpga/rte_bus_ifpga_version.map +4 -10
index 964c9a9c4..701d794d6 100644
@@ -1,17 +1,11 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	global:
 
-	rte_ifpga_get_integer32_arg;
-	rte_ifpga_get_string_arg;
 	rte_ifpga_driver_register;
 	rte_ifpga_driver_unregister;
-
+	rte_ifpga_find_afu_by_name;
+	rte_ifpga_get_integer32_arg;
+	rte_ifpga_get_string_arg;
 	local: *;
 };
 
-DPDK_19.05 {
-	global:
-
-	rte_ifpga_find_afu_by_name;
-
-} DPDK_18.05;
drivers/bus/pci/rte_bus_pci_version.map +2 -2
index 27e9c4f10..6d4dfc8ff 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_pci_dump;
@@ -13,6 +13,6 @@ DPDK_17.11 {
 	rte_pci_unmap_device;
 	rte_pci_unregister;
 	rte_pci_write_config;
-
 	local: *;
 };
+
drivers/bus/vdev/rte_bus_vdev_version.map +3 -9
index 590cf9b43..019e7cb8d 100644
@@ -1,18 +1,12 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
+	rte_vdev_add_custom_scan;
 	rte_vdev_init;
 	rte_vdev_register;
+	rte_vdev_remove_custom_scan;
 	rte_vdev_uninit;
 	rte_vdev_unregister;
-
 	local: *;
 };
 
-DPDK_18.02 {
-	global:
-
-	rte_vdev_add_custom_scan;
-	rte_vdev_remove_custom_scan;
-
-} DPDK_17.11;
drivers/bus/vmbus/rte_bus_vmbus_version.map +2 -10
index ae231ad32..0064b37e4 100644
@@ -1,6 +1,4 @@
-/* SPDX-License-Identifier: BSD-3-Clause */
-
-DPDK_18.08 {
+DPDK_20.0 {
 	global:
 
 	rte_vmbus_chan_close;
@@ -20,17 +18,11 @@ DPDK_18.08 {
 	rte_vmbus_probe;
 	rte_vmbus_register;
 	rte_vmbus_scan;
+	rte_vmbus_set_latency;
 	rte_vmbus_sub_channel_index;
 	rte_vmbus_subchan_open;
 	rte_vmbus_unmap_device;
 	rte_vmbus_unregister;
-
 	local: *;
 };
 
-DPDK_18.11 {
-	global:
-
-	rte_vmbus_set_latency;
-
-} DPDK_18.08;
drivers/common/cpt/rte_common_cpt_version.map +2 -1
index dec614f0d..d0d14b450 100644
@@ -1,6 +1,7 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
 	cpt_pmd_ops_helper_get_mlen_direct_mode;
 	cpt_pmd_ops_helper_get_mlen_sg_mode;
 };
+
drivers/common/dpaax/rte_common_dpaax_version.map +3 -3
index 8131c9e30..98d70eacb 100644
@@ -1,11 +1,11 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
-	dpaax_iova_table_update;
 	dpaax_iova_table_depopulate;
 	dpaax_iova_table_dump;
 	dpaax_iova_table_p;
 	dpaax_iova_table_populate;
-
+	dpaax_iova_table_update;
 	local: *;
 };
+
drivers/common/mvep/rte_common_mvep_version.map +3 -2
index c71722d79..79f8c5e2c 100644
@@ -1,6 +1,7 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
-	rte_mvep_init;
 	rte_mvep_deinit;
+	rte_mvep_init;
 };
+
drivers/common/octeontx/rte_common_octeontx_version.map +3 -2
index f04b3b7f8..7d6f3a617 100644
@@ -1,7 +1,8 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	global:
 
+	octeontx_mbox_send;
 	octeontx_mbox_set_ram_mbox_base;
 	octeontx_mbox_set_reg;
-	octeontx_mbox_send;
 };
+
drivers/common/octeontx2/rte_common_octeontx2_version.map +7 -11
index 4400120da..fa1bececa 100644
@@ -1,39 +1,35 @@
-DPDK_19.08 {
+DPDK_20.0 {
 	global:
 
 	otx2_dev_active_vfs;
 	otx2_dev_fini;
 	otx2_dev_priv_init;
-
+	otx2_disable_irqs;
+	otx2_intra_dev_get_cfg;
 	otx2_logtype_base;
 	otx2_logtype_dpi;
 	otx2_logtype_mbox;
+	otx2_logtype_nix;
 	otx2_logtype_npa;
 	otx2_logtype_npc;
-	otx2_logtype_nix;
 	otx2_logtype_sso;
-	otx2_logtype_tm;
 	otx2_logtype_tim;
-
+	otx2_logtype_tm;
 	otx2_mbox_alloc_msg_rsp;
 	otx2_mbox_get_rsp;
 	otx2_mbox_get_rsp_tmo;
 	otx2_mbox_id2name;
 	otx2_mbox_msg_send;
 	otx2_mbox_wait_for_rsp;
-
-	otx2_intra_dev_get_cfg;
 	otx2_npa_lf_active;
 	otx2_npa_lf_obj_get;
 	otx2_npa_lf_obj_ref;
 	otx2_npa_pf_func_get;
 	otx2_npa_set_defaults;
+	otx2_register_irq;
 	otx2_sso_pf_func_get;
 	otx2_sso_pf_func_set;
-
-	otx2_disable_irqs;
 	otx2_unregister_irq;
-	otx2_register_irq;
-
 	local: *;
 };
+
drivers/compress/isal/rte_pmd_isal_version.map +2 -1
index de8e412ff..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/compress/octeontx/rte_pmd_octeontx_compress_version.map +2 -1
index ad6e191e4..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.08 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/compress/qat/rte_pmd_qat_version.map +2 -1
index ad6e191e4..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.08 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/compress/zlib/rte_pmd_zlib_version.map +2 -1
index ad6e191e4..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.08 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/aesni_gcm/rte_pmd_aesni_gcm_version.map +2 -1
index dc4d417b7..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_16.04 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/aesni_mb/rte_pmd_aesni_mb_version.map +2 -1
index ad607bbed..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_2.2 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/armv8/rte_pmd_armv8_version.map +2 -1
index 1f84b68a8..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.02 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/caam_jr/rte_pmd_caam_jr_version.map +1 -1
index 521e51f41..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.11 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/crypto/ccp/rte_pmd_ccp_version.map +1 -1
index 9b9ab1a4c..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/crypto/dpaa2_sec/rte_pmd_dpaa2_sec_version.map +3 -7
index 0bfb986d0..a176d44fd 100644
@@ -1,12 +1,8 @@
-DPDK_17.05 {
-
-	local: *;
-};
-
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
 	dpaa2_sec_eventq_attach;
 	dpaa2_sec_eventq_detach;
+	local: *;
+};
 
-} DPDK_17.05;
drivers/crypto/dpaa_sec/rte_pmd_dpaa_sec_version.map +1 -1
index a70bd197b..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/crypto/kasumi/rte_pmd_kasumi_version.map +2 -1
index 8ffeca934..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_16.07 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/mvsam/rte_pmd_mvsam_version.map +2 -1
index a75303172..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/null/rte_pmd_null_crypto_version.map +2 -1
index dc4d417b7..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_16.04 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/octeontx/rte_pmd_octeontx_crypto_version.map +1 -1
index 521e51f41..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.11 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/crypto/openssl/rte_pmd_openssl_version.map +2 -1
index cc5829e30..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_16.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/scheduler/rte_pmd_crypto_scheduler_version.map +6 -12
index 5c43127cf..8f4f9140e 100644
@@ -1,21 +1,15 @@
-DPDK_17.02 {
+DPDK_20.0 {
 	global:
 
 	rte_cryptodev_scheduler_load_user_scheduler;
-	rte_cryptodev_scheduler_slave_attach;
-	rte_cryptodev_scheduler_slave_detach;
-	rte_cryptodev_scheduler_ordering_set;
-	rte_cryptodev_scheduler_ordering_get;
-
-};
-
-DPDK_17.05 {
-	global:
-
 	rte_cryptodev_scheduler_mode_get;
 	rte_cryptodev_scheduler_mode_set;
 	rte_cryptodev_scheduler_option_get;
 	rte_cryptodev_scheduler_option_set;
+	rte_cryptodev_scheduler_ordering_get;
+	rte_cryptodev_scheduler_ordering_set;
+	rte_cryptodev_scheduler_slave_attach;
+	rte_cryptodev_scheduler_slave_detach;
 	rte_cryptodev_scheduler_slaves_get;
+};
 
-} DPDK_17.02;
drivers/crypto/snow3g/rte_pmd_snow3g_version.map +2 -1
index dc4d417b7..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_16.04 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/virtio/rte_pmd_virtio_crypto_version.map +2 -1
index de8e412ff..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/crypto/zuc/rte_pmd_zuc_version.map +2 -1
index cc5829e30..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_16.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/event/dpaa/rte_pmd_dpaa_event_version.map +1 -1
index 179140fb8..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/event/dpaa2/rte_pmd_dpaa2_event_version.map +2 -1
index 1c0b7559d..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.08 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/event/dsw/rte_pmd_dsw_event_version.map +2 -1
index 24bd5cdb3..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/event/octeontx/rte_pmd_octeontx_event_version.map +2 -1
index 5352e7e3b..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/event/octeontx2/rte_pmd_octeontx2_event_version.map +2 -2
index 41c65c8c9..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
+
 	local: *;
 };
-
drivers/event/opdl/rte_pmd_opdl_event_version.map +2 -1
index 58b94270d..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/event/skeleton/rte_pmd_skeleton_event_version.map +1 -1
index 8591cc0b1..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/event/sw/rte_pmd_sw_event_version.map +2 -1
index 5352e7e3b..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/mempool/bucket/rte_mempool_bucket_version.map +1 -1
index 9b9ab1a4c..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/mempool/dpaa/rte_mempool_dpaa_version.map +2 -2
index 60bf50b2d..f20d86db8 100644
@@ -1,8 +1,8 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_dpaa_bpid_info;
 	rte_dpaa_memsegs;
-
 	local: *;
 };
+
drivers/mempool/dpaa2/rte_mempool_dpaa2_version.map +3 -9
index b45e7a9ac..b4024be42 100644
@@ -1,16 +1,10 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	global:
 
 	rte_dpaa2_bpid_info;
 	rte_dpaa2_mbuf_alloc_bulk;
-
-	local: *;
-};
-
-DPDK_18.05 {
-	global:
-
 	rte_dpaa2_mbuf_from_buf_addr;
 	rte_dpaa2_mbuf_pool_bpid;
+	local: *;
+};
 
-} DPDK_17.05;
drivers/mempool/octeontx/rte_mempool_octeontx_version.map +2 -1
index a75303172..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/mempool/octeontx2/rte_mempool_octeontx2_version.map +3 -3
index d703368c3..4f8889204 100644
@@ -1,8 +1,8 @@
-DPDK_19.08 {
+DPDK_20.0 {
 	global:
 
-	otx2_npa_lf_init;
 	otx2_npa_lf_fini;
-
+	otx2_npa_lf_init;
 	local: *;
 };
+
drivers/mempool/ring/rte_mempool_ring_version.map +1 -1
index 8591cc0b1..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/mempool/stack/rte_mempool_stack_version.map +1 -1
index 8591cc0b1..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/af_packet/rte_pmd_af_packet_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/af_xdp/rte_pmd_af_xdp_version.map +2 -1
index c6db030fe..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_19.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/ark/rte_pmd_ark_version.map +2 -2
index 1062e0429..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
-	 local: *;
+DPDK_20.0 {
 
+	local: *;
 };
drivers/net/atlantic/rte_pmd_atlantic_version.map +5 -7
index b16faa999..fdf813df0 100644
@@ -1,16 +1,14 @@
-DPDK_18.11 {
+DPDK_20.0 {
 
 	local: *;
 };
-
 EXPERIMENTAL {
 	global:
 
-	rte_pmd_atl_macsec_enable;
-	rte_pmd_atl_macsec_disable;
-	rte_pmd_atl_macsec_config_txsc;
 	rte_pmd_atl_macsec_config_rxsc;
-	rte_pmd_atl_macsec_select_txsa;
+	rte_pmd_atl_macsec_config_txsc;
+	rte_pmd_atl_macsec_disable;
+	rte_pmd_atl_macsec_enable;
 	rte_pmd_atl_macsec_select_rxsa;
+	rte_pmd_atl_macsec_select_txsa;
 };
-
drivers/net/avp/rte_pmd_avp_version.map +2 -1
index 5352e7e3b..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/axgbe/rte_pmd_axgbe_version.map +2 -1
index de8e412ff..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/bnx2x/rte_pmd_bnx2x_version.map +1 -1
index bd8138a03..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.1 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/bnxt/rte_pmd_bnxt_version.map +3 -3
index 4750d40ad..a83fd4036 100644
@@ -1,4 +1,4 @@
-DPDK_17.08 {
+DPDK_20.0 {
 	global:
 
 	rte_pmd_bnxt_get_vf_rx_status;
@@ -10,13 +10,13 @@ DPDK_17.08 {
 	rte_pmd_bnxt_set_tx_loopback;
 	rte_pmd_bnxt_set_vf_mac_addr;
 	rte_pmd_bnxt_set_vf_mac_anti_spoof;
+	rte_pmd_bnxt_set_vf_persist_stats;
 	rte_pmd_bnxt_set_vf_rate_limit;
 	rte_pmd_bnxt_set_vf_rxmode;
 	rte_pmd_bnxt_set_vf_vlan_anti_spoof;
 	rte_pmd_bnxt_set_vf_vlan_filter;
 	rte_pmd_bnxt_set_vf_vlan_insert;
 	rte_pmd_bnxt_set_vf_vlan_stripq;
-	rte_pmd_bnxt_set_vf_persist_stats;
-
 	local: *;
 };
+
drivers/net/bonding/rte_pmd_bond_version.map +13 -34

61 lines not on this page · raw message

drivers/net/cxgbe/rte_pmd_cxgbe_version.map +1 -1
index bd8138a03..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.1 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/dpaa/rte_pmd_dpaa_version.map +4 -7
index 8cb4500b5..94fa246bb 100644
@@ -1,12 +1,9 @@
-DPDK_17.11 {
-
-	local: *;
-};
-
-DPDK_18.08 {
+DPDK_20.0 {
 	global:
 
 	dpaa_eth_eventq_attach;
 	dpaa_eth_eventq_detach;
 	rte_pmd_dpaa_set_tx_loopback;
-} DPDK_17.11;
+	local: *;
+};
+
drivers/net/dpaa2/rte_pmd_dpaa2_version.map +4 -9
index d1b4cdb23..5e0bcef9d 100644
@@ -1,15 +1,10 @@
-DPDK_17.05 {
-
-	local: *;
-};
-
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	dpaa2_eth_eventq_attach;
 	dpaa2_eth_eventq_detach;
-
-} DPDK_17.05;
+	local: *;
+};
 
 EXPERIMENTAL {
 	global:
@@ -17,4 +12,4 @@ EXPERIMENTAL {
 	rte_pmd_dpaa2_mux_flow_create;
 	rte_pmd_dpaa2_set_custom_hash;
 	rte_pmd_dpaa2_set_timestamp;
-} DPDK_17.11;
+};
drivers/net/e1000/rte_pmd_e1000_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/ena/rte_pmd_ena_version.map +1 -1
index 349c6e1c2..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_16.04 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/enetc/rte_pmd_enetc_version.map +1 -1
index 521e51f41..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.11 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/enic/rte_pmd_enic_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/failsafe/rte_pmd_failsafe_version.map +1 -1
index b6d2840be..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.08 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/fm10k/rte_pmd_fm10k_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/hinic/rte_pmd_hinic_version.map +1 -1
index 9a61188cd..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/i40e/rte_pmd_i40e_version.map +19 -46

87 lines not on this page · raw message

drivers/net/iavf/rte_pmd_iavf_version.map +1 -1
index 179140fb8..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/ice/rte_pmd_ice_version.map +1 -1
index 7b23b609d..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.02 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/ifc/rte_pmd_ifc_version.map +1 -1
index 9b9ab1a4c..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/ipn3ke/rte_pmd_ipn3ke_version.map +1 -1
index fc8c95e91..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/ixgbe/rte_pmd_ixgbe_version.map +22 -41

79 lines not on this page · raw message

drivers/net/kni/rte_pmd_kni_version.map +1 -1
index 8591cc0b1..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/liquidio/rte_pmd_liquidio_version.map +1 -1
index 8591cc0b1..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/memif/rte_pmd_memif_version.map +2 -2
index 8861484fb..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
 
-        local: *;
+	local: *;
 };
drivers/net/mlx4/rte_pmd_mlx4_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/mlx5/rte_pmd_mlx5_version.map +2 -1
index ad607bbed..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_2.2 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/mvneta/rte_pmd_mvneta_version.map +2 -1
index 24bd5cdb3..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_18.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/mvpp2/rte_pmd_mvpp2_version.map +2 -1
index a75303172..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/netvsc/rte_pmd_netvsc_version.map +1 -2
index d534019a6..0322b777c 100644
@@ -1,5 +1,4 @@
-/* SPDX-License-Identifier: BSD-3-Clause */
+DPDK_20.0 {
 
-DPDK_18.08 {
 	local: *;
 };
drivers/net/nfb/rte_pmd_nfb_version.map +1 -1
index fc8c95e91..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/nfp/rte_pmd_nfp_version.map +2 -1
index ad607bbed..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_2.2 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/null/rte_pmd_null_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/octeontx/rte_pmd_octeontx_version.map +3 -7
index a3161b14d..13ac26b39 100644
@@ -1,11 +1,7 @@
-DPDK_17.11 {
-
-	local: *;
-};
-
-DPDK_18.02 {
+DPDK_20.0 {
 	global:
 
 	rte_octeontx_pchan_map;
+	local: *;
+};
 
-} DPDK_17.11;
drivers/net/octeontx2/rte_pmd_octeontx2_version.map +1 -1
index 9a61188cd..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/pcap/rte_pmd_pcap_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/qede/rte_pmd_qede_version.map +1 -1
index 349c6e1c2..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_16.04 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/ring/rte_pmd_ring_version.map +2 -8
index 1f785d940..4190d385a 100644
@@ -1,14 +1,8 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_eth_from_ring;
 	rte_eth_from_rings;
-
 	local: *;
 };
 
-DPDK_2.2 {
-	global:
-
-	rte_eth_from_ring;
-
-} DPDK_2.0;
drivers/net/sfc/rte_pmd_sfc_version.map +1 -1
index 31eca32eb..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.02 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/softnic/rte_pmd_softnic_version.map +1 -2
index bc44b06f9..eb4f0b07a 100644
@@ -1,8 +1,7 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_pmd_softnic_run;
-
 	local: *;
 };
 
drivers/net/szedata2/rte_pmd_szedata2_version.map +2 -1
index ad607bbed..0322b777c 100644
@@ -1,3 +1,4 @@
-DPDK_2.2 {
+DPDK_20.0 {
+
 	local: *;
 };
drivers/net/tap/rte_pmd_tap_version.map +1 -1
index 31eca32eb..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_17.02 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/thunderx/rte_pmd_thunderx_version.map +1 -1
index 1901bcb3b..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_16.07 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/vdev_netvsc/rte_pmd_vdev_netvsc_version.map +1 -1
index 179140fb8..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/vhost/rte_pmd_vhost_version.map +2 -7
index 695db8574..9f7e613f2 100644
@@ -1,13 +1,8 @@
-DPDK_16.04 {
+DPDK_20.0 {
 	global:
 
 	rte_eth_vhost_get_queue_event;
-
+	rte_eth_vhost_get_vid_from_port_id;
 	local: *;
 };
 
-DPDK_16.11 {
-	global:
-
-	rte_eth_vhost_get_vid_from_port_id;
-};
drivers/net/virtio/rte_pmd_virtio_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/net/vmxnet3/rte_pmd_vmxnet3_version.map +1 -1
index ef3539840..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/raw/dpaa2_cmdif/rte_rawdev_dpaa2_cmdif_version.map +1 -1
index 9b9ab1a4c..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/raw/dpaa2_qdma/rte_rawdev_dpaa2_qdma_version.map +3 -3
index d16a136fc..a2420771f 100644
@@ -1,4 +1,4 @@
-DPDK_19.05 {
+DPDK_20.0 {
 	global:
 
 	rte_qdma_attr_get;
@@ -9,12 +9,12 @@ DPDK_19.05 {
 	rte_qdma_start;
 	rte_qdma_stop;
 	rte_qdma_vq_create;
-	rte_qdma_vq_destroy;
 	rte_qdma_vq_dequeue;
 	rte_qdma_vq_dequeue_multi;
+	rte_qdma_vq_destroy;
 	rte_qdma_vq_enqueue;
 	rte_qdma_vq_enqueue_multi;
 	rte_qdma_vq_stats;
-
 	local: *;
 };
+
drivers/raw/ifpga/rte_rawdev_ifpga_version.map +1 -1
index 9b9ab1a4c..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.05 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/raw/ioat/rte_rawdev_ioat_version.map +1 -1
index 9a61188cd..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/raw/ntb/rte_rawdev_ntb_version.map +2 -2
index 8861484fb..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
 
-        local: *;
+	local: *;
 };
drivers/raw/octeontx2_dma/rte_rawdev_octeontx2_dma_version.map +1 -1
index 9a61188cd..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_19.08 {
+DPDK_20.0 {
 
 	local: *;
 };
drivers/raw/skeleton/rte_rawdev_skeleton_version.map +1 -1
index 179140fb8..0322b777c 100644
@@ -1,4 +1,4 @@
-DPDK_18.02 {
+DPDK_20.0 {
 
 	local: *;
 };
lib/librte_acl/rte_acl_version.map +2 -2
index b09370a10..6a5d7034a 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_acl_add_rules;
@@ -14,6 +14,6 @@ DPDK_2.0 {
 	rte_acl_reset;
 	rte_acl_reset_rules;
 	rte_acl_set_ctx_classify;
-
 	local: *;
 };
+
lib/librte_bbdev/rte_bbdev_version.map +0 -1
index 3624eb1cb..7ca27ca67 100644
@@ -36,6 +36,5 @@ EXPERIMENTAL {
 	rte_bbdev_stats_get;
 	rte_bbdev_stats_reset;
 	rte_bbdev_stop;
-
 	local: *;
 };
lib/librte_bitratestats/rte_bitratestats_version.map +2 -2
index fe7454452..0261427b9 100644
@@ -1,9 +1,9 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	global:
 
 	rte_stats_bitrate_calc;
 	rte_stats_bitrate_create;
 	rte_stats_bitrate_reg;
-
 	local: *;
 };
+
lib/librte_bpf/rte_bpf_version.map +0 -1
index a203e088e..b183ba566 100644
@@ -11,6 +11,5 @@ EXPERIMENTAL {
 	rte_bpf_exec_burst;
 	rte_bpf_get_jit;
 	rte_bpf_load;
-
 	local: *;
 };
lib/librte_cfgfile/rte_cfgfile_version.map +8 -26
index a0a11cea8..255523103 100644
@@ -1,40 +1,22 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_cfgfile_add_entry;
+	rte_cfgfile_add_section;
 	rte_cfgfile_close;
+	rte_cfgfile_create;
 	rte_cfgfile_get_entry;
 	rte_cfgfile_has_entry;
 	rte_cfgfile_has_section;
 	rte_cfgfile_load;
+	rte_cfgfile_load_with_params;
 	rte_cfgfile_num_sections;
+	rte_cfgfile_save;
 	rte_cfgfile_section_entries;
+	rte_cfgfile_section_entries_by_index;
 	rte_cfgfile_section_num_entries;
 	rte_cfgfile_sections;
-
+	rte_cfgfile_set_entry;
 	local: *;
 };
 
-DPDK_16.04 {
-	global:
-
-	rte_cfgfile_section_entries_by_index;
-
-} DPDK_2.0;
-
-DPDK_17.05 {
-	global:
-
-	rte_cfgfile_load_with_params;
-
-} DPDK_16.04;
-
-DPDK_17.11 {
-	global:
-
-	rte_cfgfile_add_entry;
-	rte_cfgfile_add_section;
-	rte_cfgfile_create;
-	rte_cfgfile_save;
-	rte_cfgfile_set_entry;
-
-} DPDK_17.05;
lib/librte_cmdline/rte_cmdline_version.map +2 -8
index 04bcb387f..29788e1ef 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	cirbuf_add_buf_head;
@@ -40,6 +40,7 @@ DPDK_2.0 {
 	cmdline_parse_num;
 	cmdline_parse_portlist;
 	cmdline_parse_string;
+	cmdline_poll;
 	cmdline_printf;
 	cmdline_quit;
 	cmdline_set_prompt;
@@ -65,13 +66,6 @@ DPDK_2.0 {
 	rdline_stop;
 	vt100_init;
 	vt100_parser;
-
 	local: *;
 };
 
-DPDK_2.1 {
-	global:
-
-	cmdline_poll;
-
-} DPDK_2.0;
lib/librte_compressdev/rte_compressdev_version.map +6 -7
index e2a108b65..6e3acd83e 100644
@@ -1,6 +1,12 @@
 EXPERIMENTAL {
 	global:
 
+	rte_comp_get_feature_name;
+	rte_comp_op_alloc;
+	rte_comp_op_bulk_alloc;
+	rte_comp_op_bulk_free;
+	rte_comp_op_free;
+	rte_comp_op_pool_create;
 	rte_compressdev_capability_get;
 	rte_compressdev_close;
 	rte_compressdev_configure;
@@ -29,12 +35,5 @@ EXPERIMENTAL {
 	rte_compressdev_stop;
 	rte_compressdev_stream_create;
 	rte_compressdev_stream_free;
-	rte_comp_get_feature_name;
-	rte_comp_op_alloc;
-	rte_comp_op_bulk_alloc;
-	rte_comp_op_bulk_free;
-	rte_comp_op_free;
-	rte_comp_op_pool_create;
-
 	local: *;
 };
lib/librte_cryptodev/rte_cryptodev_version.map +38 -69

140 lines not on this page · raw message

lib/librte_distributor/rte_distributor.c +9 -9
index 21eb1fb0a..edc942317 100644
@@ -78,7 +78,7 @@ rte_distributor_request_pkt_v1705(struct rte_distributor *d,
 	 */
 	*retptr64 |= RTE_DISTRIB_GET_BUF;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_request_pkt, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_request_pkt, _v1705, 20.0);
 MAP_STATIC_SYMBOL(void rte_distributor_request_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **oldpkt,
 		unsigned int count),
@@ -119,7 +119,7 @@ rte_distributor_poll_pkt_v1705(struct rte_distributor *d,
 
 	return count;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_poll_pkt, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_poll_pkt, _v1705, 20.0);
 MAP_STATIC_SYMBOL(int rte_distributor_poll_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **pkts),
 		rte_distributor_poll_pkt_v1705);
@@ -153,7 +153,7 @@ rte_distributor_get_pkt_v1705(struct rte_distributor *d,
 	}
 	return count;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_get_pkt, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_get_pkt, _v1705, 20.0);
 MAP_STATIC_SYMBOL(int rte_distributor_get_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **pkts,
 		struct rte_mbuf **oldpkt, unsigned int return_count),
@@ -187,7 +187,7 @@ rte_distributor_return_pkt_v1705(struct rte_distributor *d,
 
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_return_pkt, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_return_pkt, _v1705, 20.0);
 MAP_STATIC_SYMBOL(int rte_distributor_return_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **oldpkt, int num),
 		rte_distributor_return_pkt_v1705);
@@ -470,7 +470,7 @@ rte_distributor_process_v1705(struct rte_distributor *d,
 
 	return num_mbufs;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_process, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_process, _v1705, 20.0);
 MAP_STATIC_SYMBOL(int rte_distributor_process(struct rte_distributor *d,
 		struct rte_mbuf **mbufs, unsigned int num_mbufs),
 		rte_distributor_process_v1705);
@@ -502,7 +502,7 @@ rte_distributor_returned_pkts_v1705(struct rte_distributor *d,
 
 	return retval;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_returned_pkts, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_returned_pkts, _v1705, 20.0);
 MAP_STATIC_SYMBOL(int rte_distributor_returned_pkts(struct rte_distributor *d,
 		struct rte_mbuf **mbufs, unsigned int max_mbufs),
 		rte_distributor_returned_pkts_v1705);
@@ -556,7 +556,7 @@ rte_distributor_flush_v1705(struct rte_distributor *d)
 
 	return flushed;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_flush, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_flush, _v1705, 20.0);
 MAP_STATIC_SYMBOL(int rte_distributor_flush(struct rte_distributor *d),
 		rte_distributor_flush_v1705);
 
@@ -576,7 +576,7 @@ rte_distributor_clear_returns_v1705(struct rte_distributor *d)
 	for (wkr = 0; wkr < d->num_workers; wkr++)
 		d->bufs[wkr].retptr64[0] = 0;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_clear_returns, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_clear_returns, _v1705, 20.0);
 MAP_STATIC_SYMBOL(void rte_distributor_clear_returns(struct rte_distributor *d),
 		rte_distributor_clear_returns_v1705);
 
@@ -656,7 +656,7 @@ rte_distributor_create_v1705(const char *name,
 
 	return d;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_create, _v1705, 17.05);
+BIND_DEFAULT_SYMBOL(rte_distributor_create, _v1705, 20.0);
 MAP_STATIC_SYMBOL(struct rte_distributor *rte_distributor_create(
 		const char *name, unsigned int socket_id,
 		unsigned int num_workers, unsigned int alg_type),
lib/librte_distributor/rte_distributor_v20.c +0 -9
index cdc0969a8..14ee0360e 100644
@@ -38,7 +38,6 @@ rte_distributor_request_pkt_v20(struct rte_distributor_v20 *d,
 		rte_pause();
 	buf->bufptr64 = req;
 }
-VERSION_SYMBOL(rte_distributor_request_pkt, _v20, 2.0);
 
 struct rte_mbuf *
 rte_distributor_poll_pkt_v20(struct rte_distributor_v20 *d,
@@ -52,7 +51,6 @@ rte_distributor_poll_pkt_v20(struct rte_distributor_v20 *d,
 	int64_t ret = buf->bufptr64 >> RTE_DISTRIB_FLAG_BITS;
 	return (struct rte_mbuf *)((uintptr_t)ret);
 }
-VERSION_SYMBOL(rte_distributor_poll_pkt, _v20, 2.0);
 
 struct rte_mbuf *
 rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d,
@@ -64,7 +62,6 @@ rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d,
 		rte_pause();
 	return ret;
 }
-VERSION_SYMBOL(rte_distributor_get_pkt, _v20, 2.0);
 
 int
 rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d,
@@ -76,7 +73,6 @@ rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d,
 	buf->bufptr64 = req;
 	return 0;
 }
-VERSION_SYMBOL(rte_distributor_return_pkt, _v20, 2.0);
 
 /**** APIs called on distributor core ***/
 
@@ -293,7 +289,6 @@ rte_distributor_process_v20(struct rte_distributor_v20 *d,
 	d->returns.count = ret_count;
 	return num_mbufs;
 }
-VERSION_SYMBOL(rte_distributor_process, _v20, 2.0);
 
 /* return to the caller, packets returned from workers */
 int
@@ -314,7 +309,6 @@ rte_distributor_returned_pkts_v20(struct rte_distributor_v20 *d,
 
 	return retval;
 }
-VERSION_SYMBOL(rte_distributor_returned_pkts, _v20, 2.0);
 
 /* return the number of packets in-flight in a distributor, i.e. packets
  * being worked on or queued up in a backlog.
@@ -344,7 +338,6 @@ rte_distributor_flush_v20(struct rte_distributor_v20 *d)
 
 	return flushed;
 }
-VERSION_SYMBOL(rte_distributor_flush, _v20, 2.0);
 
 /* clears the internal returns array in the distributor */
 void
@@ -355,7 +348,6 @@ rte_distributor_clear_returns_v20(struct rte_distributor_v20 *d)
 	memset(d->returns.mbufs, 0, sizeof(d->returns.mbufs));
 #endif
 }
-VERSION_SYMBOL(rte_distributor_clear_returns, _v20, 2.0);
 
 /* creates a distributor instance */
 struct rte_distributor_v20 *
@@ -399,4 +391,3 @@ rte_distributor_create_v20(const char *name,
 
 	return d;
 }
-VERSION_SYMBOL(rte_distributor_create, _v20, 2.0);
lib/librte_distributor/rte_distributor_version.map +1 -15
index 3a285b394..1656d129a 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_distributor_clear_returns;
@@ -10,20 +10,6 @@ DPDK_2.0 {
 	rte_distributor_request_pkt;
 	rte_distributor_return_pkt;
 	rte_distributor_returned_pkts;
-
 	local: *;
 };
 
-DPDK_17.05 {
-	global:
-
-	rte_distributor_clear_returns;
-	rte_distributor_create;
-	rte_distributor_flush;
-	rte_distributor_get_pkt;
-	rte_distributor_poll_pkt;
-	rte_distributor_process;
-	rte_distributor_request_pkt;
-	rte_distributor_return_pkt;
-	rte_distributor_returned_pkts;
-} DPDK_2.0;
lib/librte_eal/rte_eal_version.map +162 -266

566 lines not on this page · raw message

lib/librte_efd/rte_efd_version.map +2 -2
index ae60a6417..d061f8805 100644
@@ -1,4 +1,4 @@
-DPDK_17.02 {
+DPDK_20.0 {
 	global:
 
 	rte_efd_create;
@@ -8,6 +8,6 @@ DPDK_17.02 {
 	rte_efd_lookup;
 	rte_efd_lookup_bulk;
 	rte_efd_update;
-
 	local: *;
 };
+
lib/librte_ethdev/rte_ethdev_version.map +66 -146

303 lines not on this page · raw message

lib/librte_eventdev/rte_eventdev_version.map +47 -83

163 lines not on this page · raw message

lib/librte_flow_classify/rte_flow_classify_version.map +0 -1
index 49bc25c6a..9bbdc8b6e 100644
@@ -8,6 +8,5 @@ EXPERIMENTAL {
 	rte_flow_classify_table_entry_add;
 	rte_flow_classify_table_entry_delete;
 	rte_flow_classify_validate;
-
 	local: *;
 };
lib/librte_gro/rte_gro_version.map +2 -2
index 1606b6dc7..a10aa0768 100644
@@ -1,4 +1,4 @@
-DPDK_17.08 {
+DPDK_20.0 {
 	global:
 
 	rte_gro_ctx_create;
@@ -7,6 +7,6 @@ DPDK_17.08 {
 	rte_gro_reassemble;
 	rte_gro_reassemble_burst;
 	rte_gro_timeout_flush;
-
 	local: *;
 };
+
lib/librte_gso/rte_gso_version.map +2 -2
index e1fd453ed..56f2223f0 100644
@@ -1,7 +1,7 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_gso_segment;
-
 	local: *;
 };
+
lib/librte_hash/rte_hash_version.map +9 -36

71 lines not on this page · raw message

lib/librte_ip_frag/rte_ip_frag_version.map +2 -9
index a193007c6..fe3ac7b8a 100644
@@ -1,24 +1,17 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_ip_frag_free_death_row;
 	rte_ip_frag_table_create;
+	rte_ip_frag_table_destroy;
 	rte_ip_frag_table_statistics_dump;
 	rte_ipv4_frag_reassemble_packet;
 	rte_ipv4_fragment_packet;
 	rte_ipv6_frag_reassemble_packet;
 	rte_ipv6_fragment_packet;
-
 	local: *;
 };
 
-DPDK_17.08 {
-	global:
-
-	rte_ip_frag_table_destroy;
-
-} DPDK_2.0;
-
 EXPERIMENTAL {
 	global:
 
lib/librte_ipsec/rte_ipsec_version.map +0 -1
index ee9f1961b..caf763ab9 100644
@@ -10,6 +10,5 @@ EXPERIMENTAL {
 	rte_ipsec_sa_type;
 	rte_ipsec_ses_from_crypto;
 	rte_ipsec_session_prepare;
-
 	local: *;
 };
lib/librte_jobstats/rte_jobstats_version.map +2 -8
index f89441438..1ee93ffef 100644
@@ -1,6 +1,7 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_jobstats_abort;
 	rte_jobstats_context_finish;
 	rte_jobstats_context_init;
 	rte_jobstats_context_reset;
@@ -14,13 +15,6 @@ DPDK_2.0 {
 	rte_jobstats_set_target;
 	rte_jobstats_set_update_period_function;
 	rte_jobstats_start;
-
 	local: *;
 };
[… more lines in the raw message]

Lines of this file are not shown. View the raw message.

lib/librte_kni/rte_kni_version.map +1 -2
index c877dc6aa..1de824375 100644

Lines of this file are not shown. View the raw message.

lib/librte_kvargs/rte_kvargs_version.map +2 -4
index 8f4b4e3f8..ea1db117e 100644

Lines of this file are not shown. View the raw message.

lib/librte_latencystats/rte_latencystats_version.map +2 -2
index ac8403e82..a2d6d6722 100644

Lines of this file are not shown. View the raw message.

lib/librte_lpm/rte_lpm.c +7 -14
index 3a929a1b1..ce4681b79 100644

Lines of this file are not shown. View the raw message.

lib/librte_lpm/rte_lpm6.c +4 -8
index 9b8aeb972..44828f72c 100644

Lines of this file are not shown. View the raw message.

lib/librte_lpm/rte_lpm_version.map +6 -29
index 90beac853..e57e6e7c3 100644

Lines of this file are not shown. View the raw message.

lib/librte_mbuf/rte_mbuf_version.map +11 -29
index 2662a37bf..998d3a141 100644

Lines of this file are not shown. View the raw message.

lib/librte_member/rte_member_version.map +2 -2
index 019e4cd96..e21bf8510 100644

Lines of this file are not shown. View the raw message.

lib/librte_mempool/rte_mempool_version.map +13 -32

45 lines not on this page · raw message

lib/librte_meter/rte_meter_version.map +3 -9
index 4b460d580..633326a62 100644

Lines of this file are not shown. View the raw message.

lib/librte_metrics/rte_metrics_version.map +1 -2
index 6ac99a44a..7c77cc14d 100644

Lines of this file are not shown. View the raw message.

lib/librte_net/rte_net_version.map +7 -19
index fffc4a372..f5cccd646 100644

Lines of this file are not shown. View the raw message.

lib/librte_pci/rte_pci_version.map +2 -2
index c0280277b..6fc4a9d7e 100644

Lines of this file are not shown. View the raw message.

lib/librte_pdump/rte_pdump_version.map +2 -2
index 3e744f301..aaa8db524 100644

Lines of this file are not shown. View the raw message.

lib/librte_pipeline/rte_pipeline_version.map +10 -29
index 420f065d6..b5fb09853 100644

Lines of this file are not shown. View the raw message.

lib/librte_port/rte_port_version.map +17 -47

64 lines not on this page · raw message

lib/librte_power/rte_power_version.map +6 -19
index 042917360..18e77802b 100644

Lines of this file are not shown. View the raw message.

lib/librte_rawdev/rte_rawdev_version.map +3 -3
index b61dbff11..fe9de5dfe 100644

Lines of this file are not shown. View the raw message.

lib/librte_rcu/rte_rcu_version.map +0 -1
index f8b9ef2ab..cd5aedaa9 100644

Lines of this file are not shown. View the raw message.

lib/librte_reorder/rte_reorder_version.map +5 -5
index 0a8a54de8..d7a2afd18 100644

Lines of this file are not shown. View the raw message.

lib/librte_ring/rte_ring_version.map +2 -10
index 510c1386e..38a095619 100644

Lines of this file are not shown. View the raw message.

lib/librte_sched/rte_sched_version.map +4 -11
index 729588794..7f3fe2d9a 100644

Lines of this file are not shown. View the raw message.

lib/librte_security/rte_security_version.map +1 -2
index 53267bf3c..5e21cbfe2 100644

Lines of this file are not shown. View the raw message.

lib/librte_stack/rte_stack_version.map +0 -1
index 6662679c3..b646cf7d2 100644

Lines of this file are not shown. View the raw message.

lib/librte_table/rte_table_version.map +2 -2
index 6237252be..5f2cdd13d 100644

Lines of this file are not shown. View the raw message.

lib/librte_telemetry/rte_telemetry_version.map +0 -1
index fa62d7718..cbbf41075 100644

Lines of this file are not shown. View the raw message.

lib/librte_timer/rte_timer.c +5 -10
index bdcf05d06..34c864b60 100644

Lines of this file are not shown. View the raw message.

lib/librte_timer/rte_timer_version.map +1 -12
index 72f75c818..1303571fe 100644

Lines of this file are not shown. View the raw message.

lib/librte_vhost/rte_vhost_version.map +24 -55

79 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.22.0.windows.1

Part of the diff is not shown here. View the raw message.

#5 lore raw

PATCH 5/8 lib: remove dead code from timer

In reply to Marcin Baran

After updating ABI policy old and unused
code needs to be removed and all libraries
symbols version should be set to v20.

---
 lib/librte_timer/rte_timer.c | 85 +++---------------------------------
 lib/librte_timer/rte_timer.h | 15 -------
 2 files changed, 5 insertions(+), 95 deletions(-)
lib/librte_timer/rte_timer.c +5 -80
index 34c864b60..de6959b80 100644
@@ -68,9 +68,6 @@ static struct rte_timer_data *rte_timer_data_arr;
 static const uint32_t default_data_id;
 static uint32_t rte_timer_subsystem_initialized;
 
-/* For maintaining older interfaces for a period */
-static struct rte_timer_data default_timer_data;
-
 /* when debug is enabled, store some statistics */
 #ifdef RTE_LIBRTE_TIMER_DEBUG
 #define __TIMER_STAT_ADD(priv_timer, name, n) do {			\
@@ -131,21 +128,6 @@ rte_timer_data_dealloc(uint32_t id)
 	return 0;
 }
 
-void
-rte_timer_subsystem_init_v20(void)
-{
-	unsigned lcore_id;
-	struct priv_timer *priv_timer = default_timer_data.priv_timer;
-
-	/* since priv_timer is static, it's zeroed by default, so only init some
-	 * fields.
-	 */
-	for (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id ++) {
-		rte_spinlock_init(&priv_timer[lcore_id].list_lock);
-		priv_timer[lcore_id].prev_lcore = lcore_id;
-	}
-}
-
 /* Init the timer library. Allocate an array of timer data structs in shared
  * memory, and allocate the zeroth entry for use with original timer
  * APIs. Since the intersection of the sets of lcore ids in primary and
@@ -153,7 +135,7 @@ rte_timer_subsystem_init_v20(void)
  * multiple processes.
  */
 int
-rte_timer_subsystem_init_v1905(void)
+rte_timer_subsystem_init(void)
 {
 	const struct rte_memzone *mz;
 	struct rte_timer_data *data;
@@ -208,9 +190,6 @@ rte_timer_subsystem_init_v1905(void)
 
 	return 0;
 }
-MAP_STATIC_SYMBOL(int rte_timer_subsystem_init(void),
-		  rte_timer_subsystem_init_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_subsystem_init, _v1905, 20.0);
 
 void
 rte_timer_subsystem_finalize(void)
@@ -551,41 +530,13 @@ __rte_timer_reset(struct rte_timer *tim, uint64_t expire,
 
 /* Reset and start the timer associated with the timer handle tim */
 int
-rte_timer_reset_v20(struct rte_timer *tim, uint64_t ticks,
-		    enum rte_timer_type type, unsigned int tim_lcore,
-		    rte_timer_cb_t fct, void *arg)
-{
-	uint64_t cur_time = rte_get_timer_cycles();
-	uint64_t period;
-
-	if (unlikely((tim_lcore != (unsigned)LCORE_ID_ANY) &&
-			!(rte_lcore_is_enabled(tim_lcore) ||
-			  rte_lcore_has_role(tim_lcore, ROLE_SERVICE))))
-		return -1;
-
-	if (type == PERIODICAL)
-		period = ticks;
-	else
-		period = 0;
-
-	return __rte_timer_reset(tim,  cur_time + ticks, period, tim_lcore,
-			  fct, arg, 0, &default_timer_data);
-}
-
-int
-rte_timer_reset_v1905(struct rte_timer *tim, uint64_t ticks,
+rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
 		      enum rte_timer_type type, unsigned int tim_lcore,
 		      rte_timer_cb_t fct, void *arg)
 {
 	return rte_timer_alt_reset(default_data_id, tim, ticks, type,
 				   tim_lcore, fct, arg);
 }
-MAP_STATIC_SYMBOL(int rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
-				      enum rte_timer_type type,
-				      unsigned int tim_lcore,
-				      rte_timer_cb_t fct, void *arg),
-		  rte_timer_reset_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_reset, _v1905, 20.0);
 
 int
 rte_timer_alt_reset(uint32_t timer_data_id, struct rte_timer *tim,
@@ -656,19 +607,10 @@ __rte_timer_stop(struct rte_timer *tim, int local_is_locked,
 
 /* Stop the timer associated with the timer handle tim */
 int
-rte_timer_stop_v20(struct rte_timer *tim)
-{
-	return __rte_timer_stop(tim, 0, &default_timer_data);
-}
-
-int
-rte_timer_stop_v1905(struct rte_timer *tim)
+rte_timer_stop(struct rte_timer *tim)
 {
 	return rte_timer_alt_stop(default_data_id, tim);
 }
-MAP_STATIC_SYMBOL(int rte_timer_stop(struct rte_timer *tim),
-		  rte_timer_stop_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_stop, _v1905, 20.0);
 
 int
 rte_timer_alt_stop(uint32_t timer_data_id, struct rte_timer *tim)
@@ -814,14 +756,8 @@ __rte_timer_manage(struct rte_timer_data *timer_data)
 	priv_timer[lcore_id].running_tim = NULL;
 }
 
-void
-rte_timer_manage_v20(void)
-{
-	__rte_timer_manage(&default_timer_data);
-}
-
 int
-rte_timer_manage_v1905(void)
+rte_timer_manage(void)
 {
 	struct rte_timer_data *timer_data;
 
@@ -831,8 +767,6 @@ rte_timer_manage_v1905(void)
 
 	return 0;
 }
-MAP_STATIC_SYMBOL(int rte_timer_manage(void), rte_timer_manage_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_manage, _v1905, 20.0);
 
 int
 rte_timer_alt_manage(uint32_t timer_data_id,
@@ -1070,20 +1004,11 @@ __rte_timer_dump_stats(struct rte_timer_data *timer_data __rte_unused, FILE *f)
 #endif
 }
 
-void
-rte_timer_dump_stats_v20(FILE *f)
-{
-	__rte_timer_dump_stats(&default_timer_data, f);
-}
-
 int
-rte_timer_dump_stats_v1905(FILE *f)
+rte_timer_dump_stats(FILE *f)
 {
 	return rte_timer_alt_dump_stats(default_data_id, f);
 }
-MAP_STATIC_SYMBOL(int rte_timer_dump_stats(FILE *f),
-		  rte_timer_dump_stats_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_dump_stats, _v1905, 20.0);
 
 int
 rte_timer_alt_dump_stats(uint32_t timer_data_id __rte_unused, FILE *f)
lib/librte_timer/rte_timer.h +0 -15
index 05d287d8f..9dc5fc309 100644
@@ -181,8 +181,6 @@ int rte_timer_data_dealloc(uint32_t id);
  *      subsystem
  */
 int rte_timer_subsystem_init(void);
-int rte_timer_subsystem_init_v1905(void);
-void rte_timer_subsystem_init_v20(void);
 
 /**
  * @warning
@@ -250,13 +248,6 @@ void rte_timer_init(struct rte_timer *tim);
 int rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
 		    enum rte_timer_type type, unsigned tim_lcore,
 		    rte_timer_cb_t fct, void *arg);
-int rte_timer_reset_v1905(struct rte_timer *tim, uint64_t ticks,
-			  enum rte_timer_type type, unsigned int tim_lcore,
-			  rte_timer_cb_t fct, void *arg);
-int rte_timer_reset_v20(struct rte_timer *tim, uint64_t ticks,
-			enum rte_timer_type type, unsigned int tim_lcore,
-			rte_timer_cb_t fct, void *arg);
-
 
 /**
  * Loop until rte_timer_reset() succeeds.
@@ -313,8 +304,6 @@ rte_timer_reset_sync(struct rte_timer *tim, uint64_t ticks,
  *   - (-1): The timer is in the RUNNING or CONFIG state.
  */
 int rte_timer_stop(struct rte_timer *tim);
-int rte_timer_stop_v1905(struct rte_timer *tim);
-int rte_timer_stop_v20(struct rte_timer *tim);
 
 /**
  * Loop until rte_timer_stop() succeeds.
@@ -358,8 +347,6 @@ int rte_timer_pending(struct rte_timer *tim);
  *   - -EINVAL: timer subsystem not yet initialized
  */
 int rte_timer_manage(void);
-int rte_timer_manage_v1905(void);
-void rte_timer_manage_v20(void);
 
 /**
  * Dump statistics about timers.
@@ -371,8 +358,6 @@ void rte_timer_manage_v20(void);
  *   - -EINVAL: timer subsystem not yet initialized
  */
 int rte_timer_dump_stats(FILE *f);
-int rte_timer_dump_stats_v1905(FILE *f);
-void rte_timer_dump_stats_v20(FILE *f);
 
 /**
  * @warning
Signature · 1 line
2.22.0.windows.1
#6 lore raw

PATCH 6/8 lib: remove dead code from lpm

In reply to Marcin Baran

After updating ABI policy old and unused
code needs to be removed and all libraries
symbols version should be set to v20.

---
 lib/librte_lpm/rte_lpm.c  | 995 ++------------------------------------
 lib/librte_lpm/rte_lpm.h  |  88 ----
 lib/librte_lpm/rte_lpm6.c | 128 +----
 lib/librte_lpm/rte_lpm6.h |  25 -
 4 files changed, 51 insertions(+), 1185 deletions(-)
lib/librte_lpm/rte_lpm.c +37 -958
index ce4681b79..268756419 100644
@@ -89,33 +89,8 @@ depth_to_range(uint8_t depth)
 /*
  * Find an existing lpm table and return a pointer to it.
  */
-struct rte_lpm_v20 *
-rte_lpm_find_existing_v20(const char *name)
-{
-	struct rte_lpm_v20 *l = NULL;
-	struct rte_tailq_entry *te;
-	struct rte_lpm_list *lpm_list;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	rte_mcfg_tailq_read_lock();
-	TAILQ_FOREACH(te, lpm_list, next) {
-		l = te->data;
-		if (strncmp(name, l->name, RTE_LPM_NAMESIZE) == 0)
-			break;
-	}
-	rte_mcfg_tailq_read_unlock();
-
-	if (te == NULL) {
-		rte_errno = ENOENT;
-		return NULL;
-	}
-
-	return l;
-}
-
 struct rte_lpm *
-rte_lpm_find_existing_v1604(const char *name)
+rte_lpm_find_existing(const char *name)
 {
 	struct rte_lpm *l = NULL;
 	struct rte_tailq_entry *te;
@@ -138,87 +113,12 @@ rte_lpm_find_existing_v1604(const char *name)
 
 	return l;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_find_existing, _v1604, 20.0);
-MAP_STATIC_SYMBOL(struct rte_lpm *rte_lpm_find_existing(const char *name),
-		rte_lpm_find_existing_v1604);
 
 /*
  * Allocates memory for LPM object
  */
-struct rte_lpm_v20 *
-rte_lpm_create_v20(const char *name, int socket_id, int max_rules,
-		__rte_unused int flags)
-{
-	char mem_name[RTE_LPM_NAMESIZE];
-	struct rte_lpm_v20 *lpm = NULL;
-	struct rte_tailq_entry *te;
-	uint32_t mem_size;
-	struct rte_lpm_list *lpm_list;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	RTE_BUILD_BUG_ON(sizeof(struct rte_lpm_tbl_entry_v20) != 2);
-
-	/* Check user arguments. */
-	if ((name == NULL) || (socket_id < -1) || (max_rules == 0)) {
-		rte_errno = EINVAL;
-		return NULL;
-	}
-
-	snprintf(mem_name, sizeof(mem_name), "LPM_%s", name);
-
-	/* Determine the amount of memory to allocate. */
-	mem_size = sizeof(*lpm) + (sizeof(lpm->rules_tbl[0]) * max_rules);
-
-	rte_mcfg_tailq_write_lock();
-
-	/* guarantee there's no existing */
-	TAILQ_FOREACH(te, lpm_list, next) {
-		lpm = te->data;
-		if (strncmp(name, lpm->name, RTE_LPM_NAMESIZE) == 0)
-			break;
-	}
-
-	if (te != NULL) {
-		lpm = NULL;
-		rte_errno = EEXIST;
-		goto exit;
-	}
-
-	/* allocate tailq entry */
-	te = rte_zmalloc("LPM_TAILQ_ENTRY", sizeof(*te), 0);
-	if (te == NULL) {
-		RTE_LOG(ERR, LPM, "Failed to allocate tailq entry\n");
-		rte_errno = ENOMEM;
-		goto exit;
-	}
-
-	/* Allocate memory to store the LPM data structures. */
-	lpm = rte_zmalloc_socket(mem_name, mem_size,
-			RTE_CACHE_LINE_SIZE, socket_id);
-	if (lpm == NULL) {
-		RTE_LOG(ERR, LPM, "LPM memory allocation failed\n");
-		rte_free(te);
-		rte_errno = ENOMEM;
-		goto exit;
-	}
-
-	/* Save user arguments. */
-	lpm->max_rules = max_rules;
-	strlcpy(lpm->name, name, sizeof(lpm->name));
-
-	te->data = lpm;
-
-	TAILQ_INSERT_TAIL(lpm_list, te, next);
-
-exit:
-	rte_mcfg_tailq_write_unlock();
-
-	return lpm;
-}
-
 struct rte_lpm *
-rte_lpm_create_v1604(const char *name, int socket_id,
+rte_lpm_create(const char *name, int socket_id,
 		const struct rte_lpm_config *config)
 {
 	char mem_name[RTE_LPM_NAMESIZE];
@@ -318,44 +218,12 @@ rte_lpm_create_v1604(const char *name, int socket_id,
 
 	return lpm;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_create, _v1604, 20.0);
-MAP_STATIC_SYMBOL(
-	struct rte_lpm *rte_lpm_create(const char *name, int socket_id,
-			const struct rte_lpm_config *config), rte_lpm_create_v1604);
 
 /*
  * Deallocates memory for given LPM table.
  */
 void
-rte_lpm_free_v20(struct rte_lpm_v20 *lpm)
-{
-	struct rte_lpm_list *lpm_list;
-	struct rte_tailq_entry *te;
-
-	/* Check user arguments. */
-	if (lpm == NULL)
-		return;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	rte_mcfg_tailq_write_lock();
-
-	/* find our tailq entry */
-	TAILQ_FOREACH(te, lpm_list, next) {
-		if (te->data == (void *) lpm)
-			break;
-	}
-	if (te != NULL)
-		TAILQ_REMOVE(lpm_list, te, next);
-
-	rte_mcfg_tailq_write_unlock();
-
-	rte_free(lpm);
-	rte_free(te);
-}
-
-void
-rte_lpm_free_v1604(struct rte_lpm *lpm)
+rte_lpm_free(struct rte_lpm *lpm)
 {
 	struct rte_lpm_list *lpm_list;
 	struct rte_tailq_entry *te;
@@ -383,9 +251,6 @@ rte_lpm_free_v1604(struct rte_lpm *lpm)
 	rte_free(lpm);
 	rte_free(te);
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_free, _v1604, 20.0);
-MAP_STATIC_SYMBOL(void rte_lpm_free(struct rte_lpm *lpm),
-		rte_lpm_free_v1604);
 
 /*
  * Adds a rule to the rule table.
@@ -398,79 +263,7 @@ MAP_STATIC_SYMBOL(void rte_lpm_free(struct rte_lpm *lpm),
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static int32_t
-rule_add_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth,
-	uint8_t next_hop)
-{
-	uint32_t rule_gindex, rule_index, last_rule;
-	int i;
-
-	VERIFY_DEPTH(depth);
-
-	/* Scan through rule group to see if rule already exists. */
-	if (lpm->rule_info[depth - 1].used_rules > 0) {
-
-		/* rule_gindex stands for rule group index. */
-		rule_gindex = lpm->rule_info[depth - 1].first_rule;
-		/* Initialise rule_index to point to start of rule group. */
-		rule_index = rule_gindex;
-		/* Last rule = Last used rule in this rule group. */
-		last_rule = rule_gindex + lpm->rule_info[depth - 1].used_rules;
-
-		for (; rule_index < last_rule; rule_index++) {
-
-			/* If rule already exists update its next_hop and return. */
-			if (lpm->rules_tbl[rule_index].ip == ip_masked) {
-				lpm->rules_tbl[rule_index].next_hop = next_hop;
-
-				return rule_index;
-			}
-		}
-
-		if (rule_index == lpm->max_rules)
-			return -ENOSPC;
-	} else {
-		/* Calculate the position in which the rule will be stored. */
-		rule_index = 0;
-
-		for (i = depth - 1; i > 0; i--) {
-			if (lpm->rule_info[i - 1].used_rules > 0) {
-				rule_index = lpm->rule_info[i - 1].first_rule
-						+ lpm->rule_info[i - 1].used_rules;
-				break;
-			}
-		}
-		if (rule_index == lpm->max_rules)
-			return -ENOSPC;
-
-		lpm->rule_info[depth - 1].first_rule = rule_index;
-	}
-
-	/* Make room for the new rule in the array. */
-	for (i = RTE_LPM_MAX_DEPTH; i > depth; i--) {
-		if (lpm->rule_info[i - 1].first_rule
-				+ lpm->rule_info[i - 1].used_rules == lpm->max_rules)
-			return -ENOSPC;
-
-		if (lpm->rule_info[i - 1].used_rules > 0) {
-			lpm->rules_tbl[lpm->rule_info[i - 1].first_rule
-				+ lpm->rule_info[i - 1].used_rules]
-					= lpm->rules_tbl[lpm->rule_info[i - 1].first_rule];
-			lpm->rule_info[i - 1].first_rule++;
-		}
-	}
-
-	/* Add the new rule. */
-	lpm->rules_tbl[rule_index].ip = ip_masked;
-	lpm->rules_tbl[rule_index].next_hop = next_hop;
-
-	/* Increment the used rules counter for this rule group. */
-	lpm->rule_info[depth - 1].used_rules++;
-
-	return rule_index;
-}
-
-static int32_t
-rule_add_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
+rule_add(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 	uint32_t next_hop)
 {
 	uint32_t rule_gindex, rule_index, last_rule;
@@ -546,30 +339,7 @@ rule_add_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static void
-rule_delete_v20(struct rte_lpm_v20 *lpm, int32_t rule_index, uint8_t depth)
-{
-	int i;
-
-	VERIFY_DEPTH(depth);
-
-	lpm->rules_tbl[rule_index] =
-			lpm->rules_tbl[lpm->rule_info[depth - 1].first_rule
-				+ lpm->rule_info[depth - 1].used_rules - 1];
-
-	for (i = depth; i < RTE_LPM_MAX_DEPTH; i++) {
-		if (lpm->rule_info[i].used_rules > 0) {
-			lpm->rules_tbl[lpm->rule_info[i].first_rule - 1] =
-				lpm->rules_tbl[lpm->rule_info[i].first_rule
-					+ lpm->rule_info[i].used_rules - 1];
-			lpm->rule_info[i].first_rule--;
-		}
-	}
-
-	lpm->rule_info[depth - 1].used_rules--;
-}
-
-static void
-rule_delete_v1604(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
+rule_delete(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
 {
 	int i;
 
@@ -596,28 +366,7 @@ rule_delete_v1604(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static int32_t
-rule_find_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth)
-{
-	uint32_t rule_gindex, last_rule, rule_index;
-
-	VERIFY_DEPTH(depth);
-
-	rule_gindex = lpm->rule_info[depth - 1].first_rule;
-	last_rule = rule_gindex + lpm->rule_info[depth - 1].used_rules;
-
-	/* Scan used rules at given depth to find rule. */
-	for (rule_index = rule_gindex; rule_index < last_rule; rule_index++) {
-		/* If rule is found return the rule index. */
-		if (lpm->rules_tbl[rule_index].ip == ip_masked)
-			return rule_index;
-	}
-
-	/* If rule is not found return -EINVAL. */
-	return -EINVAL;
-}
-
-static int32_t
-rule_find_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
+rule_find(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
 {
 	uint32_t rule_gindex, last_rule, rule_index;
 
@@ -641,42 +390,7 @@ rule_find_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
  * Find, clean and allocate a tbl8.
  */
 static int32_t
-tbl8_alloc_v20(struct rte_lpm_tbl_entry_v20 *tbl8)
-{
-	uint32_t group_idx; /* tbl8 group index. */
-	struct rte_lpm_tbl_entry_v20 *tbl8_entry;
-
-	/* Scan through tbl8 to find a free (i.e. INVALID) tbl8 group. */
-	for (group_idx = 0; group_idx < RTE_LPM_TBL8_NUM_GROUPS;
-			group_idx++) {
-		tbl8_entry = &tbl8[group_idx * RTE_LPM_TBL8_GROUP_NUM_ENTRIES];
-		/* If a free tbl8 group is found clean it and set as VALID. */
-		if (!tbl8_entry->valid_group) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = INVALID,
-				.depth = 0,
-				.valid_group = VALID,
-			};
-			new_tbl8_entry.next_hop = 0;
-
-			memset(&tbl8_entry[0], 0,
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES *
-					sizeof(tbl8_entry[0]));
-
-			__atomic_store(tbl8_entry, &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-
-			/* Return group index for allocated tbl8 group. */
-			return group_idx;
-		}
-	}
-
-	/* If there are no tbl8 groups free then return error. */
-	return -ENOSPC;
-}
-
-static int32_t
-tbl8_alloc_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
+tbl8_alloc(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
 {
 	uint32_t group_idx; /* tbl8 group index. */
 	struct rte_lpm_tbl_entry *tbl8_entry;
@@ -710,104 +424,18 @@ tbl8_alloc_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
 }
 
 static void
-tbl8_free_v20(struct rte_lpm_tbl_entry_v20 *tbl8, uint32_t tbl8_group_start)
+tbl8_free(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
 {
 	/* Set tbl8 group invalid*/
-	struct rte_lpm_tbl_entry_v20 zero_tbl8_entry = {
-		.valid = INVALID,
-		.depth = 0,
-		.valid_group = INVALID,
-	};
-	zero_tbl8_entry.next_hop = 0;
+	struct rte_lpm_tbl_entry zero_tbl8_entry = {0};
 
 	__atomic_store(&tbl8[tbl8_group_start], &zero_tbl8_entry,
 			__ATOMIC_RELAXED);
 }
 
-static void
-tbl8_free_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
-{
-	/* Set tbl8 group invalid*/
-	struct rte_lpm_tbl_entry zero_tbl8_entry = {0};
-
-	__atomic_store(&tbl8[tbl8_group_start], &zero_tbl8_entry,
-			__ATOMIC_RELAXED);
-}
-
-static __rte_noinline int32_t
-add_depth_small_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-		uint8_t next_hop)
-{
-	uint32_t tbl24_index, tbl24_range, tbl8_index, tbl8_group_end, i, j;
-
-	/* Calculate the index into Table24. */
-	tbl24_index = ip >> 8;
-	tbl24_range = depth_to_range(depth);
-
-	for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-		/*
-		 * For invalid OR valid and non-extended tbl 24 entries set
-		 * entry.
-		 */
-		if (!lpm->tbl24[i].valid || (lpm->tbl24[i].valid_group == 0 &&
-				lpm->tbl24[i].depth <= depth)) {
-
-			struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-				.valid = VALID,
-				.valid_group = 0,
-				.depth = depth,
-			};
-			new_tbl24_entry.next_hop = next_hop;
-
-			/* Setting tbl24 entry in one go to avoid race
-			 * conditions
-			 */
-			__atomic_store(&lpm->tbl24[i], &new_tbl24_entry,
-					__ATOMIC_RELEASE);
-
-			continue;
-		}
-
-		if (lpm->tbl24[i].valid_group == 1) {
-			/* If tbl24 entry is valid and extended calculate the
-			 *  index into tbl8.
-			 */
-			tbl8_index = lpm->tbl24[i].group_idx *
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-			tbl8_group_end = tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-			for (j = tbl8_index; j < tbl8_group_end; j++) {
-				if (!lpm->tbl8[j].valid ||
-						lpm->tbl8[j].depth <= depth) {
-					struct rte_lpm_tbl_entry_v20
-						new_tbl8_entry = {
-						.valid = VALID,
-						.valid_group = VALID,
-						.depth = depth,
-					};
-					new_tbl8_entry.next_hop = next_hop;
-
-					/*
-					 * Setting tbl8 entry in one go to avoid
-					 * race conditions
-					 */
-					__atomic_store(&lpm->tbl8[j],
-						&new_tbl8_entry,
-						__ATOMIC_RELAXED);
-
-					continue;
-				}
-			}
-		}
-	}
-
-	return 0;
-}
-
-static __rte_noinline int32_t
-add_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
-		uint32_t next_hop)
+static __rte_noinline int32_t
+add_depth_small(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+		uint32_t next_hop)
 {
 #define group_idx next_hop
 	uint32_t tbl24_index, tbl24_range, tbl8_index, tbl8_group_end, i, j;
@@ -878,150 +506,7 @@ add_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 }
 
 static __rte_noinline int32_t
-add_depth_big_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth,
-		uint8_t next_hop)
-{
-	uint32_t tbl24_index;
-	int32_t tbl8_group_index, tbl8_group_start, tbl8_group_end, tbl8_index,
-		tbl8_range, i;
-
-	tbl24_index = (ip_masked >> 8);
-	tbl8_range = depth_to_range(depth);
-
-	if (!lpm->tbl24[tbl24_index].valid) {
-		/* Search for a free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v20(lpm->tbl8);
-
-		/* Check tbl8 allocation was successful. */
-		if (tbl8_group_index < 0) {
-			return tbl8_group_index;
-		}
-
-		/* Find index into tbl8 and range. */
-		tbl8_index = (tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES) +
-				(ip_masked & 0xFF);
-
-		/* Set tbl8 entry. */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop = next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		/*
-		 * Update tbl24 entry to point to new tbl8 entry. Note: The
-		 * ext_flag and tbl8_index need to be updated simultaneously,
-		 * so assign whole structure in one go
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.group_idx = (uint8_t)tbl8_group_index,
-			.valid = VALID,
-			.valid_group = 1,
-			.depth = 0,
-		};
-
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELEASE);
-
-	} /* If valid entry but not extended calculate the index into Table8. */
-	else if (lpm->tbl24[tbl24_index].valid_group == 0) {
-		/* Search for free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v20(lpm->tbl8);
-
-		if (tbl8_group_index < 0) {
-			return tbl8_group_index;
-		}
-
-		tbl8_group_start = tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-		tbl8_group_end = tbl8_group_start +
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-		/* Populate new tbl8 with tbl24 value. */
-		for (i = tbl8_group_start; i < tbl8_group_end; i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = lpm->tbl24[tbl24_index].depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop =
-				lpm->tbl24[tbl24_index].next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-
-		/* Insert new rule into the tbl8 entry. */
-		for (i = tbl8_index; i < tbl8_index + tbl8_range; i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop = next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		/*
-		 * Update tbl24 entry to point to new tbl8 entry. Note: The
-		 * ext_flag and tbl8_index need to be updated simultaneously,
-		 * so assign whole structure in one go.
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-				.group_idx = (uint8_t)tbl8_group_index,
-				.valid = VALID,
-				.valid_group = 1,
-				.depth = 0,
-		};
-
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELEASE);
-
-	} else { /*
-		* If it is valid, extended entry calculate the index into tbl8.
-		*/
-		tbl8_group_index = lpm->tbl24[tbl24_index].group_idx;
-		tbl8_group_start = tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-		tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-
-			if (!lpm->tbl8[i].valid ||
-					lpm->tbl8[i].depth <= depth) {
-				struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-					.valid = VALID,
-					.depth = depth,
-					.valid_group = lpm->tbl8[i].valid_group,
-				};
-				new_tbl8_entry.next_hop = next_hop;
-				/*
-				 * Setting tbl8 entry in one go to avoid race
-				 * condition
-				 */
-				__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-						__ATOMIC_RELAXED);
-
-				continue;
-			}
-		}
-	}
-
-	return 0;
-}
-
-static __rte_noinline int32_t
-add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
+add_depth_big(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 		uint32_t next_hop)
 {
 #define group_idx next_hop
@@ -1034,7 +519,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 
 	if (!lpm->tbl24[tbl24_index].valid) {
 		/* Search for a free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v1604(lpm->tbl8, lpm->number_tbl8s);
+		tbl8_group_index = tbl8_alloc(lpm->tbl8, lpm->number_tbl8s);
 
 		/* Check tbl8 allocation was successful. */
 		if (tbl8_group_index < 0) {
@@ -1080,7 +565,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 	} /* If valid entry but not extended calculate the index into Table8. */
 	else if (lpm->tbl24[tbl24_index].valid_group == 0) {
 		/* Search for free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v1604(lpm->tbl8, lpm->number_tbl8s);
+		tbl8_group_index = tbl8_alloc(lpm->tbl8, lpm->number_tbl8s);
 
 		if (tbl8_group_index < 0) {
 			return tbl8_group_index;
@@ -1174,47 +659,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
  * Add a route
  */
 int
-rte_lpm_add_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-		uint8_t next_hop)
-{
-	int32_t rule_index, status = 0;
-	uint32_t ip_masked;
-
-	/* Check user arguments. */
-	if ((lpm == NULL) || (depth < 1) || (depth > RTE_LPM_MAX_DEPTH))
-		return -EINVAL;
-
-	ip_masked = ip & depth_to_mask(depth);
-
-	/* Add the rule to the rule table. */
-	rule_index = rule_add_v20(lpm, ip_masked, depth, next_hop);
-
-	/* If the is no space available for new rule return error. */
-	if (rule_index < 0) {
-		return rule_index;
-	}
-
-	if (depth <= MAX_DEPTH_TBL24) {
-		status = add_depth_small_v20(lpm, ip_masked, depth, next_hop);
-	} else { /* If depth > RTE_LPM_MAX_DEPTH_TBL24 */
-		status = add_depth_big_v20(lpm, ip_masked, depth, next_hop);
-
-		/*
-		 * If add fails due to exhaustion of tbl8 extensions delete
-		 * rule that was added to rule table.
-		 */
-		if (status < 0) {
-			rule_delete_v20(lpm, rule_index, depth);
-
-			return status;
-		}
-	}
-
-	return 0;
-}
-
-int
-rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+rte_lpm_add(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint32_t next_hop)
 {
 	int32_t rule_index, status = 0;
@@ -1227,7 +672,7 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 	ip_masked = ip & depth_to_mask(depth);
 
 	/* Add the rule to the rule table. */
-	rule_index = rule_add_v1604(lpm, ip_masked, depth, next_hop);
+	rule_index = rule_add(lpm, ip_masked, depth, next_hop);
 
 	/* If the is no space available for new rule return error. */
 	if (rule_index < 0) {
@@ -1235,16 +680,16 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 	}
 
 	if (depth <= MAX_DEPTH_TBL24) {
-		status = add_depth_small_v1604(lpm, ip_masked, depth, next_hop);
+		status = add_depth_small(lpm, ip_masked, depth, next_hop);
 	} else { /* If depth > RTE_LPM_MAX_DEPTH_TBL24 */
-		status = add_depth_big_v1604(lpm, ip_masked, depth, next_hop);
+		status = add_depth_big(lpm, ip_masked, depth, next_hop);
 
 		/*
 		 * If add fails due to exhaustion of tbl8 extensions delete
 		 * rule that was added to rule table.
 		 */
 		if (status < 0) {
-			rule_delete_v1604(lpm, rule_index, depth);
+			rule_delete(lpm, rule_index, depth);
 
 			return status;
 		}
@@ -1252,41 +697,12 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_add, _v1604, 20.0);
-MAP_STATIC_SYMBOL(int rte_lpm_add(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth, uint32_t next_hop), rte_lpm_add_v1604);
 
 /*
  * Look for a rule in the high-level rules table
  */
 int
-rte_lpm_is_rule_present_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-uint8_t *next_hop)
-{
-	uint32_t ip_masked;
-	int32_t rule_index;
-
-	/* Check user arguments. */
-	if ((lpm == NULL) ||
-		(next_hop == NULL) ||
-		(depth < 1) || (depth > RTE_LPM_MAX_DEPTH))
-		return -EINVAL;
-
-	/* Look for the rule using rule_find. */
-	ip_masked = ip & depth_to_mask(depth);
-	rule_index = rule_find_v20(lpm, ip_masked, depth);
-
-	if (rule_index >= 0) {
-		*next_hop = lpm->rules_tbl[rule_index].next_hop;
-		return 1;
-	}
-
-	/* If rule is not found return 0. */
-	return 0;
-}
-
-int
-rte_lpm_is_rule_present_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+rte_lpm_is_rule_present(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 uint32_t *next_hop)
 {
 	uint32_t ip_masked;
@@ -1300,7 +716,7 @@ uint32_t *next_hop)
 
 	/* Look for the rule using rule_find. */
 	ip_masked = ip & depth_to_mask(depth);
-	rule_index = rule_find_v1604(lpm, ip_masked, depth);
+	rule_index = rule_find(lpm, ip_masked, depth);
 
 	if (rule_index >= 0) {
 		*next_hop = lpm->rules_tbl[rule_index].next_hop;
@@ -1310,12 +726,9 @@ uint32_t *next_hop)
 	/* If rule is not found return 0. */
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_is_rule_present, _v1604, 20.0);
-MAP_STATIC_SYMBOL(int rte_lpm_is_rule_present(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth, uint32_t *next_hop), rte_lpm_is_rule_present_v1604);
 
 static int32_t
-find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
+find_previous_rule(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint8_t *sub_rule_depth)
 {
 	int32_t rule_index;
@@ -1325,7 +738,7 @@ find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
 	for (prev_depth = (uint8_t)(depth - 1); prev_depth > 0; prev_depth--) {
 		ip_masked = ip & depth_to_mask(prev_depth);
 
-		rule_index = rule_find_v20(lpm, ip_masked, prev_depth);
+		rule_index = rule_find(lpm, ip_masked, prev_depth);
 
 		if (rule_index >= 0) {
 			*sub_rule_depth = prev_depth;
@@ -1337,133 +750,7 @@ find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
 }
 
 static int32_t
-find_previous_rule_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
-		uint8_t *sub_rule_depth)
-{
-	int32_t rule_index;
-	uint32_t ip_masked;
-	uint8_t prev_depth;
-
-	for (prev_depth = (uint8_t)(depth - 1); prev_depth > 0; prev_depth--) {
-		ip_masked = ip & depth_to_mask(prev_depth);
-
-		rule_index = rule_find_v1604(lpm, ip_masked, prev_depth);
-
-		if (rule_index >= 0) {
-			*sub_rule_depth = prev_depth;
-			return rule_index;
-		}
-	}
-
-	return -1;
-}
-
-static int32_t
-delete_depth_small_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked,
-	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
-{
-	uint32_t tbl24_range, tbl24_index, tbl8_group_index, tbl8_index, i, j;
-
-	/* Calculate the range and index into Table24. */
-	tbl24_range = depth_to_range(depth);
-	tbl24_index = (ip_masked >> 8);
-
-	/*
-	 * Firstly check the sub_rule_index. A -1 indicates no replacement rule
-	 * and a positive number indicates a sub_rule_index.
-	 */
-	if (sub_rule_index < 0) {
-		/*
-		 * If no replacement rule exists then invalidate entries
-		 * associated with this rule.
-		 */
-		for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-
-			if (lpm->tbl24[i].valid_group == 0 &&
-					lpm->tbl24[i].depth <= depth) {
-				struct rte_lpm_tbl_entry_v20
-					zero_tbl24_entry = {
-						.valid = INVALID,
-						.depth = 0,
-						.valid_group = 0,
-					};
-					zero_tbl24_entry.next_hop = 0;
-				__atomic_store(&lpm->tbl24[i],
-					&zero_tbl24_entry, __ATOMIC_RELEASE);
-			} else if (lpm->tbl24[i].valid_group == 1) {
-				/*
-				 * If TBL24 entry is extended, then there has
-				 * to be a rule with depth >= 25 in the
-				 * associated TBL8 group.
-				 */
-
-				tbl8_group_index = lpm->tbl24[i].group_idx;
-				tbl8_index = tbl8_group_index *
-						RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-				for (j = tbl8_index; j < (tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES); j++) {
-
-					if (lpm->tbl8[j].depth <= depth)
-						lpm->tbl8[j].valid = INVALID;
-				}
-			}
-		}
-	} else {
-		/*
-		 * If a replacement rule exists then modify entries
-		 * associated with this rule.
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.next_hop = lpm->rules_tbl[sub_rule_index].next_hop,
-			.valid = VALID,
-			.valid_group = 0,
-			.depth = sub_rule_depth,
-		};
-
-		struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-			.valid = VALID,
-			.valid_group = VALID,
-			.depth = sub_rule_depth,
-		};
-		new_tbl8_entry.next_hop =
-				lpm->rules_tbl[sub_rule_index].next_hop;
-
-		for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-
-			if (lpm->tbl24[i].valid_group == 0 &&
-					lpm->tbl24[i].depth <= depth) {
-				__atomic_store(&lpm->tbl24[i], &new_tbl24_entry,
-						__ATOMIC_RELEASE);
-			} else  if (lpm->tbl24[i].valid_group == 1) {
-				/*
-				 * If TBL24 entry is extended, then there has
-				 * to be a rule with depth >= 25 in the
-				 * associated TBL8 group.
-				 */
-
-				tbl8_group_index = lpm->tbl24[i].group_idx;
-				tbl8_index = tbl8_group_index *
-						RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-				for (j = tbl8_index; j < (tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES); j++) {
-
-					if (lpm->tbl8[j].depth <= depth)
-						__atomic_store(&lpm->tbl8[j],
-							&new_tbl8_entry,
-							__ATOMIC_RELAXED);
-				}
-			}
-		}
-	}
-
-	return 0;
-}
-
-static int32_t
-delete_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
+delete_depth_small(struct rte_lpm *lpm, uint32_t ip_masked,
 	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
 {
 #define group_idx next_hop
@@ -1570,54 +857,7 @@ delete_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
  * thus can be recycled
  */
 static int32_t
-tbl8_recycle_check_v20(struct rte_lpm_tbl_entry_v20 *tbl8,
-		uint32_t tbl8_group_start)
-{
-	uint32_t tbl8_group_end, i;
-	tbl8_group_end = tbl8_group_start + RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-	/*
-	 * Check the first entry of the given tbl8. If it is invalid we know
-	 * this tbl8 does not contain any rule with a depth < RTE_LPM_MAX_DEPTH
-	 *  (As they would affect all entries in a tbl8) and thus this table
-	 *  can not be recycled.
-	 */
-	if (tbl8[tbl8_group_start].valid) {
-		/*
-		 * If first entry is valid check if the depth is less than 24
-		 * and if so check the rest of the entries to verify that they
-		 * are all of this depth.
-		 */
-		if (tbl8[tbl8_group_start].depth <= MAX_DEPTH_TBL24) {
-			for (i = (tbl8_group_start + 1); i < tbl8_group_end;
-					i++) {
-
-				if (tbl8[i].depth !=
-						tbl8[tbl8_group_start].depth) {
-
-					return -EEXIST;
-				}
-			}
-			/* If all entries are the same return the tb8 index */
-			return tbl8_group_start;
-		}
-
-		return -EEXIST;
-	}
-	/*
-	 * If the first entry is invalid check if the rest of the entries in
-	 * the tbl8 are invalid.
-	 */
-	for (i = (tbl8_group_start + 1); i < tbl8_group_end; i++) {
-		if (tbl8[i].valid)
-			return -EEXIST;
-	}
-	/* If no valid entries are found then return -EINVAL. */
-	return -EINVAL;
-}
-
-static int32_t
-tbl8_recycle_check_v1604(struct rte_lpm_tbl_entry *tbl8,
+tbl8_recycle_check(struct rte_lpm_tbl_entry *tbl8,
 		uint32_t tbl8_group_start)
 {
 	uint32_t tbl8_group_end, i;
@@ -1664,93 +904,7 @@ tbl8_recycle_check_v1604(struct rte_lpm_tbl_entry *tbl8,
 }
 
 static int32_t
-delete_depth_big_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked,
-	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
-{
-	uint32_t tbl24_index, tbl8_group_index, tbl8_group_start, tbl8_index,
-			tbl8_range, i;
-	int32_t tbl8_recycle_index;
-
-	/*
-	 * Calculate the index into tbl24 and range. Note: All depths larger
-	 * than MAX_DEPTH_TBL24 are associated with only one tbl24 entry.
-	 */
-	tbl24_index = ip_masked >> 8;
-
-	/* Calculate the index into tbl8 and range. */
-	tbl8_group_index = lpm->tbl24[tbl24_index].group_idx;
-	tbl8_group_start = tbl8_group_index * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-	tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-	tbl8_range = depth_to_range(depth);
-
-	if (sub_rule_index < 0) {
-		/*
-		 * Loop through the range of entries on tbl8 for which the
-		 * rule_to_delete must be removed or modified.
-		 */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			if (lpm->tbl8[i].depth <= depth)
-				lpm->tbl8[i].valid = INVALID;
-		}
-	} else {
-		/* Set new tbl8 entry. */
-		struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-			.valid = VALID,
-			.depth = sub_rule_depth,
-			.valid_group = lpm->tbl8[tbl8_group_start].valid_group,
-		};
-
-		new_tbl8_entry.next_hop =
-				lpm->rules_tbl[sub_rule_index].next_hop;
-		/*
-		 * Loop through the range of entries on tbl8 for which the
-		 * rule_to_delete must be modified.
-		 */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			if (lpm->tbl8[i].depth <= depth)
-				__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-						__ATOMIC_RELAXED);
-		}
-	}
-
-	/*
-	 * Check if there are any valid entries in this tbl8 group. If all
-	 * tbl8 entries are invalid we can free the tbl8 and invalidate the
-	 * associated tbl24 entry.
-	 */
-
-	tbl8_recycle_index = tbl8_recycle_check_v20(lpm->tbl8, tbl8_group_start);
-
-	if (tbl8_recycle_index == -EINVAL) {
-		/* Set tbl24 before freeing tbl8 to avoid race condition.
-		 * Prevent the free of the tbl8 group from hoisting.
-		 */
-		lpm->tbl24[tbl24_index].valid = 0;
-		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v20(lpm->tbl8, tbl8_group_start);
-	} else if (tbl8_recycle_index > -1) {
-		/* Update tbl24 entry. */
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.next_hop = lpm->tbl8[tbl8_recycle_index].next_hop,
-			.valid = VALID,
-			.valid_group = 0,
-			.depth = lpm->tbl8[tbl8_recycle_index].depth,
-		};
-
-		/* Set tbl24 before freeing tbl8 to avoid race condition.
-		 * Prevent the free of the tbl8 group from hoisting.
-		 */
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELAXED);
-		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v20(lpm->tbl8, tbl8_group_start);
-	}
-
-	return 0;
-}
-
-static int32_t
-delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
+delete_depth_big(struct rte_lpm *lpm, uint32_t ip_masked,
 	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
 {
 #define group_idx next_hop
@@ -1805,7 +959,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 	 * associated tbl24 entry.
 	 */
 
-	tbl8_recycle_index = tbl8_recycle_check_v1604(lpm->tbl8, tbl8_group_start);
+	tbl8_recycle_index = tbl8_recycle_check(lpm->tbl8, tbl8_group_start);
 
 	if (tbl8_recycle_index == -EINVAL) {
 		/* Set tbl24 before freeing tbl8 to avoid race condition.
@@ -1813,7 +967,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 		 */
 		lpm->tbl24[tbl24_index].valid = 0;
 		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v1604(lpm->tbl8, tbl8_group_start);
+		tbl8_free(lpm->tbl8, tbl8_group_start);
 	} else if (tbl8_recycle_index > -1) {
 		/* Update tbl24 entry. */
 		struct rte_lpm_tbl_entry new_tbl24_entry = {
@@ -1829,7 +983,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
 				__ATOMIC_RELAXED);
 		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v1604(lpm->tbl8, tbl8_group_start);
+		tbl8_free(lpm->tbl8, tbl8_group_start);
 	}
 #undef group_idx
 	return 0;
@@ -1839,60 +993,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
  * Deletes a rule
  */
 int
-rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
-{
-	int32_t rule_to_delete_index, sub_rule_index;
-	uint32_t ip_masked;
-	uint8_t sub_rule_depth;
-	/*
-	 * Check input arguments. Note: IP must be a positive integer of 32
-	 * bits in length therefore it need not be checked.
-	 */
-	if ((lpm == NULL) || (depth < 1) || (depth > RTE_LPM_MAX_DEPTH)) {
-		return -EINVAL;
-	}
-
-	ip_masked = ip & depth_to_mask(depth);
-
-	/*
-	 * Find the index of the input rule, that needs to be deleted, in the
-	 * rule table.
-	 */
-	rule_to_delete_index = rule_find_v20(lpm, ip_masked, depth);
-
-	/*
-	 * Check if rule_to_delete_index was found. If no rule was found the
-	 * function rule_find returns -EINVAL.
-	 */
-	if (rule_to_delete_index < 0)
-		return -EINVAL;
-
-	/* Delete the rule from the rule table. */
-	rule_delete_v20(lpm, rule_to_delete_index, depth);
-
-	/*
-	 * Find rule to replace the rule_to_delete. If there is no rule to
-	 * replace the rule_to_delete we return -1 and invalidate the table
-	 * entries associated with this rule.
-	 */
-	sub_rule_depth = 0;
-	sub_rule_index = find_previous_rule_v20(lpm, ip, depth, &sub_rule_depth);
-
-	/*
-	 * If the input depth value is less than 25 use function
-	 * delete_depth_small otherwise use delete_depth_big.
-	 */
-	if (depth <= MAX_DEPTH_TBL24) {
-		return delete_depth_small_v20(lpm, ip_masked, depth,
-				sub_rule_index, sub_rule_depth);
-	} else { /* If depth > MAX_DEPTH_TBL24 */
-		return delete_depth_big_v20(lpm, ip_masked, depth, sub_rule_index,
-				sub_rule_depth);
-	}
-}
-
-int
-rte_lpm_delete_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
+rte_lpm_delete(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
 {
 	int32_t rule_to_delete_index, sub_rule_index;
 	uint32_t ip_masked;
@@ -1911,7 +1012,7 @@ rte_lpm_delete_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
 	 * Find the index of the input rule, that needs to be deleted, in the
 	 * rule table.
 	 */
-	rule_to_delete_index = rule_find_v1604(lpm, ip_masked, depth);
+	rule_to_delete_index = rule_find(lpm, ip_masked, depth);
 
 	/*
 	 * Check if rule_to_delete_index was found. If no rule was found the
@@ -1921,7 +1022,7 @@ rte_lpm_delete_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
 		return -EINVAL;
 
 	/* Delete the rule from the rule table. */
-	rule_delete_v1604(lpm, rule_to_delete_index, depth);
+	rule_delete(lpm, rule_to_delete_index, depth);
 
 	/*
 	 * Find rule to replace the rule_to_delete. If there is no rule to
@@ -1929,45 +1030,26 @@ rte_lpm_delete_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
 	 * entries associated with this rule.
 	 */
 	sub_rule_depth = 0;
-	sub_rule_index = find_previous_rule_v1604(lpm, ip, depth, &sub_rule_depth);
+	sub_rule_index = find_previous_rule(lpm, ip, depth, &sub_rule_depth);
 
 	/*
 	 * If the input depth value is less than 25 use function
 	 * delete_depth_small otherwise use delete_depth_big.
 	 */
 	if (depth <= MAX_DEPTH_TBL24) {
-		return delete_depth_small_v1604(lpm, ip_masked, depth,
+		return delete_depth_small(lpm, ip_masked, depth,
 				sub_rule_index, sub_rule_depth);
 	} else { /* If depth > MAX_DEPTH_TBL24 */
-		return delete_depth_big_v1604(lpm, ip_masked, depth, sub_rule_index,
+		return delete_depth_big(lpm, ip_masked, depth, sub_rule_index,
 				sub_rule_depth);
 	}
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_delete, _v1604, 20.0);
-MAP_STATIC_SYMBOL(int rte_lpm_delete(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth), rte_lpm_delete_v1604);
 
 /*
  * Delete all rules from the LPM table.
  */
 void
-rte_lpm_delete_all_v20(struct rte_lpm_v20 *lpm)
-{
-	/* Zero rule information. */
-	memset(lpm->rule_info, 0, sizeof(lpm->rule_info));
-
-	/* Zero tbl24. */
-	memset(lpm->tbl24, 0, sizeof(lpm->tbl24));
-
-	/* Zero tbl8. */
-	memset(lpm->tbl8, 0, sizeof(lpm->tbl8));
-
-	/* Delete all rules form the rules table. */
-	memset(lpm->rules_tbl, 0, sizeof(lpm->rules_tbl[0]) * lpm->max_rules);
-}
-
-void
-rte_lpm_delete_all_v1604(struct rte_lpm *lpm)
+rte_lpm_delete_all(struct rte_lpm *lpm)
 {
 	/* Zero rule information. */
 	memset(lpm->rule_info, 0, sizeof(lpm->rule_info));
@@ -1982,6 +1064,3 @@ rte_lpm_delete_all_v1604(struct rte_lpm *lpm)
 	/* Delete all rules form the rules table. */
 	memset(lpm->rules_tbl, 0, sizeof(lpm->rules_tbl[0]) * lpm->max_rules);
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_delete_all, _v1604, 20.0);
-MAP_STATIC_SYMBOL(void rte_lpm_delete_all(struct rte_lpm *lpm),
-		rte_lpm_delete_all_v1604);
lib/librte_lpm/rte_lpm.h +0 -88

154 lines not on this page · raw message

lib/librte_lpm/rte_lpm6.c +14 -114

204 lines not on this page · raw message

lib/librte_lpm/rte_lpm6.h +0 -25
index 5d59ccb1f..37dfb2024 100644
@@ -96,12 +96,6 @@ rte_lpm6_free(struct rte_lpm6 *lpm);
 int
 rte_lpm6_add(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 		uint32_t next_hop);
-int
-rte_lpm6_add_v20(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint8_t next_hop);
-int
-rte_lpm6_add_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint32_t next_hop);
 
 /**
  * Check if a rule is present in the LPM table,
@@ -121,12 +115,6 @@ rte_lpm6_add_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 int
 rte_lpm6_is_rule_present(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 		uint32_t *next_hop);
-int
-rte_lpm6_is_rule_present_v20(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint8_t *next_hop);
-int
-rte_lpm6_is_rule_present_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint32_t *next_hop);
 
 /**
  * Delete a rule from the LPM table.
@@ -184,11 +172,6 @@ rte_lpm6_delete_all(struct rte_lpm6 *lpm);
  */
 int
 rte_lpm6_lookup(const struct rte_lpm6 *lpm, uint8_t *ip, uint32_t *next_hop);
-int
-rte_lpm6_lookup_v20(const struct rte_lpm6 *lpm, uint8_t *ip, uint8_t *next_hop);
-int
-rte_lpm6_lookup_v1705(const struct rte_lpm6 *lpm, uint8_t *ip,
-		uint32_t *next_hop);
 
 /**
  * Lookup multiple IP addresses in an LPM table.
@@ -210,14 +193,6 @@ int
 rte_lpm6_lookup_bulk_func(const struct rte_lpm6 *lpm,
 		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
 		int32_t *next_hops, unsigned int n);
-int
-rte_lpm6_lookup_bulk_func_v20(const struct rte_lpm6 *lpm,
-		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
-		int16_t *next_hops, unsigned int n);
-int
-rte_lpm6_lookup_bulk_func_v1705(const struct rte_lpm6 *lpm,
-		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
-		int32_t *next_hops, unsigned int n);
 
 #ifdef __cplusplus
 }
Signature · 1 line
2.22.0.windows.1
#7 lore raw

PATCH 7/8 lib: remove dead code from distributor

In reply to Marcin Baran

After updating ABI policy old and unused
code needs to be removed and all libraries
symbols version should be set to v20.

---
 lib/librte_distributor/rte_distributor.c      | 56 +++--------------
 .../rte_distributor_v1705.h                   | 61 -------------------
 2 files changed, 9 insertions(+), 108 deletions(-)
 delete mode 100644 lib/librte_distributor/rte_distributor_v1705.h
lib/librte_distributor/rte_distributor.c +9 -47
index edc942317..ca3f21b83 100644
@@ -19,7 +19,6 @@
 #include "rte_distributor_private.h"
 #include "rte_distributor.h"
 #include "rte_distributor_v20.h"
-#include "rte_distributor_v1705.h"
 
 TAILQ_HEAD(rte_dist_burst_list, rte_distributor);
 
@@ -33,7 +32,7 @@ EAL_REGISTER_TAILQ(rte_dist_burst_tailq)
 /**** Burst Packet APIs called by workers ****/
 
 void
-rte_distributor_request_pkt_v1705(struct rte_distributor *d,
+rte_distributor_request_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **oldpkt,
 		unsigned int count)
 {
@@ -78,14 +77,9 @@ rte_distributor_request_pkt_v1705(struct rte_distributor *d,
 	 */
 	*retptr64 |= RTE_DISTRIB_GET_BUF;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_request_pkt, _v1705, 20.0);
-MAP_STATIC_SYMBOL(void rte_distributor_request_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **oldpkt,
-		unsigned int count),
-		rte_distributor_request_pkt_v1705);
 
 int
-rte_distributor_poll_pkt_v1705(struct rte_distributor *d,
+rte_distributor_poll_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **pkts)
 {
 	struct rte_distributor_buffer *buf = &d->bufs[worker_id];
@@ -119,13 +113,9 @@ rte_distributor_poll_pkt_v1705(struct rte_distributor *d,
 
 	return count;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_poll_pkt, _v1705, 20.0);
-MAP_STATIC_SYMBOL(int rte_distributor_poll_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **pkts),
-		rte_distributor_poll_pkt_v1705);
 
 int
-rte_distributor_get_pkt_v1705(struct rte_distributor *d,
+rte_distributor_get_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **pkts,
 		struct rte_mbuf **oldpkt, unsigned int return_count)
 {
@@ -153,14 +143,9 @@ rte_distributor_get_pkt_v1705(struct rte_distributor *d,
 	}
 	return count;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_get_pkt, _v1705, 20.0);
-MAP_STATIC_SYMBOL(int rte_distributor_get_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **pkts,
-		struct rte_mbuf **oldpkt, unsigned int return_count),
-		rte_distributor_get_pkt_v1705);
 
 int
-rte_distributor_return_pkt_v1705(struct rte_distributor *d,
+rte_distributor_return_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **oldpkt, int num)
 {
 	struct rte_distributor_buffer *buf = &d->bufs[worker_id];
@@ -187,10 +172,6 @@ rte_distributor_return_pkt_v1705(struct rte_distributor *d,
 
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_return_pkt, _v1705, 20.0);
-MAP_STATIC_SYMBOL(int rte_distributor_return_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **oldpkt, int num),
-		rte_distributor_return_pkt_v1705);
 
 /**** APIs called on distributor core ***/
 
@@ -336,7 +317,7 @@ release(struct rte_distributor *d, unsigned int wkr)
 
 /* process a set of packets to distribute them to workers */
 int
-rte_distributor_process_v1705(struct rte_distributor *d,
+rte_distributor_process(struct rte_distributor *d,
 		struct rte_mbuf **mbufs, unsigned int num_mbufs)
 {
 	unsigned int next_idx = 0;
@@ -470,14 +451,10 @@ rte_distributor_process_v1705(struct rte_distributor *d,
 
 	return num_mbufs;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_process, _v1705, 20.0);
-MAP_STATIC_SYMBOL(int rte_distributor_process(struct rte_distributor *d,
-		struct rte_mbuf **mbufs, unsigned int num_mbufs),
-		rte_distributor_process_v1705);
 
 /* return to the caller, packets returned from workers */
 int
-rte_distributor_returned_pkts_v1705(struct rte_distributor *d,
+rte_distributor_returned_pkts(struct rte_distributor *d,
 		struct rte_mbuf **mbufs, unsigned int max_mbufs)
 {
 	struct rte_distributor_returned_pkts *returns = &d->returns;
@@ -502,10 +479,6 @@ rte_distributor_returned_pkts_v1705(struct rte_distributor *d,
 
 	return retval;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_returned_pkts, _v1705, 20.0);
-MAP_STATIC_SYMBOL(int rte_distributor_returned_pkts(struct rte_distributor *d,
-		struct rte_mbuf **mbufs, unsigned int max_mbufs),
-		rte_distributor_returned_pkts_v1705);
 
 /*
  * Return the number of packets in-flight in a distributor, i.e. packets
@@ -527,7 +500,7 @@ total_outstanding(const struct rte_distributor *d)
  * queued up.
  */
 int
-rte_distributor_flush_v1705(struct rte_distributor *d)
+rte_distributor_flush(struct rte_distributor *d)
 {
 	unsigned int flushed;
 	unsigned int wkr;
@@ -556,13 +529,10 @@ rte_distributor_flush_v1705(struct rte_distributor *d)
 
 	return flushed;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_flush, _v1705, 20.0);
-MAP_STATIC_SYMBOL(int rte_distributor_flush(struct rte_distributor *d),
-		rte_distributor_flush_v1705);
 
 /* clears the internal returns array in the distributor */
 void
-rte_distributor_clear_returns_v1705(struct rte_distributor *d)
+rte_distributor_clear_returns(struct rte_distributor *d)
 {
 	unsigned int wkr;
 
@@ -576,13 +546,10 @@ rte_distributor_clear_returns_v1705(struct rte_distributor *d)
 	for (wkr = 0; wkr < d->num_workers; wkr++)
 		d->bufs[wkr].retptr64[0] = 0;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_clear_returns, _v1705, 20.0);
-MAP_STATIC_SYMBOL(void rte_distributor_clear_returns(struct rte_distributor *d),
-		rte_distributor_clear_returns_v1705);
 
 /* creates a distributor instance */
 struct rte_distributor *
-rte_distributor_create_v1705(const char *name,
+rte_distributor_create(const char *name,
 		unsigned int socket_id,
 		unsigned int num_workers,
 		unsigned int alg_type)
@@ -656,8 +623,3 @@ rte_distributor_create_v1705(const char *name,
 
 	return d;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_create, _v1705, 20.0);
-MAP_STATIC_SYMBOL(struct rte_distributor *rte_distributor_create(
-		const char *name, unsigned int socket_id,
-		unsigned int num_workers, unsigned int alg_type),
-		rte_distributor_create_v1705);
lib/librte_distributor/rte_distributor_v1705.h deleted +0 -61

61 lines not on this page · raw message

Signature · 1 line
2.22.0.windows.1
#8 lore raw

PATCH 8/8 lib: change function suffix in distributor

In reply to Marcin Baran

The functions and structures version 2.0 is still in use in librte_distributor for single packet mode but the version suffix "_v20" needs to be changed to "_single" in order to avoid confusion.

---
 lib/librte_distributor/Makefile               |  2 +-
 lib/librte_distributor/meson.build            |  2 +-
 lib/librte_distributor/rte_distributor.c      | 24 +++++-----
 .../rte_distributor_private.h                 | 10 ++--
 ...ributor_v20.c => rte_distributor_single.c} | 48 +++++++++----------
 ...ributor_v20.h => rte_distributor_single.h} | 26 +++++-----
 6 files changed, 57 insertions(+), 55 deletions(-)
 rename lib/librte_distributor/{rte_distributor_v20.c => rte_distributor_single.c} (87%)
 rename lib/librte_distributor/{rte_distributor_v20.h => rte_distributor_single.h} (89%)
lib/librte_distributor/Makefile +1 -1
index 0ef80dcff..d9d008916 100644
@@ -15,7 +15,7 @@ EXPORT_MAP := rte_distributor_version.map
 LIBABIVER := 1
 
 # all source are stored in SRCS-y
-SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) := rte_distributor_v20.c
+SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) := rte_distributor_single.c
 SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += rte_distributor.c
 ifeq ($(CONFIG_RTE_ARCH_X86),y)
 SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += rte_distributor_match_sse.c
lib/librte_distributor/meson.build +1 -1
index dba7e3b2a..bd12ddb2f 100644
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-sources = files('rte_distributor.c', 'rte_distributor_v20.c')
+sources = files('rte_distributor.c', 'rte_distributor_single.c')
 if arch_subdir == 'x86'
 	sources += files('rte_distributor_match_sse.c')
 else
lib/librte_distributor/rte_distributor.c +13 -11
index ca3f21b83..b4fc0bfea 100644
@@ -18,7 +18,7 @@
 
 #include "rte_distributor_private.h"
 #include "rte_distributor.h"
-#include "rte_distributor_v20.h"
+#include "rte_distributor_single.h"
 
 TAILQ_HEAD(rte_dist_burst_list, rte_distributor);
 
@@ -42,7 +42,7 @@ rte_distributor_request_pkt(struct rte_distributor *d,
 	volatile int64_t *retptr64;
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
-		rte_distributor_request_pkt_v20(d->d_v20,
+		rte_distributor_request_pkt_single(d->d_single,
 			worker_id, oldpkt[0]);
 		return;
 	}
@@ -88,7 +88,8 @@ rte_distributor_poll_pkt(struct rte_distributor *d,
 	unsigned int i;
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
-		pkts[0] = rte_distributor_poll_pkt_v20(d->d_v20, worker_id);
+		pkts[0] = rte_distributor_poll_pkt_single(d->d_single,
+			worker_id);
 		return (pkts[0]) ? 1 : 0;
 	}
 
@@ -123,7 +124,7 @@ rte_distributor_get_pkt(struct rte_distributor *d,
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
 		if (return_count <= 1) {
-			pkts[0] = rte_distributor_get_pkt_v20(d->d_v20,
+			pkts[0] = rte_distributor_get_pkt_single(d->d_single,
 				worker_id, oldpkt[0]);
 			return (pkts[0]) ? 1 : 0;
 		} else
@@ -153,7 +154,7 @@ rte_distributor_return_pkt(struct rte_distributor *d,
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
 		if (num == 1)
-			return rte_distributor_return_pkt_v20(d->d_v20,
+			return rte_distributor_return_pkt_single(d->d_single,
 				worker_id, oldpkt[0]);
 		else
 			return -EINVAL;
@@ -330,7 +331,8 @@ rte_distributor_process(struct rte_distributor *d,
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		return rte_distributor_process_v20(d->d_v20, mbufs, num_mbufs);
+		return rte_distributor_process_single(d->d_single,
+			mbufs, num_mbufs);
 	}
 
 	if (unlikely(num_mbufs == 0)) {
@@ -464,7 +466,7 @@ rte_distributor_returned_pkts(struct rte_distributor *d,
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		return rte_distributor_returned_pkts_v20(d->d_v20,
+		return rte_distributor_returned_pkts_single(d->d_single,
 				mbufs, max_mbufs);
 	}
 
@@ -507,7 +509,7 @@ rte_distributor_flush(struct rte_distributor *d)
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		return rte_distributor_flush_v20(d->d_v20);
+		return rte_distributor_flush_single(d->d_single);
 	}
 
 	flushed = total_outstanding(d);
@@ -538,7 +540,7 @@ rte_distributor_clear_returns(struct rte_distributor *d)
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		rte_distributor_clear_returns_v20(d->d_v20);
+		rte_distributor_clear_returns_single(d->d_single);
 		return;
 	}
 
@@ -578,9 +580,9 @@ rte_distributor_create(const char *name,
 			rte_errno = ENOMEM;
 			return NULL;
 		}
-		d->d_v20 = rte_distributor_create_v20(name,
+		d->d_single = rte_distributor_create_single(name,
 				socket_id, num_workers);
-		if (d->d_v20 == NULL) {
+		if (d->d_single == NULL) {
 			free(d);
 			/* rte_errno will have been set */
 			return NULL;
lib/librte_distributor/rte_distributor_private.h +5 -5
index 33cd89410..bdb62b6e9 100644
@@ -55,7 +55,7 @@ extern "C" {
  * the next cache line to worker 0, we pad this out to three cache lines.
  * Only 64-bits of the memory is actually used though.
  */
-union rte_distributor_buffer_v20 {
+union rte_distributor_buffer_single {
 	volatile int64_t bufptr64;
 	char pad[RTE_CACHE_LINE_SIZE*3];
 } __rte_cache_aligned;
@@ -80,8 +80,8 @@ struct rte_distributor_returned_pkts {
 	struct rte_mbuf *mbufs[RTE_DISTRIB_MAX_RETURNS];
 };
 
-struct rte_distributor_v20 {
-	TAILQ_ENTRY(rte_distributor_v20) next;    /**< Next in list. */
+struct rte_distributor_single {
+	TAILQ_ENTRY(rte_distributor_single) next;    /**< Next in list. */
 
 	char name[RTE_DISTRIBUTOR_NAMESIZE];  /**< Name of the ring. */
 	unsigned int num_workers;             /**< Number of workers polling */
@@ -96,7 +96,7 @@ struct rte_distributor_v20 {
 
 	struct rte_distributor_backlog backlog[RTE_DISTRIB_MAX_WORKERS];
 
-	union rte_distributor_buffer_v20 bufs[RTE_DISTRIB_MAX_WORKERS];
+	union rte_distributor_buffer_single bufs[RTE_DISTRIB_MAX_WORKERS];
 
 	struct rte_distributor_returned_pkts returns;
 };
@@ -154,7 +154,7 @@ struct rte_distributor {
 
 	enum rte_distributor_match_function dist_match_fn;
 
-	struct rte_distributor_v20 *d_v20;
+	struct rte_distributor_single *d_single;
 };
 
 void
lib/librte_distributor/rte_distributor_single.c renamed from lib/librte_distributor/rte_distributor_v20.c +24 -24

155 lines not on this page · raw message

lib/librte_distributor/rte_distributor_single.h renamed from lib/librte_distributor/rte_distributor_v20.h +13 -13
similarity index 89%
rename from lib/librte_distributor/rte_distributor_v20.h
rename to lib/librte_distributor/rte_distributor_single.h
index 12865658b..2f80aa43d 100644
@@ -2,8 +2,8 @@
  * Copyright(c) 2010-2014 Intel Corporation
  */
 
-#ifndef _RTE_DISTRIB_V20_H_
-#define _RTE_DISTRIB_V20_H_
+#ifndef _RTE_DISTRIB_SINGLE_H_
+#define _RTE_DISTRIB_SINGLE_H_
 
 /**
  * @file
@@ -19,7 +19,7 @@ extern "C" {
 
 #define RTE_DISTRIBUTOR_NAMESIZE 32 /**< Length of name for instance */
 
-struct rte_distributor_v20;
+struct rte_distributor_single;
 struct rte_mbuf;
 
 /**
@@ -38,8 +38,8 @@ struct rte_mbuf;
  * @return
  *   The newly created distributor instance
  */
-struct rte_distributor_v20 *
-rte_distributor_create_v20(const char *name, unsigned int socket_id,
+struct rte_distributor_single *
+rte_distributor_create_single(const char *name, unsigned int socket_id,
 		unsigned int num_workers);
 
 /*  *** APIS to be called on the distributor lcore ***  */
@@ -74,7 +74,7 @@ rte_distributor_create_v20(const char *name, unsigned int socket_id,
  *   The number of mbufs processed.
  */
 int
-rte_distributor_process_v20(struct rte_distributor_v20 *d,
+rte_distributor_process_single(struct rte_distributor_single *d,
 		struct rte_mbuf **mbufs, unsigned int num_mbufs);
 
 /**
@@ -92,7 +92,7 @@ rte_distributor_process_v20(struct rte_distributor_v20 *d,
  *   The number of mbufs returned in the mbufs array.
  */
 int
-rte_distributor_returned_pkts_v20(struct rte_distributor_v20 *d,
+rte_distributor_returned_pkts_single(struct rte_distributor_single *d,
 		struct rte_mbuf **mbufs, unsigned int max_mbufs);
 
 /**
@@ -107,7 +107,7 @@ rte_distributor_returned_pkts_v20(struct rte_distributor_v20 *d,
  *   The number of queued/in-flight packets that were completed by this call.
  */
 int
-rte_distributor_flush_v20(struct rte_distributor_v20 *d);
+rte_distributor_flush_single(struct rte_distributor_single *d);
 
 /**
  * Clears the array of returned packets used as the source for the
@@ -119,7 +119,7 @@ rte_distributor_flush_v20(struct rte_distributor_v20 *d);
  *   The distributor instance to be used
  */
 void
-rte_distributor_clear_returns_v20(struct rte_distributor_v20 *d);
+rte_distributor_clear_returns_single(struct rte_distributor_single *d);
 
 /*  *** APIS to be called on the worker lcores ***  */
 /*
@@ -148,7 +148,7 @@ rte_distributor_clear_returns_v20(struct rte_distributor_v20 *d);
  *   A new packet to be processed by the worker thread.
  */
 struct rte_mbuf *
-rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_get_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id, struct rte_mbuf *oldpkt);
 
 /**
@@ -164,7 +164,7 @@ rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d,
  *   The previous packet being processed by the worker
  */
 int
-rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_return_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id, struct rte_mbuf *mbuf);
 
 /**
@@ -188,7 +188,7 @@ rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d,
  *   The previous packet, if any, being processed by the worker
  */
 void
-rte_distributor_request_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_request_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id, struct rte_mbuf *oldpkt);
 
 /**
@@ -208,7 +208,7 @@ rte_distributor_request_pkt_v20(struct rte_distributor_v20 *d,
  *   packet is yet available.
  */
 struct rte_mbuf *
-rte_distributor_poll_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_poll_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id);
 
 #ifdef __cplusplus
Signature · 1 line
2.22.0.windows.1
#9 lore raw

v2 cover Implement the new ABI policy and add helper scripts

In reply to Marcin Baran

This patchset prepares the codebase for the new ABI policy and adds a few helper scripts.

There are two new scripts for managing ABI versions added. The first one is a Python script that will read in a .map file, flatten it and update the ABI version to the ABI version specified on the command-line.

The second one is a shell script that will run the above mentioned Python script recursively over the source tree and set the ABI version to either that which is defined in config/ABI_VERSION, or a user-specified one.

Example of its usage: buildtools/update-abi.sh 20.0

This will recurse into lib/ and drivers/ directory and update whatever .map files it can find.

The other shell script that's added is one that can take in a .so file and ensure that its declared public ABI matches either current ABI, next ABI, or EXPERIMENTAL. This was moved to the last commit because it made no sense to have it beforehand.

The source tree was verified to follow the new ABI policy using the following command (assuming built binaries are in build/):

find ./build/lib ./build/drivers -name \*.so \
-exec ./buildtools/check-abi-version.sh {} \; -print

This returns 0.

Changes since v1:
- Reordered patchset to have removal of old ABI's before introducing the new one to avoid compile breakages between patches
- Added a new patch fixing missing symbol in octeontx common
- Split script commits into multiple commits and reordered them
- Re-generated the ABI bump commit
- Verified all scripts to work

Anatoly Burakov (2):
buildtools: add ABI update shell script
drivers/octeontx: add missing public symbol

Marcin Baran (6):
config: change ABI versioning for global
timer: remove deprecated code
lpm: remove deprecated code
distributor: remove deprecated code
lib: change function suffix in distributor
buildtools: add ABI versioning check script

Pawel Modrak (2):
buildtools: add script for updating symbols abi version
build: change ABI version to 20.0

 buildtools/check-abi-version.sh               |  54 +
 buildtools/meson.build                        |   2 +
 buildtools/update-abi.sh                      |  36 +
 buildtools/update_version_map_abi.py          | 148 +++
 config/ABI_VERSION                            |   1 +
 config/meson.build                            |   3 +-
 .../rte_pmd_bbdev_fpga_lte_fec_version.map    |   8 +-
 .../null/rte_pmd_bbdev_null_version.map       |   2 +-
 .../rte_pmd_bbdev_turbo_sw_version.map        |   2 +-
 drivers/bus/dpaa/rte_bus_dpaa_version.map     | 115 +-
 drivers/bus/fslmc/rte_bus_fslmc_version.map   | 154 ++-
 drivers/bus/ifpga/rte_bus_ifpga_version.map   |  14 +-
 drivers/bus/pci/rte_bus_pci_version.map       |   2 +-
 drivers/bus/vdev/rte_bus_vdev_version.map     |  12 +-
 drivers/bus/vmbus/rte_bus_vmbus_version.map   |  12 +-
 drivers/common/cpt/rte_common_cpt_version.map |   4 +-
 .../common/dpaax/rte_common_dpaax_version.map |   4 +-
 .../common/mvep/rte_common_mvep_version.map   |   6 +-
 .../octeontx/rte_common_octeontx_version.map  |   7 +-
 .../rte_common_octeontx2_version.map          |  16 +-
 .../compress/isal/rte_pmd_isal_version.map    |   2 +-
 .../rte_pmd_octeontx_compress_version.map     |   2 +-
 drivers/compress/qat/rte_pmd_qat_version.map  |   2 +-
 .../compress/zlib/rte_pmd_zlib_version.map    |   2 +-
 .../aesni_gcm/rte_pmd_aesni_gcm_version.map   |   2 +-
 .../aesni_mb/rte_pmd_aesni_mb_version.map     |   2 +-
 .../crypto/armv8/rte_pmd_armv8_version.map    |   2 +-
 .../caam_jr/rte_pmd_caam_jr_version.map       |   3 +-
 drivers/crypto/ccp/rte_pmd_ccp_version.map    |   3 +-
 .../dpaa2_sec/rte_pmd_dpaa2_sec_version.map   |  10 +-
 .../dpaa_sec/rte_pmd_dpaa_sec_version.map     |  10 +-
 .../crypto/kasumi/rte_pmd_kasumi_version.map  |   2 +-
 .../crypto/mvsam/rte_pmd_mvsam_version.map    |   2 +-
 .../crypto/nitrox/rte_pmd_nitrox_version.map  |   2 +-
 .../null/rte_pmd_null_crypto_version.map      |   2 +-
 .../rte_pmd_octeontx_crypto_version.map       |   3 +-
 .../openssl/rte_pmd_openssl_version.map       |   2 +-
 .../rte_pmd_crypto_scheduler_version.map      |  19 +-
 .../crypto/snow3g/rte_pmd_snow3g_version.map  |   2 +-
 .../virtio/rte_pmd_virtio_crypto_version.map  |   2 +-
 drivers/crypto/zuc/rte_pmd_zuc_version.map    |   2 +-
 .../event/dpaa/rte_pmd_dpaa_event_version.map |   3 +-
 .../dpaa2/rte_pmd_dpaa2_event_version.map     |   2 +-
 .../event/dsw/rte_pmd_dsw_event_version.map   |   2 +-
 .../rte_pmd_octeontx_event_version.map        |   2 +-
 .../rte_pmd_octeontx2_event_version.map       |   3 +-
 .../event/opdl/rte_pmd_opdl_event_version.map |   2 +-
 .../rte_pmd_skeleton_event_version.map        |   3 +-
 drivers/event/sw/rte_pmd_sw_event_version.map |   2 +-
 .../bucket/rte_mempool_bucket_version.map     |   3 +-
 .../mempool/dpaa/rte_mempool_dpaa_version.map |   2 +-
 .../dpaa2/rte_mempool_dpaa2_version.map       |  12 +-
 .../octeontx/rte_mempool_octeontx_version.map |   2 +-
 .../rte_mempool_octeontx2_version.map         |   4 +-
 .../mempool/ring/rte_mempool_ring_version.map |   3 +-
 .../stack/rte_mempool_stack_version.map       |   3 +-
 drivers/meson.build                           |  20 +-
 .../af_packet/rte_pmd_af_packet_version.map   |   3 +-
 drivers/net/af_xdp/rte_pmd_af_xdp_version.map |   2 +-
 drivers/net/ark/rte_pmd_ark_version.map       |   5 +-
 .../net/atlantic/rte_pmd_atlantic_version.map |   4 +-
 drivers/net/avp/rte_pmd_avp_version.map       |   2 +-
 drivers/net/axgbe/rte_pmd_axgbe_version.map   |   2 +-
 drivers/net/bnx2x/rte_pmd_bnx2x_version.map   |   3 +-
 drivers/net/bnxt/rte_pmd_bnxt_version.map     |   4 +-
 drivers/net/bonding/rte_pmd_bond_version.map  |  47 +-
 drivers/net/cxgbe/rte_pmd_cxgbe_version.map   |   3 +-
 drivers/net/dpaa/rte_pmd_dpaa_version.map     |  11 +-
 drivers/net/dpaa2/rte_pmd_dpaa2_version.map   |  12 +-
 drivers/net/e1000/rte_pmd_e1000_version.map   |   3 +-
 drivers/net/ena/rte_pmd_ena_version.map       |   3 +-
 drivers/net/enetc/rte_pmd_enetc_version.map   |   3 +-
 drivers/net/enic/rte_pmd_enic_version.map     |   3 +-
 .../net/failsafe/rte_pmd_failsafe_version.map |   3 +-
 drivers/net/fm10k/rte_pmd_fm10k_version.map   |   3 +-
 drivers/net/hinic/rte_pmd_hinic_version.map   |   3 +-
 drivers/net/hns3/rte_pmd_hns3_version.map     |   4 +-
 drivers/net/i40e/rte_pmd_i40e_version.map     |  65 +-
 drivers/net/iavf/rte_pmd_iavf_version.map     |   3 +-
 drivers/net/ice/rte_pmd_ice_version.map       |   3 +-
 drivers/net/ifc/rte_pmd_ifc_version.map       |   3 +-
 drivers/net/ipn3ke/rte_pmd_ipn3ke_version.map |   3 +-
 drivers/net/ixgbe/rte_pmd_ixgbe_version.map   |  62 +-
 drivers/net/kni/rte_pmd_kni_version.map       |   3 +-
 .../net/liquidio/rte_pmd_liquidio_version.map |   3 +-
 drivers/net/memif/rte_pmd_memif_version.map   |   5 +-
 drivers/net/mlx4/rte_pmd_mlx4_version.map     |   3 +-
 drivers/net/mlx5/rte_pmd_mlx5_version.map     |   2 +-
 drivers/net/mvneta/rte_pmd_mvneta_version.map |   2 +-
 drivers/net/mvpp2/rte_pmd_mvpp2_version.map   |   2 +-
 drivers/net/netvsc/rte_pmd_netvsc_version.map |   4 +-
 drivers/net/nfb/rte_pmd_nfb_version.map       |   3 +-
 drivers/net/nfp/rte_pmd_nfp_version.map       |   2 +-
 drivers/net/null/rte_pmd_null_version.map     |   3 +-
 .../net/octeontx/rte_pmd_octeontx_version.map |  10 +-
 .../octeontx2/rte_pmd_octeontx2_version.map   |   3 +-
 drivers/net/pcap/rte_pmd_pcap_version.map     |   3 +-
 drivers/net/qede/rte_pmd_qede_version.map     |   3 +-
 drivers/net/ring/rte_pmd_ring_version.map     |  10 +-
 drivers/net/sfc/rte_pmd_sfc_version.map       |   3 +-
 .../net/softnic/rte_pmd_softnic_version.map   |   2 +-
 .../net/szedata2/rte_pmd_szedata2_version.map |   2 +-
 drivers/net/tap/rte_pmd_tap_version.map       |   3 +-
 .../net/thunderx/rte_pmd_thunderx_version.map |   3 +-
 .../rte_pmd_vdev_netvsc_version.map           |   3 +-
 drivers/net/vhost/rte_pmd_vhost_version.map   |  11 +-
 drivers/net/virtio/rte_pmd_virtio_version.map |   3 +-
 .../net/vmxnet3/rte_pmd_vmxnet3_version.map   |   3 +-
 .../rte_rawdev_dpaa2_cmdif_version.map        |   3 +-
 .../rte_rawdev_dpaa2_qdma_version.map         |   4 +-
 .../raw/ifpga/rte_rawdev_ifpga_version.map    |   3 +-
 drivers/raw/ioat/rte_rawdev_ioat_version.map  |   3 +-
 drivers/raw/ntb/rte_rawdev_ntb_version.map    |   5 +-
 .../rte_rawdev_octeontx2_dma_version.map      |   3 +-
 .../skeleton/rte_rawdev_skeleton_version.map  |   3 +-
 lib/librte_acl/rte_acl_version.map            |   2 +-
 lib/librte_bbdev/rte_bbdev_version.map        |   4 +
 .../rte_bitratestats_version.map              |   2 +-
 lib/librte_bpf/rte_bpf_version.map            |   4 +
 lib/librte_cfgfile/rte_cfgfile_version.map    |  34 +-
 lib/librte_cmdline/rte_cmdline_version.map    |  10 +-
 .../rte_compressdev_version.map               |   4 +
 .../rte_cryptodev_version.map                 | 102 +-
 lib/librte_distributor/Makefile               |   2 +-
 lib/librte_distributor/meson.build            |   2 +-
 lib/librte_distributor/rte_distributor.c      |  80 +-
 .../rte_distributor_private.h                 |  10 +-
 ...ributor_v20.c => rte_distributor_single.c} |  48 +-
 ...ributor_v20.h => rte_distributor_single.h} |  26 +-
 .../rte_distributor_v1705.h                   |  61 --
 .../rte_distributor_version.map               |  16 +-
 lib/librte_eal/rte_eal_version.map            | 310 ++----
 lib/librte_efd/rte_efd_version.map            |   2 +-
 lib/librte_ethdev/rte_ethdev_version.map      | 160 +--
 lib/librte_eventdev/rte_eventdev_version.map  | 130 +--
 .../rte_flow_classify_version.map             |   4 +
 lib/librte_gro/rte_gro_version.map            |   2 +-
 lib/librte_gso/rte_gso_version.map            |   2 +-
 lib/librte_hash/rte_hash_version.map          |  43 +-
 lib/librte_ip_frag/rte_ip_frag_version.map    |  10 +-
 lib/librte_ipsec/rte_ipsec_version.map        |   4 +
 lib/librte_jobstats/rte_jobstats_version.map  |  10 +-
 lib/librte_kni/rte_kni_version.map            |   2 +-
 lib/librte_kvargs/rte_kvargs_version.map      |   4 +-
 .../rte_latencystats_version.map              |   2 +-
 lib/librte_lpm/rte_lpm.c                      | 996 +-----------------
 lib/librte_lpm/rte_lpm.h                      |  88 --
 lib/librte_lpm/rte_lpm6.c                     | 132 +--
 lib/librte_lpm/rte_lpm6.h                     |  25 -
 lib/librte_lpm/rte_lpm_version.map            |  39 +-
 lib/librte_mbuf/rte_mbuf_version.map          |  41 +-
 lib/librte_member/rte_member_version.map      |   2 +-
 lib/librte_mempool/rte_mempool_version.map    |  44 +-
 lib/librte_meter/rte_meter_version.map        |  13 +-
 lib/librte_metrics/rte_metrics_version.map    |   2 +-
 lib/librte_net/rte_net_version.map            |  23 +-
 lib/librte_pci/rte_pci_version.map            |   2 +-
 lib/librte_pdump/rte_pdump_version.map        |   2 +-
 lib/librte_pipeline/rte_pipeline_version.map  |  36 +-
 lib/librte_port/rte_port_version.map          |  64 +-
 lib/librte_power/rte_power_version.map        |  24 +-
 lib/librte_rawdev/rte_rawdev_version.map      |   4 +-
 lib/librte_rcu/rte_rcu_version.map            |   4 +
 lib/librte_reorder/rte_reorder_version.map    |   8 +-
 lib/librte_ring/rte_ring_version.map          |  10 +-
 lib/librte_sched/rte_sched_version.map        |  14 +-
 lib/librte_security/rte_security_version.map  |   2 +-
 lib/librte_stack/rte_stack_version.map        |   4 +
 lib/librte_table/rte_table_version.map        |   2 +-
 .../rte_telemetry_version.map                 |   4 +
 lib/librte_timer/rte_timer.c                  |  90 +-
 lib/librte_timer/rte_timer.h                  |  15 -
 lib/librte_timer/rte_timer_version.map        |  12 +-
 lib/librte_vhost/rte_vhost_version.map        |  52 +-
 lib/meson.build                               |  18 +-
 meson_options.txt                             |   2 -
 mk/rte.lib.mk                                 |  19 +-
 177 files changed, 1122 insertions(+), 2891 deletions(-)
 create mode 100755 buildtools/check-abi-version.sh
 create mode 100755 buildtools/update-abi.sh
 create mode 100755 buildtools/update_version_map_abi.py
 create mode 100644 config/ABI_VERSION
 rename lib/librte_distributor/{rte_distributor_v20.c => rte_distributor_single.c} (87%)
 rename lib/librte_distributor/{rte_distributor_v20.h => rte_distributor_single.h} (89%)
 delete mode 100644 lib/librte_distributor/rte_distributor_v1705.h
Signature · 1 line
2.17.1
#10 lore raw

PATCH v2 1/10 config: change ABI versioning for global

From: Marcin Baran <[email protected]>

The libraries should be maintained using global ABI versioning. The changes includes adding global ABI version support for both makefile and meson build system. Experimental libraries should be marked as 0.

---
 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  3 ++-
 drivers/meson.build    | 20 ++++++++++++++------
 lib/meson.build        | 18 +++++++++++++-----
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 19 +++++++++++--------
 7 files changed, 43 insertions(+), 22 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +2 -1
index a27f731f85..25ecf928e4 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and libraries
 # depending on the configuration options
 pver = meson.project_version().split('.')
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+major_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())
drivers/meson.build +14 -6
index 2ed2e95411..5c5fe87c7e 100644
@@ -110,9 +110,20 @@ foreach class:dpdk_driver_classes
 					output: out_filename,
 					depends: [pmdinfogen, tmp_lib])
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/@2@_version.map'.format(
+					meson.current_source_dir(),
+					drv_path, lib_name)
+
+			if is_windows
+				version_map = '\\'.join(version_map.split('/'))
+			endif
+
+			is_experimental = run_command(is_experimental_cmd,
+				files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
 				lib_version = major_version
 				so_version = major_version
@@ -128,9 +139,6 @@ foreach class:dpdk_driver_classes
 				install: true)
 
 			# now build the shared driver
-			version_map = '@0@/@1@/@2@_version.map'.format(
-					meson.current_source_dir(),
-					drv_path, lib_name)
 			shared_lib = shared_library(lib_name,
 				sources,
 				objects: objs,
lib/meson.build +13 -5
index e5ff838934..3892c16e8f 100644
@@ -97,9 +97,19 @@ foreach l:libraries
 				cflags += '-DALLOW_EXPERIMENTAL_API'
 			endif
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/rte_@2@_version.map'.format(
+					meson.current_source_dir(), dir_name, name)
+
+			if is_windows
+				version_map = '\\'.join(version_map.split('/'))
+			endif
+
+			is_experimental = run_command(is_experimental_cmd,
+					files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
 				lib_version = major_version
 				so_version = major_version
@@ -120,8 +130,6 @@ foreach l:libraries
 			# then use pre-build objects to build shared lib
 			sources = []
 			objs += static_lib.extract_all_objects(recursive: false)
-			version_map = '@0@/@1@/rte_@2@_version.map'.format(
-					meson.current_source_dir(), dir_name, name)
 			implib = dir_name + '.dll.a'
 
 			def_file = custom_target(name + '_def',
meson_options.txt +0 -2
index 448f3e63dc..000e38fd98 100644
@@ -28,8 +28,6 @@ option('max_lcores', type: 'integer', value: 128,
 	description: 'maximum number of cores/threads supported by EAL')
 option('max_numa_nodes', type: 'integer', value: 4,
 	description: 'maximum number of NUMA nodes supported by EAL')
-option('per_library_versions', type: 'boolean', value: true,
-	description: 'true: each lib gets its own version number, false: DPDK version used for each lib')
 option('tests', type: 'boolean', value: true,
 	description: 'build unit tests')
 option('use_hpet', type: 'boolean', value: false,
mk/rte.lib.mk +11 -8
index 4df8849a08..f84161c6d5 100644
@@ -11,20 +11,23 @@ EXTLIB_BUILD ?= n
 # VPATH contains at least SRCDIR
 VPATH += $(SRCDIR)
 
-ifneq ($(CONFIG_RTE_MAJOR_ABI),)
-ifneq ($(LIBABIVER),)
-LIBABIVER := $(CONFIG_RTE_MAJOR_ABI)
+ifeq ($(OS), Windows_NT)
+search_cmd = findstr
+print_cmd = more
+else
+search_cmd = grep
+print_cmd = cat
 endif
+
+ifneq ($(shell $(search_cmd) "^DPDK_" $(SRCDIR)/$(EXPORT_MAP)),)
+LIBABIVER := $(shell $(print_cmd) $(RTE_SRCDIR)/config/ABI_VERSION)
+else
+LIBABIVER := 0
 endif
 
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
 LIB := $(patsubst %.a,%.so.$(LIBABIVER),$(LIB))
 ifeq ($(EXTLIB_BUILD),n)
-ifeq ($(CONFIG_RTE_MAJOR_ABI),)
-ifeq ($(CONFIG_RTE_NEXT_ABI),y)
-LIB := $(LIB).1
-endif
-endif
 CPU_LDFLAGS += --version-script=$(SRCDIR)/$(EXPORT_MAP)
 endif
 endif
Signature · 1 line
2.17.1
#11 lore raw
Quoted 8 lines · Anatoly Burakov

From: Marcin Baran <[email protected]>

The libraries should be maintained using global ABI versioning. The changes includes adding global ABI version support for both makefile and meson build system. Experimental libraries should be marked as 0.

Quoted 4 lines

---

Some comments inline below.

/Bruce

Quoted 32 lines
 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  3 ++-
 drivers/meson.build    | 20 ++++++++++++++------
 lib/meson.build        | 18 +++++++++++++-----
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 19 +++++++++++--------
 7 files changed, 43 insertions(+), 22 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +0 -0
index a27f731f85..25ecf928e4 100644

config/meson.build endforeach · line 22

Quoted 7 lines
config/meson.build +2 -1
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and libraries
 # depending on the configuration options
 pver = meson.project_version().split('.')
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+major_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 

I wonder if we should rename this to abi_version rather than major_version?

Quoted 10 lines
config/meson.build +0 -0
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())
drivers/meson.build +0 -0
index 2ed2e95411..5c5fe87c7e 100644
@@ -110,9 +110,20 @@ foreach class:dpdk_driver_classes
 					output: out_filename,
 					depends: [pmdinfogen, tmp_lib])
 

drivers/meson.build foreach class:dpdk_driver_classes · line 119

Quoted 10 lines
drivers/meson.build +7 -3
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/@2@_version.map'.format(
+					meson.current_source_dir(),
+					drv_path, lib_name)
+
+			if is_windows
+				version_map = '\\'.join(version_map.split('/'))
+			endif

Don't think this block should be needed. Windows generally supports using "/" as a separator, even if traditionally "\" was used.

Quoted 27 lines
drivers/meson.build +7 -3
+
+			is_experimental = run_command(is_experimental_cmd,
+				files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
 				lib_version = major_version
 				so_version = major_version
@@ -128,9 +139,6 @@ foreach class:dpdk_driver_classes
 				install: true)
 
 			# now build the shared driver
-			version_map = '@0@/@1@/@2@_version.map'.format(
-					meson.current_source_dir(),
-					drv_path, lib_name)
 			shared_lib = shared_library(lib_name,
 				sources,
 				objects: objs,
lib/meson.build +0 -0
index e5ff838934..3892c16e8f 100644
@@ -97,9 +97,19 @@ foreach l:libraries
 				cflags += '-DALLOW_EXPERIMENTAL_API'
 			endif

lib/meson.build foreach l:libraries · line 105

Quoted 10 lines
lib/meson.build +6 -3
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/rte_@2@_version.map'.format(
+					meson.current_source_dir(), dir_name, name)
+
+			if is_windows
+				version_map = '\\'.join(version_map.split('/'))
+			endif

As above.

Quoted 39 lines
lib/meson.build +7 -2
+
+			is_experimental = run_command(is_experimental_cmd,
+					files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
 				lib_version = major_version
 				so_version = major_version
@@ -120,8 +130,6 @@ foreach l:libraries
 			# then use pre-build objects to build shared lib
 			sources = []
 			objs += static_lib.extract_all_objects(recursive: false)
-			version_map = '@0@/@1@/rte_@2@_version.map'.format(
-					meson.current_source_dir(), dir_name, name)
 			implib = dir_name + '.dll.a'
 
 			def_file = custom_target(name + '_def',
meson_options.txt +0 -2
index 448f3e63dc..000e38fd98 100644
@@ -28,8 +28,6 @@ option('max_lcores', type: 'integer', value: 128,
 	description: 'maximum number of cores/threads supported by EAL')
 option('max_numa_nodes', type: 'integer', value: 4,
 	description: 'maximum number of NUMA nodes supported by EAL')
-option('per_library_versions', type: 'boolean', value: true,
-	description: 'true: each lib gets its own version number, false: DPDK version used for each lib')
 option('tests', type: 'boolean', value: true,
 	description: 'build unit tests')
 option('use_hpet', type: 'boolean', value: false,
mk/rte.lib.mk +0 -0
index 4df8849a08..f84161c6d5 100644
@@ -11,20 +11,23 @@ EXTLIB_BUILD ?= n
 # VPATH contains at least SRCDIR
 VPATH += $(SRCDIR)

mk/rte.lib.mk EXTLIB_BUILD ?= n · line 19

Quoted 10 lines
mk/rte.lib.mk +6 -3
 
-ifneq ($(CONFIG_RTE_MAJOR_ABI),)
-ifneq ($(LIBABIVER),)
-LIBABIVER := $(CONFIG_RTE_MAJOR_ABI)
+ifeq ($(OS), Windows_NT)
+search_cmd = findstr
+print_cmd = more
+else
+search_cmd = grep
+print_cmd = cat

We don't support make on windows, so no need for using findstr.

Quoted 21 lines
mk/rte.lib.mk +5 -5
 endif
+
+ifneq ($(shell $(search_cmd) "^DPDK_" $(SRCDIR)/$(EXPORT_MAP)),)
+LIBABIVER := $(shell $(print_cmd) $(RTE_SRCDIR)/config/ABI_VERSION)
+else
+LIBABIVER := 0
 endif
 
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
 LIB := $(patsubst %.a,%.so.$(LIBABIVER),$(LIB))
 ifeq ($(EXTLIB_BUILD),n)
-ifeq ($(CONFIG_RTE_MAJOR_ABI),)
-ifeq ($(CONFIG_RTE_NEXT_ABI),y)
-LIB := $(LIB).1
-endif
-endif
 CPU_LDFLAGS += --version-script=$(SRCDIR)/$(EXPORT_MAP)
 endif
 endif
Signature · 1 line
2.17.1
#12 lore raw

PATCH v2 2/10 buildtools: add script for updating symbols abi version

In reply to Anatoly Burakov

From: Pawel Modrak <[email protected]>

Add a script that automatically merges all stable ABI's under one ABI section with the new version, while leaving experimental section exactly as it is.

---

Notes:
v2:
- Reworked script to be pep8-compliant and more reliable

 buildtools/update_version_map_abi.py | 148 +++++++++++++++++++++++++++
 1 file changed, 148 insertions(+)
 create mode 100755 buildtools/update_version_map_abi.py
buildtools/update_version_map_abi.py new file +148 -0
new file mode 100755
index 0000000000..ea9044cc81
@@ -0,0 +1,148 @@
+#!/usr/bin/env python
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+"""
+A Python program to update the ABI version and function names in a DPDK
+lib_*_version.map file. Called from the buildtools/update_abi.sh utility.
+"""
+
+from __future__ import print_function
+import argparse
+import sys
+import re
+
+
+def __parse_map_file(f_in):
+    func_line_regex = re.compile(r"\s*(?P<func>[a-zA-Z_0-9]+)\s*;\s*$")
+    section_begin_regex = re.compile(
+        r"\s*(?P<version>[a-zA-Z0-9_\.]+)\s*{\s*$")
+    section_end_regex = re.compile(
+        r"\s*}\s*(?P<parent>[a-zA-Z0-9_\.]+)?\s*;\s*$")
+
+    # for stable ABI, we don't care about which version introduced which
+    # function, we just flatten the list. there are dupes in certain files, so
+    # use a set instead of a list
+    stable_lines = set()
+    # copy experimental section as is
+    experimental_lines = []
+    is_experimental = False
+
+    # gather all functions
+    for line in f_in:
+        # clean up the line
+        line = line.strip('\n').strip()
+
+        # is this an end of section?
+        match = section_end_regex.match(line)
+        if match:
+            # whatever section this was, it's not active any more
+            is_experimental = False
+            continue
+
+        # if we're in the middle of experimental section, we need to copy
+        # the section verbatim, so just add the line
+        if is_experimental:
+            experimental_lines += [line]
+            continue
+
+        # skip empty lines
+        if not line:
+            continue
+
+        # is this a beginning of a new section?
+        match = section_begin_regex.match(line)
+        if match:
+            cur_section = match.group("version")
+            # is it experimental?
+            is_experimental = cur_section == "EXPERIMENTAL"
+            continue
+
+        # is this a function?
+        match = func_line_regex.match(line)
+        if match:
+            stable_lines.add(match.group("func"))
+
+    return stable_lines, experimental_lines
+
+
+def __regenerate_map_file(f_out, abi_version, stable_lines,
+                          experimental_lines):
+    # print ABI version header
+    print("DPDK_{} {{".format(abi_version), file=f_out)
+
+    if stable_lines:
+        # print global section
+        print("\tglobal:", file=f_out)
+        # blank line
+        print(file=f_out)
+
+        # print all stable lines, alphabetically sorted
+        for line in sorted(stable_lines):
+            print("\t{};".format(line), file=f_out)
+
+        # another blank line
+        print(file=f_out)
+
+    # print local section
+    print("\tlocal: *;", file=f_out)
+
+    # end stable version
+    print("};", file=f_out)
+
+    # do we have experimental lines?
+    if not experimental_lines:
+        return
+
+    # another blank line
+    print(file=f_out)
+
+    # start experimental section
+    print("EXPERIMENTAL {", file=f_out)
+
+    # print all experimental lines as they were
+    for line in experimental_lines:
+        # don't print empty whitespace
+        if not line:
+            print("", file=f_out)
+        else:
+            print("\t{}".format(line), file=f_out)
+
+    # end section
+    print("};", file=f_out)
+
+
+def __main():
+    arg_parser = argparse.ArgumentParser(
+        description='Merge versions in linker version script.')
+
+    arg_parser.add_argument("map_file", type=str,
+                            help='path to linker version script file '
+                                 '(pattern: *version.map)')
+    arg_parser.add_argument("abi_version", type=str,
+                            help='target ABI version (pattern: MAJOR.MINOR)')
+
+    parsed = arg_parser.parse_args()
+
+    if not parsed.map_file.endswith('version.map'):
+        print("Invalid input file: {}".format(parsed.map_file),
+              file=sys.stderr)
+        arg_parser.print_help()
+        sys.exit(1)
+
+    if not re.match(r"\d{1,2}\.\d{1,2}", parsed.abi_version):
+        print("Invalid ABI version: {}".format(parsed.abi_version),
+              file=sys.stderr)
+        arg_parser.print_help()
+        sys.exit(1)
+
+    with open(parsed.map_file) as f_in:
+        stable_lines, experimental_lines = __parse_map_file(f_in)
+
+    with open(parsed.map_file, 'w') as f_out:
+        __regenerate_map_file(f_out, parsed.abi_version, stable_lines,
+                              experimental_lines)
+
+
+if __name__ == "__main__":
+    __main()
Signature · 1 line
2.17.1
#13 lore raw

Re: [dpdk-dev] [PATCH v2 02/10] buildtools: add script for updating symbols abi version

Quoted 36 lines · Anatoly Burakov

From: Pawel Modrak <[email protected]>

Add a script that automatically merges all stable ABI's under one ABI section with the new version, while leaving experimental section exactly as it is.

---

Notes:
v2:
- Reworked script to be pep8-compliant and more reliable

 buildtools/update_version_map_abi.py | 148 +++++++++++++++++++++++++++
 1 file changed, 148 insertions(+)
 create mode 100755 buildtools/update_version_map_abi.py
buildtools/update_version_map_abi.py new file +12 -0
new file mode 100755
index 0000000000..ea9044cc81
@@ -0,0 +1,148 @@
+#!/usr/bin/env python
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+"""
+A Python program to update the ABI version and function names in a DPDK
+lib_*_version.map file. Called from the buildtools/update_abi.sh utility.
+"""
+
+from __future__ import print_function
+import argparse
+import sys

buildtools/update_version_map_abi.py line 22

Quoted 10 lines
buildtools/update_version_map_abi.py new file +10 -0
+import re
+
+
+def __parse_map_file(f_in):
+    func_line_regex = re.compile(r"\s*(?P<func>[a-zA-Z_0-9]+)\s*;\s*$")
+    section_begin_regex = re.compile(
+        r"\s*(?P<version>[a-zA-Z0-9_\.]+)\s*{\s*$")
+    section_end_regex = re.compile(
+        r"\s*}\s*(?P<parent>[a-zA-Z0-9_\.]+)?\s*;\s*$")
+

To help readers of the code, can you put in a line or two of comment explaining each regex a bit above.

#14 lore raw

PATCH v2 3/10 buildtools: add ABI update shell script

In reply to Anatoly Burakov

In order to facilitate mass updating of version files, add a shell script that recurses into lib/ and drivers/ directories and calls the ABI version update script.

---

Notes:
v2:
- Add this patch to split the shell script from previous commit
- Fixup miscellaneous bugs

 buildtools/update-abi.sh | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100755 buildtools/update-abi.sh
buildtools/update-abi.sh new file +36 -0
new file mode 100755
index 0000000000..a6f916a437
@@ -0,0 +1,36 @@
+#!/bin/bash
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+abi_version=""
+abi_version_file="./config/ABI_VERSION"
+update_path="lib drivers"
+
+if [ -z "$1" ]
+then
+      # output to stderr
+      >&2 echo "provide ABI version"
+      exit 1
+fi
+
+abi_version=$1
+
+if [ -n "$2" ]
+then
+      abi_version_file=$2
+fi
+
+if [ -n "$3" ]
+then
+      update_path=${@:3}
+fi
+
+echo "New ABI version:" $abi_version
+echo "ABI_VERSION path:" $abi_version_file
+echo "Path to update:" $update_path
+
+echo $abi_version > $abi_version_file
+
+find $update_path -name  \*version.map -exec \
+      ./buildtools/update_version_map_abi.py {} \
+      $abi_version \; -print
Signature · 1 line
2.17.1
#15 lore raw

Re: [dpdk-dev] [PATCH v2 03/10] buildtools: add ABI update shell script

Quoted 22 lines · Anatoly Burakov

In order to facilitate mass updating of version files, add a shell script that recurses into lib/ and drivers/ directories and calls the ABI version update script.

---

Notes:
v2:
- Add this patch to split the shell script from previous commit
- Fixup miscellaneous bugs

 buildtools/update-abi.sh | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100755 buildtools/update-abi.sh
buildtools/update-abi.sh new file +0 -0
new file mode 100755
index 0000000000..a6f916a437

buildtools/update-abi.sh line 1

Quoted 1 line
buildtools/update-abi.sh new file +1 -0
@@ -0,0 +1,36 @@
+#!/bin/bash

Does this actually need to be bash? Most of our scripts use plain "sh". Also on FreeBSD bash is generally in /usr/local/bin not /bin.

buildtools/update-abi.sh line 10

Quoted 9 lines
buildtools/update-abi.sh new file +9 -0
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+abi_version=""
+abi_version_file="./config/ABI_VERSION"
+update_path="lib drivers"
+
+if [ -z "$1" ]
+then

While there are a few scripts in DPDK putting the "then" on the next line most scripts put it on the same line as the "if", after a ";".

buildtools/update-abi.sh line 16

Quoted 6 lines
buildtools/update-abi.sh new file +6 -0
+      # output to stderr
+      >&2 echo "provide ABI version"
+      exit 1
+fi
+
+abi_version=$1

I think you can just do this assignment at the top when you define abi_version in the first place. Using $1 when it doesn't exist isn't a problem.

buildtools/update-abi.sh line 25

Quoted 9 lines
buildtools/update-abi.sh new file +9 -0
+
+if [ -n "$2" ]
+then
+      abi_version_file=$2
+fi
+
+if [ -n "$3" ]
+then
+      update_path=${@:3}

I think this might be a bash-ism, right? If so, I think using "shift" and then directly using $@ should work instead to make it sh-compatible..

buildtools/update-abi.sh line 32

Quoted 7 lines
buildtools/update-abi.sh new file +7 -0
+fi
+
+echo "New ABI version:" $abi_version
+echo "ABI_VERSION path:" $abi_version_file
+echo "Path to update:" $update_path
+
+echo $abi_version > $abi_version_file

Do we need to check the abi_version provided is in the correct format? Should it have both major and minor components, or just major. I think the former, so we can do minor bumps which keeping major compatibility.

Quoted 6 lines
buildtools/update-abi.sh new file +4 -0
+
+find $update_path -name  \*version.map -exec \
+      ./buildtools/update_version_map_abi.py {} \
+      $abi_version \; -print
Signature · 1 line
2.17.1
#16 lore raw

PATCH v2 4/10 timer: remove deprecated code

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v2:
- Moved this to before ABI version bump to avoid compile breakage

 lib/librte_timer/rte_timer.c | 90 ++----------------------------------
 lib/librte_timer/rte_timer.h | 15 ------
 2 files changed, 5 insertions(+), 100 deletions(-)
lib/librte_timer/rte_timer.c +5 -85
index bdcf05d06b..de6959b809 100644
@@ -68,9 +68,6 @@ static struct rte_timer_data *rte_timer_data_arr;
 static const uint32_t default_data_id;
 static uint32_t rte_timer_subsystem_initialized;
 
-/* For maintaining older interfaces for a period */
-static struct rte_timer_data default_timer_data;
-
 /* when debug is enabled, store some statistics */
 #ifdef RTE_LIBRTE_TIMER_DEBUG
 #define __TIMER_STAT_ADD(priv_timer, name, n) do {			\
@@ -131,22 +128,6 @@ rte_timer_data_dealloc(uint32_t id)
 	return 0;
 }
 
-void
-rte_timer_subsystem_init_v20(void)
-{
-	unsigned lcore_id;
-	struct priv_timer *priv_timer = default_timer_data.priv_timer;
-
-	/* since priv_timer is static, it's zeroed by default, so only init some
-	 * fields.
-	 */
-	for (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id ++) {
-		rte_spinlock_init(&priv_timer[lcore_id].list_lock);
-		priv_timer[lcore_id].prev_lcore = lcore_id;
-	}
-}
-VERSION_SYMBOL(rte_timer_subsystem_init, _v20, 2.0);
-
 /* Init the timer library. Allocate an array of timer data structs in shared
  * memory, and allocate the zeroth entry for use with original timer
  * APIs. Since the intersection of the sets of lcore ids in primary and
@@ -154,7 +135,7 @@ VERSION_SYMBOL(rte_timer_subsystem_init, _v20, 2.0);
  * multiple processes.
  */
 int
-rte_timer_subsystem_init_v1905(void)
+rte_timer_subsystem_init(void)
 {
 	const struct rte_memzone *mz;
 	struct rte_timer_data *data;
@@ -209,9 +190,6 @@ rte_timer_subsystem_init_v1905(void)
 
 	return 0;
 }
-MAP_STATIC_SYMBOL(int rte_timer_subsystem_init(void),
-		  rte_timer_subsystem_init_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_subsystem_init, _v1905, 19.05);
 
 void
 rte_timer_subsystem_finalize(void)
@@ -552,42 +530,13 @@ __rte_timer_reset(struct rte_timer *tim, uint64_t expire,
 
 /* Reset and start the timer associated with the timer handle tim */
 int
-rte_timer_reset_v20(struct rte_timer *tim, uint64_t ticks,
-		    enum rte_timer_type type, unsigned int tim_lcore,
-		    rte_timer_cb_t fct, void *arg)
-{
-	uint64_t cur_time = rte_get_timer_cycles();
-	uint64_t period;
-
-	if (unlikely((tim_lcore != (unsigned)LCORE_ID_ANY) &&
-			!(rte_lcore_is_enabled(tim_lcore) ||
-			  rte_lcore_has_role(tim_lcore, ROLE_SERVICE))))
-		return -1;
-
-	if (type == PERIODICAL)
-		period = ticks;
-	else
-		period = 0;
-
-	return __rte_timer_reset(tim,  cur_time + ticks, period, tim_lcore,
-			  fct, arg, 0, &default_timer_data);
-}
-VERSION_SYMBOL(rte_timer_reset, _v20, 2.0);
-
-int
-rte_timer_reset_v1905(struct rte_timer *tim, uint64_t ticks,
+rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
 		      enum rte_timer_type type, unsigned int tim_lcore,
 		      rte_timer_cb_t fct, void *arg)
 {
 	return rte_timer_alt_reset(default_data_id, tim, ticks, type,
 				   tim_lcore, fct, arg);
 }
-MAP_STATIC_SYMBOL(int rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
-				      enum rte_timer_type type,
-				      unsigned int tim_lcore,
-				      rte_timer_cb_t fct, void *arg),
-		  rte_timer_reset_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_reset, _v1905, 19.05);
 
 int
 rte_timer_alt_reset(uint32_t timer_data_id, struct rte_timer *tim,
@@ -658,20 +607,10 @@ __rte_timer_stop(struct rte_timer *tim, int local_is_locked,
 
 /* Stop the timer associated with the timer handle tim */
 int
-rte_timer_stop_v20(struct rte_timer *tim)
-{
-	return __rte_timer_stop(tim, 0, &default_timer_data);
-}
-VERSION_SYMBOL(rte_timer_stop, _v20, 2.0);
-
-int
-rte_timer_stop_v1905(struct rte_timer *tim)
+rte_timer_stop(struct rte_timer *tim)
 {
 	return rte_timer_alt_stop(default_data_id, tim);
 }
-MAP_STATIC_SYMBOL(int rte_timer_stop(struct rte_timer *tim),
-		  rte_timer_stop_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_stop, _v1905, 19.05);
 
 int
 rte_timer_alt_stop(uint32_t timer_data_id, struct rte_timer *tim)
@@ -817,15 +756,8 @@ __rte_timer_manage(struct rte_timer_data *timer_data)
 	priv_timer[lcore_id].running_tim = NULL;
 }
 
-void
-rte_timer_manage_v20(void)
-{
-	__rte_timer_manage(&default_timer_data);
-}
-VERSION_SYMBOL(rte_timer_manage, _v20, 2.0);
-
 int
-rte_timer_manage_v1905(void)
+rte_timer_manage(void)
 {
 	struct rte_timer_data *timer_data;
 
@@ -835,8 +767,6 @@ rte_timer_manage_v1905(void)
 
 	return 0;
 }
-MAP_STATIC_SYMBOL(int rte_timer_manage(void), rte_timer_manage_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_manage, _v1905, 19.05);
 
 int
 rte_timer_alt_manage(uint32_t timer_data_id,
@@ -1074,21 +1004,11 @@ __rte_timer_dump_stats(struct rte_timer_data *timer_data __rte_unused, FILE *f)
 #endif
 }
 
-void
-rte_timer_dump_stats_v20(FILE *f)
-{
-	__rte_timer_dump_stats(&default_timer_data, f);
-}
-VERSION_SYMBOL(rte_timer_dump_stats, _v20, 2.0);
-
 int
-rte_timer_dump_stats_v1905(FILE *f)
+rte_timer_dump_stats(FILE *f)
 {
 	return rte_timer_alt_dump_stats(default_data_id, f);
 }
-MAP_STATIC_SYMBOL(int rte_timer_dump_stats(FILE *f),
-		  rte_timer_dump_stats_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_dump_stats, _v1905, 19.05);
 
 int
 rte_timer_alt_dump_stats(uint32_t timer_data_id __rte_unused, FILE *f)
lib/librte_timer/rte_timer.h +0 -15
index 05d287d8f2..9dc5fc3092 100644
@@ -181,8 +181,6 @@ int rte_timer_data_dealloc(uint32_t id);
  *      subsystem
  */
 int rte_timer_subsystem_init(void);
-int rte_timer_subsystem_init_v1905(void);
-void rte_timer_subsystem_init_v20(void);
 
 /**
  * @warning
@@ -250,13 +248,6 @@ void rte_timer_init(struct rte_timer *tim);
 int rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
 		    enum rte_timer_type type, unsigned tim_lcore,
 		    rte_timer_cb_t fct, void *arg);
-int rte_timer_reset_v1905(struct rte_timer *tim, uint64_t ticks,
-			  enum rte_timer_type type, unsigned int tim_lcore,
-			  rte_timer_cb_t fct, void *arg);
-int rte_timer_reset_v20(struct rte_timer *tim, uint64_t ticks,
-			enum rte_timer_type type, unsigned int tim_lcore,
-			rte_timer_cb_t fct, void *arg);
-
 
 /**
  * Loop until rte_timer_reset() succeeds.
@@ -313,8 +304,6 @@ rte_timer_reset_sync(struct rte_timer *tim, uint64_t ticks,
  *   - (-1): The timer is in the RUNNING or CONFIG state.
  */
 int rte_timer_stop(struct rte_timer *tim);
-int rte_timer_stop_v1905(struct rte_timer *tim);
-int rte_timer_stop_v20(struct rte_timer *tim);
 
 /**
  * Loop until rte_timer_stop() succeeds.
@@ -358,8 +347,6 @@ int rte_timer_pending(struct rte_timer *tim);
  *   - -EINVAL: timer subsystem not yet initialized
  */
 int rte_timer_manage(void);
-int rte_timer_manage_v1905(void);
-void rte_timer_manage_v20(void);
 
 /**
  * Dump statistics about timers.
@@ -371,8 +358,6 @@ void rte_timer_manage_v20(void);
  *   - -EINVAL: timer subsystem not yet initialized
  */
 int rte_timer_dump_stats(FILE *f);
-int rte_timer_dump_stats_v1905(FILE *f);
-void rte_timer_dump_stats_v20(FILE *f);
 
 /**
  * @warning
Signature · 1 line
2.17.1
#17 lore raw

PATCH v2 5/10 lpm: remove deprecated code

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v2:
- Moved this to before ABI version bump to avoid compile breakage

 lib/librte_lpm/rte_lpm.c  | 996 ++------------------------------------
 lib/librte_lpm/rte_lpm.h  |  88 ----
 lib/librte_lpm/rte_lpm6.c | 132 +----
 lib/librte_lpm/rte_lpm6.h |  25 -
 4 files changed, 48 insertions(+), 1193 deletions(-)
lib/librte_lpm/rte_lpm.c +34 -962
index 3a929a1b16..2687564194 100644
@@ -89,34 +89,8 @@ depth_to_range(uint8_t depth)
 /*
  * Find an existing lpm table and return a pointer to it.
  */
-struct rte_lpm_v20 *
-rte_lpm_find_existing_v20(const char *name)
-{
-	struct rte_lpm_v20 *l = NULL;
-	struct rte_tailq_entry *te;
-	struct rte_lpm_list *lpm_list;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	rte_mcfg_tailq_read_lock();
-	TAILQ_FOREACH(te, lpm_list, next) {
-		l = te->data;
-		if (strncmp(name, l->name, RTE_LPM_NAMESIZE) == 0)
-			break;
-	}
-	rte_mcfg_tailq_read_unlock();
-
-	if (te == NULL) {
-		rte_errno = ENOENT;
-		return NULL;
-	}
-
-	return l;
-}
-VERSION_SYMBOL(rte_lpm_find_existing, _v20, 2.0);
-
 struct rte_lpm *
-rte_lpm_find_existing_v1604(const char *name)
+rte_lpm_find_existing(const char *name)
 {
 	struct rte_lpm *l = NULL;
 	struct rte_tailq_entry *te;
@@ -139,88 +113,12 @@ rte_lpm_find_existing_v1604(const char *name)
 
 	return l;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_find_existing, _v1604, 16.04);
-MAP_STATIC_SYMBOL(struct rte_lpm *rte_lpm_find_existing(const char *name),
-		rte_lpm_find_existing_v1604);
 
 /*
  * Allocates memory for LPM object
  */
-struct rte_lpm_v20 *
-rte_lpm_create_v20(const char *name, int socket_id, int max_rules,
-		__rte_unused int flags)
-{
-	char mem_name[RTE_LPM_NAMESIZE];
-	struct rte_lpm_v20 *lpm = NULL;
-	struct rte_tailq_entry *te;
-	uint32_t mem_size;
-	struct rte_lpm_list *lpm_list;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	RTE_BUILD_BUG_ON(sizeof(struct rte_lpm_tbl_entry_v20) != 2);
-
-	/* Check user arguments. */
-	if ((name == NULL) || (socket_id < -1) || (max_rules == 0)) {
-		rte_errno = EINVAL;
-		return NULL;
-	}
-
-	snprintf(mem_name, sizeof(mem_name), "LPM_%s", name);
-
-	/* Determine the amount of memory to allocate. */
-	mem_size = sizeof(*lpm) + (sizeof(lpm->rules_tbl[0]) * max_rules);
-
-	rte_mcfg_tailq_write_lock();
-
-	/* guarantee there's no existing */
-	TAILQ_FOREACH(te, lpm_list, next) {
-		lpm = te->data;
-		if (strncmp(name, lpm->name, RTE_LPM_NAMESIZE) == 0)
-			break;
-	}
-
-	if (te != NULL) {
-		lpm = NULL;
-		rte_errno = EEXIST;
-		goto exit;
-	}
-
-	/* allocate tailq entry */
-	te = rte_zmalloc("LPM_TAILQ_ENTRY", sizeof(*te), 0);
-	if (te == NULL) {
-		RTE_LOG(ERR, LPM, "Failed to allocate tailq entry\n");
-		rte_errno = ENOMEM;
-		goto exit;
-	}
-
-	/* Allocate memory to store the LPM data structures. */
-	lpm = rte_zmalloc_socket(mem_name, mem_size,
-			RTE_CACHE_LINE_SIZE, socket_id);
-	if (lpm == NULL) {
-		RTE_LOG(ERR, LPM, "LPM memory allocation failed\n");
-		rte_free(te);
-		rte_errno = ENOMEM;
-		goto exit;
-	}
-
-	/* Save user arguments. */
-	lpm->max_rules = max_rules;
-	strlcpy(lpm->name, name, sizeof(lpm->name));
-
-	te->data = lpm;
-
-	TAILQ_INSERT_TAIL(lpm_list, te, next);
-
-exit:
-	rte_mcfg_tailq_write_unlock();
-
-	return lpm;
-}
-VERSION_SYMBOL(rte_lpm_create, _v20, 2.0);
-
 struct rte_lpm *
-rte_lpm_create_v1604(const char *name, int socket_id,
+rte_lpm_create(const char *name, int socket_id,
 		const struct rte_lpm_config *config)
 {
 	char mem_name[RTE_LPM_NAMESIZE];
@@ -320,45 +218,12 @@ rte_lpm_create_v1604(const char *name, int socket_id,
 
 	return lpm;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_create, _v1604, 16.04);
-MAP_STATIC_SYMBOL(
-	struct rte_lpm *rte_lpm_create(const char *name, int socket_id,
-			const struct rte_lpm_config *config), rte_lpm_create_v1604);
 
 /*
  * Deallocates memory for given LPM table.
  */
 void
-rte_lpm_free_v20(struct rte_lpm_v20 *lpm)
-{
-	struct rte_lpm_list *lpm_list;
-	struct rte_tailq_entry *te;
-
-	/* Check user arguments. */
-	if (lpm == NULL)
-		return;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	rte_mcfg_tailq_write_lock();
-
-	/* find our tailq entry */
-	TAILQ_FOREACH(te, lpm_list, next) {
-		if (te->data == (void *) lpm)
-			break;
-	}
-	if (te != NULL)
-		TAILQ_REMOVE(lpm_list, te, next);
-
-	rte_mcfg_tailq_write_unlock();
-
-	rte_free(lpm);
-	rte_free(te);
-}
-VERSION_SYMBOL(rte_lpm_free, _v20, 2.0);
-
-void
-rte_lpm_free_v1604(struct rte_lpm *lpm)
+rte_lpm_free(struct rte_lpm *lpm)
 {
 	struct rte_lpm_list *lpm_list;
 	struct rte_tailq_entry *te;
@@ -386,9 +251,6 @@ rte_lpm_free_v1604(struct rte_lpm *lpm)
 	rte_free(lpm);
 	rte_free(te);
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_free, _v1604, 16.04);
-MAP_STATIC_SYMBOL(void rte_lpm_free(struct rte_lpm *lpm),
-		rte_lpm_free_v1604);
 
 /*
  * Adds a rule to the rule table.
@@ -401,79 +263,7 @@ MAP_STATIC_SYMBOL(void rte_lpm_free(struct rte_lpm *lpm),
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static int32_t
-rule_add_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth,
-	uint8_t next_hop)
-{
-	uint32_t rule_gindex, rule_index, last_rule;
-	int i;
-
-	VERIFY_DEPTH(depth);
-
-	/* Scan through rule group to see if rule already exists. */
-	if (lpm->rule_info[depth - 1].used_rules > 0) {
-
-		/* rule_gindex stands for rule group index. */
-		rule_gindex = lpm->rule_info[depth - 1].first_rule;
-		/* Initialise rule_index to point to start of rule group. */
-		rule_index = rule_gindex;
-		/* Last rule = Last used rule in this rule group. */
-		last_rule = rule_gindex + lpm->rule_info[depth - 1].used_rules;
-
-		for (; rule_index < last_rule; rule_index++) {
-
-			/* If rule already exists update its next_hop and return. */
-			if (lpm->rules_tbl[rule_index].ip == ip_masked) {
-				lpm->rules_tbl[rule_index].next_hop = next_hop;
-
-				return rule_index;
-			}
-		}
-
-		if (rule_index == lpm->max_rules)
-			return -ENOSPC;
-	} else {
-		/* Calculate the position in which the rule will be stored. */
-		rule_index = 0;
-
-		for (i = depth - 1; i > 0; i--) {
-			if (lpm->rule_info[i - 1].used_rules > 0) {
-				rule_index = lpm->rule_info[i - 1].first_rule
-						+ lpm->rule_info[i - 1].used_rules;
-				break;
-			}
-		}
-		if (rule_index == lpm->max_rules)
-			return -ENOSPC;
-
-		lpm->rule_info[depth - 1].first_rule = rule_index;
-	}
-
-	/* Make room for the new rule in the array. */
-	for (i = RTE_LPM_MAX_DEPTH; i > depth; i--) {
-		if (lpm->rule_info[i - 1].first_rule
-				+ lpm->rule_info[i - 1].used_rules == lpm->max_rules)
-			return -ENOSPC;
-
-		if (lpm->rule_info[i - 1].used_rules > 0) {
-			lpm->rules_tbl[lpm->rule_info[i - 1].first_rule
-				+ lpm->rule_info[i - 1].used_rules]
-					= lpm->rules_tbl[lpm->rule_info[i - 1].first_rule];
-			lpm->rule_info[i - 1].first_rule++;
-		}
-	}
-
-	/* Add the new rule. */
-	lpm->rules_tbl[rule_index].ip = ip_masked;
-	lpm->rules_tbl[rule_index].next_hop = next_hop;
-
-	/* Increment the used rules counter for this rule group. */
-	lpm->rule_info[depth - 1].used_rules++;
-
-	return rule_index;
-}
-
-static int32_t
-rule_add_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
+rule_add(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 	uint32_t next_hop)
 {
 	uint32_t rule_gindex, rule_index, last_rule;
@@ -549,30 +339,7 @@ rule_add_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static void
-rule_delete_v20(struct rte_lpm_v20 *lpm, int32_t rule_index, uint8_t depth)
-{
-	int i;
-
-	VERIFY_DEPTH(depth);
-
-	lpm->rules_tbl[rule_index] =
-			lpm->rules_tbl[lpm->rule_info[depth - 1].first_rule
-				+ lpm->rule_info[depth - 1].used_rules - 1];
-
-	for (i = depth; i < RTE_LPM_MAX_DEPTH; i++) {
-		if (lpm->rule_info[i].used_rules > 0) {
-			lpm->rules_tbl[lpm->rule_info[i].first_rule - 1] =
-				lpm->rules_tbl[lpm->rule_info[i].first_rule
-					+ lpm->rule_info[i].used_rules - 1];
-			lpm->rule_info[i].first_rule--;
-		}
-	}
-
-	lpm->rule_info[depth - 1].used_rules--;
-}
-
-static void
-rule_delete_v1604(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
+rule_delete(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
 {
 	int i;
 
@@ -599,28 +366,7 @@ rule_delete_v1604(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static int32_t
-rule_find_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth)
-{
-	uint32_t rule_gindex, last_rule, rule_index;
-
-	VERIFY_DEPTH(depth);
-
-	rule_gindex = lpm->rule_info[depth - 1].first_rule;
-	last_rule = rule_gindex + lpm->rule_info[depth - 1].used_rules;
-
-	/* Scan used rules at given depth to find rule. */
-	for (rule_index = rule_gindex; rule_index < last_rule; rule_index++) {
-		/* If rule is found return the rule index. */
-		if (lpm->rules_tbl[rule_index].ip == ip_masked)
-			return rule_index;
-	}
-
-	/* If rule is not found return -EINVAL. */
-	return -EINVAL;
-}
-
-static int32_t
-rule_find_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
+rule_find(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
 {
 	uint32_t rule_gindex, last_rule, rule_index;
 
@@ -644,42 +390,7 @@ rule_find_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
  * Find, clean and allocate a tbl8.
  */
 static int32_t
-tbl8_alloc_v20(struct rte_lpm_tbl_entry_v20 *tbl8)
-{
-	uint32_t group_idx; /* tbl8 group index. */
-	struct rte_lpm_tbl_entry_v20 *tbl8_entry;
-
-	/* Scan through tbl8 to find a free (i.e. INVALID) tbl8 group. */
-	for (group_idx = 0; group_idx < RTE_LPM_TBL8_NUM_GROUPS;
-			group_idx++) {
-		tbl8_entry = &tbl8[group_idx * RTE_LPM_TBL8_GROUP_NUM_ENTRIES];
-		/* If a free tbl8 group is found clean it and set as VALID. */
-		if (!tbl8_entry->valid_group) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = INVALID,
-				.depth = 0,
-				.valid_group = VALID,
-			};
-			new_tbl8_entry.next_hop = 0;
-
-			memset(&tbl8_entry[0], 0,
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES *
-					sizeof(tbl8_entry[0]));
-
-			__atomic_store(tbl8_entry, &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-
-			/* Return group index for allocated tbl8 group. */
-			return group_idx;
-		}
-	}
-
-	/* If there are no tbl8 groups free then return error. */
-	return -ENOSPC;
-}
-
-static int32_t
-tbl8_alloc_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
+tbl8_alloc(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
 {
 	uint32_t group_idx; /* tbl8 group index. */
 	struct rte_lpm_tbl_entry *tbl8_entry;
@@ -713,22 +424,7 @@ tbl8_alloc_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
 }
 
 static void
-tbl8_free_v20(struct rte_lpm_tbl_entry_v20 *tbl8, uint32_t tbl8_group_start)
-{
-	/* Set tbl8 group invalid*/
-	struct rte_lpm_tbl_entry_v20 zero_tbl8_entry = {
-		.valid = INVALID,
-		.depth = 0,
-		.valid_group = INVALID,
-	};
-	zero_tbl8_entry.next_hop = 0;
-
-	__atomic_store(&tbl8[tbl8_group_start], &zero_tbl8_entry,
-			__ATOMIC_RELAXED);
-}
-
-static void
-tbl8_free_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
+tbl8_free(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
 {
 	/* Set tbl8 group invalid*/
 	struct rte_lpm_tbl_entry zero_tbl8_entry = {0};
@@ -738,78 +434,7 @@ tbl8_free_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
 }
 
 static __rte_noinline int32_t
-add_depth_small_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-		uint8_t next_hop)
-{
-	uint32_t tbl24_index, tbl24_range, tbl8_index, tbl8_group_end, i, j;
-
-	/* Calculate the index into Table24. */
-	tbl24_index = ip >> 8;
-	tbl24_range = depth_to_range(depth);
-
-	for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-		/*
-		 * For invalid OR valid and non-extended tbl 24 entries set
-		 * entry.
-		 */
-		if (!lpm->tbl24[i].valid || (lpm->tbl24[i].valid_group == 0 &&
-				lpm->tbl24[i].depth <= depth)) {
-
-			struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-				.valid = VALID,
-				.valid_group = 0,
-				.depth = depth,
-			};
-			new_tbl24_entry.next_hop = next_hop;
-
-			/* Setting tbl24 entry in one go to avoid race
-			 * conditions
-			 */
-			__atomic_store(&lpm->tbl24[i], &new_tbl24_entry,
-					__ATOMIC_RELEASE);
-
-			continue;
-		}
-
-		if (lpm->tbl24[i].valid_group == 1) {
-			/* If tbl24 entry is valid and extended calculate the
-			 *  index into tbl8.
-			 */
-			tbl8_index = lpm->tbl24[i].group_idx *
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-			tbl8_group_end = tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-			for (j = tbl8_index; j < tbl8_group_end; j++) {
-				if (!lpm->tbl8[j].valid ||
-						lpm->tbl8[j].depth <= depth) {
-					struct rte_lpm_tbl_entry_v20
-						new_tbl8_entry = {
-						.valid = VALID,
-						.valid_group = VALID,
-						.depth = depth,
-					};
-					new_tbl8_entry.next_hop = next_hop;
-
-					/*
-					 * Setting tbl8 entry in one go to avoid
-					 * race conditions
-					 */
-					__atomic_store(&lpm->tbl8[j],
-						&new_tbl8_entry,
-						__ATOMIC_RELAXED);
-
-					continue;
-				}
-			}
-		}
-	}
-
-	return 0;
-}
-
-static __rte_noinline int32_t
-add_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+add_depth_small(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint32_t next_hop)
 {
 #define group_idx next_hop
@@ -881,150 +506,7 @@ add_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 }
 
 static __rte_noinline int32_t
-add_depth_big_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth,
-		uint8_t next_hop)
-{
-	uint32_t tbl24_index;
-	int32_t tbl8_group_index, tbl8_group_start, tbl8_group_end, tbl8_index,
-		tbl8_range, i;
-
-	tbl24_index = (ip_masked >> 8);
-	tbl8_range = depth_to_range(depth);
-
-	if (!lpm->tbl24[tbl24_index].valid) {
-		/* Search for a free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v20(lpm->tbl8);
-
-		/* Check tbl8 allocation was successful. */
-		if (tbl8_group_index < 0) {
-			return tbl8_group_index;
-		}
-
-		/* Find index into tbl8 and range. */
-		tbl8_index = (tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES) +
-				(ip_masked & 0xFF);
-
-		/* Set tbl8 entry. */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop = next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		/*
-		 * Update tbl24 entry to point to new tbl8 entry. Note: The
-		 * ext_flag and tbl8_index need to be updated simultaneously,
-		 * so assign whole structure in one go
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.group_idx = (uint8_t)tbl8_group_index,
-			.valid = VALID,
-			.valid_group = 1,
-			.depth = 0,
-		};
-
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELEASE);
-
-	} /* If valid entry but not extended calculate the index into Table8. */
-	else if (lpm->tbl24[tbl24_index].valid_group == 0) {
-		/* Search for free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v20(lpm->tbl8);
-
-		if (tbl8_group_index < 0) {
-			return tbl8_group_index;
-		}
-
-		tbl8_group_start = tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-		tbl8_group_end = tbl8_group_start +
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-		/* Populate new tbl8 with tbl24 value. */
-		for (i = tbl8_group_start; i < tbl8_group_end; i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = lpm->tbl24[tbl24_index].depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop =
-				lpm->tbl24[tbl24_index].next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-
-		/* Insert new rule into the tbl8 entry. */
-		for (i = tbl8_index; i < tbl8_index + tbl8_range; i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop = next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		/*
-		 * Update tbl24 entry to point to new tbl8 entry. Note: The
-		 * ext_flag and tbl8_index need to be updated simultaneously,
-		 * so assign whole structure in one go.
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-				.group_idx = (uint8_t)tbl8_group_index,
-				.valid = VALID,
-				.valid_group = 1,
-				.depth = 0,
-		};
-
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELEASE);
-
-	} else { /*
-		* If it is valid, extended entry calculate the index into tbl8.
-		*/
-		tbl8_group_index = lpm->tbl24[tbl24_index].group_idx;
-		tbl8_group_start = tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-		tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-
-			if (!lpm->tbl8[i].valid ||
-					lpm->tbl8[i].depth <= depth) {
-				struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-					.valid = VALID,
-					.depth = depth,
-					.valid_group = lpm->tbl8[i].valid_group,
-				};
-				new_tbl8_entry.next_hop = next_hop;
-				/*
-				 * Setting tbl8 entry in one go to avoid race
-				 * condition
-				 */
-				__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-						__ATOMIC_RELAXED);
-
-				continue;
-			}
-		}
-	}
-
-	return 0;
-}
-
-static __rte_noinline int32_t
-add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
+add_depth_big(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 		uint32_t next_hop)
 {
 #define group_idx next_hop
@@ -1037,7 +519,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 
 	if (!lpm->tbl24[tbl24_index].valid) {
 		/* Search for a free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v1604(lpm->tbl8, lpm->number_tbl8s);
+		tbl8_group_index = tbl8_alloc(lpm->tbl8, lpm->number_tbl8s);
 
 		/* Check tbl8 allocation was successful. */
 		if (tbl8_group_index < 0) {
@@ -1083,7 +565,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 	} /* If valid entry but not extended calculate the index into Table8. */
 	else if (lpm->tbl24[tbl24_index].valid_group == 0) {
 		/* Search for free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v1604(lpm->tbl8, lpm->number_tbl8s);
+		tbl8_group_index = tbl8_alloc(lpm->tbl8, lpm->number_tbl8s);
 
 		if (tbl8_group_index < 0) {
 			return tbl8_group_index;
@@ -1177,48 +659,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
  * Add a route
  */
 int
-rte_lpm_add_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-		uint8_t next_hop)
-{
-	int32_t rule_index, status = 0;
-	uint32_t ip_masked;
-
-	/* Check user arguments. */
-	if ((lpm == NULL) || (depth < 1) || (depth > RTE_LPM_MAX_DEPTH))
-		return -EINVAL;
-
-	ip_masked = ip & depth_to_mask(depth);
-
-	/* Add the rule to the rule table. */
-	rule_index = rule_add_v20(lpm, ip_masked, depth, next_hop);
-
-	/* If the is no space available for new rule return error. */
-	if (rule_index < 0) {
-		return rule_index;
-	}
-
-	if (depth <= MAX_DEPTH_TBL24) {
-		status = add_depth_small_v20(lpm, ip_masked, depth, next_hop);
-	} else { /* If depth > RTE_LPM_MAX_DEPTH_TBL24 */
-		status = add_depth_big_v20(lpm, ip_masked, depth, next_hop);
-
-		/*
-		 * If add fails due to exhaustion of tbl8 extensions delete
-		 * rule that was added to rule table.
-		 */
-		if (status < 0) {
-			rule_delete_v20(lpm, rule_index, depth);
-
-			return status;
-		}
-	}
-
-	return 0;
-}
-VERSION_SYMBOL(rte_lpm_add, _v20, 2.0);
-
-int
-rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+rte_lpm_add(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint32_t next_hop)
 {
 	int32_t rule_index, status = 0;
@@ -1231,7 +672,7 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 	ip_masked = ip & depth_to_mask(depth);
 
 	/* Add the rule to the rule table. */
-	rule_index = rule_add_v1604(lpm, ip_masked, depth, next_hop);
+	rule_index = rule_add(lpm, ip_masked, depth, next_hop);
 
 	/* If the is no space available for new rule return error. */
 	if (rule_index < 0) {
@@ -1239,16 +680,16 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 	}
 
 	if (depth <= MAX_DEPTH_TBL24) {
-		status = add_depth_small_v1604(lpm, ip_masked, depth, next_hop);
+		status = add_depth_small(lpm, ip_masked, depth, next_hop);
 	} else { /* If depth > RTE_LPM_MAX_DEPTH_TBL24 */
-		status = add_depth_big_v1604(lpm, ip_masked, depth, next_hop);
+		status = add_depth_big(lpm, ip_masked, depth, next_hop);
 
 		/*
 		 * If add fails due to exhaustion of tbl8 extensions delete
 		 * rule that was added to rule table.
 		 */
 		if (status < 0) {
-			rule_delete_v1604(lpm, rule_index, depth);
+			rule_delete(lpm, rule_index, depth);
 
 			return status;
 		}
@@ -1256,42 +697,12 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_add, _v1604, 16.04);
-MAP_STATIC_SYMBOL(int rte_lpm_add(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth, uint32_t next_hop), rte_lpm_add_v1604);
 
 /*
  * Look for a rule in the high-level rules table
  */
 int
-rte_lpm_is_rule_present_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-uint8_t *next_hop)
-{
-	uint32_t ip_masked;
-	int32_t rule_index;
-
-	/* Check user arguments. */
-	if ((lpm == NULL) ||
-		(next_hop == NULL) ||
-		(depth < 1) || (depth > RTE_LPM_MAX_DEPTH))
-		return -EINVAL;
-
-	/* Look for the rule using rule_find. */
-	ip_masked = ip & depth_to_mask(depth);
-	rule_index = rule_find_v20(lpm, ip_masked, depth);
-
-	if (rule_index >= 0) {
-		*next_hop = lpm->rules_tbl[rule_index].next_hop;
-		return 1;
-	}
-
-	/* If rule is not found return 0. */
-	return 0;
-}
-VERSION_SYMBOL(rte_lpm_is_rule_present, _v20, 2.0);
-
-int
-rte_lpm_is_rule_present_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+rte_lpm_is_rule_present(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 uint32_t *next_hop)
 {
 	uint32_t ip_masked;
@@ -1305,7 +716,7 @@ uint32_t *next_hop)
 
 	/* Look for the rule using rule_find. */
 	ip_masked = ip & depth_to_mask(depth);
-	rule_index = rule_find_v1604(lpm, ip_masked, depth);
+	rule_index = rule_find(lpm, ip_masked, depth);
 
 	if (rule_index >= 0) {
 		*next_hop = lpm->rules_tbl[rule_index].next_hop;
@@ -1315,12 +726,9 @@ uint32_t *next_hop)
 	/* If rule is not found return 0. */
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_is_rule_present, _v1604, 16.04);
-MAP_STATIC_SYMBOL(int rte_lpm_is_rule_present(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth, uint32_t *next_hop), rte_lpm_is_rule_present_v1604);
 
 static int32_t
-find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
+find_previous_rule(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint8_t *sub_rule_depth)
 {
 	int32_t rule_index;
@@ -1330,7 +738,7 @@ find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
 	for (prev_depth = (uint8_t)(depth - 1); prev_depth > 0; prev_depth--) {
 		ip_masked = ip & depth_to_mask(prev_depth);
 
-		rule_index = rule_find_v20(lpm, ip_masked, prev_depth);
+		rule_index = rule_find(lpm, ip_masked, prev_depth);
 
 		if (rule_index >= 0) {
 			*sub_rule_depth = prev_depth;
@@ -1342,133 +750,7 @@ find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
 }
 
 static int32_t
-find_previous_rule_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
-		uint8_t *sub_rule_depth)
-{
-	int32_t rule_index;
-	uint32_t ip_masked;
-	uint8_t prev_depth;
-
-	for (prev_depth = (uint8_t)(depth - 1); prev_depth > 0; prev_depth--) {
-		ip_masked = ip & depth_to_mask(prev_depth);
-
-		rule_index = rule_find_v1604(lpm, ip_masked, prev_depth);
-
-		if (rule_index >= 0) {
-			*sub_rule_depth = prev_depth;
-			return rule_index;
-		}
-	}
-
-	return -1;
-}
-
-static int32_t
-delete_depth_small_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked,
-	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
-{
-	uint32_t tbl24_range, tbl24_index, tbl8_group_index, tbl8_index, i, j;
-
-	/* Calculate the range and index into Table24. */
-	tbl24_range = depth_to_range(depth);
-	tbl24_index = (ip_masked >> 8);
-
-	/*
-	 * Firstly check the sub_rule_index. A -1 indicates no replacement rule
-	 * and a positive number indicates a sub_rule_index.
-	 */
-	if (sub_rule_index < 0) {
-		/*
-		 * If no replacement rule exists then invalidate entries
-		 * associated with this rule.
-		 */
-		for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-
-			if (lpm->tbl24[i].valid_group == 0 &&
-					lpm->tbl24[i].depth <= depth) {
-				struct rte_lpm_tbl_entry_v20
-					zero_tbl24_entry = {
-						.valid = INVALID,
-						.depth = 0,
-						.valid_group = 0,
-					};
-					zero_tbl24_entry.next_hop = 0;
-				__atomic_store(&lpm->tbl24[i],
-					&zero_tbl24_entry, __ATOMIC_RELEASE);
-			} else if (lpm->tbl24[i].valid_group == 1) {
-				/*
-				 * If TBL24 entry is extended, then there has
-				 * to be a rule with depth >= 25 in the
-				 * associated TBL8 group.
-				 */
-
-				tbl8_group_index = lpm->tbl24[i].group_idx;
-				tbl8_index = tbl8_group_index *
-						RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-				for (j = tbl8_index; j < (tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES); j++) {
-
-					if (lpm->tbl8[j].depth <= depth)
-						lpm->tbl8[j].valid = INVALID;
-				}
-			}
-		}
-	} else {
-		/*
-		 * If a replacement rule exists then modify entries
-		 * associated with this rule.
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.next_hop = lpm->rules_tbl[sub_rule_index].next_hop,
-			.valid = VALID,
-			.valid_group = 0,
-			.depth = sub_rule_depth,
-		};
-
-		struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-			.valid = VALID,
-			.valid_group = VALID,
-			.depth = sub_rule_depth,
-		};
-		new_tbl8_entry.next_hop =
-				lpm->rules_tbl[sub_rule_index].next_hop;
-
-		for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-
-			if (lpm->tbl24[i].valid_group == 0 &&
-					lpm->tbl24[i].depth <= depth) {
-				__atomic_store(&lpm->tbl24[i], &new_tbl24_entry,
-						__ATOMIC_RELEASE);
-			} else  if (lpm->tbl24[i].valid_group == 1) {
-				/*
-				 * If TBL24 entry is extended, then there has
-				 * to be a rule with depth >= 25 in the
-				 * associated TBL8 group.
-				 */
-
-				tbl8_group_index = lpm->tbl24[i].group_idx;
-				tbl8_index = tbl8_group_index *
-						RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-				for (j = tbl8_index; j < (tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES); j++) {
-
-					if (lpm->tbl8[j].depth <= depth)
-						__atomic_store(&lpm->tbl8[j],
-							&new_tbl8_entry,
-							__ATOMIC_RELAXED);
-				}
-			}
-		}
-	}
-
-	return 0;
-}
-
-static int32_t
-delete_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
+delete_depth_small(struct rte_lpm *lpm, uint32_t ip_masked,
 	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
 {
 #define group_idx next_hop
@@ -1575,7 +857,7 @@ delete_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
  * thus can be recycled
  */
 static int32_t
-tbl8_recycle_check_v20(struct rte_lpm_tbl_entry_v20 *tbl8,
+tbl8_recycle_check(struct rte_lpm_tbl_entry *tbl8,
 		uint32_t tbl8_group_start)
 {
 	uint32_t tbl8_group_end, i;
@@ -1622,140 +904,7 @@ tbl8_recycle_check_v20(struct rte_lpm_tbl_entry_v20 *tbl8,
 }
 
 static int32_t
-tbl8_recycle_check_v1604(struct rte_lpm_tbl_entry *tbl8,
-		uint32_t tbl8_group_start)
-{
-	uint32_t tbl8_group_end, i;
-	tbl8_group_end = tbl8_group_start + RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-	/*
-	 * Check the first entry of the given tbl8. If it is invalid we know
-	 * this tbl8 does not contain any rule with a depth < RTE_LPM_MAX_DEPTH
-	 *  (As they would affect all entries in a tbl8) and thus this table
-	 *  can not be recycled.
-	 */
-	if (tbl8[tbl8_group_start].valid) {
-		/*
-		 * If first entry is valid check if the depth is less than 24
-		 * and if so check the rest of the entries to verify that they
-		 * are all of this depth.
-		 */
-		if (tbl8[tbl8_group_start].depth <= MAX_DEPTH_TBL24) {
-			for (i = (tbl8_group_start + 1); i < tbl8_group_end;
-					i++) {
-
-				if (tbl8[i].depth !=
-						tbl8[tbl8_group_start].depth) {
-
-					return -EEXIST;
-				}
-			}
-			/* If all entries are the same return the tb8 index */
-			return tbl8_group_start;
-		}
-
-		return -EEXIST;
-	}
-	/*
-	 * If the first entry is invalid check if the rest of the entries in
-	 * the tbl8 are invalid.
-	 */
-	for (i = (tbl8_group_start + 1); i < tbl8_group_end; i++) {
-		if (tbl8[i].valid)
-			return -EEXIST;
-	}
-	/* If no valid entries are found then return -EINVAL. */
-	return -EINVAL;
-}
-
-static int32_t
-delete_depth_big_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked,
-	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
-{
-	uint32_t tbl24_index, tbl8_group_index, tbl8_group_start, tbl8_index,
-			tbl8_range, i;
-	int32_t tbl8_recycle_index;
-
-	/*
-	 * Calculate the index into tbl24 and range. Note: All depths larger
-	 * than MAX_DEPTH_TBL24 are associated with only one tbl24 entry.
-	 */
-	tbl24_index = ip_masked >> 8;
-
-	/* Calculate the index into tbl8 and range. */
-	tbl8_group_index = lpm->tbl24[tbl24_index].group_idx;
-	tbl8_group_start = tbl8_group_index * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-	tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-	tbl8_range = depth_to_range(depth);
-
-	if (sub_rule_index < 0) {
-		/*
-		 * Loop through the range of entries on tbl8 for which the
-		 * rule_to_delete must be removed or modified.
-		 */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			if (lpm->tbl8[i].depth <= depth)
-				lpm->tbl8[i].valid = INVALID;
-		}
-	} else {
-		/* Set new tbl8 entry. */
-		struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-			.valid = VALID,
-			.depth = sub_rule_depth,
-			.valid_group = lpm->tbl8[tbl8_group_start].valid_group,
-		};
-
-		new_tbl8_entry.next_hop =
-				lpm->rules_tbl[sub_rule_index].next_hop;
-		/*
-		 * Loop through the range of entries on tbl8 for which the
-		 * rule_to_delete must be modified.
-		 */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			if (lpm->tbl8[i].depth <= depth)
-				__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-						__ATOMIC_RELAXED);
-		}
-	}
-
-	/*
-	 * Check if there are any valid entries in this tbl8 group. If all
-	 * tbl8 entries are invalid we can free the tbl8 and invalidate the
-	 * associated tbl24 entry.
-	 */
-
-	tbl8_recycle_index = tbl8_recycle_check_v20(lpm->tbl8, tbl8_group_start);
-
-	if (tbl8_recycle_index == -EINVAL) {
-		/* Set tbl24 before freeing tbl8 to avoid race condition.
-		 * Prevent the free of the tbl8 group from hoisting.
-		 */
-		lpm->tbl24[tbl24_index].valid = 0;
-		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v20(lpm->tbl8, tbl8_group_start);
-	} else if (tbl8_recycle_index > -1) {
-		/* Update tbl24 entry. */
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.next_hop = lpm->tbl8[tbl8_recycle_index].next_hop,
-			.valid = VALID,
-			.valid_group = 0,
-			.depth = lpm->tbl8[tbl8_recycle_index].depth,
-		};
-
-		/* Set tbl24 before freeing tbl8 to avoid race condition.
-		 * Prevent the free of the tbl8 group from hoisting.
-		 */
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELAXED);
-		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v20(lpm->tbl8, tbl8_group_start);
-	}
-
-	return 0;
-}
-
-static int32_t
-delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
+delete_depth_big(struct rte_lpm *lpm, uint32_t ip_masked,
 	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
 {
 #define group_idx next_hop
@@ -1810,7 +959,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 	 * associated tbl24 entry.
 	 */
 
-	tbl8_recycle_index = tbl8_recycle_check_v1604(lpm->tbl8, tbl8_group_start);
+	tbl8_recycle_index = tbl8_recycle_check(lpm->tbl8, tbl8_group_start);
 
 	if (tbl8_recycle_index == -EINVAL) {
 		/* Set tbl24 before freeing tbl8 to avoid race condition.
@@ -1818,7 +967,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 		 */
 		lpm->tbl24[tbl24_index].valid = 0;
 		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v1604(lpm->tbl8, tbl8_group_start);
+		tbl8_free(lpm->tbl8, tbl8_group_start);
 	} else if (tbl8_recycle_index > -1) {
 		/* Update tbl24 entry. */
 		struct rte_lpm_tbl_entry new_tbl24_entry = {
@@ -1834,7 +983,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
 				__ATOMIC_RELAXED);
 		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v1604(lpm->tbl8, tbl8_group_start);
+		tbl8_free(lpm->tbl8, tbl8_group_start);
 	}
 #undef group_idx
 	return 0;
@@ -1844,7 +993,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
  * Deletes a rule
  */
 int
-rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
+rte_lpm_delete(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
 {
 	int32_t rule_to_delete_index, sub_rule_index;
 	uint32_t ip_masked;
@@ -1863,7 +1012,7 @@ rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
 	 * Find the index of the input rule, that needs to be deleted, in the
 	 * rule table.
 	 */
-	rule_to_delete_index = rule_find_v20(lpm, ip_masked, depth);
+	rule_to_delete_index = rule_find(lpm, ip_masked, depth);
 
 	/*
 	 * Check if rule_to_delete_index was found. If no rule was found the
@@ -1873,7 +1022,7 @@ rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
 		return -EINVAL;
 
 	/* Delete the rule from the rule table. */
-	rule_delete_v20(lpm, rule_to_delete_index, depth);
+	rule_delete(lpm, rule_to_delete_index, depth);
 
 	/*
 	 * Find rule to replace the rule_to_delete. If there is no rule to
@@ -1881,100 +1030,26 @@ rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
 	 * entries associated with this rule.
 	 */
 	sub_rule_depth = 0;
-	sub_rule_index = find_previous_rule_v20(lpm, ip, depth, &sub_rule_depth);
+	sub_rule_index = find_previous_rule(lpm, ip, depth, &sub_rule_depth);
 
 	/*
 	 * If the input depth value is less than 25 use function
 	 * delete_depth_small otherwise use delete_depth_big.
 	 */
 	if (depth <= MAX_DEPTH_TBL24) {
-		return delete_depth_small_v20(lpm, ip_masked, depth,
+		return delete_depth_small(lpm, ip_masked, depth,
 				sub_rule_index, sub_rule_depth);
 	} else { /* If depth > MAX_DEPTH_TBL24 */
-		return delete_depth_big_v20(lpm, ip_masked, depth, sub_rule_index,
+		return delete_depth_big(lpm, ip_masked, depth, sub_rule_index,
 				sub_rule_depth);
 	}
 }
-VERSION_SYMBOL(rte_lpm_delete, _v20, 2.0);
-
-int
-rte_lpm_delete_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
-{
-	int32_t rule_to_delete_index, sub_rule_index;
-	uint32_t ip_masked;
-	uint8_t sub_rule_depth;
-	/*
-	 * Check input arguments. Note: IP must be a positive integer of 32
-	 * bits in length therefore it need not be checked.
-	 */
-	if ((lpm == NULL) || (depth < 1) || (depth > RTE_LPM_MAX_DEPTH)) {
-		return -EINVAL;
-	}
-
-	ip_masked = ip & depth_to_mask(depth);
-
-	/*
-	 * Find the index of the input rule, that needs to be deleted, in the
-	 * rule table.
-	 */
-	rule_to_delete_index = rule_find_v1604(lpm, ip_masked, depth);
-
-	/*
-	 * Check if rule_to_delete_index was found. If no rule was found the
-	 * function rule_find returns -EINVAL.
-	 */
-	if (rule_to_delete_index < 0)
-		return -EINVAL;
-
-	/* Delete the rule from the rule table. */
-	rule_delete_v1604(lpm, rule_to_delete_index, depth);
-
-	/*
-	 * Find rule to replace the rule_to_delete. If there is no rule to
-	 * replace the rule_to_delete we return -1 and invalidate the table
-	 * entries associated with this rule.
-	 */
-	sub_rule_depth = 0;
-	sub_rule_index = find_previous_rule_v1604(lpm, ip, depth, &sub_rule_depth);
-
-	/*
-	 * If the input depth value is less than 25 use function
-	 * delete_depth_small otherwise use delete_depth_big.
-	 */
-	if (depth <= MAX_DEPTH_TBL24) {
-		return delete_depth_small_v1604(lpm, ip_masked, depth,
-				sub_rule_index, sub_rule_depth);
-	} else { /* If depth > MAX_DEPTH_TBL24 */
-		return delete_depth_big_v1604(lpm, ip_masked, depth, sub_rule_index,
-				sub_rule_depth);
-	}
-}
-BIND_DEFAULT_SYMBOL(rte_lpm_delete, _v1604, 16.04);
-MAP_STATIC_SYMBOL(int rte_lpm_delete(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth), rte_lpm_delete_v1604);
 
 /*
  * Delete all rules from the LPM table.
  */
 void
-rte_lpm_delete_all_v20(struct rte_lpm_v20 *lpm)
-{
-	/* Zero rule information. */
-	memset(lpm->rule_info, 0, sizeof(lpm->rule_info));
-
-	/* Zero tbl24. */
-	memset(lpm->tbl24, 0, sizeof(lpm->tbl24));
-
-	/* Zero tbl8. */
-	memset(lpm->tbl8, 0, sizeof(lpm->tbl8));
-
-	/* Delete all rules form the rules table. */
-	memset(lpm->rules_tbl, 0, sizeof(lpm->rules_tbl[0]) * lpm->max_rules);
-}
-VERSION_SYMBOL(rte_lpm_delete_all, _v20, 2.0);
-
-void
-rte_lpm_delete_all_v1604(struct rte_lpm *lpm)
+rte_lpm_delete_all(struct rte_lpm *lpm)
 {
 	/* Zero rule information. */
 	memset(lpm->rule_info, 0, sizeof(lpm->rule_info));
@@ -1989,6 +1064,3 @@ rte_lpm_delete_all_v1604(struct rte_lpm *lpm)
 	/* Delete all rules form the rules table. */
 	memset(lpm->rules_tbl, 0, sizeof(lpm->rules_tbl[0]) * lpm->max_rules);
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_delete_all, _v1604, 16.04);
-MAP_STATIC_SYMBOL(void rte_lpm_delete_all(struct rte_lpm *lpm),
-		rte_lpm_delete_all_v1604);
lib/librte_lpm/rte_lpm.h +0 -88

154 lines not on this page · raw message

lib/librte_lpm/rte_lpm6.c +14 -118

208 lines not on this page · raw message

lib/librte_lpm/rte_lpm6.h +0 -25
index 5d59ccb1fe..37dfb20249 100644
@@ -96,12 +96,6 @@ rte_lpm6_free(struct rte_lpm6 *lpm);
 int
 rte_lpm6_add(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 		uint32_t next_hop);
-int
-rte_lpm6_add_v20(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint8_t next_hop);
-int
-rte_lpm6_add_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint32_t next_hop);
 
 /**
  * Check if a rule is present in the LPM table,
@@ -121,12 +115,6 @@ rte_lpm6_add_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 int
 rte_lpm6_is_rule_present(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 		uint32_t *next_hop);
-int
-rte_lpm6_is_rule_present_v20(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint8_t *next_hop);
-int
-rte_lpm6_is_rule_present_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint32_t *next_hop);
 
 /**
  * Delete a rule from the LPM table.
@@ -184,11 +172,6 @@ rte_lpm6_delete_all(struct rte_lpm6 *lpm);
  */
 int
 rte_lpm6_lookup(const struct rte_lpm6 *lpm, uint8_t *ip, uint32_t *next_hop);
-int
-rte_lpm6_lookup_v20(const struct rte_lpm6 *lpm, uint8_t *ip, uint8_t *next_hop);
-int
-rte_lpm6_lookup_v1705(const struct rte_lpm6 *lpm, uint8_t *ip,
-		uint32_t *next_hop);
 
 /**
  * Lookup multiple IP addresses in an LPM table.
@@ -210,14 +193,6 @@ int
 rte_lpm6_lookup_bulk_func(const struct rte_lpm6 *lpm,
 		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
 		int32_t *next_hops, unsigned int n);
-int
-rte_lpm6_lookup_bulk_func_v20(const struct rte_lpm6 *lpm,
-		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
-		int16_t *next_hops, unsigned int n);
-int
-rte_lpm6_lookup_bulk_func_v1705(const struct rte_lpm6 *lpm,
-		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
-		int32_t *next_hops, unsigned int n);
 
 #ifdef __cplusplus
 }
Signature · 1 line
2.17.1
#18 lore raw

PATCH v2 6/10 distributor: remove deprecated code

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v2:
- Moved this to before ABI version bump to avoid compile breakage

 lib/librte_distributor/rte_distributor.c      | 56 +++--------------
 .../rte_distributor_v1705.h                   | 61 -------------------
 2 files changed, 9 insertions(+), 108 deletions(-)
 delete mode 100644 lib/librte_distributor/rte_distributor_v1705.h
lib/librte_distributor/rte_distributor.c +9 -47
index 21eb1fb0a1..ca3f21b833 100644
@@ -19,7 +19,6 @@
 #include "rte_distributor_private.h"
 #include "rte_distributor.h"
 #include "rte_distributor_v20.h"
-#include "rte_distributor_v1705.h"
 
 TAILQ_HEAD(rte_dist_burst_list, rte_distributor);
 
@@ -33,7 +32,7 @@ EAL_REGISTER_TAILQ(rte_dist_burst_tailq)
 /**** Burst Packet APIs called by workers ****/
 
 void
-rte_distributor_request_pkt_v1705(struct rte_distributor *d,
+rte_distributor_request_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **oldpkt,
 		unsigned int count)
 {
@@ -78,14 +77,9 @@ rte_distributor_request_pkt_v1705(struct rte_distributor *d,
 	 */
 	*retptr64 |= RTE_DISTRIB_GET_BUF;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_request_pkt, _v1705, 17.05);
-MAP_STATIC_SYMBOL(void rte_distributor_request_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **oldpkt,
-		unsigned int count),
-		rte_distributor_request_pkt_v1705);
 
 int
-rte_distributor_poll_pkt_v1705(struct rte_distributor *d,
+rte_distributor_poll_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **pkts)
 {
 	struct rte_distributor_buffer *buf = &d->bufs[worker_id];
@@ -119,13 +113,9 @@ rte_distributor_poll_pkt_v1705(struct rte_distributor *d,
 
 	return count;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_poll_pkt, _v1705, 17.05);
-MAP_STATIC_SYMBOL(int rte_distributor_poll_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **pkts),
-		rte_distributor_poll_pkt_v1705);
 
 int
-rte_distributor_get_pkt_v1705(struct rte_distributor *d,
+rte_distributor_get_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **pkts,
 		struct rte_mbuf **oldpkt, unsigned int return_count)
 {
@@ -153,14 +143,9 @@ rte_distributor_get_pkt_v1705(struct rte_distributor *d,
 	}
 	return count;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_get_pkt, _v1705, 17.05);
-MAP_STATIC_SYMBOL(int rte_distributor_get_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **pkts,
-		struct rte_mbuf **oldpkt, unsigned int return_count),
-		rte_distributor_get_pkt_v1705);
 
 int
-rte_distributor_return_pkt_v1705(struct rte_distributor *d,
+rte_distributor_return_pkt(struct rte_distributor *d,
 		unsigned int worker_id, struct rte_mbuf **oldpkt, int num)
 {
 	struct rte_distributor_buffer *buf = &d->bufs[worker_id];
@@ -187,10 +172,6 @@ rte_distributor_return_pkt_v1705(struct rte_distributor *d,
 
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_return_pkt, _v1705, 17.05);
-MAP_STATIC_SYMBOL(int rte_distributor_return_pkt(struct rte_distributor *d,
-		unsigned int worker_id, struct rte_mbuf **oldpkt, int num),
-		rte_distributor_return_pkt_v1705);
 
 /**** APIs called on distributor core ***/
 
@@ -336,7 +317,7 @@ release(struct rte_distributor *d, unsigned int wkr)
 
 /* process a set of packets to distribute them to workers */
 int
-rte_distributor_process_v1705(struct rte_distributor *d,
+rte_distributor_process(struct rte_distributor *d,
 		struct rte_mbuf **mbufs, unsigned int num_mbufs)
 {
 	unsigned int next_idx = 0;
@@ -470,14 +451,10 @@ rte_distributor_process_v1705(struct rte_distributor *d,
 
 	return num_mbufs;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_process, _v1705, 17.05);
-MAP_STATIC_SYMBOL(int rte_distributor_process(struct rte_distributor *d,
-		struct rte_mbuf **mbufs, unsigned int num_mbufs),
-		rte_distributor_process_v1705);
 
 /* return to the caller, packets returned from workers */
 int
-rte_distributor_returned_pkts_v1705(struct rte_distributor *d,
+rte_distributor_returned_pkts(struct rte_distributor *d,
 		struct rte_mbuf **mbufs, unsigned int max_mbufs)
 {
 	struct rte_distributor_returned_pkts *returns = &d->returns;
@@ -502,10 +479,6 @@ rte_distributor_returned_pkts_v1705(struct rte_distributor *d,
 
 	return retval;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_returned_pkts, _v1705, 17.05);
-MAP_STATIC_SYMBOL(int rte_distributor_returned_pkts(struct rte_distributor *d,
-		struct rte_mbuf **mbufs, unsigned int max_mbufs),
-		rte_distributor_returned_pkts_v1705);
 
 /*
  * Return the number of packets in-flight in a distributor, i.e. packets
@@ -527,7 +500,7 @@ total_outstanding(const struct rte_distributor *d)
  * queued up.
  */
 int
-rte_distributor_flush_v1705(struct rte_distributor *d)
+rte_distributor_flush(struct rte_distributor *d)
 {
 	unsigned int flushed;
 	unsigned int wkr;
@@ -556,13 +529,10 @@ rte_distributor_flush_v1705(struct rte_distributor *d)
 
 	return flushed;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_flush, _v1705, 17.05);
-MAP_STATIC_SYMBOL(int rte_distributor_flush(struct rte_distributor *d),
-		rte_distributor_flush_v1705);
 
 /* clears the internal returns array in the distributor */
 void
-rte_distributor_clear_returns_v1705(struct rte_distributor *d)
+rte_distributor_clear_returns(struct rte_distributor *d)
 {
 	unsigned int wkr;
 
@@ -576,13 +546,10 @@ rte_distributor_clear_returns_v1705(struct rte_distributor *d)
 	for (wkr = 0; wkr < d->num_workers; wkr++)
 		d->bufs[wkr].retptr64[0] = 0;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_clear_returns, _v1705, 17.05);
-MAP_STATIC_SYMBOL(void rte_distributor_clear_returns(struct rte_distributor *d),
-		rte_distributor_clear_returns_v1705);
 
 /* creates a distributor instance */
 struct rte_distributor *
-rte_distributor_create_v1705(const char *name,
+rte_distributor_create(const char *name,
 		unsigned int socket_id,
 		unsigned int num_workers,
 		unsigned int alg_type)
@@ -656,8 +623,3 @@ rte_distributor_create_v1705(const char *name,
 
 	return d;
 }
-BIND_DEFAULT_SYMBOL(rte_distributor_create, _v1705, 17.05);
-MAP_STATIC_SYMBOL(struct rte_distributor *rte_distributor_create(
-		const char *name, unsigned int socket_id,
-		unsigned int num_workers, unsigned int alg_type),
-		rte_distributor_create_v1705);
lib/librte_distributor/rte_distributor_v1705.h deleted +0 -61

61 lines not on this page · raw message

Signature · 1 line
2.17.1
#19 lore raw

PATCH v2 7/10 lib: change function suffix in distributor

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

The functions and structures version 2.0 is still in use in librte_distributor for single packet mode but the version suffix "_v20" needs to be changed to "_single" in order to avoid confusion.

---

Notes:
Dave: do we still need this at all? Can we remove this?

 lib/librte_distributor/Makefile               |  2 +-
 lib/librte_distributor/meson.build            |  2 +-
 lib/librte_distributor/rte_distributor.c      | 24 +++++-----
 .../rte_distributor_private.h                 | 10 ++--
 ...ributor_v20.c => rte_distributor_single.c} | 48 +++++++++----------
 ...ributor_v20.h => rte_distributor_single.h} | 26 +++++-----
 6 files changed, 57 insertions(+), 55 deletions(-)
 rename lib/librte_distributor/{rte_distributor_v20.c => rte_distributor_single.c} (87%)
 rename lib/librte_distributor/{rte_distributor_v20.h => rte_distributor_single.h} (89%)
lib/librte_distributor/Makefile +1 -1
index 0ef80dcff4..d9d0089166 100644
@@ -15,7 +15,7 @@ EXPORT_MAP := rte_distributor_version.map
 LIBABIVER := 1
 
 # all source are stored in SRCS-y
-SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) := rte_distributor_v20.c
+SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) := rte_distributor_single.c
 SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += rte_distributor.c
 ifeq ($(CONFIG_RTE_ARCH_X86),y)
 SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += rte_distributor_match_sse.c
lib/librte_distributor/meson.build +1 -1
index dba7e3b2aa..bd12ddb2f1 100644
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-sources = files('rte_distributor.c', 'rte_distributor_v20.c')
+sources = files('rte_distributor.c', 'rte_distributor_single.c')
 if arch_subdir == 'x86'
 	sources += files('rte_distributor_match_sse.c')
 else
lib/librte_distributor/rte_distributor.c +13 -11
index ca3f21b833..b4fc0bfead 100644
@@ -18,7 +18,7 @@
 
 #include "rte_distributor_private.h"
 #include "rte_distributor.h"
-#include "rte_distributor_v20.h"
+#include "rte_distributor_single.h"
 
 TAILQ_HEAD(rte_dist_burst_list, rte_distributor);
 
@@ -42,7 +42,7 @@ rte_distributor_request_pkt(struct rte_distributor *d,
 	volatile int64_t *retptr64;
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
-		rte_distributor_request_pkt_v20(d->d_v20,
+		rte_distributor_request_pkt_single(d->d_single,
 			worker_id, oldpkt[0]);
 		return;
 	}
@@ -88,7 +88,8 @@ rte_distributor_poll_pkt(struct rte_distributor *d,
 	unsigned int i;
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
-		pkts[0] = rte_distributor_poll_pkt_v20(d->d_v20, worker_id);
+		pkts[0] = rte_distributor_poll_pkt_single(d->d_single,
+			worker_id);
 		return (pkts[0]) ? 1 : 0;
 	}
 
@@ -123,7 +124,7 @@ rte_distributor_get_pkt(struct rte_distributor *d,
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
 		if (return_count <= 1) {
-			pkts[0] = rte_distributor_get_pkt_v20(d->d_v20,
+			pkts[0] = rte_distributor_get_pkt_single(d->d_single,
 				worker_id, oldpkt[0]);
 			return (pkts[0]) ? 1 : 0;
 		} else
@@ -153,7 +154,7 @@ rte_distributor_return_pkt(struct rte_distributor *d,
 
 	if (unlikely(d->alg_type == RTE_DIST_ALG_SINGLE)) {
 		if (num == 1)
-			return rte_distributor_return_pkt_v20(d->d_v20,
+			return rte_distributor_return_pkt_single(d->d_single,
 				worker_id, oldpkt[0]);
 		else
 			return -EINVAL;
@@ -330,7 +331,8 @@ rte_distributor_process(struct rte_distributor *d,
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		return rte_distributor_process_v20(d->d_v20, mbufs, num_mbufs);
+		return rte_distributor_process_single(d->d_single,
+			mbufs, num_mbufs);
 	}
 
 	if (unlikely(num_mbufs == 0)) {
@@ -464,7 +466,7 @@ rte_distributor_returned_pkts(struct rte_distributor *d,
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		return rte_distributor_returned_pkts_v20(d->d_v20,
+		return rte_distributor_returned_pkts_single(d->d_single,
 				mbufs, max_mbufs);
 	}
 
@@ -507,7 +509,7 @@ rte_distributor_flush(struct rte_distributor *d)
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		return rte_distributor_flush_v20(d->d_v20);
+		return rte_distributor_flush_single(d->d_single);
 	}
 
 	flushed = total_outstanding(d);
@@ -538,7 +540,7 @@ rte_distributor_clear_returns(struct rte_distributor *d)
 
 	if (d->alg_type == RTE_DIST_ALG_SINGLE) {
 		/* Call the old API */
-		rte_distributor_clear_returns_v20(d->d_v20);
+		rte_distributor_clear_returns_single(d->d_single);
 		return;
 	}
 
@@ -578,9 +580,9 @@ rte_distributor_create(const char *name,
 			rte_errno = ENOMEM;
 			return NULL;
 		}
-		d->d_v20 = rte_distributor_create_v20(name,
+		d->d_single = rte_distributor_create_single(name,
 				socket_id, num_workers);
-		if (d->d_v20 == NULL) {
+		if (d->d_single == NULL) {
 			free(d);
 			/* rte_errno will have been set */
 			return NULL;
lib/librte_distributor/rte_distributor_private.h +5 -5
index 33cd89410c..bdb62b6e92 100644
@@ -55,7 +55,7 @@ extern "C" {
  * the next cache line to worker 0, we pad this out to three cache lines.
  * Only 64-bits of the memory is actually used though.
  */
-union rte_distributor_buffer_v20 {
+union rte_distributor_buffer_single {
 	volatile int64_t bufptr64;
 	char pad[RTE_CACHE_LINE_SIZE*3];
 } __rte_cache_aligned;
@@ -80,8 +80,8 @@ struct rte_distributor_returned_pkts {
 	struct rte_mbuf *mbufs[RTE_DISTRIB_MAX_RETURNS];
 };
 
-struct rte_distributor_v20 {
-	TAILQ_ENTRY(rte_distributor_v20) next;    /**< Next in list. */
+struct rte_distributor_single {
+	TAILQ_ENTRY(rte_distributor_single) next;    /**< Next in list. */
 
 	char name[RTE_DISTRIBUTOR_NAMESIZE];  /**< Name of the ring. */
 	unsigned int num_workers;             /**< Number of workers polling */
@@ -96,7 +96,7 @@ struct rte_distributor_v20 {
 
 	struct rte_distributor_backlog backlog[RTE_DISTRIB_MAX_WORKERS];
 
-	union rte_distributor_buffer_v20 bufs[RTE_DISTRIB_MAX_WORKERS];
+	union rte_distributor_buffer_single bufs[RTE_DISTRIB_MAX_WORKERS];
 
 	struct rte_distributor_returned_pkts returns;
 };
@@ -154,7 +154,7 @@ struct rte_distributor {
 
 	enum rte_distributor_match_function dist_match_fn;
 
-	struct rte_distributor_v20 *d_v20;
+	struct rte_distributor_single *d_single;
 };
 
 void
lib/librte_distributor/rte_distributor_single.c renamed from lib/librte_distributor/rte_distributor_v20.c +24 -24

156 lines not on this page · raw message

lib/librte_distributor/rte_distributor_single.h renamed from lib/librte_distributor/rte_distributor_v20.h +13 -13
similarity index 89%
rename from lib/librte_distributor/rte_distributor_v20.h
rename to lib/librte_distributor/rte_distributor_single.h
index 12865658ba..2f80aa43d1 100644
@@ -2,8 +2,8 @@
  * Copyright(c) 2010-2014 Intel Corporation
  */
 
-#ifndef _RTE_DISTRIB_V20_H_
-#define _RTE_DISTRIB_V20_H_
+#ifndef _RTE_DISTRIB_SINGLE_H_
+#define _RTE_DISTRIB_SINGLE_H_
 
 /**
  * @file
@@ -19,7 +19,7 @@ extern "C" {
 
 #define RTE_DISTRIBUTOR_NAMESIZE 32 /**< Length of name for instance */
 
-struct rte_distributor_v20;
+struct rte_distributor_single;
 struct rte_mbuf;
 
 /**
@@ -38,8 +38,8 @@ struct rte_mbuf;
  * @return
  *   The newly created distributor instance
  */
-struct rte_distributor_v20 *
-rte_distributor_create_v20(const char *name, unsigned int socket_id,
+struct rte_distributor_single *
+rte_distributor_create_single(const char *name, unsigned int socket_id,
 		unsigned int num_workers);
 
 /*  *** APIS to be called on the distributor lcore ***  */
@@ -74,7 +74,7 @@ rte_distributor_create_v20(const char *name, unsigned int socket_id,
  *   The number of mbufs processed.
  */
 int
-rte_distributor_process_v20(struct rte_distributor_v20 *d,
+rte_distributor_process_single(struct rte_distributor_single *d,
 		struct rte_mbuf **mbufs, unsigned int num_mbufs);
 
 /**
@@ -92,7 +92,7 @@ rte_distributor_process_v20(struct rte_distributor_v20 *d,
  *   The number of mbufs returned in the mbufs array.
  */
 int
-rte_distributor_returned_pkts_v20(struct rte_distributor_v20 *d,
+rte_distributor_returned_pkts_single(struct rte_distributor_single *d,
 		struct rte_mbuf **mbufs, unsigned int max_mbufs);
 
 /**
@@ -107,7 +107,7 @@ rte_distributor_returned_pkts_v20(struct rte_distributor_v20 *d,
  *   The number of queued/in-flight packets that were completed by this call.
  */
 int
-rte_distributor_flush_v20(struct rte_distributor_v20 *d);
+rte_distributor_flush_single(struct rte_distributor_single *d);
 
 /**
  * Clears the array of returned packets used as the source for the
@@ -119,7 +119,7 @@ rte_distributor_flush_v20(struct rte_distributor_v20 *d);
  *   The distributor instance to be used
  */
 void
-rte_distributor_clear_returns_v20(struct rte_distributor_v20 *d);
+rte_distributor_clear_returns_single(struct rte_distributor_single *d);
 
 /*  *** APIS to be called on the worker lcores ***  */
 /*
@@ -148,7 +148,7 @@ rte_distributor_clear_returns_v20(struct rte_distributor_v20 *d);
  *   A new packet to be processed by the worker thread.
  */
 struct rte_mbuf *
-rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_get_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id, struct rte_mbuf *oldpkt);
 
 /**
@@ -164,7 +164,7 @@ rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d,
  *   The previous packet being processed by the worker
  */
 int
-rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_return_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id, struct rte_mbuf *mbuf);
 
 /**
@@ -188,7 +188,7 @@ rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d,
  *   The previous packet, if any, being processed by the worker
  */
 void
-rte_distributor_request_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_request_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id, struct rte_mbuf *oldpkt);
 
 /**
@@ -208,7 +208,7 @@ rte_distributor_request_pkt_v20(struct rte_distributor_v20 *d,
  *   packet is yet available.
  */
 struct rte_mbuf *
-rte_distributor_poll_pkt_v20(struct rte_distributor_v20 *d,
+rte_distributor_poll_pkt_single(struct rte_distributor_single *d,
 		unsigned int worker_id);
 
 #ifdef __cplusplus
Signature · 1 line
2.17.1
#20 lore raw

Re: [dpdk-dev] [PATCH v2 07/10] lib: change function suffix in distributor

Quoted 8 lines · Anatoly Burakov

From: Marcin Baran <[email protected]>

The functions and structures version 2.0 is still in use in librte_distributor for single packet mode but the version suffix "_v20" needs to be changed to "_single" in order to avoid confusion.

Quoted 6 lines

---

Notes:
Dave: do we still need this at all? Can we remove this?

Yes, it probably makes sense to remove the single version.

Rgds,
Dave.

Quoted 1 line

--snip--

#21 lore raw

PATCH v2 8/10 drivers/octeontx: add missing public symbol

In reply to Anatoly Burakov

The logtype symbol was missing from the .map file. Add it.

Fixes d8dd31652cf4 ("common/octeontx: move mbox to common folder")

---

Notes:
v2:
- add this patch to avoid compile breakage when bumping ABI

 drivers/common/octeontx/rte_common_octeontx_version.map | 1 +
 1 file changed, 1 insertion(+)
drivers/common/octeontx/rte_common_octeontx_version.map +1 -0
index f04b3b7f8a..a9b3cff9bc 100644
@@ -1,6 +1,7 @@
 DPDK_18.05 {
 	global:
 
+	octeontx_logtype_mbox;
 	octeontx_mbox_set_ram_mbox_base;
 	octeontx_mbox_set_reg;
 	octeontx_mbox_send;
Signature · 1 line
2.17.1
#22 lore raw

PATCH v2 9/10 build: change ABI version to 20.0

In reply to Anatoly Burakov

From: Pawel Modrak <[email protected]>

Merge all vesions in linker version script files to DPDK_20.0.

This commit was generated by running the following command:

:~/DPDK$ buildtools/update-abi.sh 20.0

---

Notes:
v2:
- Regenerated this patch using the new script

 .../rte_pmd_bbdev_fpga_lte_fec_version.map    |   8 +-
 .../null/rte_pmd_bbdev_null_version.map       |   2 +-
 .../rte_pmd_bbdev_turbo_sw_version.map        |   2 +-
 drivers/bus/dpaa/rte_bus_dpaa_version.map     | 115 +++----
 drivers/bus/fslmc/rte_bus_fslmc_version.map   | 154 ++++-----
 drivers/bus/ifpga/rte_bus_ifpga_version.map   |  14 +-
 drivers/bus/pci/rte_bus_pci_version.map       |   2 +-
 drivers/bus/vdev/rte_bus_vdev_version.map     |  12 +-
 drivers/bus/vmbus/rte_bus_vmbus_version.map   |  12 +-
 drivers/common/cpt/rte_common_cpt_version.map |   4 +-
 .../common/dpaax/rte_common_dpaax_version.map |   4 +-
 .../common/mvep/rte_common_mvep_version.map   |   6 +-
 .../octeontx/rte_common_octeontx_version.map  |   6 +-
 .../rte_common_octeontx2_version.map          |  16 +-
 .../compress/isal/rte_pmd_isal_version.map    |   2 +-
 .../rte_pmd_octeontx_compress_version.map     |   2 +-
 drivers/compress/qat/rte_pmd_qat_version.map  |   2 +-
 .../compress/zlib/rte_pmd_zlib_version.map    |   2 +-
 .../aesni_gcm/rte_pmd_aesni_gcm_version.map   |   2 +-
 .../aesni_mb/rte_pmd_aesni_mb_version.map     |   2 +-
 .../crypto/armv8/rte_pmd_armv8_version.map    |   2 +-
 .../caam_jr/rte_pmd_caam_jr_version.map       |   3 +-
 drivers/crypto/ccp/rte_pmd_ccp_version.map    |   3 +-
 .../dpaa2_sec/rte_pmd_dpaa2_sec_version.map   |  10 +-
 .../dpaa_sec/rte_pmd_dpaa_sec_version.map     |  10 +-
 .../crypto/kasumi/rte_pmd_kasumi_version.map  |   2 +-
 .../crypto/mvsam/rte_pmd_mvsam_version.map    |   2 +-
 .../crypto/nitrox/rte_pmd_nitrox_version.map  |   2 +-
 .../null/rte_pmd_null_crypto_version.map      |   2 +-
 .../rte_pmd_octeontx_crypto_version.map       |   3 +-
 .../openssl/rte_pmd_openssl_version.map       |   2 +-
 .../rte_pmd_crypto_scheduler_version.map      |  19 +-
 .../crypto/snow3g/rte_pmd_snow3g_version.map  |   2 +-
 .../virtio/rte_pmd_virtio_crypto_version.map  |   2 +-
 drivers/crypto/zuc/rte_pmd_zuc_version.map    |   2 +-
 .../event/dpaa/rte_pmd_dpaa_event_version.map |   3 +-
 .../dpaa2/rte_pmd_dpaa2_event_version.map     |   2 +-
 .../event/dsw/rte_pmd_dsw_event_version.map   |   2 +-
 .../rte_pmd_octeontx_event_version.map        |   2 +-
 .../rte_pmd_octeontx2_event_version.map       |   3 +-
 .../event/opdl/rte_pmd_opdl_event_version.map |   2 +-
 .../rte_pmd_skeleton_event_version.map        |   3 +-
 drivers/event/sw/rte_pmd_sw_event_version.map |   2 +-
 .../bucket/rte_mempool_bucket_version.map     |   3 +-
 .../mempool/dpaa/rte_mempool_dpaa_version.map |   2 +-
 .../dpaa2/rte_mempool_dpaa2_version.map       |  12 +-
 .../octeontx/rte_mempool_octeontx_version.map |   2 +-
 .../rte_mempool_octeontx2_version.map         |   4 +-
 .../mempool/ring/rte_mempool_ring_version.map |   3 +-
 .../stack/rte_mempool_stack_version.map       |   3 +-
 .../af_packet/rte_pmd_af_packet_version.map   |   3 +-
 drivers/net/af_xdp/rte_pmd_af_xdp_version.map |   2 +-
 drivers/net/ark/rte_pmd_ark_version.map       |   5 +-
 .../net/atlantic/rte_pmd_atlantic_version.map |   4 +-
 drivers/net/avp/rte_pmd_avp_version.map       |   2 +-
 drivers/net/axgbe/rte_pmd_axgbe_version.map   |   2 +-
 drivers/net/bnx2x/rte_pmd_bnx2x_version.map   |   3 +-
 drivers/net/bnxt/rte_pmd_bnxt_version.map     |   4 +-
 drivers/net/bonding/rte_pmd_bond_version.map  |  47 +--
 drivers/net/cxgbe/rte_pmd_cxgbe_version.map   |   3 +-
 drivers/net/dpaa/rte_pmd_dpaa_version.map     |  11 +-
 drivers/net/dpaa2/rte_pmd_dpaa2_version.map   |  12 +-
 drivers/net/e1000/rte_pmd_e1000_version.map   |   3 +-
 drivers/net/ena/rte_pmd_ena_version.map       |   3 +-
 drivers/net/enetc/rte_pmd_enetc_version.map   |   3 +-
 drivers/net/enic/rte_pmd_enic_version.map     |   3 +-
 .../net/failsafe/rte_pmd_failsafe_version.map |   3 +-
 drivers/net/fm10k/rte_pmd_fm10k_version.map   |   3 +-
 drivers/net/hinic/rte_pmd_hinic_version.map   |   3 +-
 drivers/net/hns3/rte_pmd_hns3_version.map     |   4 +-
 drivers/net/i40e/rte_pmd_i40e_version.map     |  65 ++--
 drivers/net/iavf/rte_pmd_iavf_version.map     |   3 +-
 drivers/net/ice/rte_pmd_ice_version.map       |   3 +-
 drivers/net/ifc/rte_pmd_ifc_version.map       |   3 +-
 drivers/net/ipn3ke/rte_pmd_ipn3ke_version.map |   3 +-
 drivers/net/ixgbe/rte_pmd_ixgbe_version.map   |  62 ++--
 drivers/net/kni/rte_pmd_kni_version.map       |   3 +-
 .../net/liquidio/rte_pmd_liquidio_version.map |   3 +-
 drivers/net/memif/rte_pmd_memif_version.map   |   5 +-
 drivers/net/mlx4/rte_pmd_mlx4_version.map     |   3 +-
 drivers/net/mlx5/rte_pmd_mlx5_version.map     |   2 +-
 drivers/net/mvneta/rte_pmd_mvneta_version.map |   2 +-
 drivers/net/mvpp2/rte_pmd_mvpp2_version.map   |   2 +-
 drivers/net/netvsc/rte_pmd_netvsc_version.map |   4 +-
 drivers/net/nfb/rte_pmd_nfb_version.map       |   3 +-
 drivers/net/nfp/rte_pmd_nfp_version.map       |   2 +-
 drivers/net/null/rte_pmd_null_version.map     |   3 +-
 .../net/octeontx/rte_pmd_octeontx_version.map |  10 +-
 .../octeontx2/rte_pmd_octeontx2_version.map   |   3 +-
 drivers/net/pcap/rte_pmd_pcap_version.map     |   3 +-
 drivers/net/qede/rte_pmd_qede_version.map     |   3 +-
 drivers/net/ring/rte_pmd_ring_version.map     |  10 +-
 drivers/net/sfc/rte_pmd_sfc_version.map       |   3 +-
 .../net/softnic/rte_pmd_softnic_version.map   |   2 +-
 .../net/szedata2/rte_pmd_szedata2_version.map |   2 +-
 drivers/net/tap/rte_pmd_tap_version.map       |   3 +-
 .../net/thunderx/rte_pmd_thunderx_version.map |   3 +-
 .../rte_pmd_vdev_netvsc_version.map           |   3 +-
 drivers/net/vhost/rte_pmd_vhost_version.map   |  11 +-
 drivers/net/virtio/rte_pmd_virtio_version.map |   3 +-
 .../net/vmxnet3/rte_pmd_vmxnet3_version.map   |   3 +-
 .../rte_rawdev_dpaa2_cmdif_version.map        |   3 +-
 .../rte_rawdev_dpaa2_qdma_version.map         |   4 +-
 .../raw/ifpga/rte_rawdev_ifpga_version.map    |   3 +-
 drivers/raw/ioat/rte_rawdev_ioat_version.map  |   3 +-
 drivers/raw/ntb/rte_rawdev_ntb_version.map    |   5 +-
 .../rte_rawdev_octeontx2_dma_version.map      |   3 +-
 .../skeleton/rte_rawdev_skeleton_version.map  |   3 +-
 lib/librte_acl/rte_acl_version.map            |   2 +-
 lib/librte_bbdev/rte_bbdev_version.map        |   4 +
 .../rte_bitratestats_version.map              |   2 +-
 lib/librte_bpf/rte_bpf_version.map            |   4 +
 lib/librte_cfgfile/rte_cfgfile_version.map    |  34 +-
 lib/librte_cmdline/rte_cmdline_version.map    |  10 +-
 .../rte_compressdev_version.map               |   4 +
 .../rte_cryptodev_version.map                 | 102 ++----
 .../rte_distributor_version.map               |  16 +-
 lib/librte_eal/rte_eal_version.map            | 310 +++++++-----------
 lib/librte_efd/rte_efd_version.map            |   2 +-
 lib/librte_ethdev/rte_ethdev_version.map      | 160 +++------
 lib/librte_eventdev/rte_eventdev_version.map  | 130 +++-----
 .../rte_flow_classify_version.map             |   4 +
 lib/librte_gro/rte_gro_version.map            |   2 +-
 lib/librte_gso/rte_gso_version.map            |   2 +-
 lib/librte_hash/rte_hash_version.map          |  43 +--
 lib/librte_ip_frag/rte_ip_frag_version.map    |  10 +-
 lib/librte_ipsec/rte_ipsec_version.map        |   4 +
 lib/librte_jobstats/rte_jobstats_version.map  |  10 +-
 lib/librte_kni/rte_kni_version.map            |   2 +-
 lib/librte_kvargs/rte_kvargs_version.map      |   4 +-
 .../rte_latencystats_version.map              |   2 +-
 lib/librte_lpm/rte_lpm_version.map            |  39 +--
 lib/librte_mbuf/rte_mbuf_version.map          |  41 +--
 lib/librte_member/rte_member_version.map      |   2 +-
 lib/librte_mempool/rte_mempool_version.map    |  44 +--
 lib/librte_meter/rte_meter_version.map        |  13 +-
 lib/librte_metrics/rte_metrics_version.map    |   2 +-
 lib/librte_net/rte_net_version.map            |  23 +-
 lib/librte_pci/rte_pci_version.map            |   2 +-
 lib/librte_pdump/rte_pdump_version.map        |   2 +-
 lib/librte_pipeline/rte_pipeline_version.map  |  36 +-
 lib/librte_port/rte_port_version.map          |  64 +---
 lib/librte_power/rte_power_version.map        |  24 +-
 lib/librte_rawdev/rte_rawdev_version.map      |   4 +-
 lib/librte_rcu/rte_rcu_version.map            |   4 +
 lib/librte_reorder/rte_reorder_version.map    |   8 +-
 lib/librte_ring/rte_ring_version.map          |  10 +-
 lib/librte_sched/rte_sched_version.map        |  14 +-
 lib/librte_security/rte_security_version.map  |   2 +-
 lib/librte_stack/rte_stack_version.map        |   4 +
 lib/librte_table/rte_table_version.map        |   2 +-
 .../rte_telemetry_version.map                 |   4 +
 lib/librte_timer/rte_timer_version.map        |  12 +-
 lib/librte_vhost/rte_vhost_version.map        |  52 +--
 154 files changed, 721 insertions(+), 1413 deletions(-)
drivers/baseband/fpga_lte_fec/rte_pmd_bbdev_fpga_lte_fec_version.map +4 -4
index f64b0f9c27..6bcea2cc7f 100644
@@ -1,10 +1,10 @@
-DPDK_19.08 {
-    local: *;
+DPDK_20.0 {
+	local: *;
 };
 
 EXPERIMENTAL {
-    global:
+	global:
 
-    fpga_lte_fec_configure;
+	fpga_lte_fec_configure;
 
 };
drivers/baseband/null/rte_pmd_bbdev_null_version.map +1 -1
index 58b94270d4..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.02 {
+DPDK_20.0 {
 	local: *;
 };
drivers/baseband/turbo_sw/rte_pmd_bbdev_turbo_sw_version.map +1 -1
index 58b94270d4..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.02 {
+DPDK_20.0 {
 	local: *;
 };
drivers/bus/dpaa/rte_bus_dpaa_version.map +41 -74

172 lines not on this page · raw message

drivers/bus/fslmc/rte_bus_fslmc_version.map +60 -94

204 lines not on this page · raw message

drivers/bus/ifpga/rte_bus_ifpga_version.map +4 -10
index 964c9a9c45..05b4a28c1b 100644
@@ -1,17 +1,11 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	global:
 
-	rte_ifpga_get_integer32_arg;
-	rte_ifpga_get_string_arg;
 	rte_ifpga_driver_register;
 	rte_ifpga_driver_unregister;
+	rte_ifpga_find_afu_by_name;
+	rte_ifpga_get_integer32_arg;
+	rte_ifpga_get_string_arg;
 
 	local: *;
 };
-
-DPDK_19.05 {
-	global:
-
-	rte_ifpga_find_afu_by_name;
-
-} DPDK_18.05;
drivers/bus/pci/rte_bus_pci_version.map +1 -1
index 27e9c4f101..012d817e14 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_pci_dump;
drivers/bus/vdev/rte_bus_vdev_version.map +3 -9
index 590cf9b437..5abb10ecb0 100644
@@ -1,18 +1,12 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
+	rte_vdev_add_custom_scan;
 	rte_vdev_init;
 	rte_vdev_register;
+	rte_vdev_remove_custom_scan;
 	rte_vdev_uninit;
 	rte_vdev_unregister;
 
 	local: *;
 };
-
-DPDK_18.02 {
-	global:
-
-	rte_vdev_add_custom_scan;
-	rte_vdev_remove_custom_scan;
-
-} DPDK_17.11;
drivers/bus/vmbus/rte_bus_vmbus_version.map +2 -10
index ae231ad329..cbaaebc06c 100644
@@ -1,6 +1,4 @@
-/* SPDX-License-Identifier: BSD-3-Clause */
-
-DPDK_18.08 {
+DPDK_20.0 {
 	global:
 
 	rte_vmbus_chan_close;
@@ -20,6 +18,7 @@ DPDK_18.08 {
 	rte_vmbus_probe;
 	rte_vmbus_register;
 	rte_vmbus_scan;
+	rte_vmbus_set_latency;
 	rte_vmbus_sub_channel_index;
 	rte_vmbus_subchan_open;
 	rte_vmbus_unmap_device;
@@ -27,10 +26,3 @@ DPDK_18.08 {
 
 	local: *;
 };
-
-DPDK_18.11 {
-	global:
-
-	rte_vmbus_set_latency;
-
-} DPDK_18.08;
drivers/common/cpt/rte_common_cpt_version.map +3 -1
index dec614f0de..79fa5751bc 100644
@@ -1,6 +1,8 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
 	cpt_pmd_ops_helper_get_mlen_direct_mode;
 	cpt_pmd_ops_helper_get_mlen_sg_mode;
+
+	local: *;
 };
drivers/common/dpaax/rte_common_dpaax_version.map +2 -2
index 8131c9e305..45d62aea9d 100644
@@ -1,11 +1,11 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
-	dpaax_iova_table_update;
 	dpaax_iova_table_depopulate;
 	dpaax_iova_table_dump;
 	dpaax_iova_table_p;
 	dpaax_iova_table_populate;
+	dpaax_iova_table_update;
 
 	local: *;
 };
drivers/common/mvep/rte_common_mvep_version.map +4 -2
index c71722d79f..030928439d 100644
@@ -1,6 +1,8 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
-	rte_mvep_init;
 	rte_mvep_deinit;
+	rte_mvep_init;
+
+	local: *;
 };
drivers/common/octeontx/rte_common_octeontx_version.map +4 -2
index a9b3cff9bc..c15fb89112 100644
@@ -1,8 +1,10 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	global:
 
 	octeontx_logtype_mbox;
+	octeontx_mbox_send;
 	octeontx_mbox_set_ram_mbox_base;
 	octeontx_mbox_set_reg;
-	octeontx_mbox_send;
+
+	local: *;
 };
drivers/common/octeontx2/rte_common_octeontx2_version.map +6 -10
index 4400120da0..adad21a2d6 100644
@@ -1,39 +1,35 @@
-DPDK_19.08 {
+DPDK_20.0 {
 	global:
 
 	otx2_dev_active_vfs;
 	otx2_dev_fini;
 	otx2_dev_priv_init;
-
+	otx2_disable_irqs;
+	otx2_intra_dev_get_cfg;
 	otx2_logtype_base;
 	otx2_logtype_dpi;
 	otx2_logtype_mbox;
+	otx2_logtype_nix;
 	otx2_logtype_npa;
 	otx2_logtype_npc;
-	otx2_logtype_nix;
 	otx2_logtype_sso;
-	otx2_logtype_tm;
 	otx2_logtype_tim;
-
+	otx2_logtype_tm;
 	otx2_mbox_alloc_msg_rsp;
 	otx2_mbox_get_rsp;
 	otx2_mbox_get_rsp_tmo;
 	otx2_mbox_id2name;
 	otx2_mbox_msg_send;
 	otx2_mbox_wait_for_rsp;
-
-	otx2_intra_dev_get_cfg;
 	otx2_npa_lf_active;
 	otx2_npa_lf_obj_get;
 	otx2_npa_lf_obj_ref;
 	otx2_npa_pf_func_get;
 	otx2_npa_set_defaults;
+	otx2_register_irq;
 	otx2_sso_pf_func_get;
 	otx2_sso_pf_func_set;
-
-	otx2_disable_irqs;
 	otx2_unregister_irq;
-	otx2_register_irq;
 
 	local: *;
 };
drivers/compress/isal/rte_pmd_isal_version.map +1 -1
index de8e412ff1..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/compress/octeontx/rte_pmd_octeontx_compress_version.map +1 -1
index ad6e191e49..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.08 {
+DPDK_20.0 {
 	local: *;
 };
drivers/compress/qat/rte_pmd_qat_version.map +1 -1
index ad6e191e49..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.08 {
+DPDK_20.0 {
 	local: *;
 };
drivers/compress/zlib/rte_pmd_zlib_version.map +1 -1
index ad6e191e49..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.08 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/aesni_gcm/rte_pmd_aesni_gcm_version.map +1 -1
index dc4d417b7b..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_16.04 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/aesni_mb/rte_pmd_aesni_mb_version.map +1 -1
index ad607bbedd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_2.2 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/armv8/rte_pmd_armv8_version.map +1 -1
index 1f84b68a83..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.02 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/caam_jr/rte_pmd_caam_jr_version.map +1 -2
index 521e51f411..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.11 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/ccp/rte_pmd_ccp_version.map +1 -2
index 9b9ab1a4cf..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/dpaa2_sec/rte_pmd_dpaa2_sec_version.map +3 -7
index 0bfb986d0b..5952d645fd 100644
@@ -1,12 +1,8 @@
-DPDK_17.05 {
-
-	local: *;
-};
-
-DPDK_18.11 {
+DPDK_20.0 {
 	global:
 
 	dpaa2_sec_eventq_attach;
 	dpaa2_sec_eventq_detach;
 
-} DPDK_17.05;
+	local: *;
+};
drivers/crypto/dpaa_sec/rte_pmd_dpaa_sec_version.map +3 -7
index cc7f2162e0..8580fa13db 100644
@@ -1,12 +1,8 @@
-DPDK_17.11 {
-
-	local: *;
-};
-
-DPDK_19.11 {
+DPDK_20.0 {
 	global:
 
 	dpaa_sec_eventq_attach;
 	dpaa_sec_eventq_detach;
 
-} DPDK_17.11;
+	local: *;
+};
drivers/crypto/kasumi/rte_pmd_kasumi_version.map +1 -1
index 8ffeca934e..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_16.07 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/mvsam/rte_pmd_mvsam_version.map +1 -1
index a753031720..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/nitrox/rte_pmd_nitrox_version.map +1 -1
index 406964d1fc..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_19.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/null/rte_pmd_null_crypto_version.map +1 -1
index dc4d417b7b..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_16.04 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/octeontx/rte_pmd_octeontx_crypto_version.map +1 -2
index 521e51f411..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.11 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/openssl/rte_pmd_openssl_version.map +1 -1
index cc5829e30b..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_16.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/scheduler/rte_pmd_crypto_scheduler_version.map +7 -12
index 5c43127cf2..077afedce7 100644
@@ -1,21 +1,16 @@
-DPDK_17.02 {
+DPDK_20.0 {
 	global:
 
 	rte_cryptodev_scheduler_load_user_scheduler;
-	rte_cryptodev_scheduler_slave_attach;
-	rte_cryptodev_scheduler_slave_detach;
-	rte_cryptodev_scheduler_ordering_set;
-	rte_cryptodev_scheduler_ordering_get;
-
-};
-
-DPDK_17.05 {
-	global:
-
 	rte_cryptodev_scheduler_mode_get;
 	rte_cryptodev_scheduler_mode_set;
 	rte_cryptodev_scheduler_option_get;
 	rte_cryptodev_scheduler_option_set;
+	rte_cryptodev_scheduler_ordering_get;
+	rte_cryptodev_scheduler_ordering_set;
+	rte_cryptodev_scheduler_slave_attach;
+	rte_cryptodev_scheduler_slave_detach;
 	rte_cryptodev_scheduler_slaves_get;
 
-} DPDK_17.02;
+	local: *;
+};
drivers/crypto/snow3g/rte_pmd_snow3g_version.map +1 -1
index dc4d417b7b..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_16.04 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/virtio/rte_pmd_virtio_crypto_version.map +1 -1
index de8e412ff1..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/crypto/zuc/rte_pmd_zuc_version.map +1 -1
index cc5829e30b..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_16.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/event/dpaa/rte_pmd_dpaa_event_version.map +1 -2
index 179140fb87..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.02 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/event/dpaa2/rte_pmd_dpaa2_event_version.map +1 -1
index 1c0b7559dc..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.08 {
+DPDK_20.0 {
 	local: *;
 };
drivers/event/dsw/rte_pmd_dsw_event_version.map +1 -1
index 24bd5cdb35..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/event/octeontx/rte_pmd_octeontx_event_version.map +1 -1
index 5352e7e3bd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/event/octeontx2/rte_pmd_octeontx2_event_version.map +1 -2
index 41c65c8c9c..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
+DPDK_20.0 {
 	local: *;
 };
-
drivers/event/opdl/rte_pmd_opdl_event_version.map +1 -1
index 58b94270d4..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.02 {
+DPDK_20.0 {
 	local: *;
 };
drivers/event/skeleton/rte_pmd_skeleton_event_version.map +1 -2
index 8591cc0b18..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/event/sw/rte_pmd_sw_event_version.map +1 -1
index 5352e7e3bd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/mempool/bucket/rte_mempool_bucket_version.map +1 -2
index 9b9ab1a4cf..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/mempool/dpaa/rte_mempool_dpaa_version.map +1 -1
index 60bf50b2d1..9eebaf7ffd 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_dpaa_bpid_info;
drivers/mempool/dpaa2/rte_mempool_dpaa2_version.map +3 -9
index b45e7a9ac1..cd4bc88273 100644
@@ -1,16 +1,10 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	global:
 
 	rte_dpaa2_bpid_info;
 	rte_dpaa2_mbuf_alloc_bulk;
-
-	local: *;
-};
-
-DPDK_18.05 {
-	global:
-
 	rte_dpaa2_mbuf_from_buf_addr;
 	rte_dpaa2_mbuf_pool_bpid;
 
-} DPDK_17.05;
+	local: *;
+};
drivers/mempool/octeontx/rte_mempool_octeontx_version.map +1 -1
index a753031720..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/mempool/octeontx2/rte_mempool_octeontx2_version.map +2 -2
index d703368c31..d4f81aed8e 100644
@@ -1,8 +1,8 @@
-DPDK_19.08 {
+DPDK_20.0 {
 	global:
 
-	otx2_npa_lf_init;
 	otx2_npa_lf_fini;
+	otx2_npa_lf_init;
 
 	local: *;
 };
drivers/mempool/ring/rte_mempool_ring_version.map +1 -2
index 8591cc0b18..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/mempool/stack/rte_mempool_stack_version.map +1 -2
index 8591cc0b18..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/af_packet/rte_pmd_af_packet_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/af_xdp/rte_pmd_af_xdp_version.map +1 -1
index c6db030fe6..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_19.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ark/rte_pmd_ark_version.map +2 -3
index 1062e0429f..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.05 {
-	 local: *;
-
+DPDK_20.0 {
+	local: *;
 };
drivers/net/atlantic/rte_pmd_atlantic_version.map +1 -3
index b16faa999f..9b04838d84 100644
@@ -1,5 +1,4 @@
-DPDK_18.11 {
-
+DPDK_20.0 {
 	local: *;
 };
 
@@ -13,4 +12,3 @@ EXPERIMENTAL {
 	rte_pmd_atl_macsec_select_txsa;
 	rte_pmd_atl_macsec_select_rxsa;
 };
-
drivers/net/avp/rte_pmd_avp_version.map +1 -1
index 5352e7e3bd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/axgbe/rte_pmd_axgbe_version.map +1 -1
index de8e412ff1..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.05 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/bnx2x/rte_pmd_bnx2x_version.map +1 -2
index bd8138a034..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.1 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/bnxt/rte_pmd_bnxt_version.map +2 -2
index 4750d40ad6..bb52562347 100644
@@ -1,4 +1,4 @@
-DPDK_17.08 {
+DPDK_20.0 {
 	global:
 
 	rte_pmd_bnxt_get_vf_rx_status;
@@ -10,13 +10,13 @@ DPDK_17.08 {
 	rte_pmd_bnxt_set_tx_loopback;
 	rte_pmd_bnxt_set_vf_mac_addr;
 	rte_pmd_bnxt_set_vf_mac_anti_spoof;
+	rte_pmd_bnxt_set_vf_persist_stats;
 	rte_pmd_bnxt_set_vf_rate_limit;
 	rte_pmd_bnxt_set_vf_rxmode;
 	rte_pmd_bnxt_set_vf_vlan_anti_spoof;
 	rte_pmd_bnxt_set_vf_vlan_filter;
 	rte_pmd_bnxt_set_vf_vlan_insert;
 	rte_pmd_bnxt_set_vf_vlan_stripq;
-	rte_pmd_bnxt_set_vf_persist_stats;
 
 	local: *;
 };
drivers/net/bonding/rte_pmd_bond_version.map +13 -34

58 lines not on this page · raw message

drivers/net/cxgbe/rte_pmd_cxgbe_version.map +1 -2
index bd8138a034..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.1 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/dpaa/rte_pmd_dpaa_version.map +4 -7
index 8cb4500b51..f403a1526d 100644
@@ -1,12 +1,9 @@
-DPDK_17.11 {
-
-	local: *;
-};
-
-DPDK_18.08 {
+DPDK_20.0 {
 	global:
 
 	dpaa_eth_eventq_attach;
 	dpaa_eth_eventq_detach;
 	rte_pmd_dpaa_set_tx_loopback;
-} DPDK_17.11;
+
+	local: *;
+};
drivers/net/dpaa2/rte_pmd_dpaa2_version.map +4 -8
index d1b4cdb232..f2bb793319 100644
@@ -1,15 +1,11 @@
-DPDK_17.05 {
-
-	local: *;
-};
-
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	dpaa2_eth_eventq_attach;
 	dpaa2_eth_eventq_detach;
 
-} DPDK_17.05;
+	local: *;
+};
 
 EXPERIMENTAL {
 	global:
@@ -17,4 +13,4 @@ EXPERIMENTAL {
 	rte_pmd_dpaa2_mux_flow_create;
 	rte_pmd_dpaa2_set_custom_hash;
 	rte_pmd_dpaa2_set_timestamp;
-} DPDK_17.11;
+};
drivers/net/e1000/rte_pmd_e1000_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ena/rte_pmd_ena_version.map +1 -2
index 349c6e1c22..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_16.04 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/enetc/rte_pmd_enetc_version.map +1 -2
index 521e51f411..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.11 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/enic/rte_pmd_enic_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/failsafe/rte_pmd_failsafe_version.map +1 -2
index b6d2840be4..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.08 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/fm10k/rte_pmd_fm10k_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/hinic/rte_pmd_hinic_version.map +1 -2
index 9a61188cd5..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/hns3/rte_pmd_hns3_version.map +2 -2
index 35e5f2debb..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_19.11 {
-	 local: *;
+DPDK_20.0 {
+	local: *;
 };
drivers/net/i40e/rte_pmd_i40e_version.map +19 -46

86 lines not on this page · raw message

drivers/net/iavf/rte_pmd_iavf_version.map +1 -2
index 179140fb87..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.02 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ice/rte_pmd_ice_version.map +1 -2
index 7b23b609da..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.02 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ifc/rte_pmd_ifc_version.map +1 -2
index 9b9ab1a4cf..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ipn3ke/rte_pmd_ipn3ke_version.map +1 -2
index fc8c95e919..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ixgbe/rte_pmd_ixgbe_version.map +22 -40

79 lines not on this page · raw message

drivers/net/kni/rte_pmd_kni_version.map +1 -2
index 8591cc0b18..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/liquidio/rte_pmd_liquidio_version.map +1 -2
index 8591cc0b18..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/memif/rte_pmd_memif_version.map +2 -3
index 8861484fb3..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
-
-        local: *;
+DPDK_20.0 {
+	local: *;
 };
drivers/net/mlx4/rte_pmd_mlx4_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/mlx5/rte_pmd_mlx5_version.map +1 -1
index ad607bbedd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_2.2 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/mvneta/rte_pmd_mvneta_version.map +1 -1
index 24bd5cdb35..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_18.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/mvpp2/rte_pmd_mvpp2_version.map +1 -1
index a753031720..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/netvsc/rte_pmd_netvsc_version.map +1 -3
index d534019a6b..f9f17e4f6e 100644
@@ -1,5 +1,3 @@
-/* SPDX-License-Identifier: BSD-3-Clause */
-
-DPDK_18.08 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/nfb/rte_pmd_nfb_version.map +1 -2
index fc8c95e919..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/nfp/rte_pmd_nfp_version.map +1 -1
index ad607bbedd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_2.2 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/null/rte_pmd_null_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/octeontx/rte_pmd_octeontx_version.map +3 -7
index a3161b14d0..f7cae02fac 100644
@@ -1,11 +1,7 @@
-DPDK_17.11 {
-
-	local: *;
-};
-
-DPDK_18.02 {
+DPDK_20.0 {
 	global:
 
 	rte_octeontx_pchan_map;
 
-} DPDK_17.11;
+	local: *;
+};
drivers/net/octeontx2/rte_pmd_octeontx2_version.map +1 -2
index 9a61188cd5..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/pcap/rte_pmd_pcap_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/qede/rte_pmd_qede_version.map +1 -2
index 349c6e1c22..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_16.04 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/ring/rte_pmd_ring_version.map +2 -8
index 1f785d9409..ebb6be2733 100644
@@ -1,14 +1,8 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_eth_from_ring;
 	rte_eth_from_rings;
 
 	local: *;
 };
-
-DPDK_2.2 {
-	global:
-
-	rte_eth_from_ring;
-
-} DPDK_2.0;
drivers/net/sfc/rte_pmd_sfc_version.map +1 -2
index 31eca32ebe..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.02 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/softnic/rte_pmd_softnic_version.map +1 -1
index bc44b06f98..50f113d5a2 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_pmd_softnic_run;
drivers/net/szedata2/rte_pmd_szedata2_version.map +1 -1
index ad607bbedd..f9f17e4f6e 100644
@@ -1,3 +1,3 @@
-DPDK_2.2 {
+DPDK_20.0 {
 	local: *;
 };
drivers/net/tap/rte_pmd_tap_version.map +1 -2
index 31eca32ebe..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_17.02 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/thunderx/rte_pmd_thunderx_version.map +1 -2
index 1901bcb3b3..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_16.07 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/vdev_netvsc/rte_pmd_vdev_netvsc_version.map +1 -2
index 179140fb87..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.02 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/vhost/rte_pmd_vhost_version.map +3 -8
index 695db85749..16b591ccc4 100644
@@ -1,13 +1,8 @@
-DPDK_16.04 {
+DPDK_20.0 {
 	global:
 
 	rte_eth_vhost_get_queue_event;
-
-	local: *;
-};
-
-DPDK_16.11 {
-	global:
-
 	rte_eth_vhost_get_vid_from_port_id;
+
+	local: *;
 };
drivers/net/virtio/rte_pmd_virtio_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/net/vmxnet3/rte_pmd_vmxnet3_version.map +1 -2
index ef35398402..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_2.0 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/raw/dpaa2_cmdif/rte_rawdev_dpaa2_cmdif_version.map +1 -2
index 9b9ab1a4cf..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/raw/dpaa2_qdma/rte_rawdev_dpaa2_qdma_version.map +2 -2
index d16a136fc8..ca6a0d7626 100644
@@ -1,4 +1,4 @@
-DPDK_19.05 {
+DPDK_20.0 {
 	global:
 
 	rte_qdma_attr_get;
@@ -9,9 +9,9 @@ DPDK_19.05 {
 	rte_qdma_start;
 	rte_qdma_stop;
 	rte_qdma_vq_create;
-	rte_qdma_vq_destroy;
 	rte_qdma_vq_dequeue;
 	rte_qdma_vq_dequeue_multi;
+	rte_qdma_vq_destroy;
 	rte_qdma_vq_enqueue;
 	rte_qdma_vq_enqueue_multi;
 	rte_qdma_vq_stats;
drivers/raw/ifpga/rte_rawdev_ifpga_version.map +1 -2
index 9b9ab1a4cf..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.05 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/raw/ioat/rte_rawdev_ioat_version.map +1 -2
index 9a61188cd5..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/raw/ntb/rte_rawdev_ntb_version.map +2 -3
index 8861484fb3..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
-
-        local: *;
+DPDK_20.0 {
+	local: *;
 };
drivers/raw/octeontx2_dma/rte_rawdev_octeontx2_dma_version.map +1 -2
index 9a61188cd5..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_19.08 {
-
+DPDK_20.0 {
 	local: *;
 };
drivers/raw/skeleton/rte_rawdev_skeleton_version.map +1 -2
index 179140fb87..f9f17e4f6e 100644
@@ -1,4 +1,3 @@
-DPDK_18.02 {
-
+DPDK_20.0 {
 	local: *;
 };
lib/librte_acl/rte_acl_version.map +1 -1
index b09370a104..c3daca8115 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_acl_add_rules;
lib/librte_bbdev/rte_bbdev_version.map +4 -0
index 3624eb1cb4..45b560dbe7 100644
@@ -1,3 +1,7 @@
+DPDK_20.0 {
+	local: *;
+};
+
 EXPERIMENTAL {
 	global:
 
lib/librte_bitratestats/rte_bitratestats_version.map +1 -1
index fe7454452d..88fc2912db 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	global:
 
 	rte_stats_bitrate_calc;
lib/librte_bpf/rte_bpf_version.map +4 -0
index a203e088ea..e1ec43faa0 100644
@@ -1,3 +1,7 @@
+DPDK_20.0 {
+	local: *;
+};
+
 EXPERIMENTAL {
 	global:
 
lib/librte_cfgfile/rte_cfgfile_version.map +8 -26
index a0a11cea8d..906eee96bf 100644
@@ -1,40 +1,22 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_cfgfile_add_entry;
+	rte_cfgfile_add_section;
 	rte_cfgfile_close;
+	rte_cfgfile_create;
 	rte_cfgfile_get_entry;
 	rte_cfgfile_has_entry;
 	rte_cfgfile_has_section;
 	rte_cfgfile_load;
+	rte_cfgfile_load_with_params;
 	rte_cfgfile_num_sections;
+	rte_cfgfile_save;
 	rte_cfgfile_section_entries;
+	rte_cfgfile_section_entries_by_index;
 	rte_cfgfile_section_num_entries;
 	rte_cfgfile_sections;
+	rte_cfgfile_set_entry;
 
 	local: *;
 };
-
-DPDK_16.04 {
-	global:
-
-	rte_cfgfile_section_entries_by_index;
-
-} DPDK_2.0;
-
-DPDK_17.05 {
-	global:
-
-	rte_cfgfile_load_with_params;
-
-} DPDK_16.04;
-
-DPDK_17.11 {
-	global:
-
-	rte_cfgfile_add_entry;
-	rte_cfgfile_add_section;
-	rte_cfgfile_create;
-	rte_cfgfile_save;
-	rte_cfgfile_set_entry;
-
-} DPDK_17.05;
lib/librte_cmdline/rte_cmdline_version.map +2 -8
index 04bcb387f2..95fce812ff 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	cirbuf_add_buf_head;
@@ -40,6 +40,7 @@ DPDK_2.0 {
 	cmdline_parse_num;
 	cmdline_parse_portlist;
 	cmdline_parse_string;
+	cmdline_poll;
 	cmdline_printf;
 	cmdline_quit;
 	cmdline_set_prompt;
@@ -68,10 +69,3 @@ DPDK_2.0 {
 
 	local: *;
 };
-
-DPDK_2.1 {
-	global:
-
-	cmdline_poll;
-
-} DPDK_2.0;
lib/librte_compressdev/rte_compressdev_version.map +4 -0
index e2a108b650..cfcd50ac1c 100644
@@ -1,3 +1,7 @@
+DPDK_20.0 {
+	local: *;
+};
+
 EXPERIMENTAL {
 	global:
 
lib/librte_cryptodev/rte_cryptodev_version.map +36 -66

128 lines not on this page · raw message

lib/librte_distributor/rte_distributor_version.map +1 -15
index 3a285b394e..1b7c643005 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_distributor_clear_returns;
@@ -13,17 +13,3 @@ DPDK_2.0 {
 
 	local: *;
 };
-
-DPDK_17.05 {
-	global:
-
-	rte_distributor_clear_returns;
-	rte_distributor_create;
-	rte_distributor_flush;
-	rte_distributor_get_pkt;
-	rte_distributor_poll_pkt;
-	rte_distributor_process;
-	rte_distributor_request_pkt;
-	rte_distributor_return_pkt;
-	rte_distributor_returned_pkts;
-} DPDK_2.0;
lib/librte_eal/rte_eal_version.map +110 -200

411 lines not on this page · raw message

lib/librte_efd/rte_efd_version.map +1 -1
index ae60a64178..e010eecfe4 100644
@@ -1,4 +1,4 @@
-DPDK_17.02 {
+DPDK_20.0 {
 	global:
 
 	rte_efd_create;
lib/librte_ethdev/rte_ethdev_version.map +47 -113

243 lines not on this page · raw message

lib/librte_eventdev/rte_eventdev_version.map +47 -83

163 lines not on this page · raw message

lib/librte_flow_classify/rte_flow_classify_version.map +4 -0
index 49bc25c6a0..001ff660e3 100644
@@ -1,3 +1,7 @@
+DPDK_20.0 {
+	local: *;
+};
+
 EXPERIMENTAL {
 	global:
 
lib/librte_gro/rte_gro_version.map +1 -1
index 1606b6dc72..9f6fe79e57 100644
@@ -1,4 +1,4 @@
-DPDK_17.08 {
+DPDK_20.0 {
 	global:
 
 	rte_gro_ctx_create;
lib/librte_gso/rte_gso_version.map +1 -1
index e1fd453edb..8505a59c27 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_gso_segment;
lib/librte_hash/rte_hash_version.map +9 -34

67 lines not on this page · raw message

lib/librte_ip_frag/rte_ip_frag_version.map +2 -8
index a193007c61..5dd34f828c 100644
@@ -1,8 +1,9 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_ip_frag_free_death_row;
 	rte_ip_frag_table_create;
+	rte_ip_frag_table_destroy;
 	rte_ip_frag_table_statistics_dump;
 	rte_ipv4_frag_reassemble_packet;
 	rte_ipv4_fragment_packet;
@@ -12,13 +13,6 @@ DPDK_2.0 {
 	local: *;
 };
 
-DPDK_17.08 {
-	global:
-
-	rte_ip_frag_table_destroy;
-
-} DPDK_2.0;
-
 EXPERIMENTAL {
 	global:
 
lib/librte_ipsec/rte_ipsec_version.map +4 -0
index ee9f1961b0..3723b812fc 100644
@@ -1,3 +1,7 @@
+DPDK_20.0 {
+	local: *;
+};
+
 EXPERIMENTAL {
 	global:
 
lib/librte_jobstats/rte_jobstats_version.map +2 -8
index f89441438e..dbd2664ae2 100644
@@ -1,6 +1,7 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_jobstats_abort;
 	rte_jobstats_context_finish;
 	rte_jobstats_context_init;
 	rte_jobstats_context_reset;
@@ -17,10 +18,3 @@ DPDK_2.0 {
 
 	local: *;
 };
-
-DPDK_16.04 {
-	global:
-
-	rte_jobstats_abort;
-
-} DPDK_2.0;
lib/librte_kni/rte_kni_version.map +1 -1
index c877dc6aaa..9cd3cedc54 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_kni_alloc;
lib/librte_kvargs/rte_kvargs_version.map +2 -2
index 8f4b4e3f8f..3ba0f4b59c 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_kvargs_count;
@@ -15,4 +15,4 @@ EXPERIMENTAL {
 	rte_kvargs_parse_delim;
 	rte_kvargs_strcmp;
 
-} DPDK_2.0;
+};
lib/librte_latencystats/rte_latencystats_version.map +1 -1
index ac8403e821..e04e63463f 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	global:
 
 	rte_latencystats_get;
lib/librte_lpm/rte_lpm_version.map +8 -31
index 90beac853d..500f58b806 100644
@@ -1,13 +1,6 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
-	rte_lpm_add;
-	rte_lpm_create;
-	rte_lpm_delete;
-	rte_lpm_delete_all;
-	rte_lpm_find_existing;
-	rte_lpm_free;
-	rte_lpm_is_rule_present;
 	rte_lpm6_add;
 	rte_lpm6_create;
 	rte_lpm6_delete;
@@ -18,29 +11,13 @@ DPDK_2.0 {
 	rte_lpm6_is_rule_present;
 	rte_lpm6_lookup;
 	rte_lpm6_lookup_bulk_func;
+	rte_lpm_add;
+	rte_lpm_create;
+	rte_lpm_delete;
+	rte_lpm_delete_all;
+	rte_lpm_find_existing;
+	rte_lpm_free;
+	rte_lpm_is_rule_present;
 
 	local: *;
 };
-
-DPDK_16.04 {
-	global:
-
-	rte_lpm_add;
-	rte_lpm_find_existing;
-	rte_lpm_create;
-	rte_lpm_free;
-	rte_lpm_is_rule_present;
-	rte_lpm_delete;
-	rte_lpm_delete_all;
-
-} DPDK_2.0;
-
-DPDK_17.05 {
-	global:
-
-	rte_lpm6_add;
-	rte_lpm6_is_rule_present;
-	rte_lpm6_lookup;
-	rte_lpm6_lookup_bulk_func;
-
-} DPDK_16.04;
lib/librte_mbuf/rte_mbuf_version.map +12 -29

59 lines not on this page · raw message

lib/librte_member/rte_member_version.map +1 -1
index 019e4cd962..87780ae611 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	rte_member_add;
lib/librte_mempool/rte_mempool_version.map +13 -31

70 lines not on this page · raw message

lib/librte_meter/rte_meter_version.map +4 -9
index 4b460d5803..46410b0369 100644
@@ -1,21 +1,16 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_meter_srtcm_color_aware_check;
 	rte_meter_srtcm_color_blind_check;
 	rte_meter_srtcm_config;
+	rte_meter_srtcm_profile_config;
 	rte_meter_trtcm_color_aware_check;
 	rte_meter_trtcm_color_blind_check;
 	rte_meter_trtcm_config;
-
-	local: *;
-};
-
-DPDK_18.08 {
-	global:
-
-	rte_meter_srtcm_profile_config;
 	rte_meter_trtcm_profile_config;
+
+	local: *;
 };
 
 EXPERIMENTAL {
lib/librte_metrics/rte_metrics_version.map +1 -1
index 6ac99a44a1..85663f356e 100644
@@ -1,4 +1,4 @@
-DPDK_17.05 {
+DPDK_20.0 {
 	global:
 
 	rte_metrics_get_names;
lib/librte_net/rte_net_version.map +6 -17
index fffc4a3723..8a4e75a3a0 100644
@@ -1,25 +1,14 @@
-DPDK_16.11 {
-	global:
-	rte_net_get_ptype;
-
-	local: *;
-};
-
-DPDK_17.05 {
-	global:
-
-	rte_net_crc_calc;
-	rte_net_crc_set_alg;
-
-} DPDK_16.11;
-
-DPDK_19.08 {
+DPDK_20.0 {
 	global:
 
 	rte_eth_random_addr;
 	rte_ether_format_addr;
+	rte_net_crc_calc;
+	rte_net_crc_set_alg;
+	rte_net_get_ptype;
 
-} DPDK_17.05;
+	local: *;
+};
 
 EXPERIMENTAL {
 	global:
lib/librte_pci/rte_pci_version.map +1 -1
index c0280277bb..539785f5f4 100644
@@ -1,4 +1,4 @@
-DPDK_17.11 {
+DPDK_20.0 {
 	global:
 
 	eal_parse_pci_BDF;
lib/librte_pdump/rte_pdump_version.map +1 -1
index 3e744f3012..6d02ccce6d 100644
@@ -1,4 +1,4 @@
-DPDK_16.07 {
+DPDK_20.0 {
 	global:
 
 	rte_pdump_disable;
lib/librte_pipeline/rte_pipeline_version.map +9 -27
index 420f065d6e..64d38afecd 100644
@@ -1,6 +1,8 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
+	rte_pipeline_ah_packet_drop;
+	rte_pipeline_ah_packet_hijack;
 	rte_pipeline_check;
 	rte_pipeline_create;
 	rte_pipeline_flush;
@@ -9,42 +11,22 @@ DPDK_2.0 {
 	rte_pipeline_port_in_create;
 	rte_pipeline_port_in_disable;
 	rte_pipeline_port_in_enable;
+	rte_pipeline_port_in_stats_read;
 	rte_pipeline_port_out_create;
 	rte_pipeline_port_out_packet_insert;
+	rte_pipeline_port_out_stats_read;
 	rte_pipeline_run;
 	rte_pipeline_table_create;
 	rte_pipeline_table_default_entry_add;
 	rte_pipeline_table_default_entry_delete;
 	rte_pipeline_table_entry_add;
-	rte_pipeline_table_entry_delete;
-
-	local: *;
-};
-
-DPDK_2.1 {
-	global:
-
-	rte_pipeline_port_in_stats_read;
-	rte_pipeline_port_out_stats_read;
-	rte_pipeline_table_stats_read;
-
-} DPDK_2.0;
-
-DPDK_2.2 {
-	global:
-
 	rte_pipeline_table_entry_add_bulk;
+	rte_pipeline_table_entry_delete;
 	rte_pipeline_table_entry_delete_bulk;
+	rte_pipeline_table_stats_read;
 
-} DPDK_2.1;
-
-DPDK_16.04 {
-	global:
-
-	rte_pipeline_ah_packet_hijack;
-	rte_pipeline_ah_packet_drop;
-
-} DPDK_2.2;
+	local: *;
+};
 
 EXPERIMENTAL {
 	global:
lib/librte_port/rte_port_version.map +17 -47

79 lines not on this page · raw message

lib/librte_power/rte_power_version.map +6 -18
index 042917360e..a94ab30c3d 100644
@@ -1,39 +1,27 @@
-DPDK_2.0 {
+DPDK_20.0 {
 	global:
 
 	rte_power_exit;
+	rte_power_freq_disable_turbo;
 	rte_power_freq_down;
+	rte_power_freq_enable_turbo;
 	rte_power_freq_max;
 	rte_power_freq_min;
 	rte_power_freq_up;
 	rte_power_freqs;
+	rte_power_get_capabilities;
 	rte_power_get_env;
 	rte_power_get_freq;
+	rte_power_guest_channel_send_msg;
 	rte_power_init;
 	rte_power_set_env;
 	rte_power_set_freq;
+	rte_power_turbo_status;
 	rte_power_unset_env;
 
[… more lines in the raw message]

Lines of this file are not shown. View the raw message.

lib/librte_rawdev/rte_rawdev_version.map +2 -2
index b61dbff11c..d847c9e0d3 100644

Lines of this file are not shown. View the raw message.

lib/librte_rcu/rte_rcu_version.map +4 -0
index f8b9ef2abb..787e51ef27 100644

Lines of this file are not shown. View the raw message.

lib/librte_reorder/rte_reorder_version.map +4 -4
index 0a8a54de83..cf444062df 100644

Lines of this file are not shown. View the raw message.

lib/librte_ring/rte_ring_version.map +2 -8
index 510c1386e0..89d84bcf48 100644

Lines of this file are not shown. View the raw message.

lib/librte_sched/rte_sched_version.map +4 -10
index 729588794e..1b48bfbf36 100644

Lines of this file are not shown. View the raw message.

lib/librte_security/rte_security_version.map +1 -1
index 53267bf3cc..b07314bbf4 100644

Lines of this file are not shown. View the raw message.

lib/librte_stack/rte_stack_version.map +4 -0
index 6662679c36..adbb7be9d9 100644

Lines of this file are not shown. View the raw message.

lib/librte_table/rte_table_version.map +1 -1
index 6237252bec..40f72b1fe8 100644

Lines of this file are not shown. View the raw message.

lib/librte_telemetry/rte_telemetry_version.map +4 -0
index fa62d7718c..c1f4613af5 100644

Lines of this file are not shown. View the raw message.

lib/librte_timer/rte_timer_version.map +1 -11
index 72f75c8181..2a59d3f081 100644

Lines of this file are not shown. View the raw message.

lib/librte_vhost/rte_vhost_version.map +11 -41

52 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.17.1

Part of the diff is not shown here. View the raw message.

#23 lore raw

v3 cover Implement the new ABI policy and add helper scripts

In reply to Anatoly Burakov

This patchset prepares the codebase for the new ABI policy and adds a few helper scripts.

There are two new scripts for managing ABI versions added. The first one is a Python script that will read in a .map file, flatten it and update the ABI version to the ABI version specified on the command-line.

The second one is a shell script that will run the above mentioned Python script recursively over the source tree and set the ABI version to either that which is defined in config/ABI_VERSION, or a user-specified one.

Example of its usage: buildtools/update-abi.sh 20.0

This will recurse into lib/ and drivers/ directory and update whatever .map files it can find.

The other shell script that's added is one that can take in a .so file and ensure that its declared public ABI matches either current ABI, next ABI, or EXPERIMENTAL. This was moved to the last commit because it made no sense to have it beforehand.

The source tree was verified to follow the new ABI policy using the following command (assuming built binaries are in build/):

find ./build/lib ./build/drivers -name \*.so \
-exec ./buildtools/check-abi-version.sh {} \; -print

This returns 0.

Changes since v2:
- Addressed Bruce's review comments
- Removed single distributor mode as per Dave's suggestion

Changes since v1:
- Reordered patchset to have removal of old ABI's before introducing the new one to avoid compile breakages between patches
- Added a new patch fixing missing symbol in octeontx common
- Split script commits into multiple commits and reordered them
- Re-generated the ABI bump commit
- Verified all scripts to work

Anatoly Burakov (2):
buildtools: add ABI update shell script
drivers/octeontx: add missing public symbol

Marcin Baran (5):
config: change ABI versioning to global
timer: remove deprecated code
lpm: remove deprecated code
distributor: remove deprecated code
buildtools: add ABI versioning check script

Pawel Modrak (2):
buildtools: add script for updating symbols abi version
build: change ABI version to 20.0

 app/test/test_distributor.c                   | 102 +-
 app/test/test_distributor_perf.c              |  12 -
 buildtools/check-abi-version.sh               |  54 +
 buildtools/meson.build                        |   2 +
 buildtools/update-abi.sh                      |  42 +
 buildtools/update_version_map_abi.py          | 170 +++
 config/ABI_VERSION                            |   1 +
 config/meson.build                            |   5 +-
 .../rte_pmd_bbdev_fpga_lte_fec_version.map    |   8 +-
 .../null/rte_pmd_bbdev_null_version.map       |   2 +-
 .../rte_pmd_bbdev_turbo_sw_version.map        |   2 +-
 drivers/bus/dpaa/rte_bus_dpaa_version.map     | 115 +-
 drivers/bus/fslmc/rte_bus_fslmc_version.map   | 154 ++-
 drivers/bus/ifpga/rte_bus_ifpga_version.map   |  14 +-
 drivers/bus/pci/rte_bus_pci_version.map       |   2 +-
 drivers/bus/vdev/rte_bus_vdev_version.map     |  12 +-
 drivers/bus/vmbus/rte_bus_vmbus_version.map   |  12 +-
 drivers/common/cpt/rte_common_cpt_version.map |   4 +-
 .../common/dpaax/rte_common_dpaax_version.map |   4 +-
 .../common/mvep/rte_common_mvep_version.map   |   6 +-
 .../octeontx/rte_common_octeontx_version.map  |   7 +-
 .../rte_common_octeontx2_version.map          |  16 +-
 .../compress/isal/rte_pmd_isal_version.map    |   2 +-
 .../rte_pmd_octeontx_compress_version.map     |   2 +-
 drivers/compress/qat/rte_pmd_qat_version.map  |   2 +-
 .../compress/zlib/rte_pmd_zlib_version.map    |   2 +-
 .../aesni_gcm/rte_pmd_aesni_gcm_version.map   |   2 +-
 .../aesni_mb/rte_pmd_aesni_mb_version.map     |   2 +-
 .../crypto/armv8/rte_pmd_armv8_version.map    |   2 +-
 .../caam_jr/rte_pmd_caam_jr_version.map       |   3 +-
 drivers/crypto/ccp/rte_pmd_ccp_version.map    |   3 +-
 .../dpaa2_sec/rte_pmd_dpaa2_sec_version.map   |  10 +-
 .../dpaa_sec/rte_pmd_dpaa_sec_version.map     |  10 +-
 .../crypto/kasumi/rte_pmd_kasumi_version.map  |   2 +-
 .../crypto/mvsam/rte_pmd_mvsam_version.map    |   2 +-
 .../crypto/nitrox/rte_pmd_nitrox_version.map  |   2 +-
 .../null/rte_pmd_null_crypto_version.map      |   2 +-
 .../rte_pmd_octeontx_crypto_version.map       |   3 +-
 .../openssl/rte_pmd_openssl_version.map       |   2 +-
 .../rte_pmd_crypto_scheduler_version.map      |  19 +-
 .../crypto/snow3g/rte_pmd_snow3g_version.map  |   2 +-
 .../virtio/rte_pmd_virtio_crypto_version.map  |   2 +-
 drivers/crypto/zuc/rte_pmd_zuc_version.map    |   2 +-
 .../event/dpaa/rte_pmd_dpaa_event_version.map |   3 +-
 .../dpaa2/rte_pmd_dpaa2_event_version.map     |   2 +-
 .../event/dsw/rte_pmd_dsw_event_version.map   |   2 +-
 .../rte_pmd_octeontx_event_version.map        |   2 +-
 .../rte_pmd_octeontx2_event_version.map       |   3 +-
 .../event/opdl/rte_pmd_opdl_event_version.map |   2 +-
 .../rte_pmd_skeleton_event_version.map        |   3 +-
 drivers/event/sw/rte_pmd_sw_event_version.map |   2 +-
 .../bucket/rte_mempool_bucket_version.map     |   3 +-
 .../mempool/dpaa/rte_mempool_dpaa_version.map |   2 +-
 .../dpaa2/rte_mempool_dpaa2_version.map       |  12 +-
 .../octeontx/rte_mempool_octeontx_version.map |   2 +-
 .../rte_mempool_octeontx2_version.map         |   4 +-
 .../mempool/ring/rte_mempool_ring_version.map |   3 +-
 .../stack/rte_mempool_stack_version.map       |   3 +-
 drivers/meson.build                           |  20 +-
 .../af_packet/rte_pmd_af_packet_version.map   |   3 +-
 drivers/net/af_xdp/rte_pmd_af_xdp_version.map |   2 +-
 drivers/net/ark/rte_pmd_ark_version.map       |   5 +-
 .../net/atlantic/rte_pmd_atlantic_version.map |   4 +-
 drivers/net/avp/rte_pmd_avp_version.map       |   2 +-
 drivers/net/axgbe/rte_pmd_axgbe_version.map   |   2 +-
 drivers/net/bnx2x/rte_pmd_bnx2x_version.map   |   3 +-
 drivers/net/bnxt/rte_pmd_bnxt_version.map     |   4 +-
 drivers/net/bonding/rte_pmd_bond_version.map  |  47 +-
 drivers/net/cxgbe/rte_pmd_cxgbe_version.map   |   3 +-
 drivers/net/dpaa/rte_pmd_dpaa_version.map     |  11 +-
 drivers/net/dpaa2/rte_pmd_dpaa2_version.map   |  12 +-
 drivers/net/e1000/rte_pmd_e1000_version.map   |   3 +-
 drivers/net/ena/rte_pmd_ena_version.map       |   3 +-
 drivers/net/enetc/rte_pmd_enetc_version.map   |   3 +-
 drivers/net/enic/rte_pmd_enic_version.map     |   3 +-
 .../net/failsafe/rte_pmd_failsafe_version.map |   3 +-
 drivers/net/fm10k/rte_pmd_fm10k_version.map   |   3 +-
 drivers/net/hinic/rte_pmd_hinic_version.map   |   3 +-
 drivers/net/hns3/rte_pmd_hns3_version.map     |   4 +-
 drivers/net/i40e/rte_pmd_i40e_version.map     |  65 +-
 drivers/net/iavf/rte_pmd_iavf_version.map     |   3 +-
 drivers/net/ice/rte_pmd_ice_version.map       |   3 +-
 drivers/net/ifc/rte_pmd_ifc_version.map       |   3 +-
 drivers/net/ipn3ke/rte_pmd_ipn3ke_version.map |   3 +-
 drivers/net/ixgbe/rte_pmd_ixgbe_version.map   |  62 +-
 drivers/net/kni/rte_pmd_kni_version.map       |   3 +-
 .../net/liquidio/rte_pmd_liquidio_version.map |   3 +-
 drivers/net/memif/rte_pmd_memif_version.map   |   5 +-
 drivers/net/mlx4/rte_pmd_mlx4_version.map     |   3 +-
 drivers/net/mlx5/rte_pmd_mlx5_version.map     |   2 +-
 drivers/net/mvneta/rte_pmd_mvneta_version.map |   2 +-
 drivers/net/mvpp2/rte_pmd_mvpp2_version.map   |   2 +-
 drivers/net/netvsc/rte_pmd_netvsc_version.map |   4 +-
 drivers/net/nfb/rte_pmd_nfb_version.map       |   3 +-
 drivers/net/nfp/rte_pmd_nfp_version.map       |   2 +-
 drivers/net/null/rte_pmd_null_version.map     |   3 +-
 .../net/octeontx/rte_pmd_octeontx_version.map |  10 +-
 .../octeontx2/rte_pmd_octeontx2_version.map   |   3 +-
 drivers/net/pcap/rte_pmd_pcap_version.map     |   3 +-
 drivers/net/qede/rte_pmd_qede_version.map     |   3 +-
 drivers/net/ring/rte_pmd_ring_version.map     |  10 +-
 drivers/net/sfc/rte_pmd_sfc_version.map       |   3 +-
 .../net/softnic/rte_pmd_softnic_version.map   |   2 +-
 .../net/szedata2/rte_pmd_szedata2_version.map |   2 +-
 drivers/net/tap/rte_pmd_tap_version.map       |   3 +-
 .../net/thunderx/rte_pmd_thunderx_version.map |   3 +-
 .../rte_pmd_vdev_netvsc_version.map           |   3 +-
 drivers/net/vhost/rte_pmd_vhost_version.map   |  11 +-
 drivers/net/virtio/rte_pmd_virtio_version.map |   3 +-
 .../net/vmxnet3/rte_pmd_vmxnet3_version.map   |   3 +-
 .../rte_rawdev_dpaa2_cmdif_version.map        |   3 +-
 .../rte_rawdev_dpaa2_qdma_version.map         |   4 +-
 .../raw/ifpga/rte_rawdev_ifpga_version.map    |   3 +-
 drivers/raw/ioat/rte_rawdev_ioat_version.map  |   3 +-
 drivers/raw/ntb/rte_rawdev_ntb_version.map    |   5 +-
 .../rte_rawdev_octeontx2_dma_version.map      |   3 +-
 .../skeleton/rte_rawdev_skeleton_version.map  |   3 +-
 lib/librte_acl/rte_acl_version.map            |   2 +-
 lib/librte_bbdev/rte_bbdev_version.map        |   4 +
 .../rte_bitratestats_version.map              |   2 +-
 lib/librte_bpf/rte_bpf_version.map            |   4 +
 lib/librte_cfgfile/rte_cfgfile_version.map    |  34 +-
 lib/librte_cmdline/rte_cmdline_version.map    |  10 +-
 .../rte_compressdev_version.map               |   4 +
 .../rte_cryptodev_version.map                 | 102 +-
 lib/librte_distributor/Makefile               |   1 -
 lib/librte_distributor/meson.build            |   2 +-
 lib/librte_distributor/rte_distributor.c      | 126 +--
 lib/librte_distributor/rte_distributor.h      |   1 -
 .../rte_distributor_private.h                 |  35 -
 .../rte_distributor_v1705.h                   |  61 --
 lib/librte_distributor/rte_distributor_v20.c  | 402 -------
 lib/librte_distributor/rte_distributor_v20.h  | 218 ----
 .../rte_distributor_version.map               |  16 +-
 lib/librte_eal/rte_eal_version.map            | 310 ++----
 lib/librte_efd/rte_efd_version.map            |   2 +-
 lib/librte_ethdev/rte_ethdev_version.map      | 160 +--
 lib/librte_eventdev/rte_eventdev_version.map  | 130 +--
 .../rte_flow_classify_version.map             |   4 +
 lib/librte_gro/rte_gro_version.map            |   2 +-
 lib/librte_gso/rte_gso_version.map            |   2 +-
 lib/librte_hash/rte_hash_version.map          |  43 +-
 lib/librte_ip_frag/rte_ip_frag_version.map    |  10 +-
 lib/librte_ipsec/rte_ipsec_version.map        |   4 +
 lib/librte_jobstats/rte_jobstats_version.map  |  10 +-
 lib/librte_kni/rte_kni_version.map            |   2 +-
 lib/librte_kvargs/rte_kvargs_version.map      |   4 +-
 .../rte_latencystats_version.map              |   2 +-
 lib/librte_lpm/rte_lpm.c                      | 996 +-----------------
 lib/librte_lpm/rte_lpm.h                      |  88 --
 lib/librte_lpm/rte_lpm6.c                     | 132 +--
 lib/librte_lpm/rte_lpm6.h                     |  25 -
 lib/librte_lpm/rte_lpm_version.map            |  39 +-
 lib/librte_mbuf/rte_mbuf_version.map          |  41 +-
 lib/librte_member/rte_member_version.map      |   2 +-
 lib/librte_mempool/rte_mempool_version.map    |  44 +-
 lib/librte_meter/rte_meter_version.map        |  13 +-
 lib/librte_metrics/rte_metrics_version.map    |   2 +-
 lib/librte_net/rte_net_version.map            |  23 +-
 lib/librte_pci/rte_pci_version.map            |   2 +-
 lib/librte_pdump/rte_pdump_version.map        |   2 +-
 lib/librte_pipeline/rte_pipeline_version.map  |  36 +-
 lib/librte_port/rte_port_version.map          |  64 +-
 lib/librte_power/rte_power_version.map        |  24 +-
 lib/librte_rawdev/rte_rawdev_version.map      |   4 +-
 lib/librte_rcu/rte_rcu_version.map            |   4 +
 lib/librte_reorder/rte_reorder_version.map    |   8 +-
 lib/librte_ring/rte_ring_version.map          |  10 +-
 lib/librte_sched/rte_sched_version.map        |  14 +-
 lib/librte_security/rte_security_version.map  |   2 +-
 lib/librte_stack/rte_stack_version.map        |   4 +
 lib/librte_table/rte_table_version.map        |   2 +-
 .../rte_telemetry_version.map                 |   4 +
 lib/librte_timer/rte_timer.c                  |  90 +-
 lib/librte_timer/rte_timer.h                  |  15 -
 lib/librte_timer/rte_timer_version.map        |  12 +-
 lib/librte_vhost/rte_vhost_version.map        |  52 +-
 lib/meson.build                               |  18 +-
 meson_options.txt                             |   2 -
 mk/rte.lib.mk                                 |  13 +-
 180 files changed, 1111 insertions(+), 3657 deletions(-)
 create mode 100755 buildtools/check-abi-version.sh
 create mode 100755 buildtools/update-abi.sh
 create mode 100755 buildtools/update_version_map_abi.py
 create mode 100644 config/ABI_VERSION
 delete mode 100644 lib/librte_distributor/rte_distributor_v1705.h
 delete mode 100644 lib/librte_distributor/rte_distributor_v20.c
 delete mode 100644 lib/librte_distributor/rte_distributor_v20.h
Signature · 1 line
2.17.1
#24 lore raw

PATCH v3 1/9 config: change ABI versioning to global

From: Marcin Baran <[email protected]>

As per new ABI policy, all of the libraries are now versioned using one global ABI version. Changes in this patch implement the necessary steps to enable that.

---

Notes:
v3:
- Removed Windows support from Makefile changes
- Removed unneeded path conversions from meson files

 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  5 +++--
 drivers/meson.build    | 20 ++++++++++++--------
 lib/meson.build        | 18 +++++++++++-------
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 13 ++++---------
 7 files changed, 33 insertions(+), 28 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +3 -2
index a27f731f85..3cfc02406c 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and libraries
 # depending on the configuration options
 pver = meson.project_version().split('.')
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+abi_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())
@@ -37,7 +38,7 @@ endif
 
 pmd_subdir_opt = get_option('drivers_install_subdir')
 if pmd_subdir_opt.contains('<VERSION>')
-	pmd_subdir_opt = major_version.join(pmd_subdir_opt.split('<VERSION>'))
+	pmd_subdir_opt = abi_version.join(pmd_subdir_opt.split('<VERSION>'))
 endif
 driver_install_path = join_paths(get_option('libdir'), pmd_subdir_opt)
 eal_pmd_path = join_paths(get_option('prefix'), driver_install_path)
drivers/meson.build +12 -8
index 2ed2e95411..fd628d9587 100644
@@ -110,12 +110,19 @@ foreach class:dpdk_driver_classes
 					output: out_filename,
 					depends: [pmdinfogen, tmp_lib])
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/@2@_version.map'.format(
+					meson.current_source_dir(),
+					drv_path, lib_name)
+
+			is_experimental = run_command(is_experimental_cmd,
+				files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
-				lib_version = major_version
-				so_version = major_version
+				lib_version = abi_version
+				so_version = abi_version
 			endif
 
 			# now build the static driver
@@ -128,9 +135,6 @@ foreach class:dpdk_driver_classes
 				install: true)
 
 			# now build the shared driver
-			version_map = '@0@/@1@/@2@_version.map'.format(
-					meson.current_source_dir(),
-					drv_path, lib_name)
 			shared_lib = shared_library(lib_name,
 				sources,
 				objects: objs,
lib/meson.build +11 -7
index e5ff838934..e626da778c 100644
@@ -97,12 +97,18 @@ foreach l:libraries
 				cflags += '-DALLOW_EXPERIMENTAL_API'
 			endif
 
-			if get_option('per_library_versions')
-				lib_version = '@[email protected]'.format(version)
-				so_version = '@0@'.format(version)
+			version_map = '@0@/@1@/rte_@2@_version.map'.format(
+					meson.current_source_dir(), dir_name, name)
+
+			is_experimental = run_command(is_experimental_cmd,
+					files(version_map)).returncode()
+
+			if is_experimental != 0
+				lib_version = '0.1'
+				so_version = '0'
 			else
-				lib_version = major_version
-				so_version = major_version
+				lib_version = abi_version
+				so_version = abi_version
 			endif
 
 			# first build static lib
@@ -120,8 +126,6 @@ foreach l:libraries
 			# then use pre-build objects to build shared lib
 			sources = []
 			objs += static_lib.extract_all_objects(recursive: false)
-			version_map = '@0@/@1@/rte_@2@_version.map'.format(
-					meson.current_source_dir(), dir_name, name)
 			implib = dir_name + '.dll.a'
 
 			def_file = custom_target(name + '_def',
meson_options.txt +0 -2
index 448f3e63dc..000e38fd98 100644
@@ -28,8 +28,6 @@ option('max_lcores', type: 'integer', value: 128,
 	description: 'maximum number of cores/threads supported by EAL')
 option('max_numa_nodes', type: 'integer', value: 4,
 	description: 'maximum number of NUMA nodes supported by EAL')
-option('per_library_versions', type: 'boolean', value: true,
-	description: 'true: each lib gets its own version number, false: DPDK version used for each lib')
 option('tests', type: 'boolean', value: true,
 	description: 'build unit tests')
 option('use_hpet', type: 'boolean', value: false,
mk/rte.lib.mk +4 -9
index 4df8849a08..e1ea292b6e 100644
@@ -11,20 +11,15 @@ EXTLIB_BUILD ?= n
 # VPATH contains at least SRCDIR
 VPATH += $(SRCDIR)
 
-ifneq ($(CONFIG_RTE_MAJOR_ABI),)
-ifneq ($(LIBABIVER),)
-LIBABIVER := $(CONFIG_RTE_MAJOR_ABI)
-endif
+ifneq ($(shell grep "^DPDK_" $(SRCDIR)/$(EXPORT_MAP)),)
+LIBABIVER := $(shell cat $(RTE_SRCDIR)/config/ABI_VERSION)
+else
+LIBABIVER := 0
 endif
 
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
 LIB := $(patsubst %.a,%.so.$(LIBABIVER),$(LIB))
 ifeq ($(EXTLIB_BUILD),n)
-ifeq ($(CONFIG_RTE_MAJOR_ABI),)
-ifeq ($(CONFIG_RTE_NEXT_ABI),y)
-LIB := $(LIB).1
-endif
-endif
 CPU_LDFLAGS += --version-script=$(SRCDIR)/$(EXPORT_MAP)
 endif
 endif
Signature · 1 line
2.17.1
#25 lore raw

Re: [dpdk-dev] [PATCH v3 1/9] config: change ABI versioning to global

Quoted 58 lines · Anatoly Burakov

From: Marcin Baran <[email protected]>

As per new ABI policy, all of the libraries are now versioned using one global ABI version. Changes in this patch implement the necessary steps to enable that.

---

Notes:
v3:
- Removed Windows support from Makefile changes
- Removed unneeded path conversions from meson files

 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  5 +++--
 drivers/meson.build    | 20 ++++++++++++--------
 lib/meson.build        | 18 +++++++++++-------
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 13 ++++---------
 7 files changed, 33 insertions(+), 28 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +2 -1
index a27f731f85..3cfc02406c 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and libraries
 # depending on the configuration options
 pver = meson.project_version().split('.')
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+abi_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())

config/meson.build endif · line 42

Quoted 6 lines
config/meson.build +1 -1
@@ -37,7 +38,7 @@ endif
 
 pmd_subdir_opt = get_option('drivers_install_subdir')
 if pmd_subdir_opt.contains('<VERSION>')
-	pmd_subdir_opt = major_version.join(pmd_subdir_opt.split('<VERSION>'))
+	pmd_subdir_opt = abi_version.join(pmd_subdir_opt.split('<VERSION>'))
 endif

This is an interesting change, and I'm not sure about it. I think for user-visible changes, version should still refer to DPDK version rather than ABI version. Even with a stable ABI, it makes more sense to me to find the drivers in a 19.11 directory than a 20.0 one. Then again, the drivers should be re-usable across the one ABI version, so perhaps this is the best approach.

Thoughts from others? Luca or Kevin, any thoughts from a packagers perspective?

/Bruce

#26 lore raw

Re: [dpdk-dev] [PATCH v3 1/9] config: change ABI versioning to global

Quoted 73 lines · Bruce Richardson
Quoted 58 lines · Anatoly Burakov

From: Marcin Baran <[email protected]>

As per new ABI policy, all of the libraries are now versioned using one global ABI version. Changes in this patch implement the necessary steps to enable that.

---

Notes:
v3:
- Removed Windows support from Makefile changes
- Removed unneeded path conversions from meson files

  buildtools/meson.build |  2 ++
  config/ABI_VERSION     |  1 +
  config/meson.build     |  5 +++--
  drivers/meson.build    | 20 ++++++++++++--------
  lib/meson.build        | 18 +++++++++++-------
  meson_options.txt      |  2 --
  mk/rte.lib.mk          | 13 ++++---------
  7 files changed, 33 insertions(+), 28 deletions(-)

create mode 100644 config/ABI_VERSION

buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
  else
  	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
  endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +2 -1
index a27f731f85..3cfc02406c 100644
@@ -17,7 +17,8 @@ endforeach
  # set the major version, which might be used by drivers and libraries
  # depending on the configuration options
  pver = meson.project_version().split('.')
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+abi_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
  # extract all version information into the build configuration
  dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())

config/meson.build endif · line 42

Quoted 6 lines
config/meson.build +1 -1
@@ -37,7 +38,7 @@ endif
 
  pmd_subdir_opt = get_option('drivers_install_subdir')
  if pmd_subdir_opt.contains('<VERSION>')
-	pmd_subdir_opt = major_version.join(pmd_subdir_opt.split('<VERSION>'))
+	pmd_subdir_opt = abi_version.join(pmd_subdir_opt.split('<VERSION>'))
  endif

This is an interesting change, and I'm not sure about it. I think for user-visible changes, version should still refer to DPDK version rather than ABI version. Even with a stable ABI, it makes more sense to me to find the drivers in a 19.11 directory than a 20.0 one. Then again, the drivers should be re-usable across the one ABI version, so perhaps this is the best approach.

Quoted 4 lines

Thoughts from others? Luca or Kevin, any thoughts from a packagers perspective?

/Bruce

I can certainly change it back. This wasn't intentional - i just did a search-and-replace without thinking too much about it :)

Signature · 2 lines
Thanks,
Anatoly
#27 lore raw

Re: [dpdk-dev] [PATCH v3 1/9] config: change ABI versioning to global

In reply to Bruce Richardson
Quoted 88 lines · Bruce Richardson
Quoted 67 lines · Anatoly Burakov

From: Marcin Baran <
[email protected]

Quoted 1 line

As per new ABI policy, all of the libraries are now versioned using one global ABI version. Changes in this patch implement the necessary steps to enable that.

Signed-off-by: Marcin Baran <
[email protected]

Quoted 1 line

Signed-off-by: Pawel Modrak <
[email protected]

Quoted 1 line

Signed-off-by: Anatoly Burakov <
[email protected]

Quoted 1 line

---

Notes:
v3:
- Removed Windows support from Makefile changes
- Removed unneeded path conversions from meson files

 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  5 +++--
 drivers/meson.build    | 20 ++++++++++++--------
 lib/meson.build        | 18 +++++++++++-------
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 13 ++++---------
 7 files changed, 33 insertions(+), 28 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +0 -0
index a27f731f85..3cfc02406c 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and

libraries

 # depending on the configuration options
 pver = meson.project_version().split('.')
config/meson.build +2 -1
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+abi_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())

config/meson.build endif · line 44

Quoted 8 lines
config/meson.build +1 -1
@@ -37,7 +38,7 @@ endif
 
 pmd_subdir_opt = get_option('drivers_install_subdir')
 if pmd_subdir_opt.contains('<VERSION>')
-	pmd_subdir_opt =
 major_version.join(pmd_subdir_opt.split('<VERSION>'))
+	pmd_subdir_opt =
 abi_version.join(pmd_subdir_opt.split('<VERSION>'))
 endif

This is an interesting change, and I'm not sure about it. I think for user-visible changes, version should still refer to DPDK version rather
than ABI version. Even with a stable ABI, it makes more sense to me to find
the drivers in a 19.11 directory than a 20.0 one. Then again, the drivers
should be re-usable across the one ABI version, so perhaps this is the best
approach.

Quoted 4 lines

Thoughts from others? Luca or Kevin, any thoughts from a packagers perspective?

/Bruce

Hi,

We are currently assembing this path using the ABI version in Debian/Ubuntu, as we want same-ABI libraries not to be co-installed, but instead fo use the exact same name/path. So from our POV this change seems right.

Signature · 2 lines
Kind regards,
Luca Boccassi
#28 lore raw

Re: [dpdk-dev] [PATCH v3 1/9] config: change ABI versioning to global

Quoted 92 lines · Luca Boccassi
Quoted 91 lines · Bruce Richardson
Quoted 67 lines · Anatoly Burakov

From: Marcin Baran <
[email protected]

Quoted 1 line

As per new ABI policy, all of the libraries are now versioned using one global ABI version. Changes in this patch implement the necessary steps to enable that.

Signed-off-by: Marcin Baran <
[email protected]

Quoted 1 line

Signed-off-by: Pawel Modrak <
[email protected]

Quoted 1 line

Signed-off-by: Anatoly Burakov <
[email protected]

Quoted 1 line

---

Notes:
v3:
- Removed Windows support from Makefile changes
- Removed unneeded path conversions from meson files

 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  5 +++--
 drivers/meson.build    | 20 ++++++++++++--------
 lib/meson.build        | 18 +++++++++++-------
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 13 ++++---------
 7 files changed, 33 insertions(+), 28 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +0 -0
index a27f731f85..3cfc02406c 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and

libraries

 # depending on the configuration options
 pver = meson.project_version().split('.')
config/meson.build +2 -1
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+abi_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())

config/meson.build endif · line 44

Quoted 8 lines
config/meson.build +1 -1
@@ -37,7 +38,7 @@ endif
 
 pmd_subdir_opt = get_option('drivers_install_subdir')
 if pmd_subdir_opt.contains('<VERSION>')
-	pmd_subdir_opt =
 major_version.join(pmd_subdir_opt.split('<VERSION>'))
+	pmd_subdir_opt =
 abi_version.join(pmd_subdir_opt.split('<VERSION>'))
 endif

This is an interesting change, and I'm not sure about it. I think for user-visible changes, version should still refer to DPDK version rather
than ABI version. Even with a stable ABI, it makes more sense to me to find
the drivers in a 19.11 directory than a 20.0 one. Then again, the drivers
should be re-usable across the one ABI version, so perhaps this is the best
approach.

Thoughts from others? Luca or Kevin, any thoughts from a packagers perspective?

Quoted 9 lines
Quoted 1 line

/Bruce

Hi,

We are currently assembing this path using the ABI version in Debian/Ubuntu, as we want same-ABI libraries not to be co-installed, but instead fo use the exact same name/path. So from our POV this change seems right.

Thanks for confirming, Luca.

#29 lore raw

Re: [dpdk-dev] [PATCH v3 1/9] config: change ABI versioning to global

In reply to Luca Boccassi
Quoted 92 lines · Luca Boccassi
Quoted 91 lines · Bruce Richardson
Quoted 67 lines · Anatoly Burakov

From: Marcin Baran <
[email protected]

Quoted 1 line

As per new ABI policy, all of the libraries are now versioned using one global ABI version. Changes in this patch implement the necessary steps to enable that.

Signed-off-by: Marcin Baran <
[email protected]

Quoted 1 line

Signed-off-by: Pawel Modrak <
[email protected]

Quoted 1 line

Signed-off-by: Anatoly Burakov <
[email protected]

Quoted 1 line

---

Notes:
v3:
- Removed Windows support from Makefile changes
- Removed unneeded path conversions from meson files

 buildtools/meson.build |  2 ++
 config/ABI_VERSION     |  1 +
 config/meson.build     |  5 +++--
 drivers/meson.build    | 20 ++++++++++++--------
 lib/meson.build        | 18 +++++++++++-------
 meson_options.txt      |  2 --
 mk/rte.lib.mk          | 13 ++++---------
 7 files changed, 33 insertions(+), 28 deletions(-)
 create mode 100644 config/ABI_VERSION
buildtools/meson.build +2 -0
index 32c79c1308..78ce69977d 100644
@@ -12,3 +12,5 @@ if python3.found()
 else
 	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
 endif
+
+is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
config/ABI_VERSION new file +1 -0
new file mode 100644
index 0000000000..9a7c1e503f
@@ -0,0 +1 @@
+20.0
config/meson.build +0 -0
index a27f731f85..3cfc02406c 100644
@@ -17,7 +17,8 @@ endforeach
 # set the major version, which might be used by drivers and

libraries

 # depending on the configuration options
 pver = meson.project_version().split('.')
config/meson.build +2 -1
-major_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+abi_version = run_command(find_program('cat', 'more'),
+	files('ABI_VERSION')).stdout().strip()
 
 # extract all version information into the build configuration
 dpdk_conf.set('RTE_VER_YEAR', pver.get(0).to_int())

config/meson.build endif · line 44

Quoted 8 lines
config/meson.build +1 -1
@@ -37,7 +38,7 @@ endif
 
 pmd_subdir_opt = get_option('drivers_install_subdir')
 if pmd_subdir_opt.contains('<VERSION>')
-	pmd_subdir_opt =
 major_version.join(pmd_subdir_opt.split('<VERSION>'))
+	pmd_subdir_opt =
 abi_version.join(pmd_subdir_opt.split('<VERSION>'))
 endif

This is an interesting change, and I'm not sure about it. I think for user-visible changes, version should still refer to DPDK version rather
than ABI version. Even with a stable ABI, it makes more sense to me to find
the drivers in a 19.11 directory than a 20.0 one. Then again, the drivers
should be re-usable across the one ABI version, so perhaps this is the best
approach.

Thoughts from others? Luca or Kevin, any thoughts from a packagers perspective?

Quoted 9 lines
Quoted 1 line

/Bruce

Hi,

We are currently assembing this path using the ABI version in Debian/Ubuntu, as we want same-ABI libraries not to be co-installed, but instead fo use the exact same name/path. So from our POV this change seems right.

Seems ok to me as it's consistent with having the libs from different releases using one ABI version. Would like to check with Timothy too..

+ Timothy

#30 lore raw

PATCH v3 2/9 buildtools: add script for updating symbols abi version

In reply to Anatoly Burakov

From: Pawel Modrak <[email protected]>

Add a script that automatically merges all stable ABI's under one ABI section with the new version, while leaving experimental section exactly as it is.

---

Notes:
v3:
- Add comments to regex patterns

v2:
- Reworked script to be pep8-compliant and more reliable

 buildtools/update_version_map_abi.py | 170 +++++++++++++++++++++++++++
 1 file changed, 170 insertions(+)
 create mode 100755 buildtools/update_version_map_abi.py
buildtools/update_version_map_abi.py new file +170 -0
new file mode 100755
index 0000000000..50283e6a3d
@@ -0,0 +1,170 @@
+#!/usr/bin/env python
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+"""
+A Python program to update the ABI version and function names in a DPDK
+lib_*_version.map file. Called from the buildtools/update_abi.sh utility.
+"""
+
+from __future__ import print_function
+import argparse
+import sys
+import re
+
+
+def __parse_map_file(f_in):
+    # match function name, followed by semicolon, followed by EOL, optionally
+    # with whitespace inbetween each item
+    func_line_regex = re.compile(r"\s*"
+                                 r"(?P<func>[a-zA-Z_0-9]+)"
+                                 r"\s*"
+                                 r";"
+                                 r"\s*"
+                                 r"$")
+    # match section name, followed by opening bracked, followed by EOL,
+    # optionally with whitespace inbetween each item
+    section_begin_regex = re.compile(r"\s*"
+                                     r"(?P<version>[a-zA-Z0-9_\.]+)"
+                                     r"\s*"
+                                     r"{"
+                                     r"\s*"
+                                     r"$")
+    # match closing bracket, optionally followed by section name (for when we
+    # inherit from another ABI version), followed by semicolon, followed by
+    # EOL, optionally with whitespace inbetween each item
+    section_end_regex = re.compile(r"\s*"
+                                   r"}"
+                                   r"\s*"
+                                   r"(?P<parent>[a-zA-Z0-9_\.]+)?"
+                                   r"\s*"
+                                   r";"
+                                   r"\s*"
+                                   r"$")
+
+    # for stable ABI, we don't care about which version introduced which
+    # function, we just flatten the list. there are dupes in certain files, so
+    # use a set instead of a list
+    stable_lines = set()
+    # copy experimental section as is
+    experimental_lines = []
+    is_experimental = False
+
+    # gather all functions
+    for line in f_in:
+        # clean up the line
+        line = line.strip('\n').strip()
+
+        # is this an end of section?
+        match = section_end_regex.match(line)
+        if match:
+            # whatever section this was, it's not active any more
+            is_experimental = False
+            continue
+
+        # if we're in the middle of experimental section, we need to copy
+        # the section verbatim, so just add the line
+        if is_experimental:
+            experimental_lines += [line]
+            continue
+
+        # skip empty lines
+        if not line:
+            continue
+
+        # is this a beginning of a new section?
+        match = section_begin_regex.match(line)
+        if match:
+            cur_section = match.group("version")
+            # is it experimental?
+            is_experimental = cur_section == "EXPERIMENTAL"
+            continue
+
+        # is this a function?
+        match = func_line_regex.match(line)
+        if match:
+            stable_lines.add(match.group("func"))
+
+    return stable_lines, experimental_lines
+
+
+def __regenerate_map_file(f_out, abi_version, stable_lines,
+                          experimental_lines):
+    # print ABI version header
+    print("DPDK_{} {{".format(abi_version), file=f_out)
+
+    if stable_lines:
+        # print global section
+        print("\tglobal:", file=f_out)
+        # blank line
+        print(file=f_out)
+
+        # print all stable lines, alphabetically sorted
+        for line in sorted(stable_lines):
+            print("\t{};".format(line), file=f_out)
+
+        # another blank line
+        print(file=f_out)
+
+    # print local section
+    print("\tlocal: *;", file=f_out)
+
+    # end stable version
+    print("};", file=f_out)
+
+    # do we have experimental lines?
+    if not experimental_lines:
+        return
+
+    # another blank line
+    print(file=f_out)
+
+    # start experimental section
+    print("EXPERIMENTAL {", file=f_out)
+
+    # print all experimental lines as they were
+    for line in experimental_lines:
+        # don't print empty whitespace
+        if not line:
+            print("", file=f_out)
+        else:
+            print("\t{}".format(line), file=f_out)
+
+    # end section
+    print("};", file=f_out)
+
+
+def __main():
+    arg_parser = argparse.ArgumentParser(
+        description='Merge versions in linker version script.')
+
+    arg_parser.add_argument("map_file", type=str,
+                            help='path to linker version script file '
+                                 '(pattern: *version.map)')
+    arg_parser.add_argument("abi_version", type=str,
+                            help='target ABI version (pattern: MAJOR.MINOR)')
+
+    parsed = arg_parser.parse_args()
+
+    if not parsed.map_file.endswith('version.map'):
+        print("Invalid input file: {}".format(parsed.map_file),
+              file=sys.stderr)
+        arg_parser.print_help()
+        sys.exit(1)
+
+    if not re.match(r"\d{1,2}\.\d{1,2}", parsed.abi_version):
+        print("Invalid ABI version: {}".format(parsed.abi_version),
+              file=sys.stderr)
+        arg_parser.print_help()
+        sys.exit(1)
+
+    with open(parsed.map_file) as f_in:
+        stable_lines, experimental_lines = __parse_map_file(f_in)
+
+    with open(parsed.map_file, 'w') as f_out:
+        __regenerate_map_file(f_out, parsed.abi_version, stable_lines,
+                              experimental_lines)
+
+
+if __name__ == "__main__":
+    __main()
Signature · 1 line
2.17.1
#31 lore raw

PATCH v3 3/9 buildtools: add ABI update shell script

In reply to Anatoly Burakov

In order to facilitate mass updating of version files, add a shell script that recurses into lib/ and drivers/ directories and calls the ABI version update script.

---

Notes:
v3:
- Switch to sh rather than bash, and remove bash-isms
- Address review comments

v2:
- Add this patch to split the shell script from previous commit
- Fixup miscellaneous bugs

 buildtools/update-abi.sh | 42 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)
 create mode 100755 buildtools/update-abi.sh
buildtools/update-abi.sh new file +42 -0
new file mode 100755
index 0000000000..89ba5804a6
@@ -0,0 +1,42 @@
+#!/bin/sh
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+abi_version=$1
+abi_version_file="./config/ABI_VERSION"
+update_path="lib drivers"
+
+if [ -z "$1" ]; then
+      # output to stderr
+      >&2 echo "Please provide ABI version"
+      exit 1
+fi
+
+# check version string format
+echo $abi_version | grep -q -e "^[[:digit:]]\{1,2\}\.[[:digit:]]\{1,2\}$"
+if [ "$?" -ne 0 ]; then
+      # output to stderr
+      >&2 echo "ABI version must be formatted as MAJOR.MINOR version"
+      exit 1
+fi
+
+if [ -n "$2" ]; then
+      abi_version_file=$2
+fi
+
+if [ -n "$3" ]; then
+      # drop $1 and $2
+      shift 2
+      # assign all other arguments as update paths
+      update_path=$@
+fi
+
+echo "New ABI version:" $abi_version
+echo "ABI_VERSION path:" $abi_version_file
+echo "Path to update:" $update_path
+
+echo $abi_version > $abi_version_file
+
+find $update_path -name  \*version.map -exec \
+      ./buildtools/update_version_map_abi.py {} \
+      $abi_version \; -print
Signature · 1 line
2.17.1
#32 lore raw

PATCH v3 4/9 timer: remove deprecated code

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v2:
- Moved this to before ABI version bump to avoid compile breakage

 lib/librte_timer/rte_timer.c | 90 ++----------------------------------
 lib/librte_timer/rte_timer.h | 15 ------
 2 files changed, 5 insertions(+), 100 deletions(-)
lib/librte_timer/rte_timer.c +5 -85
index bdcf05d06b..de6959b809 100644
@@ -68,9 +68,6 @@ static struct rte_timer_data *rte_timer_data_arr;
 static const uint32_t default_data_id;
 static uint32_t rte_timer_subsystem_initialized;
 
-/* For maintaining older interfaces for a period */
-static struct rte_timer_data default_timer_data;
-
 /* when debug is enabled, store some statistics */
 #ifdef RTE_LIBRTE_TIMER_DEBUG
 #define __TIMER_STAT_ADD(priv_timer, name, n) do {			\
@@ -131,22 +128,6 @@ rte_timer_data_dealloc(uint32_t id)
 	return 0;
 }
 
-void
-rte_timer_subsystem_init_v20(void)
-{
-	unsigned lcore_id;
-	struct priv_timer *priv_timer = default_timer_data.priv_timer;
-
-	/* since priv_timer is static, it's zeroed by default, so only init some
-	 * fields.
-	 */
-	for (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id ++) {
-		rte_spinlock_init(&priv_timer[lcore_id].list_lock);
-		priv_timer[lcore_id].prev_lcore = lcore_id;
-	}
-}
-VERSION_SYMBOL(rte_timer_subsystem_init, _v20, 2.0);
-
 /* Init the timer library. Allocate an array of timer data structs in shared
  * memory, and allocate the zeroth entry for use with original timer
  * APIs. Since the intersection of the sets of lcore ids in primary and
@@ -154,7 +135,7 @@ VERSION_SYMBOL(rte_timer_subsystem_init, _v20, 2.0);
  * multiple processes.
  */
 int
-rte_timer_subsystem_init_v1905(void)
+rte_timer_subsystem_init(void)
 {
 	const struct rte_memzone *mz;
 	struct rte_timer_data *data;
@@ -209,9 +190,6 @@ rte_timer_subsystem_init_v1905(void)
 
 	return 0;
 }
-MAP_STATIC_SYMBOL(int rte_timer_subsystem_init(void),
-		  rte_timer_subsystem_init_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_subsystem_init, _v1905, 19.05);
 
 void
 rte_timer_subsystem_finalize(void)
@@ -552,42 +530,13 @@ __rte_timer_reset(struct rte_timer *tim, uint64_t expire,
 
 /* Reset and start the timer associated with the timer handle tim */
 int
-rte_timer_reset_v20(struct rte_timer *tim, uint64_t ticks,
-		    enum rte_timer_type type, unsigned int tim_lcore,
-		    rte_timer_cb_t fct, void *arg)
-{
-	uint64_t cur_time = rte_get_timer_cycles();
-	uint64_t period;
-
-	if (unlikely((tim_lcore != (unsigned)LCORE_ID_ANY) &&
-			!(rte_lcore_is_enabled(tim_lcore) ||
-			  rte_lcore_has_role(tim_lcore, ROLE_SERVICE))))
-		return -1;
-
-	if (type == PERIODICAL)
-		period = ticks;
-	else
-		period = 0;
-
-	return __rte_timer_reset(tim,  cur_time + ticks, period, tim_lcore,
-			  fct, arg, 0, &default_timer_data);
-}
-VERSION_SYMBOL(rte_timer_reset, _v20, 2.0);
-
-int
-rte_timer_reset_v1905(struct rte_timer *tim, uint64_t ticks,
+rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
 		      enum rte_timer_type type, unsigned int tim_lcore,
 		      rte_timer_cb_t fct, void *arg)
 {
 	return rte_timer_alt_reset(default_data_id, tim, ticks, type,
 				   tim_lcore, fct, arg);
 }
-MAP_STATIC_SYMBOL(int rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
-				      enum rte_timer_type type,
-				      unsigned int tim_lcore,
-				      rte_timer_cb_t fct, void *arg),
-		  rte_timer_reset_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_reset, _v1905, 19.05);
 
 int
 rte_timer_alt_reset(uint32_t timer_data_id, struct rte_timer *tim,
@@ -658,20 +607,10 @@ __rte_timer_stop(struct rte_timer *tim, int local_is_locked,
 
 /* Stop the timer associated with the timer handle tim */
 int
-rte_timer_stop_v20(struct rte_timer *tim)
-{
-	return __rte_timer_stop(tim, 0, &default_timer_data);
-}
-VERSION_SYMBOL(rte_timer_stop, _v20, 2.0);
-
-int
-rte_timer_stop_v1905(struct rte_timer *tim)
+rte_timer_stop(struct rte_timer *tim)
 {
 	return rte_timer_alt_stop(default_data_id, tim);
 }
-MAP_STATIC_SYMBOL(int rte_timer_stop(struct rte_timer *tim),
-		  rte_timer_stop_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_stop, _v1905, 19.05);
 
 int
 rte_timer_alt_stop(uint32_t timer_data_id, struct rte_timer *tim)
@@ -817,15 +756,8 @@ __rte_timer_manage(struct rte_timer_data *timer_data)
 	priv_timer[lcore_id].running_tim = NULL;
 }
 
-void
-rte_timer_manage_v20(void)
-{
-	__rte_timer_manage(&default_timer_data);
-}
-VERSION_SYMBOL(rte_timer_manage, _v20, 2.0);
-
 int
-rte_timer_manage_v1905(void)
+rte_timer_manage(void)
 {
 	struct rte_timer_data *timer_data;
 
@@ -835,8 +767,6 @@ rte_timer_manage_v1905(void)
 
 	return 0;
 }
-MAP_STATIC_SYMBOL(int rte_timer_manage(void), rte_timer_manage_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_manage, _v1905, 19.05);
 
 int
 rte_timer_alt_manage(uint32_t timer_data_id,
@@ -1074,21 +1004,11 @@ __rte_timer_dump_stats(struct rte_timer_data *timer_data __rte_unused, FILE *f)
 #endif
 }
 
-void
-rte_timer_dump_stats_v20(FILE *f)
-{
-	__rte_timer_dump_stats(&default_timer_data, f);
-}
-VERSION_SYMBOL(rte_timer_dump_stats, _v20, 2.0);
-
 int
-rte_timer_dump_stats_v1905(FILE *f)
+rte_timer_dump_stats(FILE *f)
 {
 	return rte_timer_alt_dump_stats(default_data_id, f);
 }
-MAP_STATIC_SYMBOL(int rte_timer_dump_stats(FILE *f),
-		  rte_timer_dump_stats_v1905);
-BIND_DEFAULT_SYMBOL(rte_timer_dump_stats, _v1905, 19.05);
 
 int
 rte_timer_alt_dump_stats(uint32_t timer_data_id __rte_unused, FILE *f)
lib/librte_timer/rte_timer.h +0 -15
index 05d287d8f2..9dc5fc3092 100644
@@ -181,8 +181,6 @@ int rte_timer_data_dealloc(uint32_t id);
  *      subsystem
  */
 int rte_timer_subsystem_init(void);
-int rte_timer_subsystem_init_v1905(void);
-void rte_timer_subsystem_init_v20(void);
 
 /**
  * @warning
@@ -250,13 +248,6 @@ void rte_timer_init(struct rte_timer *tim);
 int rte_timer_reset(struct rte_timer *tim, uint64_t ticks,
 		    enum rte_timer_type type, unsigned tim_lcore,
 		    rte_timer_cb_t fct, void *arg);
-int rte_timer_reset_v1905(struct rte_timer *tim, uint64_t ticks,
-			  enum rte_timer_type type, unsigned int tim_lcore,
-			  rte_timer_cb_t fct, void *arg);
-int rte_timer_reset_v20(struct rte_timer *tim, uint64_t ticks,
-			enum rte_timer_type type, unsigned int tim_lcore,
-			rte_timer_cb_t fct, void *arg);
-
 
 /**
  * Loop until rte_timer_reset() succeeds.
@@ -313,8 +304,6 @@ rte_timer_reset_sync(struct rte_timer *tim, uint64_t ticks,
  *   - (-1): The timer is in the RUNNING or CONFIG state.
  */
 int rte_timer_stop(struct rte_timer *tim);
-int rte_timer_stop_v1905(struct rte_timer *tim);
-int rte_timer_stop_v20(struct rte_timer *tim);
 
 /**
  * Loop until rte_timer_stop() succeeds.
@@ -358,8 +347,6 @@ int rte_timer_pending(struct rte_timer *tim);
  *   - -EINVAL: timer subsystem not yet initialized
  */
 int rte_timer_manage(void);
-int rte_timer_manage_v1905(void);
-void rte_timer_manage_v20(void);
 
 /**
  * Dump statistics about timers.
@@ -371,8 +358,6 @@ void rte_timer_manage_v20(void);
  *   - -EINVAL: timer subsystem not yet initialized
  */
 int rte_timer_dump_stats(FILE *f);
-int rte_timer_dump_stats_v1905(FILE *f);
-void rte_timer_dump_stats_v20(FILE *f);
 
 /**
  * @warning
Signature · 1 line
2.17.1
#33 lore raw

PATCH v3 5/9 lpm: remove deprecated code

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v2:
- Moved this to before ABI version bump to avoid compile breakage

 lib/librte_lpm/rte_lpm.c  | 996 ++------------------------------------
 lib/librte_lpm/rte_lpm.h  |  88 ----
 lib/librte_lpm/rte_lpm6.c | 132 +----
 lib/librte_lpm/rte_lpm6.h |  25 -
 4 files changed, 48 insertions(+), 1193 deletions(-)
lib/librte_lpm/rte_lpm.c +34 -962
index 3a929a1b16..2687564194 100644
@@ -89,34 +89,8 @@ depth_to_range(uint8_t depth)
 /*
  * Find an existing lpm table and return a pointer to it.
  */
-struct rte_lpm_v20 *
-rte_lpm_find_existing_v20(const char *name)
-{
-	struct rte_lpm_v20 *l = NULL;
-	struct rte_tailq_entry *te;
-	struct rte_lpm_list *lpm_list;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	rte_mcfg_tailq_read_lock();
-	TAILQ_FOREACH(te, lpm_list, next) {
-		l = te->data;
-		if (strncmp(name, l->name, RTE_LPM_NAMESIZE) == 0)
-			break;
-	}
-	rte_mcfg_tailq_read_unlock();
-
-	if (te == NULL) {
-		rte_errno = ENOENT;
-		return NULL;
-	}
-
-	return l;
-}
-VERSION_SYMBOL(rte_lpm_find_existing, _v20, 2.0);
-
 struct rte_lpm *
-rte_lpm_find_existing_v1604(const char *name)
+rte_lpm_find_existing(const char *name)
 {
 	struct rte_lpm *l = NULL;
 	struct rte_tailq_entry *te;
@@ -139,88 +113,12 @@ rte_lpm_find_existing_v1604(const char *name)
 
 	return l;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_find_existing, _v1604, 16.04);
-MAP_STATIC_SYMBOL(struct rte_lpm *rte_lpm_find_existing(const char *name),
-		rte_lpm_find_existing_v1604);
 
 /*
  * Allocates memory for LPM object
  */
-struct rte_lpm_v20 *
-rte_lpm_create_v20(const char *name, int socket_id, int max_rules,
-		__rte_unused int flags)
-{
-	char mem_name[RTE_LPM_NAMESIZE];
-	struct rte_lpm_v20 *lpm = NULL;
-	struct rte_tailq_entry *te;
-	uint32_t mem_size;
-	struct rte_lpm_list *lpm_list;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	RTE_BUILD_BUG_ON(sizeof(struct rte_lpm_tbl_entry_v20) != 2);
-
-	/* Check user arguments. */
-	if ((name == NULL) || (socket_id < -1) || (max_rules == 0)) {
-		rte_errno = EINVAL;
-		return NULL;
-	}
-
-	snprintf(mem_name, sizeof(mem_name), "LPM_%s", name);
-
-	/* Determine the amount of memory to allocate. */
-	mem_size = sizeof(*lpm) + (sizeof(lpm->rules_tbl[0]) * max_rules);
-
-	rte_mcfg_tailq_write_lock();
-
-	/* guarantee there's no existing */
-	TAILQ_FOREACH(te, lpm_list, next) {
-		lpm = te->data;
-		if (strncmp(name, lpm->name, RTE_LPM_NAMESIZE) == 0)
-			break;
-	}
-
-	if (te != NULL) {
-		lpm = NULL;
-		rte_errno = EEXIST;
-		goto exit;
-	}
-
-	/* allocate tailq entry */
-	te = rte_zmalloc("LPM_TAILQ_ENTRY", sizeof(*te), 0);
-	if (te == NULL) {
-		RTE_LOG(ERR, LPM, "Failed to allocate tailq entry\n");
-		rte_errno = ENOMEM;
-		goto exit;
-	}
-
-	/* Allocate memory to store the LPM data structures. */
-	lpm = rte_zmalloc_socket(mem_name, mem_size,
-			RTE_CACHE_LINE_SIZE, socket_id);
-	if (lpm == NULL) {
-		RTE_LOG(ERR, LPM, "LPM memory allocation failed\n");
-		rte_free(te);
-		rte_errno = ENOMEM;
-		goto exit;
-	}
-
-	/* Save user arguments. */
-	lpm->max_rules = max_rules;
-	strlcpy(lpm->name, name, sizeof(lpm->name));
-
-	te->data = lpm;
-
-	TAILQ_INSERT_TAIL(lpm_list, te, next);
-
-exit:
-	rte_mcfg_tailq_write_unlock();
-
-	return lpm;
-}
-VERSION_SYMBOL(rte_lpm_create, _v20, 2.0);
-
 struct rte_lpm *
-rte_lpm_create_v1604(const char *name, int socket_id,
+rte_lpm_create(const char *name, int socket_id,
 		const struct rte_lpm_config *config)
 {
 	char mem_name[RTE_LPM_NAMESIZE];
@@ -320,45 +218,12 @@ rte_lpm_create_v1604(const char *name, int socket_id,
 
 	return lpm;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_create, _v1604, 16.04);
-MAP_STATIC_SYMBOL(
-	struct rte_lpm *rte_lpm_create(const char *name, int socket_id,
-			const struct rte_lpm_config *config), rte_lpm_create_v1604);
 
 /*
  * Deallocates memory for given LPM table.
  */
 void
-rte_lpm_free_v20(struct rte_lpm_v20 *lpm)
-{
-	struct rte_lpm_list *lpm_list;
-	struct rte_tailq_entry *te;
-
-	/* Check user arguments. */
-	if (lpm == NULL)
-		return;
-
-	lpm_list = RTE_TAILQ_CAST(rte_lpm_tailq.head, rte_lpm_list);
-
-	rte_mcfg_tailq_write_lock();
-
-	/* find our tailq entry */
-	TAILQ_FOREACH(te, lpm_list, next) {
-		if (te->data == (void *) lpm)
-			break;
-	}
-	if (te != NULL)
-		TAILQ_REMOVE(lpm_list, te, next);
-
-	rte_mcfg_tailq_write_unlock();
-
-	rte_free(lpm);
-	rte_free(te);
-}
-VERSION_SYMBOL(rte_lpm_free, _v20, 2.0);
-
-void
-rte_lpm_free_v1604(struct rte_lpm *lpm)
+rte_lpm_free(struct rte_lpm *lpm)
 {
 	struct rte_lpm_list *lpm_list;
 	struct rte_tailq_entry *te;
@@ -386,9 +251,6 @@ rte_lpm_free_v1604(struct rte_lpm *lpm)
 	rte_free(lpm);
 	rte_free(te);
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_free, _v1604, 16.04);
-MAP_STATIC_SYMBOL(void rte_lpm_free(struct rte_lpm *lpm),
-		rte_lpm_free_v1604);
 
 /*
  * Adds a rule to the rule table.
@@ -401,79 +263,7 @@ MAP_STATIC_SYMBOL(void rte_lpm_free(struct rte_lpm *lpm),
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static int32_t
-rule_add_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth,
-	uint8_t next_hop)
-{
-	uint32_t rule_gindex, rule_index, last_rule;
-	int i;
-
-	VERIFY_DEPTH(depth);
-
-	/* Scan through rule group to see if rule already exists. */
-	if (lpm->rule_info[depth - 1].used_rules > 0) {
-
-		/* rule_gindex stands for rule group index. */
-		rule_gindex = lpm->rule_info[depth - 1].first_rule;
-		/* Initialise rule_index to point to start of rule group. */
-		rule_index = rule_gindex;
-		/* Last rule = Last used rule in this rule group. */
-		last_rule = rule_gindex + lpm->rule_info[depth - 1].used_rules;
-
-		for (; rule_index < last_rule; rule_index++) {
-
-			/* If rule already exists update its next_hop and return. */
-			if (lpm->rules_tbl[rule_index].ip == ip_masked) {
-				lpm->rules_tbl[rule_index].next_hop = next_hop;
-
-				return rule_index;
-			}
-		}
-
-		if (rule_index == lpm->max_rules)
-			return -ENOSPC;
-	} else {
-		/* Calculate the position in which the rule will be stored. */
-		rule_index = 0;
-
-		for (i = depth - 1; i > 0; i--) {
-			if (lpm->rule_info[i - 1].used_rules > 0) {
-				rule_index = lpm->rule_info[i - 1].first_rule
-						+ lpm->rule_info[i - 1].used_rules;
-				break;
-			}
-		}
-		if (rule_index == lpm->max_rules)
-			return -ENOSPC;
-
-		lpm->rule_info[depth - 1].first_rule = rule_index;
-	}
-
-	/* Make room for the new rule in the array. */
-	for (i = RTE_LPM_MAX_DEPTH; i > depth; i--) {
-		if (lpm->rule_info[i - 1].first_rule
-				+ lpm->rule_info[i - 1].used_rules == lpm->max_rules)
-			return -ENOSPC;
-
-		if (lpm->rule_info[i - 1].used_rules > 0) {
-			lpm->rules_tbl[lpm->rule_info[i - 1].first_rule
-				+ lpm->rule_info[i - 1].used_rules]
-					= lpm->rules_tbl[lpm->rule_info[i - 1].first_rule];
-			lpm->rule_info[i - 1].first_rule++;
-		}
-	}
-
-	/* Add the new rule. */
-	lpm->rules_tbl[rule_index].ip = ip_masked;
-	lpm->rules_tbl[rule_index].next_hop = next_hop;
-
-	/* Increment the used rules counter for this rule group. */
-	lpm->rule_info[depth - 1].used_rules++;
-
-	return rule_index;
-}
-
-static int32_t
-rule_add_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
+rule_add(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 	uint32_t next_hop)
 {
 	uint32_t rule_gindex, rule_index, last_rule;
@@ -549,30 +339,7 @@ rule_add_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static void
-rule_delete_v20(struct rte_lpm_v20 *lpm, int32_t rule_index, uint8_t depth)
-{
-	int i;
-
-	VERIFY_DEPTH(depth);
-
-	lpm->rules_tbl[rule_index] =
-			lpm->rules_tbl[lpm->rule_info[depth - 1].first_rule
-				+ lpm->rule_info[depth - 1].used_rules - 1];
-
-	for (i = depth; i < RTE_LPM_MAX_DEPTH; i++) {
-		if (lpm->rule_info[i].used_rules > 0) {
-			lpm->rules_tbl[lpm->rule_info[i].first_rule - 1] =
-				lpm->rules_tbl[lpm->rule_info[i].first_rule
-					+ lpm->rule_info[i].used_rules - 1];
-			lpm->rule_info[i].first_rule--;
-		}
-	}
-
-	lpm->rule_info[depth - 1].used_rules--;
-}
-
-static void
-rule_delete_v1604(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
+rule_delete(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
 {
 	int i;
 
@@ -599,28 +366,7 @@ rule_delete_v1604(struct rte_lpm *lpm, int32_t rule_index, uint8_t depth)
  * NOTE: Valid range for depth parameter is 1 .. 32 inclusive.
  */
 static int32_t
-rule_find_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth)
-{
-	uint32_t rule_gindex, last_rule, rule_index;
-
-	VERIFY_DEPTH(depth);
-
-	rule_gindex = lpm->rule_info[depth - 1].first_rule;
-	last_rule = rule_gindex + lpm->rule_info[depth - 1].used_rules;
-
-	/* Scan used rules at given depth to find rule. */
-	for (rule_index = rule_gindex; rule_index < last_rule; rule_index++) {
-		/* If rule is found return the rule index. */
-		if (lpm->rules_tbl[rule_index].ip == ip_masked)
-			return rule_index;
-	}
-
-	/* If rule is not found return -EINVAL. */
-	return -EINVAL;
-}
-
-static int32_t
-rule_find_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
+rule_find(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
 {
 	uint32_t rule_gindex, last_rule, rule_index;
 
@@ -644,42 +390,7 @@ rule_find_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth)
  * Find, clean and allocate a tbl8.
  */
 static int32_t
-tbl8_alloc_v20(struct rte_lpm_tbl_entry_v20 *tbl8)
-{
-	uint32_t group_idx; /* tbl8 group index. */
-	struct rte_lpm_tbl_entry_v20 *tbl8_entry;
-
-	/* Scan through tbl8 to find a free (i.e. INVALID) tbl8 group. */
-	for (group_idx = 0; group_idx < RTE_LPM_TBL8_NUM_GROUPS;
-			group_idx++) {
-		tbl8_entry = &tbl8[group_idx * RTE_LPM_TBL8_GROUP_NUM_ENTRIES];
-		/* If a free tbl8 group is found clean it and set as VALID. */
-		if (!tbl8_entry->valid_group) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = INVALID,
-				.depth = 0,
-				.valid_group = VALID,
-			};
-			new_tbl8_entry.next_hop = 0;
-
-			memset(&tbl8_entry[0], 0,
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES *
-					sizeof(tbl8_entry[0]));
-
-			__atomic_store(tbl8_entry, &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-
-			/* Return group index for allocated tbl8 group. */
-			return group_idx;
-		}
-	}
-
-	/* If there are no tbl8 groups free then return error. */
-	return -ENOSPC;
-}
-
-static int32_t
-tbl8_alloc_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
+tbl8_alloc(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
 {
 	uint32_t group_idx; /* tbl8 group index. */
 	struct rte_lpm_tbl_entry *tbl8_entry;
@@ -713,22 +424,7 @@ tbl8_alloc_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t number_tbl8s)
 }
 
 static void
-tbl8_free_v20(struct rte_lpm_tbl_entry_v20 *tbl8, uint32_t tbl8_group_start)
-{
-	/* Set tbl8 group invalid*/
-	struct rte_lpm_tbl_entry_v20 zero_tbl8_entry = {
-		.valid = INVALID,
-		.depth = 0,
-		.valid_group = INVALID,
-	};
-	zero_tbl8_entry.next_hop = 0;
-
-	__atomic_store(&tbl8[tbl8_group_start], &zero_tbl8_entry,
-			__ATOMIC_RELAXED);
-}
-
-static void
-tbl8_free_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
+tbl8_free(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
 {
 	/* Set tbl8 group invalid*/
 	struct rte_lpm_tbl_entry zero_tbl8_entry = {0};
@@ -738,78 +434,7 @@ tbl8_free_v1604(struct rte_lpm_tbl_entry *tbl8, uint32_t tbl8_group_start)
 }
 
 static __rte_noinline int32_t
-add_depth_small_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-		uint8_t next_hop)
-{
-	uint32_t tbl24_index, tbl24_range, tbl8_index, tbl8_group_end, i, j;
-
-	/* Calculate the index into Table24. */
-	tbl24_index = ip >> 8;
-	tbl24_range = depth_to_range(depth);
-
-	for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-		/*
-		 * For invalid OR valid and non-extended tbl 24 entries set
-		 * entry.
-		 */
-		if (!lpm->tbl24[i].valid || (lpm->tbl24[i].valid_group == 0 &&
-				lpm->tbl24[i].depth <= depth)) {
-
-			struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-				.valid = VALID,
-				.valid_group = 0,
-				.depth = depth,
-			};
-			new_tbl24_entry.next_hop = next_hop;
-
-			/* Setting tbl24 entry in one go to avoid race
-			 * conditions
-			 */
-			__atomic_store(&lpm->tbl24[i], &new_tbl24_entry,
-					__ATOMIC_RELEASE);
-
-			continue;
-		}
-
-		if (lpm->tbl24[i].valid_group == 1) {
-			/* If tbl24 entry is valid and extended calculate the
-			 *  index into tbl8.
-			 */
-			tbl8_index = lpm->tbl24[i].group_idx *
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-			tbl8_group_end = tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-			for (j = tbl8_index; j < tbl8_group_end; j++) {
-				if (!lpm->tbl8[j].valid ||
-						lpm->tbl8[j].depth <= depth) {
-					struct rte_lpm_tbl_entry_v20
-						new_tbl8_entry = {
-						.valid = VALID,
-						.valid_group = VALID,
-						.depth = depth,
-					};
-					new_tbl8_entry.next_hop = next_hop;
-
-					/*
-					 * Setting tbl8 entry in one go to avoid
-					 * race conditions
-					 */
-					__atomic_store(&lpm->tbl8[j],
-						&new_tbl8_entry,
-						__ATOMIC_RELAXED);
-
-					continue;
-				}
-			}
-		}
-	}
-
-	return 0;
-}
-
-static __rte_noinline int32_t
-add_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+add_depth_small(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint32_t next_hop)
 {
 #define group_idx next_hop
@@ -881,150 +506,7 @@ add_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 }
 
 static __rte_noinline int32_t
-add_depth_big_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked, uint8_t depth,
-		uint8_t next_hop)
-{
-	uint32_t tbl24_index;
-	int32_t tbl8_group_index, tbl8_group_start, tbl8_group_end, tbl8_index,
-		tbl8_range, i;
-
-	tbl24_index = (ip_masked >> 8);
-	tbl8_range = depth_to_range(depth);
-
-	if (!lpm->tbl24[tbl24_index].valid) {
-		/* Search for a free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v20(lpm->tbl8);
-
-		/* Check tbl8 allocation was successful. */
-		if (tbl8_group_index < 0) {
-			return tbl8_group_index;
-		}
-
-		/* Find index into tbl8 and range. */
-		tbl8_index = (tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES) +
-				(ip_masked & 0xFF);
-
-		/* Set tbl8 entry. */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop = next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		/*
-		 * Update tbl24 entry to point to new tbl8 entry. Note: The
-		 * ext_flag and tbl8_index need to be updated simultaneously,
-		 * so assign whole structure in one go
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.group_idx = (uint8_t)tbl8_group_index,
-			.valid = VALID,
-			.valid_group = 1,
-			.depth = 0,
-		};
-
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELEASE);
-
-	} /* If valid entry but not extended calculate the index into Table8. */
-	else if (lpm->tbl24[tbl24_index].valid_group == 0) {
-		/* Search for free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v20(lpm->tbl8);
-
-		if (tbl8_group_index < 0) {
-			return tbl8_group_index;
-		}
-
-		tbl8_group_start = tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-		tbl8_group_end = tbl8_group_start +
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-		/* Populate new tbl8 with tbl24 value. */
-		for (i = tbl8_group_start; i < tbl8_group_end; i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = lpm->tbl24[tbl24_index].depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop =
-				lpm->tbl24[tbl24_index].next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-
-		/* Insert new rule into the tbl8 entry. */
-		for (i = tbl8_index; i < tbl8_index + tbl8_range; i++) {
-			struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-				.valid = VALID,
-				.depth = depth,
-				.valid_group = lpm->tbl8[i].valid_group,
-			};
-			new_tbl8_entry.next_hop = next_hop;
-			__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-					__ATOMIC_RELAXED);
-		}
-
-		/*
-		 * Update tbl24 entry to point to new tbl8 entry. Note: The
-		 * ext_flag and tbl8_index need to be updated simultaneously,
-		 * so assign whole structure in one go.
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-				.group_idx = (uint8_t)tbl8_group_index,
-				.valid = VALID,
-				.valid_group = 1,
-				.depth = 0,
-		};
-
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELEASE);
-
-	} else { /*
-		* If it is valid, extended entry calculate the index into tbl8.
-		*/
-		tbl8_group_index = lpm->tbl24[tbl24_index].group_idx;
-		tbl8_group_start = tbl8_group_index *
-				RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-		tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-
-			if (!lpm->tbl8[i].valid ||
-					lpm->tbl8[i].depth <= depth) {
-				struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-					.valid = VALID,
-					.depth = depth,
-					.valid_group = lpm->tbl8[i].valid_group,
-				};
-				new_tbl8_entry.next_hop = next_hop;
-				/*
-				 * Setting tbl8 entry in one go to avoid race
-				 * condition
-				 */
-				__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-						__ATOMIC_RELAXED);
-
-				continue;
-			}
-		}
-	}
-
-	return 0;
-}
-
-static __rte_noinline int32_t
-add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
+add_depth_big(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 		uint32_t next_hop)
 {
 #define group_idx next_hop
@@ -1037,7 +519,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 
 	if (!lpm->tbl24[tbl24_index].valid) {
 		/* Search for a free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v1604(lpm->tbl8, lpm->number_tbl8s);
+		tbl8_group_index = tbl8_alloc(lpm->tbl8, lpm->number_tbl8s);
 
 		/* Check tbl8 allocation was successful. */
 		if (tbl8_group_index < 0) {
@@ -1083,7 +565,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
 	} /* If valid entry but not extended calculate the index into Table8. */
 	else if (lpm->tbl24[tbl24_index].valid_group == 0) {
 		/* Search for free tbl8 group. */
-		tbl8_group_index = tbl8_alloc_v1604(lpm->tbl8, lpm->number_tbl8s);
+		tbl8_group_index = tbl8_alloc(lpm->tbl8, lpm->number_tbl8s);
 
 		if (tbl8_group_index < 0) {
 			return tbl8_group_index;
@@ -1177,48 +659,7 @@ add_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked, uint8_t depth,
  * Add a route
  */
 int
-rte_lpm_add_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-		uint8_t next_hop)
-{
-	int32_t rule_index, status = 0;
-	uint32_t ip_masked;
-
-	/* Check user arguments. */
-	if ((lpm == NULL) || (depth < 1) || (depth > RTE_LPM_MAX_DEPTH))
-		return -EINVAL;
-
-	ip_masked = ip & depth_to_mask(depth);
-
-	/* Add the rule to the rule table. */
-	rule_index = rule_add_v20(lpm, ip_masked, depth, next_hop);
-
-	/* If the is no space available for new rule return error. */
-	if (rule_index < 0) {
-		return rule_index;
-	}
-
-	if (depth <= MAX_DEPTH_TBL24) {
-		status = add_depth_small_v20(lpm, ip_masked, depth, next_hop);
-	} else { /* If depth > RTE_LPM_MAX_DEPTH_TBL24 */
-		status = add_depth_big_v20(lpm, ip_masked, depth, next_hop);
-
-		/*
-		 * If add fails due to exhaustion of tbl8 extensions delete
-		 * rule that was added to rule table.
-		 */
-		if (status < 0) {
-			rule_delete_v20(lpm, rule_index, depth);
-
-			return status;
-		}
-	}
-
-	return 0;
-}
-VERSION_SYMBOL(rte_lpm_add, _v20, 2.0);
-
-int
-rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+rte_lpm_add(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint32_t next_hop)
 {
 	int32_t rule_index, status = 0;
@@ -1231,7 +672,7 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 	ip_masked = ip & depth_to_mask(depth);
 
 	/* Add the rule to the rule table. */
-	rule_index = rule_add_v1604(lpm, ip_masked, depth, next_hop);
+	rule_index = rule_add(lpm, ip_masked, depth, next_hop);
 
 	/* If the is no space available for new rule return error. */
 	if (rule_index < 0) {
@@ -1239,16 +680,16 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 	}
 
 	if (depth <= MAX_DEPTH_TBL24) {
-		status = add_depth_small_v1604(lpm, ip_masked, depth, next_hop);
+		status = add_depth_small(lpm, ip_masked, depth, next_hop);
 	} else { /* If depth > RTE_LPM_MAX_DEPTH_TBL24 */
-		status = add_depth_big_v1604(lpm, ip_masked, depth, next_hop);
+		status = add_depth_big(lpm, ip_masked, depth, next_hop);
 
 		/*
 		 * If add fails due to exhaustion of tbl8 extensions delete
 		 * rule that was added to rule table.
 		 */
 		if (status < 0) {
-			rule_delete_v1604(lpm, rule_index, depth);
+			rule_delete(lpm, rule_index, depth);
 
 			return status;
 		}
@@ -1256,42 +697,12 @@ rte_lpm_add_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_add, _v1604, 16.04);
-MAP_STATIC_SYMBOL(int rte_lpm_add(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth, uint32_t next_hop), rte_lpm_add_v1604);
 
 /*
  * Look for a rule in the high-level rules table
  */
 int
-rte_lpm_is_rule_present_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
-uint8_t *next_hop)
-{
-	uint32_t ip_masked;
-	int32_t rule_index;
-
-	/* Check user arguments. */
-	if ((lpm == NULL) ||
-		(next_hop == NULL) ||
-		(depth < 1) || (depth > RTE_LPM_MAX_DEPTH))
-		return -EINVAL;
-
-	/* Look for the rule using rule_find. */
-	ip_masked = ip & depth_to_mask(depth);
-	rule_index = rule_find_v20(lpm, ip_masked, depth);
-
-	if (rule_index >= 0) {
-		*next_hop = lpm->rules_tbl[rule_index].next_hop;
-		return 1;
-	}
-
-	/* If rule is not found return 0. */
-	return 0;
-}
-VERSION_SYMBOL(rte_lpm_is_rule_present, _v20, 2.0);
-
-int
-rte_lpm_is_rule_present_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
+rte_lpm_is_rule_present(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 uint32_t *next_hop)
 {
 	uint32_t ip_masked;
@@ -1305,7 +716,7 @@ uint32_t *next_hop)
 
 	/* Look for the rule using rule_find. */
 	ip_masked = ip & depth_to_mask(depth);
-	rule_index = rule_find_v1604(lpm, ip_masked, depth);
+	rule_index = rule_find(lpm, ip_masked, depth);
 
 	if (rule_index >= 0) {
 		*next_hop = lpm->rules_tbl[rule_index].next_hop;
@@ -1315,12 +726,9 @@ uint32_t *next_hop)
 	/* If rule is not found return 0. */
 	return 0;
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_is_rule_present, _v1604, 16.04);
-MAP_STATIC_SYMBOL(int rte_lpm_is_rule_present(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth, uint32_t *next_hop), rte_lpm_is_rule_present_v1604);
 
 static int32_t
-find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
+find_previous_rule(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
 		uint8_t *sub_rule_depth)
 {
 	int32_t rule_index;
@@ -1330,7 +738,7 @@ find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
 	for (prev_depth = (uint8_t)(depth - 1); prev_depth > 0; prev_depth--) {
 		ip_masked = ip & depth_to_mask(prev_depth);
 
-		rule_index = rule_find_v20(lpm, ip_masked, prev_depth);
+		rule_index = rule_find(lpm, ip_masked, prev_depth);
 
 		if (rule_index >= 0) {
 			*sub_rule_depth = prev_depth;
@@ -1342,133 +750,7 @@ find_previous_rule_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth,
 }
 
 static int32_t
-find_previous_rule_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth,
-		uint8_t *sub_rule_depth)
-{
-	int32_t rule_index;
-	uint32_t ip_masked;
-	uint8_t prev_depth;
-
-	for (prev_depth = (uint8_t)(depth - 1); prev_depth > 0; prev_depth--) {
-		ip_masked = ip & depth_to_mask(prev_depth);
-
-		rule_index = rule_find_v1604(lpm, ip_masked, prev_depth);
-
-		if (rule_index >= 0) {
-			*sub_rule_depth = prev_depth;
-			return rule_index;
-		}
-	}
-
-	return -1;
-}
-
-static int32_t
-delete_depth_small_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked,
-	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
-{
-	uint32_t tbl24_range, tbl24_index, tbl8_group_index, tbl8_index, i, j;
-
-	/* Calculate the range and index into Table24. */
-	tbl24_range = depth_to_range(depth);
-	tbl24_index = (ip_masked >> 8);
-
-	/*
-	 * Firstly check the sub_rule_index. A -1 indicates no replacement rule
-	 * and a positive number indicates a sub_rule_index.
-	 */
-	if (sub_rule_index < 0) {
-		/*
-		 * If no replacement rule exists then invalidate entries
-		 * associated with this rule.
-		 */
-		for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-
-			if (lpm->tbl24[i].valid_group == 0 &&
-					lpm->tbl24[i].depth <= depth) {
-				struct rte_lpm_tbl_entry_v20
-					zero_tbl24_entry = {
-						.valid = INVALID,
-						.depth = 0,
-						.valid_group = 0,
-					};
-					zero_tbl24_entry.next_hop = 0;
-				__atomic_store(&lpm->tbl24[i],
-					&zero_tbl24_entry, __ATOMIC_RELEASE);
-			} else if (lpm->tbl24[i].valid_group == 1) {
-				/*
-				 * If TBL24 entry is extended, then there has
-				 * to be a rule with depth >= 25 in the
-				 * associated TBL8 group.
-				 */
-
-				tbl8_group_index = lpm->tbl24[i].group_idx;
-				tbl8_index = tbl8_group_index *
-						RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-				for (j = tbl8_index; j < (tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES); j++) {
-
-					if (lpm->tbl8[j].depth <= depth)
-						lpm->tbl8[j].valid = INVALID;
-				}
-			}
-		}
-	} else {
-		/*
-		 * If a replacement rule exists then modify entries
-		 * associated with this rule.
-		 */
-
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.next_hop = lpm->rules_tbl[sub_rule_index].next_hop,
-			.valid = VALID,
-			.valid_group = 0,
-			.depth = sub_rule_depth,
-		};
-
-		struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-			.valid = VALID,
-			.valid_group = VALID,
-			.depth = sub_rule_depth,
-		};
-		new_tbl8_entry.next_hop =
-				lpm->rules_tbl[sub_rule_index].next_hop;
-
-		for (i = tbl24_index; i < (tbl24_index + tbl24_range); i++) {
-
-			if (lpm->tbl24[i].valid_group == 0 &&
-					lpm->tbl24[i].depth <= depth) {
-				__atomic_store(&lpm->tbl24[i], &new_tbl24_entry,
-						__ATOMIC_RELEASE);
-			} else  if (lpm->tbl24[i].valid_group == 1) {
-				/*
-				 * If TBL24 entry is extended, then there has
-				 * to be a rule with depth >= 25 in the
-				 * associated TBL8 group.
-				 */
-
-				tbl8_group_index = lpm->tbl24[i].group_idx;
-				tbl8_index = tbl8_group_index *
-						RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-				for (j = tbl8_index; j < (tbl8_index +
-					RTE_LPM_TBL8_GROUP_NUM_ENTRIES); j++) {
-
-					if (lpm->tbl8[j].depth <= depth)
-						__atomic_store(&lpm->tbl8[j],
-							&new_tbl8_entry,
-							__ATOMIC_RELAXED);
-				}
-			}
-		}
-	}
-
-	return 0;
-}
-
-static int32_t
-delete_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
+delete_depth_small(struct rte_lpm *lpm, uint32_t ip_masked,
 	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
 {
 #define group_idx next_hop
@@ -1575,7 +857,7 @@ delete_depth_small_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
  * thus can be recycled
  */
 static int32_t
-tbl8_recycle_check_v20(struct rte_lpm_tbl_entry_v20 *tbl8,
+tbl8_recycle_check(struct rte_lpm_tbl_entry *tbl8,
 		uint32_t tbl8_group_start)
 {
 	uint32_t tbl8_group_end, i;
@@ -1622,140 +904,7 @@ tbl8_recycle_check_v20(struct rte_lpm_tbl_entry_v20 *tbl8,
 }
 
 static int32_t
-tbl8_recycle_check_v1604(struct rte_lpm_tbl_entry *tbl8,
-		uint32_t tbl8_group_start)
-{
-	uint32_t tbl8_group_end, i;
-	tbl8_group_end = tbl8_group_start + RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-
-	/*
-	 * Check the first entry of the given tbl8. If it is invalid we know
-	 * this tbl8 does not contain any rule with a depth < RTE_LPM_MAX_DEPTH
-	 *  (As they would affect all entries in a tbl8) and thus this table
-	 *  can not be recycled.
-	 */
-	if (tbl8[tbl8_group_start].valid) {
-		/*
-		 * If first entry is valid check if the depth is less than 24
-		 * and if so check the rest of the entries to verify that they
-		 * are all of this depth.
-		 */
-		if (tbl8[tbl8_group_start].depth <= MAX_DEPTH_TBL24) {
-			for (i = (tbl8_group_start + 1); i < tbl8_group_end;
-					i++) {
-
-				if (tbl8[i].depth !=
-						tbl8[tbl8_group_start].depth) {
-
-					return -EEXIST;
-				}
-			}
-			/* If all entries are the same return the tb8 index */
-			return tbl8_group_start;
-		}
-
-		return -EEXIST;
-	}
-	/*
-	 * If the first entry is invalid check if the rest of the entries in
-	 * the tbl8 are invalid.
-	 */
-	for (i = (tbl8_group_start + 1); i < tbl8_group_end; i++) {
-		if (tbl8[i].valid)
-			return -EEXIST;
-	}
-	/* If no valid entries are found then return -EINVAL. */
-	return -EINVAL;
-}
-
-static int32_t
-delete_depth_big_v20(struct rte_lpm_v20 *lpm, uint32_t ip_masked,
-	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
-{
-	uint32_t tbl24_index, tbl8_group_index, tbl8_group_start, tbl8_index,
-			tbl8_range, i;
-	int32_t tbl8_recycle_index;
-
-	/*
-	 * Calculate the index into tbl24 and range. Note: All depths larger
-	 * than MAX_DEPTH_TBL24 are associated with only one tbl24 entry.
-	 */
-	tbl24_index = ip_masked >> 8;
-
-	/* Calculate the index into tbl8 and range. */
-	tbl8_group_index = lpm->tbl24[tbl24_index].group_idx;
-	tbl8_group_start = tbl8_group_index * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
-	tbl8_index = tbl8_group_start + (ip_masked & 0xFF);
-	tbl8_range = depth_to_range(depth);
-
-	if (sub_rule_index < 0) {
-		/*
-		 * Loop through the range of entries on tbl8 for which the
-		 * rule_to_delete must be removed or modified.
-		 */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			if (lpm->tbl8[i].depth <= depth)
-				lpm->tbl8[i].valid = INVALID;
-		}
-	} else {
-		/* Set new tbl8 entry. */
-		struct rte_lpm_tbl_entry_v20 new_tbl8_entry = {
-			.valid = VALID,
-			.depth = sub_rule_depth,
-			.valid_group = lpm->tbl8[tbl8_group_start].valid_group,
-		};
-
-		new_tbl8_entry.next_hop =
-				lpm->rules_tbl[sub_rule_index].next_hop;
-		/*
-		 * Loop through the range of entries on tbl8 for which the
-		 * rule_to_delete must be modified.
-		 */
-		for (i = tbl8_index; i < (tbl8_index + tbl8_range); i++) {
-			if (lpm->tbl8[i].depth <= depth)
-				__atomic_store(&lpm->tbl8[i], &new_tbl8_entry,
-						__ATOMIC_RELAXED);
-		}
-	}
-
-	/*
-	 * Check if there are any valid entries in this tbl8 group. If all
-	 * tbl8 entries are invalid we can free the tbl8 and invalidate the
-	 * associated tbl24 entry.
-	 */
-
-	tbl8_recycle_index = tbl8_recycle_check_v20(lpm->tbl8, tbl8_group_start);
-
-	if (tbl8_recycle_index == -EINVAL) {
-		/* Set tbl24 before freeing tbl8 to avoid race condition.
-		 * Prevent the free of the tbl8 group from hoisting.
-		 */
-		lpm->tbl24[tbl24_index].valid = 0;
-		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v20(lpm->tbl8, tbl8_group_start);
-	} else if (tbl8_recycle_index > -1) {
-		/* Update tbl24 entry. */
-		struct rte_lpm_tbl_entry_v20 new_tbl24_entry = {
-			.next_hop = lpm->tbl8[tbl8_recycle_index].next_hop,
-			.valid = VALID,
-			.valid_group = 0,
-			.depth = lpm->tbl8[tbl8_recycle_index].depth,
-		};
-
-		/* Set tbl24 before freeing tbl8 to avoid race condition.
-		 * Prevent the free of the tbl8 group from hoisting.
-		 */
-		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
-				__ATOMIC_RELAXED);
-		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v20(lpm->tbl8, tbl8_group_start);
-	}
-
-	return 0;
-}
-
-static int32_t
-delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
+delete_depth_big(struct rte_lpm *lpm, uint32_t ip_masked,
 	uint8_t depth, int32_t sub_rule_index, uint8_t sub_rule_depth)
 {
 #define group_idx next_hop
@@ -1810,7 +959,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 	 * associated tbl24 entry.
 	 */
 
-	tbl8_recycle_index = tbl8_recycle_check_v1604(lpm->tbl8, tbl8_group_start);
+	tbl8_recycle_index = tbl8_recycle_check(lpm->tbl8, tbl8_group_start);
 
 	if (tbl8_recycle_index == -EINVAL) {
 		/* Set tbl24 before freeing tbl8 to avoid race condition.
@@ -1818,7 +967,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 		 */
 		lpm->tbl24[tbl24_index].valid = 0;
 		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v1604(lpm->tbl8, tbl8_group_start);
+		tbl8_free(lpm->tbl8, tbl8_group_start);
 	} else if (tbl8_recycle_index > -1) {
 		/* Update tbl24 entry. */
 		struct rte_lpm_tbl_entry new_tbl24_entry = {
@@ -1834,7 +983,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
 		__atomic_store(&lpm->tbl24[tbl24_index], &new_tbl24_entry,
 				__ATOMIC_RELAXED);
 		__atomic_thread_fence(__ATOMIC_RELEASE);
-		tbl8_free_v1604(lpm->tbl8, tbl8_group_start);
+		tbl8_free(lpm->tbl8, tbl8_group_start);
 	}
 #undef group_idx
 	return 0;
@@ -1844,7 +993,7 @@ delete_depth_big_v1604(struct rte_lpm *lpm, uint32_t ip_masked,
  * Deletes a rule
  */
 int
-rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
+rte_lpm_delete(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
 {
 	int32_t rule_to_delete_index, sub_rule_index;
 	uint32_t ip_masked;
@@ -1863,7 +1012,7 @@ rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
 	 * Find the index of the input rule, that needs to be deleted, in the
 	 * rule table.
 	 */
-	rule_to_delete_index = rule_find_v20(lpm, ip_masked, depth);
+	rule_to_delete_index = rule_find(lpm, ip_masked, depth);
 
 	/*
 	 * Check if rule_to_delete_index was found. If no rule was found the
@@ -1873,7 +1022,7 @@ rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
 		return -EINVAL;
 
 	/* Delete the rule from the rule table. */
-	rule_delete_v20(lpm, rule_to_delete_index, depth);
+	rule_delete(lpm, rule_to_delete_index, depth);
 
 	/*
 	 * Find rule to replace the rule_to_delete. If there is no rule to
@@ -1881,100 +1030,26 @@ rte_lpm_delete_v20(struct rte_lpm_v20 *lpm, uint32_t ip, uint8_t depth)
 	 * entries associated with this rule.
 	 */
 	sub_rule_depth = 0;
-	sub_rule_index = find_previous_rule_v20(lpm, ip, depth, &sub_rule_depth);
+	sub_rule_index = find_previous_rule(lpm, ip, depth, &sub_rule_depth);
 
 	/*
 	 * If the input depth value is less than 25 use function
 	 * delete_depth_small otherwise use delete_depth_big.
 	 */
 	if (depth <= MAX_DEPTH_TBL24) {
-		return delete_depth_small_v20(lpm, ip_masked, depth,
+		return delete_depth_small(lpm, ip_masked, depth,
 				sub_rule_index, sub_rule_depth);
 	} else { /* If depth > MAX_DEPTH_TBL24 */
-		return delete_depth_big_v20(lpm, ip_masked, depth, sub_rule_index,
+		return delete_depth_big(lpm, ip_masked, depth, sub_rule_index,
 				sub_rule_depth);
 	}
 }
-VERSION_SYMBOL(rte_lpm_delete, _v20, 2.0);
-
-int
-rte_lpm_delete_v1604(struct rte_lpm *lpm, uint32_t ip, uint8_t depth)
-{
-	int32_t rule_to_delete_index, sub_rule_index;
-	uint32_t ip_masked;
-	uint8_t sub_rule_depth;
-	/*
-	 * Check input arguments. Note: IP must be a positive integer of 32
-	 * bits in length therefore it need not be checked.
-	 */
-	if ((lpm == NULL) || (depth < 1) || (depth > RTE_LPM_MAX_DEPTH)) {
-		return -EINVAL;
-	}
-
-	ip_masked = ip & depth_to_mask(depth);
-
-	/*
-	 * Find the index of the input rule, that needs to be deleted, in the
-	 * rule table.
-	 */
-	rule_to_delete_index = rule_find_v1604(lpm, ip_masked, depth);
-
-	/*
-	 * Check if rule_to_delete_index was found. If no rule was found the
-	 * function rule_find returns -EINVAL.
-	 */
-	if (rule_to_delete_index < 0)
-		return -EINVAL;
-
-	/* Delete the rule from the rule table. */
-	rule_delete_v1604(lpm, rule_to_delete_index, depth);
-
-	/*
-	 * Find rule to replace the rule_to_delete. If there is no rule to
-	 * replace the rule_to_delete we return -1 and invalidate the table
-	 * entries associated with this rule.
-	 */
-	sub_rule_depth = 0;
-	sub_rule_index = find_previous_rule_v1604(lpm, ip, depth, &sub_rule_depth);
-
-	/*
-	 * If the input depth value is less than 25 use function
-	 * delete_depth_small otherwise use delete_depth_big.
-	 */
-	if (depth <= MAX_DEPTH_TBL24) {
-		return delete_depth_small_v1604(lpm, ip_masked, depth,
-				sub_rule_index, sub_rule_depth);
-	} else { /* If depth > MAX_DEPTH_TBL24 */
-		return delete_depth_big_v1604(lpm, ip_masked, depth, sub_rule_index,
-				sub_rule_depth);
-	}
-}
-BIND_DEFAULT_SYMBOL(rte_lpm_delete, _v1604, 16.04);
-MAP_STATIC_SYMBOL(int rte_lpm_delete(struct rte_lpm *lpm, uint32_t ip,
-		uint8_t depth), rte_lpm_delete_v1604);
 
 /*
  * Delete all rules from the LPM table.
  */
 void
-rte_lpm_delete_all_v20(struct rte_lpm_v20 *lpm)
-{
-	/* Zero rule information. */
-	memset(lpm->rule_info, 0, sizeof(lpm->rule_info));
-
-	/* Zero tbl24. */
-	memset(lpm->tbl24, 0, sizeof(lpm->tbl24));
-
-	/* Zero tbl8. */
-	memset(lpm->tbl8, 0, sizeof(lpm->tbl8));
-
-	/* Delete all rules form the rules table. */
-	memset(lpm->rules_tbl, 0, sizeof(lpm->rules_tbl[0]) * lpm->max_rules);
-}
-VERSION_SYMBOL(rte_lpm_delete_all, _v20, 2.0);
-
-void
-rte_lpm_delete_all_v1604(struct rte_lpm *lpm)
+rte_lpm_delete_all(struct rte_lpm *lpm)
 {
 	/* Zero rule information. */
 	memset(lpm->rule_info, 0, sizeof(lpm->rule_info));
@@ -1989,6 +1064,3 @@ rte_lpm_delete_all_v1604(struct rte_lpm *lpm)
 	/* Delete all rules form the rules table. */
 	memset(lpm->rules_tbl, 0, sizeof(lpm->rules_tbl[0]) * lpm->max_rules);
 }
-BIND_DEFAULT_SYMBOL(rte_lpm_delete_all, _v1604, 16.04);
-MAP_STATIC_SYMBOL(void rte_lpm_delete_all(struct rte_lpm *lpm),
-		rte_lpm_delete_all_v1604);
lib/librte_lpm/rte_lpm.h +0 -88

154 lines not on this page · raw message

lib/librte_lpm/rte_lpm6.c +14 -118

208 lines not on this page · raw message

lib/librte_lpm/rte_lpm6.h +0 -25
index 5d59ccb1fe..37dfb20249 100644
@@ -96,12 +96,6 @@ rte_lpm6_free(struct rte_lpm6 *lpm);
 int
 rte_lpm6_add(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 		uint32_t next_hop);
-int
-rte_lpm6_add_v20(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint8_t next_hop);
-int
-rte_lpm6_add_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint32_t next_hop);
 
 /**
  * Check if a rule is present in the LPM table,
@@ -121,12 +115,6 @@ rte_lpm6_add_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 int
 rte_lpm6_is_rule_present(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
 		uint32_t *next_hop);
-int
-rte_lpm6_is_rule_present_v20(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint8_t *next_hop);
-int
-rte_lpm6_is_rule_present_v1705(struct rte_lpm6 *lpm, uint8_t *ip, uint8_t depth,
-		uint32_t *next_hop);
 
 /**
  * Delete a rule from the LPM table.
@@ -184,11 +172,6 @@ rte_lpm6_delete_all(struct rte_lpm6 *lpm);
  */
 int
 rte_lpm6_lookup(const struct rte_lpm6 *lpm, uint8_t *ip, uint32_t *next_hop);
-int
-rte_lpm6_lookup_v20(const struct rte_lpm6 *lpm, uint8_t *ip, uint8_t *next_hop);
-int
-rte_lpm6_lookup_v1705(const struct rte_lpm6 *lpm, uint8_t *ip,
-		uint32_t *next_hop);
 
 /**
  * Lookup multiple IP addresses in an LPM table.
@@ -210,14 +193,6 @@ int
 rte_lpm6_lookup_bulk_func(const struct rte_lpm6 *lpm,
 		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
 		int32_t *next_hops, unsigned int n);
-int
-rte_lpm6_lookup_bulk_func_v20(const struct rte_lpm6 *lpm,
-		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
-		int16_t *next_hops, unsigned int n);
-int
-rte_lpm6_lookup_bulk_func_v1705(const struct rte_lpm6 *lpm,
-		uint8_t ips[][RTE_LPM6_IPV6_ADDR_SIZE],
-		int32_t *next_hops, unsigned int n);
 
 #ifdef __cplusplus
 }
Signature · 1 line
2.17.1
#34 lore raw

PATCH v3 6/9 distributor: remove deprecated code

In reply to Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v3:
- Removed single mode from distributor as per Dave's comments

v2:
- Moved this to before ABI version bump to avoid compile breakage

 app/test/test_distributor.c                   | 102 ++---
 app/test/test_distributor_perf.c              |  12 -
 lib/librte_distributor/Makefile               |   1 -
 lib/librte_distributor/meson.build            |   2 +-
 lib/librte_distributor/rte_distributor.c      | 126 +-----
 lib/librte_distributor/rte_distributor.h      |   1 -
 .../rte_distributor_private.h                 |  35 --
 .../rte_distributor_v1705.h                   |  61 ---
 lib/librte_distributor/rte_distributor_v20.c  | 402 ------------------
 lib/librte_distributor/rte_distributor_v20.h  | 218 ----------
 .../rte_distributor_version.map               |  16 +-
 11 files changed, 38 insertions(+), 938 deletions(-)
 delete mode 100644 lib/librte_distributor/rte_distributor_v1705.h
 delete mode 100644 lib/librte_distributor/rte_distributor_v20.c
 delete mode 100644 lib/librte_distributor/rte_distributor_v20.h
app/test/test_distributor.c +27 -75
index 7090b55f88..af42f3a991 100644
@@ -511,18 +511,9 @@ test_flush_with_worker_shutdown(struct worker_params *wp,
 static
 int test_error_distributor_create_name(void)
 {
-	struct rte_distributor *d = NULL;
 	struct rte_distributor *db = NULL;
 	char *name = NULL;
 
-	d = rte_distributor_create(name, rte_socket_id(),
-			rte_lcore_count() - 1,
-			RTE_DIST_ALG_SINGLE);
-	if (d != NULL || rte_errno != EINVAL) {
-		printf("ERROR: No error on create() with NULL name param\n");
-		return -1;
-	}
-
 	db = rte_distributor_create(name, rte_socket_id(),
 			rte_lcore_count() - 1,
 			RTE_DIST_ALG_BURST);
@@ -538,17 +529,8 @@ int test_error_distributor_create_name(void)
 static
 int test_error_distributor_create_numworkers(void)
 {
-	struct rte_distributor *ds = NULL;
 	struct rte_distributor *db = NULL;
 
-	ds = rte_distributor_create("test_numworkers", rte_socket_id(),
-			RTE_MAX_LCORE + 10,
-			RTE_DIST_ALG_SINGLE);
-	if (ds != NULL || rte_errno != EINVAL) {
-		printf("ERROR: No error on create() with num_workers > MAX\n");
-		return -1;
-	}
-
 	db = rte_distributor_create("test_numworkers", rte_socket_id(),
 			RTE_MAX_LCORE + 10,
 			RTE_DIST_ALG_BURST);
@@ -589,11 +571,8 @@ quit_workers(struct worker_params *wp, struct rte_mempool *p)
 static int
 test_distributor(void)
 {
-	static struct rte_distributor *ds;
 	static struct rte_distributor *db;
-	static struct rte_distributor *dist[2];
 	static struct rte_mempool *p;
-	int i;
 
 	if (rte_lcore_count() < 2) {
 		printf("Not enough cores for distributor_autotest, expecting at least 2\n");
@@ -613,20 +592,6 @@ test_distributor(void)
 		rte_distributor_clear_returns(db);
 	}
 
-	if (ds == NULL) {
-		ds = rte_distributor_create("Test_dist_single",
-				rte_socket_id(),
-				rte_lcore_count() - 1,
-			RTE_DIST_ALG_SINGLE);
-		if (ds == NULL) {
-			printf("Error creating single distributor\n");
-			return -1;
-		}
-	} else {
-		rte_distributor_flush(ds);
-		rte_distributor_clear_returns(ds);
-	}
-
 	const unsigned nb_bufs = (511 * rte_lcore_count()) < BIG_BATCH ?
 			(BIG_BATCH * 2) - 1 : (511 * rte_lcore_count());
 	if (p == NULL) {
@@ -638,52 +603,39 @@ test_distributor(void)
 		}
 	}
 
-	dist[0] = ds;
-	dist[1] = db;
-
-	for (i = 0; i < 2; i++) {
-
-		worker_params.dist = dist[i];
-		if (i)
-			strlcpy(worker_params.name, "burst",
-					sizeof(worker_params.name));
-		else
-			strlcpy(worker_params.name, "single",
-					sizeof(worker_params.name));
-
-		rte_eal_mp_remote_launch(handle_work,
-				&worker_params, SKIP_MASTER);
-		if (sanity_test(&worker_params, p) < 0)
+	worker_params.dist = db;
+
+	rte_eal_mp_remote_launch(handle_work,
+			&worker_params, SKIP_MASTER);
+	if (sanity_test(&worker_params, p) < 0)
+		goto err;
+	quit_workers(&worker_params, p);
+
+	rte_eal_mp_remote_launch(handle_work_with_free_mbufs,
+			&worker_params, SKIP_MASTER);
+	if (sanity_test_with_mbuf_alloc(&worker_params, p) < 0)
+		goto err;
+	quit_workers(&worker_params, p);
+
+	if (rte_lcore_count() > 2) {
+		rte_eal_mp_remote_launch(handle_work_for_shutdown_test,
+				&worker_params,
+				SKIP_MASTER);
+		if (sanity_test_with_worker_shutdown(&worker_params,
+				p) < 0)
 			goto err;
 		quit_workers(&worker_params, p);
 
-		rte_eal_mp_remote_launch(handle_work_with_free_mbufs,
-				&worker_params, SKIP_MASTER);
-		if (sanity_test_with_mbuf_alloc(&worker_params, p) < 0)
+		rte_eal_mp_remote_launch(handle_work_for_shutdown_test,
+				&worker_params,
+				SKIP_MASTER);
+		if (test_flush_with_worker_shutdown(&worker_params,
+				p) < 0)
 			goto err;
 		quit_workers(&worker_params, p);
 
-		if (rte_lcore_count() > 2) {
-			rte_eal_mp_remote_launch(handle_work_for_shutdown_test,
-					&worker_params,
-					SKIP_MASTER);
-			if (sanity_test_with_worker_shutdown(&worker_params,
-					p) < 0)
-				goto err;
-			quit_workers(&worker_params, p);
-
-			rte_eal_mp_remote_launch(handle_work_for_shutdown_test,
-					&worker_params,
-					SKIP_MASTER);
-			if (test_flush_with_worker_shutdown(&worker_params,
-					p) < 0)
-				goto err;
-			quit_workers(&worker_params, p);
-
-		} else {
-			printf("Too few cores to run worker shutdown test\n");
-		}
-
+	} else {
+		printf("Too few cores to run worker shutdown test\n");
 	}
 
 	if (test_error_distributor_create_numworkers() == -1 ||
app/test/test_distributor_perf.c +0 -12
index 664530ff9e..a0bbae1a16 100644
@@ -215,18 +215,6 @@ test_distributor_perf(void)
 	/* first time how long it takes to round-trip a cache line */
 	time_cache_line_switch();
 
-	if (ds == NULL) {
-		ds = rte_distributor_create("Test_perf", rte_socket_id(),
-				rte_lcore_count() - 1,
-				RTE_DIST_ALG_SINGLE);
-		if (ds == NULL) {
-			printf("Error creating distributor\n");
-			return -1;
-		}
-	} else {
-		rte_distributor_clear_returns(ds);
-	}
-
 	if (db == NULL) {
 		db = rte_distributor_create("Test_burst", rte_socket_id(),
 				rte_lcore_count() - 1,
lib/librte_distributor/Makefile +0 -1
index 0ef80dcff4..54e9b0cc27 100644
@@ -15,7 +15,6 @@ EXPORT_MAP := rte_distributor_version.map
 LIBABIVER := 1
 
 # all source are stored in SRCS-y
-SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) := rte_distributor_v20.c
 SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += rte_distributor.c
 ifeq ($(CONFIG_RTE_ARCH_X86),y)
 SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += rte_distributor_match_sse.c
lib/librte_distributor/meson.build +1 -1
index dba7e3b2aa..d3e2aaa9e0 100644
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-sources = files('rte_distributor.c', 'rte_distributor_v20.c')
+sources = files('rte_distributor.c')
 if arch_subdir == 'x86'
 	sources += files('rte_distributor_match_sse.c')
 else
lib/librte_distributor/rte_distributor.c +9 -117

267 lines not on this page · raw message

lib/librte_distributor/rte_distributor.h +0 -1
index 327c0c4ab2..41c06093ee 100644
@@ -20,7 +20,6 @@ extern "C" {
 /* Type of distribution (burst/single) */
 enum rte_distributor_alg_type {
 	RTE_DIST_ALG_BURST = 0,
-	RTE_DIST_ALG_SINGLE,
 	RTE_DIST_NUM_ALG_TYPES
 };
 
lib/librte_distributor/rte_distributor_private.h +0 -35
index 33cd89410c..552eecc88f 100644
@@ -48,18 +48,6 @@ extern "C" {
 
 #define RTE_DISTRIBUTOR_NAMESIZE 32 /**< Length of name for instance */
 
-/**
- * Buffer structure used to pass the pointer data between cores. This is cache
- * line aligned, but to improve performance and prevent adjacent cache-line
- * prefetches of buffers for other workers, e.g. when worker 1's buffer is on
- * the next cache line to worker 0, we pad this out to three cache lines.
- * Only 64-bits of the memory is actually used though.
- */
-union rte_distributor_buffer_v20 {
-	volatile int64_t bufptr64;
-	char pad[RTE_CACHE_LINE_SIZE*3];
-} __rte_cache_aligned;
-
 /*
  * Transfer up to 8 mbufs at a time to/from workers, and
  * flow matching algorithm optimized for 8 flow IDs at a time
@@ -80,27 +68,6 @@ struct rte_distributor_returned_pkts {
 	struct rte_mbuf *mbufs[RTE_DISTRIB_MAX_RETURNS];
 };
 
-struct rte_distributor_v20 {
-	TAILQ_ENTRY(rte_distributor_v20) next;    /**< Next in list. */
-
-	char name[RTE_DISTRIBUTOR_NAMESIZE];  /**< Name of the ring. */
-	unsigned int num_workers;             /**< Number of workers polling */
-
-	uint32_t in_flight_tags[RTE_DISTRIB_MAX_WORKERS];
-		/**< Tracks the tag being processed per core */
-	uint64_t in_flight_bitmask;
-		/**< on/off bits for in-flight tags.
-		 * Note that if RTE_DISTRIB_MAX_WORKERS is larger than 64 then
-		 * the bitmask has to expand.
-		 */
-
-	struct rte_distributor_backlog backlog[RTE_DISTRIB_MAX_WORKERS];
-
-	union rte_distributor_buffer_v20 bufs[RTE_DISTRIB_MAX_WORKERS];
-
-	struct rte_distributor_returned_pkts returns;
-};
-
 /* All different signature compare functions */
 enum rte_distributor_match_function {
 	RTE_DIST_MATCH_SCALAR = 0,
@@ -153,8 +120,6 @@ struct rte_distributor {
 	struct rte_distributor_returned_pkts returns;
 
 	enum rte_distributor_match_function dist_match_fn;
-
-	struct rte_distributor_v20 *d_v20;
 };
 
 void
lib/librte_distributor/rte_distributor_v1705.h deleted +0 -61

61 lines not on this page · raw message

lib/librte_distributor/rte_distributor_v20.c deleted +0 -402

402 lines not on this page · raw message

lib/librte_distributor/rte_distributor_v20.h deleted +0 -218

218 lines not on this page · raw message

lib/librte_distributor/rte_distributor_version.map +1 -15
index 3a285b394e..5643ab85fb 100644
@@ -1,4 +1,4 @@
-DPDK_2.0 {
+DPDK_17.05 {
 	global:
 
 	rte_distributor_clear_returns;
@@ -13,17 +13,3 @@ DPDK_2.0 {
 
 	local: *;
 };
-
-DPDK_17.05 {
-	global:
-
-	rte_distributor_clear_returns;
-	rte_distributor_create;
-	rte_distributor_flush;
-	rte_distributor_get_pkt;
-	rte_distributor_poll_pkt;
-	rte_distributor_process;
-	rte_distributor_request_pkt;
-	rte_distributor_return_pkt;
-	rte_distributor_returned_pkts;
-} DPDK_2.0;
Signature · 1 line
2.17.1
#35 lore raw

Re: [dpdk-dev] [PATCH v3 6/9] distributor: remove deprecated code

Quoted 11 lines · Anatoly Burakov

From: Marcin Baran <[email protected]>

Remove code for old ABI versions ahead of ABI version bump.

---

Notes:
v3:
- Removed single mode from distributor as per Dave's comments

Hi Anatoly,

Having looked at this code closer, I see that this now breaks the API for when a distributor instance is created with the RTE_DIST_ALG_SINGLE.

I think now that the better solution would be to just re-name the _v20 to _single for structs, functions, etc, as you did in the previous patch version. That means that the unit and perf tests should still work unchanged, and maintain the API.

Rgds,
Dave.

#36 lore raw

PATCH v3 7/9 drivers/octeontx: add missing public symbol

In reply to Anatoly Burakov

The logtype symbol was missing from the .map file. Add it.

Fixes d8dd31652cf4 ("common/octeontx: move mbox to common folder")

---

Notes:
v2:
- add this patch to avoid compile breakage when bumping ABI

 drivers/common/octeontx/rte_common_octeontx_version.map | 1 +
 1 file changed, 1 insertion(+)
drivers/common/octeontx/rte_common_octeontx_version.map +1 -0
index f04b3b7f8a..a9b3cff9bc 100644
@@ -1,6 +1,7 @@
 DPDK_18.05 {
 	global:
 
+	octeontx_logtype_mbox;
 	octeontx_mbox_set_ram_mbox_base;
 	octeontx_mbox_set_reg;
 	octeontx_mbox_send;
Signature · 1 line
2.17.1