Skip to content
Snippets Groups Projects
openvswitch-2.13.0.patch 3.09 MiB
Newer Older
Louis Abel's avatar
Louis Abel committed
diff --git a/.ci/linux-build.sh b/.ci/linux-build.sh
new file mode 100755
index 0000000000..b22ad95310
--- /dev/null
+++ b/.ci/linux-build.sh
@@ -0,0 +1,244 @@
+#!/bin/bash
+
+set -o errexit
+set -x
+
+CFLAGS_FOR_OVS="-g -O2"
+SPARSE_FLAGS=""
+EXTRA_OPTS="--enable-Werror"
+TARGET="x86_64-native-linuxapp-gcc"
+
+function install_kernel()
+{
+    if [[ "$1" =~ ^5.* ]]; then
+        PREFIX="v5.x"
+    elif [[ "$1" =~ ^4.* ]]; then
+        PREFIX="v4.x"
+    elif [[ "$1" =~ ^3.* ]]; then
+        PREFIX="v3.x"
+    else
+        PREFIX="v2.6/longterm/v2.6.32"
+    fi
+
+    base_url="https://cdn.kernel.org/pub/linux/kernel/${PREFIX}"
+    # Download page with list of all available kernel versions.
+    wget ${base_url}/
+    # Uncompress in case server returned gzipped page.
+    (file index* | grep ASCII) || (mv index* index.new.gz && gunzip index*)
+    # Get version of the latest stable release.
+    hi_ver=$(echo ${1} | sed 's/\./\\\./')
+    lo_ver=$(cat ./index* | grep -P -o "${hi_ver}\.[0-9]+" | \
+             sed 's/.*\..*\.\(.*\)/\1/' | sort -h | tail -1)
+    version="${1}.${lo_ver}"
+
+    rm -rf index* linux-*
+
+    url="${base_url}/linux-${version}.tar.xz"
+    # Download kernel sources. Try direct link on CDN failure.
+    wget ${url} ||
+    (rm -f linux-${version}.tar.xz && wget ${url}) ||
+    (rm -f linux-${version}.tar.xz && wget ${url/cdn/www})
+
+    tar xvf linux-${version}.tar.xz > /dev/null
+    pushd linux-${version}
+    make allmodconfig
+
+    # Cannot use CONFIG_KCOV: -fsanitize-coverage=trace-pc is not supported by compiler
+    sed -i 's/CONFIG_KCOV=y/CONFIG_KCOV=n/' .config
+
+    # stack validation depends on tools/objtool, but objtool does not compile on travis.
+    # It is giving following error.
+    #  >>> GEN      arch/x86/insn/inat-tables.c
+    #  >>> Semantic error at 40: Unknown imm opnd: AL
+    # So for now disable stack-validation for the build.
+
+    sed -i 's/CONFIG_STACK_VALIDATION=y/CONFIG_STACK_VALIDATION=n/' .config
+    make oldconfig
+
+    # Older kernels do not include openvswitch
+    if [ -d "net/openvswitch" ]; then
+        make net/openvswitch/
+    else
+        make net/bridge/
+    fi
+
+    if [ "$AFXDP" ]; then
+        sudo make headers_install INSTALL_HDR_PATH=/usr
+        pushd tools/lib/bpf/
+        # Bulding with gcc because there are some issues in make files
+        # that breaks building libbpf with clang on Travis.
+        CC=gcc sudo make install
+        CC=gcc sudo make install_headers
+        sudo ldconfig
+        popd
+        # The Linux kernel defines __always_inline in stddef.h (283d7573), and
+        # sys/cdefs.h tries to re-define it.  Older libc-dev package in xenial
+        # doesn't have a fix for this issue.  Applying it manually.
+        sudo sed -i '/^# define __always_inline .*/i # undef __always_inline' \
+                    /usr/include/x86_64-linux-gnu/sys/cdefs.h || true
+        EXTRA_OPTS="${EXTRA_OPTS} --enable-afxdp"
+    else
+        EXTRA_OPTS="${EXTRA_OPTS} --with-linux=$(pwd)"
+        echo "Installed kernel source in $(pwd)"
+    fi
+    popd
+}
+
+function install_dpdk()
+{
+    local DPDK_VER=$1
+    local VERSION_FILE="dpdk-dir/travis-dpdk-cache-version"
+
+    if [ "${DPDK_VER##refs/*/}" != "${DPDK_VER}" ]; then
+        # Avoid using cache for git tree build.
+        rm -rf dpdk-dir
+
+        DPDK_GIT=${DPDK_GIT:-https://dpdk.org/git/dpdk}
+        git clone --single-branch $DPDK_GIT dpdk-dir -b "${DPDK_VER##refs/*/}"
+        pushd dpdk-dir
+        git log -1 --oneline
+    else
+        if [ -f "${VERSION_FILE}" ]; then
+            VER=$(cat ${VERSION_FILE})
+            if [ "${VER}" = "${DPDK_VER}" ]; then
+                EXTRA_OPTS="${EXTRA_OPTS} --with-dpdk=$(pwd)/dpdk-dir/build"
+                echo "Found cached DPDK ${VER} build in $(pwd)/dpdk-dir"
+                return
+            fi
+        fi
+        # No cache or version mismatch.
+        rm -rf dpdk-dir
+        wget https://fast.dpdk.org/rel/dpdk-$1.tar.xz
+        tar xvf dpdk-$1.tar.xz > /dev/null
+        DIR_NAME=$(tar -tf dpdk-$1.tar.xz | head -1 | cut -f1 -d"/")
+        mv ${DIR_NAME} dpdk-dir
+        pushd dpdk-dir
+    fi
+
+    make config CC=gcc T=$TARGET
+
+    if [ "$DPDK_SHARED" ]; then
+        sed -i '/CONFIG_RTE_BUILD_SHARED_LIB=n/s/=n/=y/' build/.config
+        export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(pwd)/$TARGET/lib
+    fi
+
+    # Disable building DPDK kernel modules. Not needed for OVS build or tests.
+    sed -i '/CONFIG_RTE_EAL_IGB_UIO=y/s/=y/=n/' build/.config
+    sed -i '/CONFIG_RTE_KNI_KMOD=y/s/=y/=n/' build/.config
+
+    # Enable pdump support in DPDK.
+    sed -i '/CONFIG_RTE_LIBRTE_PMD_PCAP=n/s/=n/=y/' build/.config
+    sed -i '/CONFIG_RTE_LIBRTE_PDUMP=n/s/=n/=y/' build/.config
+
+    # Switching to 'default' machine to make dpdk-dir cache usable on different
+    # CPUs.  We can't be sure that all CI machines are exactly same.
+    sed -i '/CONFIG_RTE_MACHINE="native"/s/="native"/="default"/' build/.config
+
+    make -j4 CC=gcc EXTRA_CFLAGS='-fPIC'
+    EXTRA_OPTS="$EXTRA_OPTS --with-dpdk=$(pwd)/build"
+    echo "Installed DPDK source in $(pwd)"
+    popd
+    echo "${DPDK_VER}" > ${VERSION_FILE}
+}
+
+function configure_ovs()
+{
+    ./boot.sh
+    ./configure CFLAGS="${CFLAGS_FOR_OVS}" $* || { cat config.log; exit 1; }
+}
+
+function build_ovs()
+{
+    local KERNEL=$1
+
+    configure_ovs $OPTS
+    make selinux-policy
+
+    # Only build datapath if we are testing kernel w/o running testsuite and
+    # AF_XDP support.
+    if [ "${KERNEL}" ] && ! [ "$AFXDP" ]; then
+        pushd datapath
+        make -j4
+        popd
+    else
+        make -j4 || { cat config.log; exit 1; }
+    fi
+}
+
+if [ "$DEB_PACKAGE" ]; then
+    mk-build-deps --install --root-cmd sudo --remove debian/control
+    dpkg-checkbuilddeps
+    DEB_BUILD_OPTIONS='parallel=4 nocheck' fakeroot debian/rules binary
+    # Not trying to install ipsec package as there are issues with system-wide
+    # installed python3-openvswitch package and the pyenv used by Travis.
+    packages=$(ls $(pwd)/../*.deb | grep -v ipsec)
+    sudo apt install ${packages}
+    exit 0
+fi
+
+if [ "$KERNEL" ]; then
+    install_kernel $KERNEL
+fi
+
+if [ "$DPDK" ] || [ "$DPDK_SHARED" ]; then
+    if [ -z "$DPDK_VER" ]; then
+        DPDK_VER="19.11.8"
+    fi
+    install_dpdk $DPDK_VER
+    # Enable pdump support in OVS.
+    EXTRA_OPTS="${EXTRA_OPTS} --enable-dpdk-pdump"
+    if [ "$CC" = "clang" ]; then
+        # Disregard cast alignment errors until DPDK is fixed
+        CFLAGS_FOR_OVS="${CFLAGS_FOR_OVS} -Wno-cast-align"
+    fi
+fi
Louis Abel's avatar
Louis Abel committed
+
+if [ "$CC" = "clang" ]; then
+    CFLAGS_FOR_OVS="${CFLAGS_FOR_OVS} -Wno-error=unused-command-line-argument"
+elif [ "$M32" ]; then
+    # Not using sparse for 32bit builds on 64bit machine.
+    # Adding m32 flag directly to CC to avoid any posiible issues with API/ABI
+    # difference on 'configure' and 'make' stages.
+    export CC="$CC -m32"
+else
+    OPTS="--enable-sparse"
+    if [ "$AFXDP" ]; then
+        # netdev-afxdp uses memset for 64M for umem initialization.
+        SPARSE_FLAGS="${SPARSE_FLAGS} -Wno-memcpy-max-count"
+    fi
+    CFLAGS_FOR_OVS="${CFLAGS_FOR_OVS} ${SPARSE_FLAGS}"
+fi
+
+save_OPTS="${OPTS} $*"
+OPTS="${EXTRA_OPTS} ${save_OPTS}"
+
+if [ "$TESTSUITE" ]; then
+    # 'distcheck' will reconfigure with required options.
+    # Now we only need to prepare the Makefile without sparse-wrapped CC.
+    configure_ovs
+
+    export DISTCHECK_CONFIGURE_FLAGS="$OPTS"
+    if ! make distcheck -j4 CFLAGS="${CFLAGS_FOR_OVS}" \
+         TESTSUITEFLAGS=-j4 RECHECK=yes; then
+        # testsuite.log is necessary for debugging.
+        cat */_build/sub/tests/testsuite.log
+        exit 1
+    fi
+else
+    if [ -z "${KERNEL_LIST}" ]; then build_ovs ${KERNEL};
+    else
+        save_EXTRA_OPTS="${EXTRA_OPTS}"
+        for KERNEL in ${KERNEL_LIST}; do
+            echo "=============================="
+            echo "Building with kernel ${KERNEL}"
+            echo "=============================="
+            EXTRA_OPTS="${save_EXTRA_OPTS}"
+            install_kernel ${KERNEL}
+            OPTS="${EXTRA_OPTS} ${save_OPTS}"
+            build_ovs ${KERNEL}
+            make distclean
+        done
+    fi
+fi
+
+exit 0
diff --git a/.ci/linux-prepare.sh b/.ci/linux-prepare.sh
new file mode 100755
index 0000000000..fea905a830
--- /dev/null
+++ b/.ci/linux-prepare.sh
@@ -0,0 +1,42 @@
+#!/bin/bash
+
+set -ev
+
+if [ "$DEB_PACKAGE" ]; then
+    # We're not using sparse for debian packages, tests are skipped and
+    # all extra dependencies tracked by mk-build-deps.
+    exit 0
+fi
+
+# Build and install sparse.
+#
+# Explicitly disable sparse support for llvm because some travis
+# environments claim to have LLVM (llvm-config exists and works) but
+# linking against it fails.
+# Disabling sqlite support because sindex build fails and we don't
+# really need this utility being installed.
+git clone git://git.kernel.org/pub/scm/devel/sparse/sparse.git
+cd sparse
+make -j4 HAVE_LLVM= HAVE_SQLITE= install
+cd ..
+
+pip3 install --disable-pip-version-check --user flake8 hacking
+pip3 install --user --upgrade docutils
+
+if [ "$M32" ]; then
+    # Installing 32-bit libraries.
+    pkgs="gcc-multilib"
+    if [ -z "$GITHUB_WORKFLOW" ]; then
+        # 32-bit and 64-bit libunwind can not be installed at the same time.
+        # This will remove the 64-bit libunwind and install 32-bit version.
+        # GitHub Actions doesn't have 32-bit versions of these libs.
+        pkgs=$pkgs" libunwind-dev:i386 libunbound-dev:i386"
+    fi
+
+    sudo apt-get install -y $pkgs
+fi
+
+# IPv6 is supported by kernel but disabled in TravisCI images:
+#   https://github.com/travis-ci/travis-ci/issues/8891
+# Enable it to avoid skipping of IPv6 related tests.
+sudo sysctl -w net.ipv6.conf.all.disable_ipv6=0
diff --git a/.ci/osx-build.sh b/.ci/osx-build.sh
new file mode 100755
index 0000000000..bf2c13fa3c
--- /dev/null
+++ b/.ci/osx-build.sh
@@ -0,0 +1,32 @@
+#!/bin/bash
+
+set -o errexit
+
+CFLAGS="-Werror $CFLAGS"
+EXTRA_OPTS=""
+
+function configure_ovs()
+{
+    ./boot.sh && ./configure $*
+}
+
+configure_ovs $EXTRA_OPTS $*
+
+if [ "$CC" = "clang" ]; then
+    set make CFLAGS="$CFLAGS -Wno-error=unused-command-line-argument"
+else
+    set make CFLAGS="$CFLAGS $BUILD_ENV"
+fi
+if ! "$@"; then
+    cat config.log
+    exit 1
+fi
+if [ "$TESTSUITE" ] && [ "$CC" != "clang" ]; then
+    if ! make distcheck RECHECK=yes; then
+        # testsuite.log is necessary for debugging.
+        cat */_build/sub/tests/testsuite.log
+        exit 1
+    fi
+fi
+
+exit 0
diff --git a/.ci/osx-prepare.sh b/.ci/osx-prepare.sh
new file mode 100755
index 0000000000..b6447aba1b
--- /dev/null
+++ b/.ci/osx-prepare.sh
@@ -0,0 +1,3 @@
+#!/bin/bash
+set -ev
+pip3 install --user --upgrade docutils
diff --git a/.cirrus.yml b/.cirrus.yml
Louis Abel's avatar
Louis Abel committed
index 1b32f55d65..480fea2421 100644
Louis Abel's avatar
Louis Abel committed
--- a/.cirrus.yml
+++ b/.cirrus.yml
@@ -2,21 +2,23 @@ freebsd_build_task:
 
   freebsd_instance:
     matrix:
-      image_family: freebsd-12-1-snap
-      image_family: freebsd-11-3-snap
+      image_family: freebsd-12-2-snap
+      image_family: freebsd-11-4-snap
     cpu: 4
Louis Abel's avatar
Louis Abel committed
-    memory: 8G
+    memory: 4G
Louis Abel's avatar
Louis Abel committed
361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990
 
   env:
-    DEPENDENCIES: automake libtool gmake gcc wget openssl
-                  python3 py37-openssl py37-sphinx
+    DEPENDENCIES: automake libtool gmake gcc wget openssl python3
+    PY_DEPS:      sphinx|openssl
     matrix:
       COMPILER: gcc
       COMPILER: clang
 
   prepare_script:
     - sysctl -w kern.coredump=0
+    - pkg update -f
     - pkg install -y ${DEPENDENCIES}
+        $(pkg search -xq "^py3[0-9]+-(${PY_DEPS})-[0-9]+" | xargs)
 
   configure_script:
     - ./boot.sh
diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.yml
new file mode 100644
index 0000000000..c1b88264c2
--- /dev/null
+++ b/.github/workflows/build-and-test.yml
@@ -0,0 +1,211 @@
+name: Build and Test
+
+on: [push, pull_request]
+
+jobs:
+  build-linux:
+    env:
+      dependencies: |
+        automake libtool gcc bc libjemalloc1 libjemalloc-dev    \
+        libssl-dev llvm-dev libelf-dev libnuma-dev libpcap-dev  \
+        python3-openssl python3-pip python3-sphinx              \
+        selinux-policy-dev
+      deb_dependencies: |
+        linux-headers-$(uname -r) build-essential fakeroot devscripts equivs
+      AFXDP:       ${{ matrix.afxdp }}
+      CC:          ${{ matrix.compiler }}
+      DEB_PACKAGE: ${{ matrix.deb_package }}
+      DPDK:        ${{ matrix.dpdk }}
+      DPDK_SHARED: ${{ matrix.dpdk_shared }}
+      KERNEL:      ${{ matrix.kernel }}
+      KERNEL_LIST: ${{ matrix.kernel_list }}
+      LIBS:        ${{ matrix.libs }}
+      M32:         ${{ matrix.m32 }}
+      OPTS:        ${{ matrix.opts }}
+      TESTSUITE:   ${{ matrix.testsuite }}
+
+    name: linux ${{ join(matrix.*, ' ') }}
+    runs-on: ubuntu-18.04
+    timeout-minutes: 30
+
+    strategy:
+      fail-fast: false
+      matrix:
+        include:
+          - compiler:     gcc
+            opts:         --disable-ssl
+          - compiler:     clang
+            opts:         --disable-ssl
+
+          - compiler:     gcc
+            testsuite:    test
+            kernel:       3.16
+          - compiler:     clang
+            testsuite:    test
+            kernel:       3.16
+
+          - compiler:     gcc
+            testsuite:    test
+            opts:         --enable-shared
+          - compiler:     clang
+            testsuite:    test
+            opts:         --enable-shared
+
+          - compiler:     gcc
+            testsuite:    test
+            dpdk:         dpdk
+          - compiler:     clang
+            testsuite:    test
+            dpdk:         dpdk
+
+          - compiler:     gcc
+            testsuite:    test
+            libs:         -ljemalloc
+          - compiler:     clang
+            testsuite:    test
+            libs:         -ljemalloc
+
+          - compiler:     gcc
+            kernel_list:  5.0 4.20 4.19 4.18 4.17 4.16
+          - compiler:     clang
+            kernel_list:  5.0 4.20 4.19 4.18 4.17 4.16
+
+          - compiler:     gcc
+            kernel_list:  4.15 4.14 4.9 4.4 3.16
+          - compiler:     clang
+            kernel_list:  4.15 4.14 4.9 4.4 3.16
+
+          - compiler:     gcc
+            afxdp:        afxdp
+            kernel:       5.3
+          - compiler:     clang
+            afxdp:        afxdp
+            kernel:       5.3
+
+          - compiler:     gcc
+            dpdk:         dpdk
+            opts:         --enable-shared
+          - compiler:     clang
+            dpdk:         dpdk
+            opts:         --enable-shared
+
+          - compiler:     gcc
+            dpdk_shared:  dpdk-shared
+          - compiler:     clang
+            dpdk_shared:  dpdk-shared
+
+          - compiler:     gcc
+            dpdk_shared:  dpdk-shared
+            opts:         --enable-shared
+          - compiler:     clang
+            dpdk_shared:  dpdk-shared
+            opts:         --enable-shared
+
+          - compiler:     gcc
+            m32:          m32
+            opts:         --disable-ssl
+
+          - compiler:     gcc
+            deb_package:  deb
+
+    steps:
+    - name: checkout
+      uses: actions/checkout@v2
+
+    - name: fix up /etc/hosts
+      # https://github.com/actions/virtual-environments/issues/3353
+      run:  |
+        cat /etc/hosts
+        sudo sed -i "/don't remove this line/d" /etc/hosts || true
+
+    - name: create ci signature file for the dpdk cache key
+      if:   matrix.dpdk != '' || matrix.dpdk_shared != ''
+      # This will collect most of DPDK related lines, so hash will be different
+      # if something changed in a way we're building DPDK including DPDK_VER.
+      # This also allows us to use cache from any branch as long as version
+      # and a way we're building DPDK stays the same.
+      run:  |
+        grep -irE 'RTE_|DPDK|meson|ninja' -r .ci/ > dpdk-ci-signature
+        cat dpdk-ci-signature
+
+    - name: cache
+      if:   matrix.dpdk != '' || matrix.dpdk_shared != ''
+      uses: actions/cache@v2
+      env:
+        matrix_key: ${{ matrix.dpdk }}${{ matrix.dpdk_shared }}
+        ci_key:     ${{ hashFiles('dpdk-ci-signature') }}
+      with:
+        path: dpdk-dir
+        key:  ${{ env.matrix_key }}-${{ env.ci_key }}
+
+    - name: update APT cache
+      run:  sudo apt update || true
+    - name: install common dependencies
+      if:   matrix.deb_package == ''
+      run:  sudo apt install -y ${{ env.dependencies }}
+    - name: install dependencies for debian packages
+      if:   matrix.deb_package != ''
+      run:  sudo apt install -y ${{ env.deb_dependencies }}
+    - name: install libunbound libunwind
+      if:   matrix.m32 == ''
+      run:  sudo apt install -y libunbound-dev libunwind-dev
+
+    - name: prepare
+      run:  ./.ci/linux-prepare.sh
+
+    - name: build
+      run:  PATH="$PATH:$HOME/bin" ./.ci/linux-build.sh
+
+    - name: upload deb packages
+      if:   matrix.deb_package != ''
+      uses: actions/upload-artifact@v2
+      with:
+        name: deb-packages
+        path: '/home/runner/work/ovs/*.deb'
+
+    - name: copy logs on failure
+      if: failure() || cancelled()
+      run: |
+        # upload-artifact@v2 throws exceptions if it tries to upload socket
+        # files and we could have some socket files in testsuite.dir.
+        # Also, upload-artifact@v2 doesn't work well enough with wildcards.
+        # So, we're just archiving everything here to avoid any issues.
+        mkdir logs
+        cp config.log ./logs/
+        cp -r ./*/_build/sub/tests/testsuite.* ./logs/ || true
+        tar -czvf logs.tgz logs/
+
+    - name: upload logs on failure
+      if: failure() || cancelled()
+      uses: actions/upload-artifact@v2
+      with:
+        name: logs-linux-${{ join(matrix.*, '-') }}
+        path: logs.tgz
+
+  build-osx:
+    env:
+      CC:    clang
+      OPTS:  --disable-ssl
+
+    name:    osx clang --disable-ssl
+    runs-on: macos-latest
+    timeout-minutes: 30
+
+    strategy:
+      fail-fast: false
+
+    steps:
+    - name: checkout
+      uses: actions/checkout@v2
+    - name: install dependencies
+      run:  brew install automake libtool
+    - name: prepare
+      run:  ./.ci/osx-prepare.sh
+    - name: build
+      run:  PATH="$PATH:$HOME/bin" ./.ci/osx-build.sh
+    - name: upload logs on failure
+      if: failure()
+      uses: actions/upload-artifact@v2
+      with:
+        name: logs-osx-clang---disable-ssl
+        path: config.log
diff --git a/AUTHORS.rst b/AUTHORS.rst
index fe3935fca2..4c8772f63a 100644
--- a/AUTHORS.rst
+++ b/AUTHORS.rst
@@ -419,6 +419,7 @@ Zhenyu Gao                         sysugaozhenyu@gmail.com
 ZhiPeng Lu                         luzhipeng@uniudc.com
 Zhou Yangchao                      1028519445@qq.com
 aginwala                           amginwal@gmail.com
+lzhecheng                          lzhecheng@vmware.com
 parameswaran krishnamurthy         parkrish@gmail.com
 solomon                            liwei.solomon@gmail.com
 wenxu                              wenxu@ucloud.cn
@@ -496,6 +497,7 @@ Edwin Chiu                      echiu@vmware.com
 Eivind Bulie Haanaes
 Enas Ahmad                      enas.ahmad@kaust.edu.sa
 Eric Lopez
+Frank Wang (王培辉)             wangpeihui@inspur.com
 Frido Roose                     fr.roose@gmail.com
 Gaetano Catalli                 gaetano.catalli@gmail.com
 Gavin Remaley                   gavin_remaley@selinc.com
@@ -558,6 +560,7 @@ Krishna Miriyala                miriyalak@vmware.com
 Krishna Mohan Elluru            elluru.kri.mohan@hpe.com
 László Sürü                     laszlo.suru@ericsson.com
 Len Gao                         leng@vmware.com
+Linhaifeng                      haifeng.lin@huawei.com
 Logan Rosen                     logatronico@gmail.com
 Luca Falavigna                  dktrkranz@debian.org
 Luiz Henrique Ozaki             luiz.ozaki@gmail.com
@@ -655,6 +658,7 @@ Ying Chen                       yingchen@vmware.com
 Yongqiang Liu                   liuyq7809@gmail.com
 ZHANG Zhiming                   zhangzhiming@yunshan.net.cn
 Zhangguanghui                   zhang.guanghui@h3c.com
+Zheng Jingzhou                  glovejmm@163.com
 Ziyou Wang                      ziyouw@vmware.com
 ankur dwivedi                   ankurengg2003@gmail.com
 chen zhang                      3zhangchen9211@gmail.com
diff --git a/Documentation/automake.mk b/Documentation/automake.mk
index 22976a3cd6..f46ec988a3 100644
--- a/Documentation/automake.mk
+++ b/Documentation/automake.mk
@@ -217,8 +217,13 @@ install-man-rst: docs-check
 	    $(extract_stem_and_section); \
 	    echo " $(MKDIR_P) '$(DESTDIR)'\"$$mandir\""; \
 	    $(MKDIR_P) '$(DESTDIR)'"$$mandir"; \
-	    echo " $(INSTALL_DATA) $(SPHINXBUILDDIR)/man/$$stem.$$section '$(DESTDIR)'\"$$mandir/$$stem.$$section\""; \
-	    $(INSTALL_DATA) $(SPHINXBUILDDIR)/man/$$stem.$$section '$(DESTDIR)'"$$mandir/$$stem.$$section"; \
+	    if test -f $(SPHINXBUILDDIR)/man/$$stem.$$section; then \
+	        filepath=$(SPHINXBUILDDIR)/man/$$stem.$$section; \
+	    else \
+	        filepath=$(SPHINXBUILDDIR)/man/$$section/$$stem.$$section; \
+	    fi; \
+	    echo " $(INSTALL_DATA) $$filepath '$(DESTDIR)'\"$$mandir/$$stem.$$section\""; \
+	    $(INSTALL_DATA) $$filepath '$(DESTDIR)'"$$mandir/$$stem.$$section"; \
 	done
 else
 install-man-rst:
diff --git a/Documentation/faq/releases.rst b/Documentation/faq/releases.rst
index 6702c58a2b..70a0e9b221 100644
--- a/Documentation/faq/releases.rst
+++ b/Documentation/faq/releases.rst
@@ -67,9 +67,10 @@ Q: What Linux kernel versions does each Open vSwitch release work with?
     2.7.x        3.10 to 4.9
     2.8.x        3.10 to 4.12
     2.9.x        3.10 to 4.13
-    2.10.x       3.10 to 4.17
-    2.11.x       3.10 to 4.18
-    2.12.x       3.10 to 5.0
+    2.10.x       3.16 to 4.17
+    2.11.x       3.16 to 4.18
+    2.12.x       3.16 to 5.0
+    2.13.x       3.16 to 5.0
     ============ ==============
 
     Open vSwitch userspace should also work with the Linux kernel module built
@@ -78,6 +79,10 @@ Q: What Linux kernel versions does each Open vSwitch release work with?
     Open vSwitch userspace is not sensitive to the Linux kernel version.  It
     should build against almost any kernel, certainly against 2.6.32 and later.
 
+    Open vSwitch branches 2.10 through 2.13 will still compile against the
+    RHEL and CentOS 7 3.10 based kernels since they have diverged from the
+    Linux kernel.org 3.10 kernels.
+
 Q: Are all features available with all datapaths?
 
     A: Open vSwitch supports different datapaths on different platforms.  Each
@@ -173,9 +178,9 @@ Q: What DPDK version does each Open vSwitch release work with?
     A: The following table lists the DPDK version against which the given
     versions of Open vSwitch will successfully build.
 
-    ============ =======
+    ============ ========
     Open vSwitch DPDK
-    ============ =======
+    ============ ========
     2.2.x        1.6
     2.3.x        1.6
     2.4.x        2.0
@@ -183,11 +188,12 @@ Q: What DPDK version does each Open vSwitch release work with?
     2.6.x        16.07.2
     2.7.x        16.11.9
     2.8.x        17.05.2
-    2.9.x        17.11.4
-    2.10.x       17.11.4
-    2.11.x       18.11.5
-    2.12.x       18.11.5
-    ============ =======
+    2.9.x        17.11.10
+    2.10.x       17.11.10
+    2.11.x       18.11.11
+    2.12.x       18.11.11
+    2.13.x       19.11.8
+    ============ ========
 
 Q: Are all the DPDK releases that OVS versions work with maintained?
 
diff --git a/Documentation/internals/contributing/submitting-patches.rst b/Documentation/internals/contributing/submitting-patches.rst
index 5a314cc60a..f2039595e7 100644
--- a/Documentation/internals/contributing/submitting-patches.rst
+++ b/Documentation/internals/contributing/submitting-patches.rst
@@ -68,11 +68,9 @@ Testing is also important:
   feature.  A bug fix patch should preferably add a test that would
   fail if the bug recurs.
 
-If you are using GitHub, then you may utilize the travis-ci.org CI build system
-by linking your GitHub repository to it. This will run some of the above tests
-automatically when you push changes to your repository.  See the "Continuous
-Integration with Travis-CI" in :doc:`/topics/testing` for details on how to set
-it up.
+If you are using GitHub, then you may utilize the GitHub Actions CI build
+system.  It will run some of the above tests automatically when you push
+changes to your repository.
 
 Email Subject
 -------------
diff --git a/Documentation/intro/install/dpdk.rst b/Documentation/intro/install/dpdk.rst
index dbf88ec43f..b603b6f0b0 100644
--- a/Documentation/intro/install/dpdk.rst
+++ b/Documentation/intro/install/dpdk.rst
@@ -42,7 +42,7 @@ Build requirements
 In addition to the requirements described in :doc:`general`, building Open
 vSwitch with DPDK will require the following:
 
-- DPDK 19.11
+- DPDK 19.11.8
 
 - A `DPDK supported NIC`_
 
@@ -71,9 +71,9 @@ Install DPDK
 #. Download the `DPDK sources`_, extract the file and set ``DPDK_DIR``::
 
        $ cd /usr/src/
-       $ wget https://fast.dpdk.org/rel/dpdk-19.11.tar.xz
-       $ tar xf dpdk-19.11.tar.xz
-       $ export DPDK_DIR=/usr/src/dpdk-19.11
+       $ wget https://fast.dpdk.org/rel/dpdk-19.11.8.tar.xz
+       $ tar xf dpdk-19.11.8.tar.xz
+       $ export DPDK_DIR=/usr/src/dpdk-stable-19.11.8
        $ cd $DPDK_DIR
 
 #. (Optional) Configure DPDK as a shared library
@@ -687,6 +687,15 @@ Limitations
   around is temporary and is expected to be removed once a method is provided
   by DPDK to query the upper bound MTU value for a given device.
 
+- Flow Control: When using i40e devices (Intel(R) 700 Series) it is recommended
+  to set Link State Change detection to interrupt mode. Otherwise it has been
+  observed that using the default polling mode, flow control changes may not be
+  applied, and flow control states will not be reflected correctly.
+  The issue is under investigation, this is a temporary work around.
+
+  For information about setting Link State Change detection, refer to
+  :ref:`lsc-detection`.
+
 Reporting Bugs
 --------------
 
diff --git a/Documentation/topics/dpdk/phy.rst b/Documentation/topics/dpdk/phy.rst
index 38e52c8deb..55a98e2b0e 100644
--- a/Documentation/topics/dpdk/phy.rst
+++ b/Documentation/topics/dpdk/phy.rst
@@ -385,6 +385,8 @@ Jumbo Frames
 DPDK physical ports can be configured to use Jumbo Frames. For more
 information, refer to :doc:`jumbo-frames`.
 
+.. _lsc-detection:
+
 Link State Change (LSC) detection configuration
 -----------------------------------------------
 
diff --git a/Documentation/topics/dpdk/pmd.rst b/Documentation/topics/dpdk/pmd.rst
index 6f1fdcbc6f..b017b84f6a 100644
--- a/Documentation/topics/dpdk/pmd.rst
+++ b/Documentation/topics/dpdk/pmd.rst
@@ -224,7 +224,9 @@ load then the actual reassignment will be performed.
 
     PMD Auto Load Balancing doesn't currently work if queues are assigned
     cross NUMA as actual processing load could get worse after assignment
-    as compared to what dry run predicts.
+    as compared to what dry run predicts. The only exception is when all
+    PMD threads are running on cores from a single NUMA node.  In this case
+    Auto Load Balancing is still possible.
 
 The minimum time between 2 consecutive PMD auto load balancing iterations can
 also be configured by::
diff --git a/Documentation/topics/dpdk/qos.rst b/Documentation/topics/dpdk/qos.rst
index 103495415a..a98ec672fc 100644
--- a/Documentation/topics/dpdk/qos.rst
+++ b/Documentation/topics/dpdk/qos.rst
@@ -69,22 +69,24 @@ to prioritize certain traffic over others at a port level.
 
 For example, the following configuration will limit the traffic rate at a
 port level to a maximum of 2000 packets a second (64 bytes IPv4 packets).
-100pps as CIR (Committed Information Rate) and 1000pps as EIR (Excess
-Information Rate). High priority traffic is routed to queue 10, which marks
+1000pps as CIR (Committed Information Rate) and 1000pps as EIR (Excess
+Information Rate). CIR and EIR are measured in bytes without Ethernet header.
+As a result, 1000pps means (64-byte - 14-byte) * 1000 = 50,000 in the
+configuration below. High priority traffic is routed to queue 10, which marks
 all traffic as CIR, i.e. Green. All low priority traffic, queue 20, is
 marked as EIR, i.e. Yellow::
 
     $ ovs-vsctl --timeout=5 set port dpdk1 qos=@myqos -- \
         --id=@myqos create qos type=trtcm-policer \
-        other-config:cir=52000 other-config:cbs=2048 \
-        other-config:eir=52000 other-config:ebs=2048  \
+        other-config:cir=50000 other-config:cbs=2048 \
+        other-config:eir=50000 other-config:ebs=2048  \
         queues:10=@dpdk1Q10 queues:20=@dpdk1Q20 -- \
          --id=@dpdk1Q10 create queue \
-          other-config:cir=41600000 other-config:cbs=2048 \
+          other-config:cir=100000 other-config:cbs=2048 \
           other-config:eir=0 other-config:ebs=0 -- \
          --id=@dpdk1Q20 create queue \
            other-config:cir=0 other-config:cbs=0 \
-           other-config:eir=41600000 other-config:ebs=2048 \
+           other-config:eir=50000 other-config:ebs=2048
 
 This configuration accomplishes that the high priority traffic has a
 guaranteed bandwidth egressing the ports at CIR (1000pps), but it can also
diff --git a/Documentation/topics/dpdk/vhost-user.rst b/Documentation/topics/dpdk/vhost-user.rst
index c6c6fd8bde..b10daa53e3 100644
--- a/Documentation/topics/dpdk/vhost-user.rst
+++ b/Documentation/topics/dpdk/vhost-user.rst
@@ -392,9 +392,9 @@ To begin, instantiate a guest as described in :ref:`dpdk-vhost-user` or
 DPDK sources to VM and build DPDK::
 
     $ cd /root/dpdk/
-    $ wget https://fast.dpdk.org/rel/dpdk-19.11.tar.xz
-    $ tar xf dpdk-19.11.tar.xz
-    $ export DPDK_DIR=/root/dpdk/dpdk-19.11
+    $ wget https://fast.dpdk.org/rel/dpdk-19.11.8.tar.xz
+    $ tar xf dpdk-19.11.8.tar.xz
+    $ export DPDK_DIR=/root/dpdk/dpdk-stable-19.11.8
     $ export DPDK_TARGET=x86_64-native-linuxapp-gcc
     $ export DPDK_BUILD=$DPDK_DIR/$DPDK_TARGET
     $ cd $DPDK_DIR
diff --git a/Documentation/topics/testing.rst b/Documentation/topics/testing.rst
index 161e9d442e..fb1cbdf25e 100644
--- a/Documentation/topics/testing.rst
+++ b/Documentation/topics/testing.rst
@@ -405,45 +405,17 @@ You should invoke scan-view to view analysis results. The last line of output
 from ``clang-analyze`` will list the command (containing results directory)
 that you should invoke to view the results on a browser.
 
-Continuous Integration with Travis CI
--------------------------------------
+Continuous Integration with GitHub Actions
+------------------------------------------
 
-A .travis.yml file is provided to automatically build Open vSwitch with various
-build configurations and run the testsuite using Travis CI. Builds will be
-performed with gcc, sparse and clang with the -Werror compiler flag included,
-therefore the build will fail if a new warning has been introduced.
+A ``.github/workflows/*.yml`` files provided to automatically build
+Open vSwitch with various build configurations and run the testsuite using
+GitHub Actions. Builds will be performed with gcc, sparse and clang with the
+-Werror compiler flag included, therefore the build will fail if a new warning
+has been introduced.
 
 The CI build is triggered via git push (regardless of the specific branch) or
-pull request against any Open vSwitch GitHub repository that is linked to
-travis-ci.
-
-Instructions to setup travis-ci for your GitHub repository:
-
-1. Go to https://travis-ci.org/ and sign in using your GitHub ID.
-2. Go to the "Repositories" tab and enable the ovs repository. You may disable
-   builds for pushes or pull requests.
-3. In order to avoid forks sending build failures to the upstream mailing list,
-   the notification email recipient is encrypted. If you want to receive email
-   notification for build failures, replace the encrypted string:
-
-   1. Install the travis-ci CLI (Requires ruby >=2.0): gem install travis
-   2. In your Open vSwitch repository: travis encrypt mylist@mydomain.org
-   3. Add/replace the notifications section in .travis.yml and fill in the
-      secure string as returned by travis encrypt::
-
-          notifications:
-            email:
-              recipients:
-                - secure: "....."
-
-  .. note::
-    You may remove/omit the notifications section to fall back to default
-    notification behaviour which is to send an email directly to the author and
-    committer of the failing commit. Note that the email is only sent if the
-    author/committer have commit rights for the particular GitHub repository.
-
-4. Pushing a commit to the repository which breaks the build or the
-   testsuite will now trigger a email sent to mylist@mydomain.org
+pull request against any Open vSwitch GitHub repository.
 
 vsperf
 ------
diff --git a/Documentation/topics/userspace-tso.rst b/Documentation/topics/userspace-tso.rst
index 94eddc0b2f..f7b6b2639a 100644
--- a/Documentation/topics/userspace-tso.rst
+++ b/Documentation/topics/userspace-tso.rst
@@ -91,20 +91,24 @@ The current OvS userspace `TSO` implementation supports flat and VLAN networks
 only (i.e. no support for `TSO` over tunneled connection [VxLAN, GRE, IPinIP,
 etc.]).
 
+The NIC driver must support and advertise checksum offload for TCP and UDP.
+However, SCTP is not mandatory because very few drivers advertised support
+and it wasn't a widely used protocol at the moment this feature was introduced
+in Open vSwitch. Currently, if the NIC supports that, then the feature is
+enabled, otherwise TSO can still be enabled but SCTP packets sent to the NIC
+will be dropped.
+
 There is no software implementation of TSO, so all ports attached to the
 datapath must support TSO or packets using that feature will be dropped
 on ports without TSO support.  That also means guests using vhost-user
 in client mode will receive TSO packet regardless of TSO being enabled
 or disabled within the guest.
 
-When the NIC performing the segmentation is using the i40e DPDK PMD, a fix
-must be included in the DPDK build, otherwise TSO will not work. The fix can
-be found on `DPDK patchwork`__.
-
-__ https://patches.dpdk.org/patch/64136/
-
-This fix is expected to be included in the 19.11.1 release. When OVS migrates
-to this DPDK release, this limitation can be removed.
+All kernel devices that use the raw socket interface (veth, for example)
+require the kernel commit 9d2f67e43b73 ("net/packet: fix packet drop as of
+virtio gso") in order to work properly. This commit was merged in upstream
+kernel 4.19-rc7, so make sure your kernel is either newer or contains the
+backport.
 
 ~~~~~~~~~~~~~~~~~~
 Performance Tuning
diff --git a/Documentation/tutorials/ipsec.rst b/Documentation/tutorials/ipsec.rst
index b4c3235132..d7c56d5fcf 100644
--- a/Documentation/tutorials/ipsec.rst
+++ b/Documentation/tutorials/ipsec.rst
@@ -298,6 +298,7 @@ For example::
                                              Otherwise, error message will
                                              be provided
    Tunnel Type:    gre
+   Local IP:       %defaultroute
    Remote IP:      2.2.2.2
    SKB mark:       None
    Local cert:     None
diff --git a/Makefile.am b/Makefile.am
index b279303d18..b3b56cd50e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -46,7 +46,7 @@ AM_CPPFLAGS += -DNDEBUG
 AM_CFLAGS += -fomit-frame-pointer
 endif
 
-AM_CTAGSFLAGS = $(OVS_CTAGS_IDENTIFIERS_LIST)
+AM_CTAGSFLAGS = -I "$(OVS_CTAGS_IDENTIFIERS_LIST)"
 
 if WIN32
 psep=";"
@@ -76,12 +76,12 @@ EXTRA_DIST = \
 	MAINTAINERS.rst \
 	README.rst \
 	NOTICE \
+	.ci/linux-build.sh \
+	.ci/linux-prepare.sh \
+	.ci/osx-build.sh \
+	.ci/osx-prepare.sh \
 	.cirrus.yml \
-	.travis.yml \
-	.travis/linux-build.sh \
-	.travis/linux-prepare.sh \
-	.travis/osx-build.sh \
-	.travis/osx-prepare.sh \
+	.github/workflows/build-and-test.yml \
 	appveyor.yml \
 	boot.sh \
 	poc/builders/Vagrantfile \
diff --git a/NEWS b/NEWS
Louis Abel's avatar
Louis Abel committed
index dab94e924d..0ae1076ee1 100644
Louis Abel's avatar
Louis Abel committed
--- a/NEWS
+++ b/NEWS
Louis Abel's avatar
Louis Abel committed
@@ -1,3 +1,56 @@
+v2.13.5 - xx xxx xxxx
Louis Abel's avatar
Louis Abel committed
+---------------------
Louis Abel's avatar
Louis Abel committed
+   - OVS now reports the datapath capability 'ct_zero_snat', which reflects
+     whether the SNAT with all-zero IP address is supported.
+     See ovs-vswitchd.conf.db(5) for details.
+
+v2.13.4 - 01 Jul 2021
+---------------------
+   - Bug fixes
Louis Abel's avatar
Louis Abel committed
+   - DPDK:
+     * OVS validated with DPDK 19.11.8. It is recommended to use this version
+       until further releases.
+   - ovs-ctl:
+     * New option '--no-record-hostname' to disable hostname configuration
+       in ovsdb on startup.
+     * New command 'record-hostname-if-not-set' to update hostname in ovsdb.
+
+v2.13.3 - 10 Feb 2021
+---------------------
+   - Bug fixes
+   - Security:
+     * Fixed packet parsing vulnerability CVE-2020-35498.
+
+v2.13.2 - 13 Jan 2021
+---------------------
+   - Bug fixes
+   - LLDP:
+     * Security fixes for CVE-2015-8011 and CVE-2020-27827.
+   - IPsec:
+     * Fixed support of strongswan 5.7+ in ovs-monitor-ipsec.
+     * Add option '--no-cleanup' to allow ovs-monitor-ipsec to stop without
+       tearing down IPsec tunnels.
+     * Add option '--no-restart-ike-daemon' to allow ovs-monitor-ipsec to start
+       without restarting ipsec daemon.
+   - OVSDB:
+     * New unixctl command 'ovsdb-server/memory-trim-on-compaction on|off'.
+       If turned on, ovsdb-server will try to reclaim all the unused memory
+       after every DB compaction back to OS.  Disabled by default.
+     * Maximum backlog on RAFT connections limited to 500 messages or 4GB.
+       Once threshold reached, connection is dropped (and re-established).
+       Use the 'cluster/set-backlog-threshold' command to change limits.
+     * Fixed SHA-1 hash computation for databases larger than 512 MB.
+   - DPDK:
+     * Fixed support of 'net_virtio' devices.
+
+v2.13.1 - 30 Jul 2020
+---------------------
+   - Bug fixes
+   - DPDK:
+     * OVS validated with DPDK 19.11.2, due to the inclusion of fixes for
+       CVE-2020-10722, CVE-2020-10723, CVE-2020-10724, CVE-2020-10725 and
+       CVE-2020-10726, this DPDK version is strongly recommended to be used.
+
 v2.13.0 - 14 Feb 2020
 ---------------------
    - OVN:
Louis Abel's avatar
Louis Abel committed
@@ -43,6 +96,9 @@ v2.13.0 - 14 Feb 2020
Louis Abel's avatar
Louis Abel committed
    - 'ovs-appctl dpctl/dump-flows' can now show offloaded=partial for
      partially offloaded flows, dp:dpdk for fully offloaded by dpdk, and
      type filter supports new filters: "dpdk" and "partially-offloaded".
+   - Add new argument '--offload-stats' for command
+     'ovs-appctl bridge/dump-flows',
+     so it can display offloaded packets statistics.
 
 v2.12.0 - 03 Sep 2019
 ---------------------
Louis Abel's avatar
Louis Abel committed
@@ -117,9 +173,6 @@ v2.12.0 - 03 Sep 2019
Louis Abel's avatar
Louis Abel committed
      * Add support for conntrack zone-based timeout policy.
    - 'ovs-dpctl dump-flows' is no longer suitable for dumping offloaded flows.
      'ovs-appctl dpctl/dump-flows' should be used instead.
-   - Add new argument '--offload-stats' for command
-     'ovs-appctl bridge/dump-flows',
-     so it can display offloaded packets statistics.
    - Add L2 GRE tunnel over IPv6 support.
 
 v2.11.0 - 19 Feb 2019
diff --git a/README.rst b/README.rst
index e06ddf2671..8e64d74aee 100644
--- a/README.rst
+++ b/README.rst
@@ -6,8 +6,8 @@
 Open vSwitch
 ============
 
-.. image:: https://travis-ci.org/openvswitch/ovs.png
-    :target: https://travis-ci.org/openvswitch/ovs
+.. image:: https://github.com/openvswitch/ovs/workflows/Build%20and%20Test/badge.svg
+    :target: https://github.com/openvswitch/ovs/actions
 .. image:: https://ci.appveyor.com/api/projects/status/github/openvswitch/ovs?branch=master&svg=true&retina=true
     :target: https://ci.appveyor.com/project/blp/ovs/history
 .. image:: https://api.cirrus-ci.com/github/openvswitch/ovs.svg
diff --git a/acinclude.m4 b/acinclude.m4
index c1470ccc6b..914e27b932 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -192,10 +192,10 @@ dnl Configure Linux tc compat.
 AC_DEFUN([OVS_CHECK_LINUX_TC], [
   AC_COMPILE_IFELSE([
     AC_LANG_PROGRAM([#include <linux/pkt_cls.h>], [
-        int x = TCA_ACT_FLAGS;
+        int x = TCA_FLOWER_KEY_CT_FLAGS_REPLY;
     ])],
-    [AC_DEFINE([HAVE_TCA_ACT_FLAGS], [1],
-               [Define to 1 if TCA_ACT_FLAGS is available.])])
+    [AC_DEFINE([HAVE_TCA_FLOWER_KEY_CT_FLAGS_REPLY], [1],
+               [Define to 1 if TCA_FLOWER_KEY_CT_FLAGS_REPLY is available.])])
 
   AC_CHECK_MEMBERS([struct tcf_t.firstuse], [], [], [#include <linux/pkt_cls.h>])
 
@@ -250,6 +250,18 @@ AC_DEFUN([OVS_CHECK_LINUX_SCTP_CT], [
                [Define to 1 if SCTP_CONNTRACK_HEARTBEAT_SENT is available.])])
 ])
 
+dnl OVS_CHECK_LINUX_VIRTIO_TYPES
+dnl
+dnl Checks for kernels that need virtio_types definition.
+AC_DEFUN([OVS_CHECK_LINUX_VIRTIO_TYPES], [
+  AC_COMPILE_IFELSE([
+    AC_LANG_PROGRAM([#include <linux/virtio_types.h>], [
+        __virtio16 x =  0;
+    ])],
+    [AC_DEFINE([HAVE_VIRTIO_TYPES], [1],
+    [Define to 1 if __virtio16 is available.])])
+])
+
 dnl OVS_FIND_DEPENDENCY(FUNCTION, SEARCH_LIBS, NAME_TO_PRINT)
 dnl
 dnl Check for a function in a library list.
@@ -379,7 +391,6 @@ AC_DEFUN([OVS_CHECK_DPDK], [
       [AC_MSG_RESULT([no])])
 
     AC_CHECK_DECL([RTE_LIBRTE_MLX5_PMD], [dnl found
-      OVS_FIND_DEPENDENCY([mnl_attr_put], [mnl], [libmnl])
       AC_CHECK_DECL([RTE_IBVERBS_LINK_DLOPEN], [], [dnl not found
         OVS_FIND_DEPENDENCY([mlx5dv_create_wq], [mlx5], [libmlx5])
         OVS_FIND_DEPENDENCY([verbs_init_cq], [ibverbs], [libibverbs])
@@ -420,6 +431,16 @@ AC_DEFUN([OVS_CHECK_DPDK], [
     if test "$DPDK_AUTO_DISCOVER" = "false"; then
       OVS_LDFLAGS="$OVS_LDFLAGS -L$DPDK_LIB_DIR"
     fi
+    # Stripping out possible instruction set specific configuration that DPDK
+    # forces in pkg-config since this could override user-specified options.
+    # It's enough to have -mssse3 to build with DPDK headers.
+    DPDK_INCLUDE=$(echo "$DPDK_INCLUDE" | sed 's/-march=[[^ ]]*//g')
+    # Also stripping out '-mno-avx512f'.  Support for AVX512 will be disabled
+    # if OVS will detect that it's broken.  OVS could be built with a
+    # completely different toolchain that correctly supports AVX512, flags
+    # forced by DPDK only breaks our feature detection mechanism and leads to
+    # build failures: https://github.com/openvswitch/ovs-issues/issues/201
+    DPDK_INCLUDE=$(echo "$DPDK_INCLUDE" | sed 's/-mno-avx512f//g')
     OVS_CFLAGS="$OVS_CFLAGS $DPDK_INCLUDE"
     OVS_ENABLE_OPTION([-mssse3])
 
@@ -567,9 +588,14 @@ AC_DEFUN([OVS_CHECK_LINUX_COMPAT], [
   OVS_GREP_IFELSE([$KSRC/include/net/ip6_fib.h], [rt6_get_cookie],
                   [OVS_DEFINE([HAVE_RT6_GET_COOKIE])])
 
+  OVS_FIND_FIELD_IFELSE([$KSRC/include/net/addrconf.h], [ipv6_stub],
+                        [dst_entry])
   OVS_GREP_IFELSE([$KSRC/include/net/addrconf.h], [ipv6_dst_lookup.*net],
                   [OVS_DEFINE([HAVE_IPV6_DST_LOOKUP_NET])])
+  OVS_GREP_IFELSE([$KSRC/include/net/addrconf.h], [ipv6_dst_lookup_flow.*net],
+                  [OVS_DEFINE([HAVE_IPV6_DST_LOOKUP_FLOW_NET])])
   OVS_GREP_IFELSE([$KSRC/include/net/addrconf.h], [ipv6_stub])
+  OVS_GREP_IFELSE([$KSRC/include/net/addrconf.h], [ipv6_dst_lookup_flow])
 
   OVS_GREP_IFELSE([$KSRC/include/linux/err.h], [ERR_CAST])
   OVS_GREP_IFELSE([$KSRC/include/linux/err.h], [IS_ERR_OR_NULL])
@@ -765,6 +791,10 @@ AC_DEFUN([OVS_CHECK_LINUX_COMPAT], [
                   [prandom_u32[[\(]]],
                   [OVS_DEFINE([HAVE_PRANDOM_U32])])
   OVS_GREP_IFELSE([$KSRC/include/linux/random.h], [prandom_u32_max])
+  OVS_GREP_IFELSE([$KSRC/include/linux/prandom.h],
+                  [prandom_u32[[\(]]],
+                  [OVS_DEFINE([HAVE_PRANDOM_U32])])
+  OVS_GREP_IFELSE([$KSRC/include/linux/prandom.h], [prandom_u32_max])
 
   OVS_GREP_IFELSE([$KSRC/include/net/rtnetlink.h], [get_link_net])
   OVS_GREP_IFELSE([$KSRC/include/net/rtnetlink.h], [name_assign_type])
@@ -918,8 +948,6 @@ AC_DEFUN([OVS_CHECK_LINUX_COMPAT], [
 
   OVS_GREP_IFELSE([$KSRC/include/net/sock.h], [sk_no_check_tx])
   OVS_GREP_IFELSE([$KSRC/include/linux/udp.h], [no_check6_tx])
-  OVS_GREP_IFELSE([$KSRC/include/linux/utsrelease.h], [el6],
-                  [OVS_DEFINE([HAVE_RHEL6_PER_CPU])])
   OVS_FIND_PARAM_IFELSE([$KSRC/include/net/protocol.h],
                         [udp_add_offload], [net],
                         [OVS_DEFINE([HAVE_UDP_ADD_OFFLOAD_TAKES_NET])])
@@ -1294,11 +1322,11 @@ AC_DEFUN([OVS_ENABLE_SPARSE],
 
 dnl OVS_CTAGS_IDENTIFIERS
 dnl
-dnl ctags ignores symbols with extras identifiers. This builds a list of
-dnl specially handled identifiers to be ignored.
+dnl ctags ignores symbols with extras identifiers. This is a list of
+dnl specially handled identifiers to be ignored. [ctags(1) -I <list>].
 AC_DEFUN([OVS_CTAGS_IDENTIFIERS],
     AC_SUBST([OVS_CTAGS_IDENTIFIERS_LIST],
-           [`printf %s '-I "'; sed -n 's/^#define \(OVS_[A-Z_]\+\)(\.\.\.)$/\1+/p' ${srcdir}/include/openvswitch/compiler.h  | tr \\\n ' ' ; printf '"'`] ))
+           ["OVS_LOCKABLE OVS_NO_THREAD_SAFETY_ANALYSIS OVS_REQ_RDLOCK+ OVS_ACQ_RDLOCK+ OVS_REQ_WRLOCK+ OVS_ACQ_WRLOCK+ OVS_REQUIRES+ OVS_ACQUIRES+ OVS_TRY_WRLOCK+ OVS_TRY_RDLOCK+ OVS_TRY_LOCK+ OVS_GUARDED_BY+ OVS_EXCLUDED+ OVS_RELEASES+ OVS_ACQ_BEFORE+ OVS_ACQ_AFTER+"]))
 
 dnl OVS_PTHREAD_SET_NAME
 dnl
diff --git a/build-aux/dist-docs b/build-aux/dist-docs
index f6b88ca2d0..9429702db9 100755
--- a/build-aux/dist-docs
+++ b/build-aux/dist-docs
@@ -43,7 +43,7 @@ rm -rf $distdir
 mkdir $distdir
 
 # Install manpages.
-${MAKE-make} install-man mandir="$abs_distdir"/man
+${MAKE-make} install-man install-man-rst mandir="$abs_distdir"/man
 (cd $distdir && mv `find man -type f` . && rm -rf man)
 manpages=`cd $distdir && echo *`
 
diff --git a/configure.ac b/configure.ac
Louis Abel's avatar
Louis Abel committed
index 92b52f6712..0dc2a7dbca 100644
Louis Abel's avatar
Louis Abel committed
--- a/configure.ac
+++ b/configure.ac
@@ -13,7 +13,7 @@
 # limitations under the License.
 
 AC_PREREQ(2.63)
-AC_INIT(openvswitch, 2.13.0, bugs@openvswitch.org)
Louis Abel's avatar
Louis Abel committed
+AC_INIT(openvswitch, 2.13.5, bugs@openvswitch.org)
Louis Abel's avatar
Louis Abel committed
 AC_CONFIG_SRCDIR([datapath/datapath.c])
 AC_CONFIG_MACRO_DIR([m4])
 AC_CONFIG_AUX_DIR([build-aux])
@@ -100,6 +100,7 @@ OVS_CHECK_IF_DL
 OVS_CHECK_STRTOK_R
 OVS_CHECK_LINUX_AF_XDP
 AC_CHECK_DECLS([sys_siglist], [], [], [[#include <signal.h>]])
+AC_CHECK_DECLS([malloc_trim], [], [], [[#include <malloc.h>]])
 AC_CHECK_MEMBERS([struct stat.st_mtim.tv_nsec, struct stat.st_mtimensec],
   [], [], [[#include <sys/stat.h>]])
 AC_CHECK_MEMBERS([struct ifreq.ifr_flagshigh], [], [], [[#include <net/if.h>]])
@@ -188,6 +189,7 @@ OVS_CHECK_LINUX
 OVS_CHECK_LINUX_NETLINK
 OVS_CHECK_LINUX_TC
 OVS_CHECK_LINUX_SCTP_CT
+OVS_CHECK_LINUX_VIRTIO_TYPES
 OVS_CHECK_DPDK
 OVS_CHECK_PRAGMA_MESSAGE
 AC_SUBST([OVS_CFLAGS])
diff --git a/datapath-windows/ovsext/Actions.c b/datapath-windows/ovsext/Actions.c
Louis Abel's avatar
Louis Abel committed
index 5c9b5c3a0c..b49243006f 100644
Louis Abel's avatar
Louis Abel committed
--- a/datapath-windows/ovsext/Actions.c
+++ b/datapath-windows/ovsext/Actions.c
Louis Abel's avatar
Louis Abel committed
@@ -1112,9 +1112,9 @@ OvsPopFieldInPacketBuf(OvsForwardingContext *ovsFwdCtx,
      * should split the function and refactor. */
     if (!bufferData) {
         EthHdr *ethHdr = (EthHdr *)bufferStart;
-        /* If the frame is not VLAN make it a no op */
         if (ethHdr->Type != ETH_TYPE_802_1PQ_NBO) {
-            return NDIS_STATUS_SUCCESS;
+            OVS_LOG_ERROR("Invalid ethHdr type %u, nbl %p", ethHdr->Type, ovsFwdCtx->curNbl);
+            return NDIS_STATUS_INVALID_PACKET;
         }
     }
     RtlMoveMemory(bufferStart + shiftLength, bufferStart, shiftOffset);
@@ -1137,6 +1137,9 @@ OvsPopFieldInPacketBuf(OvsForwardingContext *ovsFwdCtx,
 static __inline NDIS_STATUS
 OvsPopVlanInPktBuf(OvsForwardingContext *ovsFwdCtx)
 {
+    NDIS_STATUS status;
+    OVS_PACKET_HDR_INFO* layers = &ovsFwdCtx->layers;
+
     /*
      * Declare a dummy vlanTag structure since we need to compute the size
      * of shiftLength. The NDIS one is a unionized structure.
@@ -1145,7 +1148,15 @@ OvsPopVlanInPktBuf(OvsForwardingContext *ovsFwdCtx)
     UINT32 shiftLength = sizeof(vlanTag.TagHeader);
     UINT32 shiftOffset = sizeof(DL_EUI48) + sizeof(DL_EUI48);
 
-    return OvsPopFieldInPacketBuf(ovsFwdCtx, shiftOffset, shiftLength, NULL);
+    status = OvsPopFieldInPacketBuf(ovsFwdCtx, shiftOffset, shiftLength,
+                                    NULL);
+
+    if (status == NDIS_STATUS_SUCCESS) {
+        layers->l3Offset -= (UINT16) shiftLength;
+        layers->l4Offset -= (UINT16) shiftLength;
+    }
+
+    return status;
 }
 
 
@@ -1259,6 +1270,7 @@ OvsActionMplsPush(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
  */
 static __inline NDIS_STATUS
 OvsUpdateEthHeader(OvsForwardingContext *ovsFwdCtx,
+                   OvsFlowKey *key,
                    const struct ovs_key_ethernet *ethAttr)
 {
     PNET_BUFFER curNb;
Louis Abel's avatar
Louis Abel committed
@@ -1285,9 +1297,11 @@ OvsUpdateEthHeader(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
     }
     ethHdr = (EthHdr *)(bufferStart + NET_BUFFER_CURRENT_MDL_OFFSET(curNb));
 
-    RtlCopyMemory(ethHdr->Destination, ethAttr->eth_dst,
-                   sizeof ethHdr->Destination);
-    RtlCopyMemory(ethHdr->Source, ethAttr->eth_src, sizeof ethHdr->Source);
+    RtlCopyMemory(ethHdr->Destination, ethAttr->eth_dst, ETH_ADDR_LENGTH);
+    RtlCopyMemory(ethHdr->Source, ethAttr->eth_src, ETH_ADDR_LENGTH);
+    /* Update l2 flow key */
+    RtlCopyMemory(key->l2.dlDst, ethAttr->eth_dst, ETH_ADDR_LENGTH);
+    RtlCopyMemory(key->l2.dlSrc, ethAttr->eth_src, ETH_ADDR_LENGTH);
 
     return NDIS_STATUS_SUCCESS;
 }
Louis Abel's avatar
Louis Abel committed
@@ -1376,6 +1390,7 @@ PUINT8 OvsGetHeaderBySize(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
  */
 NDIS_STATUS
 OvsUpdateUdpPorts(OvsForwardingContext *ovsFwdCtx,
+                  OvsFlowKey *key,
                   const struct ovs_key_udp *udpAttr)
 {
     PUINT8 bufferStart;
Louis Abel's avatar
Louis Abel committed
@@ -1400,15 +1415,19 @@ OvsUpdateUdpPorts(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
             udpHdr->check = ChecksumUpdate16(udpHdr->check, udpHdr->source,
                                              udpAttr->udp_src);
             udpHdr->source = udpAttr->udp_src;
+            key->ipKey.l4.tpSrc = udpAttr->udp_src;
         }
         if (udpHdr->dest != udpAttr->udp_dst) {
             udpHdr->check = ChecksumUpdate16(udpHdr->check, udpHdr->dest,
                                              udpAttr->udp_dst);
             udpHdr->dest = udpAttr->udp_dst;
+            key->ipKey.l4.tpDst = udpAttr->udp_dst;
         }
     } else {
         udpHdr->source = udpAttr->udp_src;
+        key->ipKey.l4.tpSrc = udpAttr->udp_src;
         udpHdr->dest = udpAttr->udp_dst;
+        key->ipKey.l4.tpDst = udpAttr->udp_dst;
     }
 
     return NDIS_STATUS_SUCCESS;
Louis Abel's avatar
Louis Abel committed
@@ -1423,6 +1442,7 @@ OvsUpdateUdpPorts(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
  */
 NDIS_STATUS
 OvsUpdateTcpPorts(OvsForwardingContext *ovsFwdCtx,
+                  OvsFlowKey *key,
                   const struct ovs_key_tcp *tcpAttr)
 {
     PUINT8 bufferStart;
Louis Abel's avatar
Louis Abel committed
@@ -1447,11 +1467,13 @@ OvsUpdateTcpPorts(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
         tcpHdr->check = ChecksumUpdate16(tcpHdr->check, tcpHdr->source,
                                          tcpAttr->tcp_src);
         tcpHdr->source = tcpAttr->tcp_src;
+        key->ipKey.l4.tpSrc = tcpAttr->tcp_src;
     }
     if (tcpHdr->dest != tcpAttr->tcp_dst) {
         tcpHdr->check = ChecksumUpdate16(tcpHdr->check, tcpHdr->dest,
                                          tcpAttr->tcp_dst);
         tcpHdr->dest = tcpAttr->tcp_dst;
+        key->ipKey.l4.tpDst = tcpAttr->tcp_dst;
     }
 
     return NDIS_STATUS_SUCCESS;
Louis Abel's avatar
Louis Abel committed
@@ -1539,9 +1561,21 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
         if (tcpHdr) {
             portField = &tcpHdr->dest;
             checkField = &tcpHdr->check;
+            l4Offload = isTx ? (BOOLEAN)csumInfo.Transmit.TcpChecksum :
+                        ((BOOLEAN)csumInfo.Receive.TcpChecksumSucceeded ||
+                         (BOOLEAN)csumInfo.Receive.TcpChecksumFailed);
         } else if (udpHdr) {
             portField = &udpHdr->dest;
             checkField = &udpHdr->check;
+            l4Offload = isTx ? (BOOLEAN)csumInfo.Transmit.UdpChecksum :
+                        ((BOOLEAN)csumInfo.Receive.UdpChecksumSucceeded ||
+                         (BOOLEAN)csumInfo.Receive.UdpChecksumFailed);
+        }
+
+       if (l4Offload) {
+            *checkField = IPPseudoChecksum(&ipHdr->saddr, &newAddr,
+                tcpHdr ? IPPROTO_TCP : IPPROTO_UDP,
+                ntohs(ipHdr->tot_len) - ipHdr->ihl * 4);
         }
     }
 
Louis Abel's avatar
Louis Abel committed
@@ -1579,6 +1613,7 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
  */
 NDIS_STATUS
 OvsUpdateIPv4Header(OvsForwardingContext *ovsFwdCtx,
+                    OvsFlowKey *key,
                     const struct ovs_key_ipv4 *ipAttr)
 {
     PUINT8 bufferStart;
Louis Abel's avatar
Louis Abel committed
@@ -1632,6 +1667,7 @@ OvsUpdateIPv4Header(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
                                             ipAttr->ipv4_src);
         }
         ipHdr->saddr = ipAttr->ipv4_src;
+        key->ipKey.nwSrc = ipAttr->ipv4_src;
     }
     if (ipHdr->daddr != ipAttr->ipv4_dst) {
         if (tcpHdr) {
Louis Abel's avatar
Louis Abel committed
@@ -1647,6 +1683,7 @@ OvsUpdateIPv4Header(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
                                             ipAttr->ipv4_dst);
         }
         ipHdr->daddr = ipAttr->ipv4_dst;
+        key->ipKey.nwDst = ipAttr->ipv4_dst;
     }
     if (ipHdr->protocol != ipAttr->ipv4_proto) {
         UINT16 oldProto = (ipHdr->protocol << 16) & 0xff00;
Louis Abel's avatar
Louis Abel committed
@@ -1661,6 +1698,7 @@ OvsUpdateIPv4Header(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
             ipHdr->check = ChecksumUpdate16(ipHdr->check, oldProto, newProto);
         }
         ipHdr->protocol = ipAttr->ipv4_proto;
+        key->ipKey.nwProto = ipAttr->ipv4_proto;
     }
     if (ipHdr->ttl != ipAttr->ipv4_ttl) {
         UINT16 oldTtl = (ipHdr->ttl) & 0xff;
Louis Abel's avatar
Louis Abel committed
@@ -1669,6 +1707,7 @@ OvsUpdateIPv4Header(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
             ipHdr->check = ChecksumUpdate16(ipHdr->check, oldTtl, newTtl);
         }
         ipHdr->ttl = ipAttr->ipv4_ttl;
+        key->ipKey.nwTtl = ipAttr->ipv4_ttl;
     }
 
     return NDIS_STATUS_SUCCESS;
Louis Abel's avatar
Louis Abel committed
@@ -1691,12 +1730,12 @@ OvsExecuteSetAction(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
 
     switch (type) {
     case OVS_KEY_ATTR_ETHERNET:
-        status = OvsUpdateEthHeader(ovsFwdCtx,
+        status = OvsUpdateEthHeader(ovsFwdCtx, key,
             NlAttrGetUnspec(a, sizeof(struct ovs_key_ethernet)));
         break;
 
     case OVS_KEY_ATTR_IPV4:
-        status = OvsUpdateIPv4Header(ovsFwdCtx,
+        status = OvsUpdateIPv4Header(ovsFwdCtx, key,
             NlAttrGetUnspec(a, sizeof(struct ovs_key_ipv4)));
         break;
 
Louis Abel's avatar
Louis Abel committed
@@ -1709,16 +1748,17 @@ OvsExecuteSetAction(OvsForwardingContext *ovsFwdCtx,
Louis Abel's avatar
Louis Abel committed
         status = SUCCEEDED(convertStatus) ? NDIS_STATUS_SUCCESS : NDIS_STATUS_FAILURE;
         ASSERT(status == NDIS_STATUS_SUCCESS);
         RtlCopyMemory(&ovsFwdCtx->tunKey, &tunKey, sizeof ovsFwdCtx->tunKey);
+        RtlCopyMemory(&key->tunKey, &tunKey, sizeof key->tunKey);
         break;
     }
 
     case OVS_KEY_ATTR_UDP:
-        status = OvsUpdateUdpPorts(ovsFwdCtx,
+        status = OvsUpdateUdpPorts(ovsFwdCtx, key,
             NlAttrGetUnspec(a, sizeof(struct ovs_key_udp)));
         break;
 
     case OVS_KEY_ATTR_TCP:
-        status = OvsUpdateTcpPorts(ovsFwdCtx,
+        status = OvsUpdateTcpPorts(ovsFwdCtx, key,
             NlAttrGetUnspec(a, sizeof(struct ovs_key_tcp)));
         break;
 
Louis Abel's avatar
Louis Abel committed
@@ -1763,9 +1803,11 @@ OvsExecuteRecirc(OvsForwardingContext *ovsFwdCtx,
     }
 
     if (newNbl) {
-        deferredAction = OvsAddDeferredActions(newNbl, key, NULL);
+        deferredAction = OvsAddDeferredActions(newNbl, key, &(ovsFwdCtx->layers),
+                                               NULL);
     } else {
-        deferredAction = OvsAddDeferredActions(ovsFwdCtx->curNbl, key, NULL);
+        deferredAction = OvsAddDeferredActions(ovsFwdCtx->curNbl, key,
+                                              &(ovsFwdCtx->layers), NULL);
     }
 
     if (deferredAction) {
@@ -1917,7 +1959,7 @@ OvsExecuteSampleAction(OvsForwardingContext *ovsFwdCtx,
         return STATUS_SUCCESS;
     }
 
-    if (!OvsAddDeferredActions(newNbl, key, a)) {
+    if (!OvsAddDeferredActions(newNbl, key, &(ovsFwdCtx->layers), a)) {
         OVS_LOG_INFO(
             "Deferred actions limit reached, dropping sample action.");
         OvsCompleteNBL(ovsFwdCtx->switchContext, newNbl, TRUE);
@@ -2053,6 +2095,7 @@ OvsDoExecuteActions(POVS_SWITCH_CONTEXT switchContext,
                  */
                 status = OvsPopVlanInPktBuf(&ovsFwdCtx);
                 if (status != NDIS_STATUS_SUCCESS) {
+                    OVS_LOG_ERROR("OVS-pop vlan action failed status = %lu", status);
                     dropReason = L"OVS-pop vlan action failed";
                     goto dropit;
                 }
@@ -2302,7 +2345,7 @@ OvsActionsExecute(POVS_SWITCH_CONTEXT switchContext,
 
     if (status == STATUS_SUCCESS) {
         status = OvsProcessDeferredActions(switchContext, completionList,
-                                           portNo, sendFlags, layers);
+                                           portNo, sendFlags, NULL);
     }
 
     return status;
Louis Abel's avatar
Louis Abel committed
diff --git a/datapath-windows/ovsext/Actions.h b/datapath-windows/ovsext/Actions.h
index fd050d5dd8..bc12e1166d 100644
--- a/datapath-windows/ovsext/Actions.h
+++ b/datapath-windows/ovsext/Actions.h
@@ -115,14 +115,17 @@ PUINT8 OvsGetHeaderBySize(OvsForwardingContext *ovsFwdCtx,
 
 NDIS_STATUS
 OvsUpdateUdpPorts(OvsForwardingContext *ovsFwdCtx,
+                  OvsFlowKey *key,
                   const struct ovs_key_udp *udpAttr);
 
 NDIS_STATUS
 OvsUpdateTcpPorts(OvsForwardingContext *ovsFwdCtx,
+                  OvsFlowKey *key,
                   const struct ovs_key_tcp *tcpAttr);
 
 NDIS_STATUS
 OvsUpdateIPv4Header(OvsForwardingContext *ovsFwdCtx,
+                    OvsFlowKey *key,
                     const struct ovs_key_ipv4 *ipAttr);
 
 NDIS_STATUS
diff --git a/datapath-windows/ovsext/Conntrack-other.c b/datapath-windows/ovsext/Conntrack-other.c
index 962cc8ac65..8580415a6b 100644
--- a/datapath-windows/ovsext/Conntrack-other.c
+++ b/datapath-windows/ovsext/Conntrack-other.c
@@ -49,17 +49,19 @@ OvsConntrackUpdateOtherEntry(OVS_CT_ENTRY *conn_,
 {
     ASSERT(conn_);
     struct conn_other *conn = OvsCastConntrackEntryToOtherEntry(conn_);
+    enum CT_UPDATE_RES ret = CT_UPDATE_VALID;
 
     if (reply && conn->state != OTHERS_BIDIR) {
         conn->state = OTHERS_BIDIR;
     } else if (conn->state == OTHERS_FIRST) {
         conn->state = OTHERS_MULTIPLE;
+        ret = CT_UPDATE_VALID_NEW;
     }
 
     OvsConntrackUpdateExpiration(&conn->up, now,
                                  other_timeouts[conn->state]);
 
-    return CT_UPDATE_VALID;
+    return ret;
 }
 
 OVS_CT_ENTRY *
diff --git a/datapath-windows/ovsext/Conntrack-tcp.c b/datapath-windows/ovsext/Conntrack-tcp.c
index eda42ac823..a468c3e6bc 100644
--- a/datapath-windows/ovsext/Conntrack-tcp.c
+++ b/datapath-windows/ovsext/Conntrack-tcp.c
@@ -213,11 +213,17 @@ OvsConntrackUpdateTcpEntry(OVS_CT_ENTRY* conn_,
         return CT_UPDATE_INVALID;
     }
 
-    if (((tcp_flags & (TCP_SYN|TCP_ACK)) == TCP_SYN)
-            && dst->state >= CT_DPIF_TCPS_FIN_WAIT_2
+    if ((tcp_flags & (TCP_SYN|TCP_ACK)) == TCP_SYN) {
+        if (dst->state >= CT_DPIF_TCPS_FIN_WAIT_2
             && src->state >= CT_DPIF_TCPS_FIN_WAIT_2) {
-        src->state = dst->state = CT_DPIF_TCPS_CLOSED;
-        return CT_UPDATE_NEW;
+            src->state = dst->state = CT_DPIF_TCPS_CLOSED;
+            return CT_UPDATE_NEW;
+        } else if (src->state <= CT_DPIF_TCPS_SYN_SENT) {
+            src->state = CT_DPIF_TCPS_SYN_SENT;
+            OvsConntrackUpdateExpiration(&conn->up, now,
+                                         30 * CT_INTERVAL_SEC);
+            return CT_UPDATE_VALID_NEW;
+        }
     }
 
     if (src->wscale & CT_WSCALE_FLAG
diff --git a/datapath-windows/ovsext/Conntrack.c b/datapath-windows/ovsext/Conntrack.c
index ba5611697a..55917c43ff 100644
--- a/datapath-windows/ovsext/Conntrack.c
+++ b/datapath-windows/ovsext/Conntrack.c
@@ -753,6 +753,9 @@ OvsProcessConntrackEntry(OvsForwardingContext *fwdCtx,
                 return NULL;
             }
             break;
+        case CT_UPDATE_VALID_NEW:
+            state |= OVS_CS_F_NEW;
+            break;
         }
     }
     if (entry) {
diff --git a/datapath-windows/ovsext/Conntrack.h b/datapath-windows/ovsext/Conntrack.h
index bc6580d708..b0932186af 100644
--- a/datapath-windows/ovsext/Conntrack.h
+++ b/datapath-windows/ovsext/Conntrack.h
@@ -56,6 +56,7 @@ typedef enum CT_UPDATE_RES {
     CT_UPDATE_INVALID,
     CT_UPDATE_VALID,
     CT_UPDATE_NEW,
+    CT_UPDATE_VALID_NEW,
 } CT_UPDATE_RES;
 
 /* Metadata mark for masked write to conntrack mark */
Louis Abel's avatar
Louis Abel committed
diff --git a/datapath-windows/ovsext/Recirc.c b/datapath-windows/ovsext/Recirc.c
index 2febf060dd..a32b75352b 100644
--- a/datapath-windows/ovsext/Recirc.c
+++ b/datapath-windows/ovsext/Recirc.c
@@ -277,16 +277,23 @@ OvsDeferredActionsQueuePush(POVS_DEFERRED_ACTION_QUEUE queue)
 POVS_DEFERRED_ACTION
 OvsAddDeferredActions(PNET_BUFFER_LIST nbl,
                       OvsFlowKey *key,
+                      POVS_PACKET_HDR_INFO layers,
                       const PNL_ATTR actions)
 {
     POVS_DEFERRED_ACTION_QUEUE queue = OvsDeferredActionsQueueGet();
     POVS_DEFERRED_ACTION deferredAction = NULL;
+    OVS_PACKET_HDR_INFO layersInit = { 0 };
 
     deferredAction = OvsDeferredActionsQueuePush(queue);
     if (deferredAction) {
         deferredAction->nbl = nbl;
         deferredAction->actions = actions;
         deferredAction->key = *key;
+        if (layers) {
+            deferredAction->layers = *layers;
+        } else {
+            deferredAction->layers = layersInit;
+        }
     }
 
     return deferredAction;
@@ -309,9 +316,16 @@ OvsProcessDeferredActions(POVS_SWITCH_CONTEXT switchContext,
     NDIS_STATUS status = NDIS_STATUS_SUCCESS;
     POVS_DEFERRED_ACTION_QUEUE queue = OvsDeferredActionsQueueGet();
     POVS_DEFERRED_ACTION deferredAction = NULL;
+    POVS_PACKET_HDR_INFO layersDeferred = NULL;
 
     /* Process all deferred actions. */
     while ((deferredAction = OvsDeferredActionsQueuePop(queue)) != NULL) {
+        if (layers) {
+            layersDeferred = layers;
+         } else {
+            layersDeferred = &(deferredAction->layers);
+         }
+
         if (deferredAction->actions) {
             status = OvsDoExecuteActions(switchContext,
                                          completionList,
@@ -319,7 +333,7 @@ OvsProcessDeferredActions(POVS_SWITCH_CONTEXT switchContext,
                                          portNo,
                                          sendFlags,
                                          &deferredAction->key, NULL,
-                                         layers, deferredAction->actions,
+                                         layersDeferred, deferredAction->actions,
                                          NlAttrGetSize(deferredAction->actions));
         } else {
             status = OvsDoRecirc(switchContext,
@@ -327,7 +341,7 @@ OvsProcessDeferredActions(POVS_SWITCH_CONTEXT switchContext,
                                  deferredAction->nbl,
                                  &deferredAction->key,
                                  portNo,
-                                 layers);
+                                 layersDeferred);
         }
     }
 
diff --git a/datapath-windows/ovsext/Recirc.h b/datapath-windows/ovsext/Recirc.h
index 2b314ce274..74130a4600 100644
--- a/datapath-windows/ovsext/Recirc.h
+++ b/datapath-windows/ovsext/Recirc.h
@@ -18,6 +18,7 @@
 #define __RECIRC_H_ 1
 
 #include "Actions.h"
+#include "NetProto.h"
 
 #define DEFERRED_ACTION_QUEUE_SIZE          10
 #define DEFERRED_ACTION_EXEC_LEVEL           4
@@ -26,6 +27,7 @@ typedef struct _OVS_DEFERRED_ACTION {
     PNET_BUFFER_LIST    nbl;
     PNL_ATTR            actions;
     OvsFlowKey          key;
+    OVS_PACKET_HDR_INFO layers;
 } OVS_DEFERRED_ACTION, *POVS_DEFERRED_ACTION;
 
 /*
@@ -52,6 +54,7 @@ OvsProcessDeferredActions(POVS_SWITCH_CONTEXT switchContext,
 POVS_DEFERRED_ACTION
 OvsAddDeferredActions(PNET_BUFFER_LIST packet,
                       OvsFlowKey *key,
+                      POVS_PACKET_HDR_INFO layers,
                       const PNL_ATTR actions);
 
 /*
Louis Abel's avatar
Louis Abel committed
diff --git a/datapath-windows/ovsext/ovsext.vcxproj b/datapath-windows/ovsext/ovsext.vcxproj
index d50a126b43..18f884f41b 100644
--- a/datapath-windows/ovsext/ovsext.vcxproj
+++ b/datapath-windows/ovsext/ovsext.vcxproj
@@ -192,22 +192,39 @@
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win10 Release|x64'">
     <Inf2CatUseLocalTime>true</Inf2CatUseLocalTime>
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win10 Debug|x64'">
     <Inf2CatUseLocalTime>true</Inf2CatUseLocalTime>
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win10Analyze|x64'">
     <Inf2CatUseLocalTime>true</Inf2CatUseLocalTime>
     <CodeAnalysisRuleSet>..\misc\DriverRecommendedRules.ruleset</CodeAnalysisRuleSet>
     <RunCodeAnalysis>true</RunCodeAnalysis>
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8.1Analyze|x64'">
     <RunCodeAnalysis>true</RunCodeAnalysis>
     <CodeAnalysisRuleSet>..\misc\DriverRecommendedRules.ruleset</CodeAnalysisRuleSet>
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8Analyze|x64'">
     <RunCodeAnalysis>true</RunCodeAnalysis>
     <CodeAnalysisRuleSet>..\misc\DriverRecommendedRules.ruleset</CodeAnalysisRuleSet>
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
+  </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8 Debug|x64'">
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
+  </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8 Release|x64'">
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
+  </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8.1 Debug|x64'">
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
+  </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Win8.1 Release|x64'">
+    <ExternalIncludePath>$(CRT_IncludePath);$(KM_IncludePath);</ExternalIncludePath>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Win8 Release|x64'">
     <ClCompile>
Louis Abel's avatar
Louis Abel committed
diff --git a/datapath/conntrack.c b/datapath/conntrack.c
index 838cf63c90..67e0628703 100644
--- a/datapath/conntrack.c
+++ b/datapath/conntrack.c
@@ -1972,7 +1972,8 @@ static void ovs_ct_limit_exit(struct net *net, struct ovs_net *ovs_net)
 		struct hlist_head *head = &info->limits[i];
 		struct ovs_ct_limit *ct_limit;
 
-		hlist_for_each_entry_rcu(ct_limit, head, hlist_node)
+		hlist_for_each_entry_rcu(ct_limit, head, hlist_node,
+					 lockdep_ovsl_is_held())
 			kfree_rcu(ct_limit, rcu);
 	}
 	kfree(ovs_net->ct_limit_info->limits);
diff --git a/datapath/datapath.c b/datapath/datapath.c
index 853bfb5af1..3dbdb5b59c 100644
--- a/datapath/datapath.c
+++ b/datapath/datapath.c
@@ -2437,8 +2437,10 @@ static void __net_exit ovs_exit_net(struct net *dnet)
 
 	ovs_netns_frags6_exit(dnet);
 	ovs_netns_frags_exit(dnet);
-	ovs_ct_exit(dnet);
 	ovs_lock();
+
+	ovs_ct_exit(dnet);
+
 	list_for_each_entry_safe(dp, dp_next, &ovs_net->dps, list_node)
 		__dp_destroy(dp);
 
diff --git a/datapath/linux/compat/geneve.c b/datapath/linux/compat/geneve.c
index c044b14896..bf995aa83a 100644
--- a/datapath/linux/compat/geneve.c
+++ b/datapath/linux/compat/geneve.c
@@ -962,14 +962,26 @@ static struct dst_entry *geneve_get_v6_dst(struct sk_buff *skb,
 			return dst;
 	}
 
-#ifdef HAVE_IPV6_DST_LOOKUP_NET
-	if (ipv6_stub->ipv6_dst_lookup(geneve->net, gs6->sock->sk, &dst, fl6)) {
+#if defined(HAVE_IPV6_STUB_WITH_DST_ENTRY) && defined(HAVE_IPV6_DST_LOOKUP_FLOW)
+#ifdef HAVE_IPV6_DST_LOOKUP_FLOW_NET
+	dst = ipv6_stub->ipv6_dst_lookup_flow(geneve->net, gs6->sock->sk, fl6,
+					      NULL);
 #else
-#ifdef HAVE_IPV6_STUB
+	dst = ipv6_stub->ipv6_dst_lookup_flow(gs6->sock->sk, fl6,
+					      NULL);
+#endif
+	if (IS_ERR(dst)) {
+#elif defined(HAVE_IPV6_DST_LOOKUP_FLOW_NET)
+	if (ipv6_stub->ipv6_dst_lookup_flow(geneve->net, gs6->sock->sk, &dst,
+                                            fl6)) {
+#elif defined(HAVE_IPV6_DST_LOOKUP_FLOW)
+	if (ipv6_stub->ipv6_dst_lookup_flow(gs6->sock->sk, &dst, fl6)) {
+#elif defined(HAVE_IPV6_DST_LOOKUP_NET)
+	if (ipv6_stub->ipv6_dst_lookup(geneve->net, gs6->sock->sk, &dst, fl6)) {
+#elif defined(HAVE_IPV6_STUB)
 	if (ipv6_stub->ipv6_dst_lookup(gs6->sock->sk, &dst, fl6)) {
 #else
 	if (ip6_dst_lookup(gs6->sock->sk, &dst, fl6)) {
-#endif
 #endif
 		netdev_dbg(dev, "no route to %pI6\n", &fl6->daddr);
 		return ERR_PTR(-ENETUNREACH);
diff --git a/datapath/linux/compat/include/linux/percpu.h b/datapath/linux/compat/include/linux/percpu.h
index 7c346aa31a..a039142e22 100644
--- a/datapath/linux/compat/include/linux/percpu.h
+++ b/datapath/linux/compat/include/linux/percpu.h
@@ -7,12 +7,6 @@
 #define this_cpu_ptr(ptr) per_cpu_ptr(ptr, smp_processor_id())
 #endif
 
-#ifdef HAVE_RHEL6_PER_CPU
-#undef this_cpu_read
-#undef this_cpu_inc
-#undef this_cpu_dec
-#endif
-
 #if !defined this_cpu_read
 #define this_cpu_read(ptr) percpu_read(ptr)
 #endif
diff --git a/datapath/linux/compat/include/linux/rculist.h b/datapath/linux/compat/include/linux/rculist.h
index 8df8ad8a27..40fd5e1710 100644
--- a/datapath/linux/compat/include/linux/rculist.h
+++ b/datapath/linux/compat/include/linux/rculist.h
@@ -9,9 +9,28 @@
 #define hlist_pprev_rcu(node)   (*((struct hlist_node __rcu **)((node)->pprev)))
 #endif
 
+/*
+ * Check during list traversal that we are within an RCU reader
+ */
+
+#define check_arg_count_one(dummy)
+
+#ifdef CONFIG_PROVE_RCU_LIST
+#define __list_check_rcu(dummy, cond, extra...)				\
+	({								\
+	check_arg_count_one(extra);					\
+	RCU_LOCKDEP_WARN(!cond && !rcu_read_lock_any_held(),		\
+			 "RCU-list traversed in non-reader section!");	\
+	 })
+#else
+#define __list_check_rcu(dummy, cond, extra...)				\
+	({ check_arg_count_one(extra); })
+#endif
+
 #undef hlist_for_each_entry_rcu
-#define hlist_for_each_entry_rcu(pos, head, member)			\
-	for (pos = hlist_entry_safe (rcu_dereference_raw(hlist_first_rcu(head)),\
+#define hlist_for_each_entry_rcu(pos, head, member, cond...)		\
+	for (__list_check_rcu(dummy, ## cond, 0),			\
+	     pos = hlist_entry_safe(rcu_dereference_raw(hlist_first_rcu(head)),\
 			typeof(*(pos)), member);			\
 		pos;							\
 		pos = hlist_entry_safe(rcu_dereference_raw(hlist_next_rcu(\
diff --git a/datapath/linux/compat/include/linux/skbuff.h b/datapath/linux/compat/include/linux/skbuff.h
index 63972891bf..f276898b20 100644
--- a/datapath/linux/compat/include/linux/skbuff.h
+++ b/datapath/linux/compat/include/linux/skbuff.h
@@ -278,7 +278,7 @@ static inline void skb_clear_hash(struct sk_buff *skb)
 #ifdef HAVE_RXHASH
 	skb->rxhash = 0;
 #endif
-#if defined(HAVE_L4_RXHASH) && !defined(HAVE_RHEL_OVS_HOOK)
+#if defined(HAVE_L4_RXHASH)
 	skb->l4_rxhash = 0;
 #endif
 }
diff --git a/datapath/linux/compat/nf_conntrack_reasm.c b/datapath/linux/compat/nf_conntrack_reasm.c
index ced9fba98b..77b4b25485 100644
--- a/datapath/linux/compat/nf_conntrack_reasm.c
+++ b/datapath/linux/compat/nf_conntrack_reasm.c
@@ -57,10 +57,13 @@
 #include <net/netns/generic.h>
 #include "datapath.h"
 
-#ifdef OVS_NF_DEFRAG6_BACKPORT
+#if defined(HAVE_INET_FRAGS_WITH_FRAGS_WORK) || !defined(HAVE_INET_FRAGS_RND)
 
 static const char nf_frags_cache_name[] = "ovs-frag6";
 
+#endif
+
+#ifdef OVS_NF_DEFRAG6_BACKPORT
 struct nf_ct_frag6_skb_cb
 {
 	struct inet6_skb_parm	h;
diff --git a/datapath/linux/compat/vxlan.c b/datapath/linux/compat/vxlan.c
index 23118e8b63..05ccfb9288 100644
--- a/datapath/linux/compat/vxlan.c
+++ b/datapath/linux/compat/vxlan.c
@@ -967,7 +967,10 @@ static struct dst_entry *vxlan6_get_route(struct vxlan_dev *vxlan,
 	bool use_cache = (dst_cache && ip_tunnel_dst_cache_usable(skb, info));
 	struct dst_entry *ndst;
 	struct flowi6 fl6;
+#if !defined(HAVE_IPV6_STUB_WITH_DST_ENTRY) || \
+    !defined(HAVE_IPV6_DST_LOOKUP_FLOW)
 	int err;
+#endif
 
 	if (!sock6)
 		return ERR_PTR(-EIO);
@@ -990,20 +993,35 @@ static struct dst_entry *vxlan6_get_route(struct vxlan_dev *vxlan,
 	fl6.fl6_dport = dport;
 	fl6.fl6_sport = sport;
 
-#ifdef HAVE_IPV6_DST_LOOKUP_NET
-	err = ipv6_stub->ipv6_dst_lookup(vxlan->net,
-					 sock6->sock->sk,
-					 &ndst, &fl6);
+#if defined(HAVE_IPV6_STUB_WITH_DST_ENTRY) && defined(HAVE_IPV6_DST_LOOKUP_FLOW)
+#ifdef HAVE_IPV6_DST_LOOKUP_FLOW_NET
+	ndst = ipv6_stub->ipv6_dst_lookup_flow(vxlan->net, sock6->sock->sk,
+					       &fl6, NULL);
 #else
-#ifdef HAVE_IPV6_STUB
+	ndst = ipv6_stub->ipv6_dst_lookup_flow(sock6->sock->sk, &fl6, NULL);
+#endif
+	if (unlikely(IS_ERR(ndst))) {
+#elif defined(HAVE_IPV6_DST_LOOKUP_FLOW_NET)
+	err = ipv6_stub->ipv6_dst_lookup_flow(vxlan->net, sock6->sock->sk,
+					      &ndst, &fl6);
+#elif defined(HAVE_IPV6_DST_LOOKUP_FLOW)
+	err = ipv6_stub->ipv6_dst_lookup_flow(sock6->sock->sk, &ndst, &fl6);
+#elif defined(HAVE_IPV6_DST_LOOKUP_NET)
+	err = ipv6_stub->ipv6_dst_lookup(vxlan->net, sock6->sock->sk,
+					 &ndst, &fl6);
+#elif defined(HAVE_IPV6_STUB)
 	err = ipv6_stub->ipv6_dst_lookup(vxlan->vn6_sock->sock->sk,
 					 &ndst, &fl6);
 #else
 	err = ip6_dst_lookup(vxlan->vn6_sock->sock->sk, &ndst, &fl6);
 #endif
-#endif
+#if defined(HAVE_IPV6_STUB_WITH_DST_ENTRY) && defined(HAVE_IPV6_DST_LOOKUP_FLOW)
+		return ERR_PTR(-ENETUNREACH);
+	}
+#else
 	if (err < 0)
 		return ERR_PTR(err);
+#endif
 
 	*saddr = fl6.saddr;
 	if (use_cache)
diff --git a/debian/changelog b/debian/changelog
Louis Abel's avatar
Louis Abel committed
index 8e075bc98b..05025442a6 100644
Louis Abel's avatar
Louis Abel committed
--- a/debian/changelog
+++ b/debian/changelog
Louis Abel's avatar
Louis Abel committed
@@ -1,3 +1,33 @@
+openvswitch (2.13.5-1) unstable; urgency=low
+   [ Open vSwitch team ]
+   * New upstream version
+
+ -- Open vSwitch team <dev@openvswitch.org>  Thu, 01 Jul 2021 20:17:41 +0200
+
Louis Abel's avatar
Louis Abel committed
+openvswitch (2.13.4-1) unstable; urgency=low
+   [ Open vSwitch team ]
+   * New upstream version
+
Louis Abel's avatar
Louis Abel committed
+ -- Open vSwitch team <dev@openvswitch.org>  Thu, 01 Jul 2021 20:17:41 +0200
Louis Abel's avatar
Louis Abel committed
+
+openvswitch (2.13.3-1) unstable; urgency=low
+   [ Open vSwitch team ]
+   * New upstream version
+
+ -- Open vSwitch team <dev@openvswitch.org>  Wed, 10 Feb 2021 16:07:28 +0100
+
+openvswitch (2.13.2-1) unstable; urgency=low
+   [ Open vSwitch team ]
+   * New upstream version
+
+ -- Open vSwitch team <dev@openvswitch.org>  Wed, 13 Jan 2021 11:26:36 -0500
+
+openvswitch (2.13.1-1) unstable; urgency=low
+   [ Open vSwitch team]
+   * New upstream version
+
+ -- Open vSwitch team <dev@openvswitch.org>  Thu, 30 Jul 2020 00:25:23 +0200
+
 openvswitch (2.13.0-1) unstable; urgency=low
    [ Open vSwitch team]
    * New upstream version
diff --git a/debian/control b/debian/control
index a50e97249f..6420b9d3e2 100644
--- a/debian/control
+++ b/debian/control
@@ -14,8 +14,9 @@ Build-Depends: graphviz,
                openssl,
                procps,
                python3-all,
-               python3-twisted-conch,
-               python3-zopeinterface,
+               python3-sphinx,
+               python3-twisted,
+               python3-zope.interface,
                libunbound-dev,
                libunwind-dev
 Standards-Version: 3.9.3
@@ -187,7 +188,7 @@ Description: Python bindings for Open vSwitch
 Package: openvswitch-test
 Architecture: all
 Depends: python3,
-         python3-twisted-web,
+         python3-twisted,
          ${misc:Depends},
          ${python3:Depends}
 Description: Open vSwitch test package
diff --git a/debian/openvswitch-common.manpages b/debian/openvswitch-common.manpages
index 9ac6a1dd6d..95004122cc 100644
--- a/debian/openvswitch-common.manpages
+++ b/debian/openvswitch-common.manpages
@@ -1,7 +1,7 @@
 ovsdb/ovsdb-client.1
 ovsdb/ovsdb-tool.1
 utilities/bugtool/ovs-bugtool.8
-utilities/ovs-appctl.8
+debian/tmp/usr/share/man/man8/ovs-appctl.8
 utilities/ovs-ofctl.8
-utilities/ovs-parse-backtrace.8
-utilities/ovs-pki.8
+debian/tmp/usr/share/man/man8/ovs-parse-backtrace.8
+debian/tmp/usr/share/man/man8/ovs-pki.8
diff --git a/debian/openvswitch-switch.manpages b/debian/openvswitch-switch.manpages
index 1161cfda77..7fd7bc55da 100644
--- a/debian/openvswitch-switch.manpages
+++ b/debian/openvswitch-switch.manpages
@@ -1,12 +1,12 @@
 ovsdb/ovsdb-server.1
 ovsdb/ovsdb-server.5
-utilities/ovs-ctl.8
+debian/tmp/usr/share/man/man8/ovs-ctl.8
 utilities/ovs-dpctl-top.8
 utilities/ovs-dpctl.8
 utilities/ovs-kmod-ctl.8
 utilities/ovs-pcap.1
-utilities/ovs-tcpdump.8
-utilities/ovs-tcpundump.1
+debian/tmp/usr/share/man/man8/ovs-tcpdump.8
+debian/tmp/usr/share/man/man1/ovs-tcpundump.1
 utilities/ovs-vsctl.8
 vswitchd/ovs-vswitchd.8
 vswitchd/ovs-vswitchd.conf.db.5
diff --git a/debian/openvswitch-test.manpages b/debian/openvswitch-test.manpages
index 3f71858691..eb3a561d01 100644
--- a/debian/openvswitch-test.manpages
+++ b/debian/openvswitch-test.manpages
@@ -1 +1 @@
-utilities/ovs-l3ping.8
+debian/tmp/usr/share/man/man8/ovs-l3ping.8
diff --git a/dpdk/.ci/linux-setup.sh b/dpdk/.ci/linux-setup.sh
index dfb9d4a206..38bb88e15c 100755
--- a/dpdk/.ci/linux-setup.sh
+++ b/dpdk/.ci/linux-setup.sh
@@ -1,7 +1,7 @@
 #!/bin/sh -xe
 
 # need to install as 'root' since some of the unit tests won't run without it
-sudo python3 -m pip install --upgrade meson
+sudo python3 -m pip install --upgrade 'meson==0.47.1'
 
 # setup hugepages
 cat /proc/meminfo
diff --git a/dpdk/.travis.yml b/dpdk/.travis.yml
index 8f90d06f28..77ac26dd85 100644
--- a/dpdk/.travis.yml
+++ b/dpdk/.travis.yml
@@ -15,19 +15,19 @@ addons:
     packages: &required_packages
       - [libnuma-dev, linux-headers-$(uname -r), python3-setuptools, python3-wheel, python3-pip, ninja-build]
 
-aarch64_packages: &aarch64_packages
+_aarch64_packages: &aarch64_packages
   - *required_packages
   - [gcc-aarch64-linux-gnu, libc6-dev-arm64-cross, pkg-config-aarch64-linux-gnu]
 
-extra_packages: &extra_packages
+_extra_packages: &extra_packages
   - *required_packages
-  - [libbsd-dev, libpcap-dev, libcrypto++-dev, libjansson4]
+  - [libbsd-dev, libpcap-dev, libcrypto++-dev, libjansson-dev]
 
-build_32b_packages: &build_32b_packages
+_build_32b_packages: &build_32b_packages
   - *required_packages
   - [gcc-multilib]
 
-doc_packages: &doc_packages
+_doc_packages: &doc_packages
   - [doxygen, graphviz, python3-sphinx]
 
 before_install: ./.ci/${TRAVIS_OS_NAME}-setup.sh
@@ -39,7 +39,7 @@ env:
   - DEF_LIB="shared" OPTS="-Denable_kmods=false"
   - DEF_LIB="shared" RUN_TESTS=1
 
-matrix:
+jobs:
   include:
   - env: DEF_LIB="static" BUILD_32BIT=1
     compiler: gcc
diff --git a/dpdk/MAINTAINERS b/dpdk/MAINTAINERS
index 4395d8df14..952ded7b00 100644
--- a/dpdk/MAINTAINERS
+++ b/dpdk/MAINTAINERS
@@ -46,7 +46,7 @@ M: Jerin Jacob <jerinj@marvell.com>
 T: git://dpdk.org/next/dpdk-next-net-mrvl
 
 Next-net-mlx Tree
-M: Raslan Darawsheh <rasland@mellanox.com>
+M: Raslan Darawsheh <rasland@nvidia.com>
 T: git://dpdk.org/next/dpdk-next-net-mlx
 
 Next-virtio Tree
@@ -128,8 +128,11 @@ F: meson.build
 F: lib/librte_eal/freebsd/BSDmakefile.meson
 F: meson_options.txt
 F: config/rte_config.h
+F: buildtools/call-sphinx-build.py
 F: buildtools/gen-pmdinfo-cfile.sh
 F: buildtools/map_to_def.py
+F: buildtools/list-dir-globs.py
+F: buildtools/pkg-config/
 F: buildtools/symlink-drivers-solibs.sh
 
 Public CI
@@ -370,7 +373,7 @@ F: devtools/test-null.sh
 F: doc/guides/prog_guide/switch_representation.rst
 
 Flow API
-M: Adrien Mazarguil <adrien.mazarguil@6wind.com>
+M: Ori Kam <orika@nvidia.com>
 T: git://dpdk.org/next/dpdk-next-net
 F: app/test-pmd/cmdline_flow.c
 F: doc/guides/prog_guide/rte_flow.rst
@@ -456,8 +459,8 @@ F: lib/librte_eventdev/*crypto_adapter*
 F: app/test/test_event_crypto_adapter.c
 F: doc/guides/prog_guide/event_crypto_adapter.rst
 
-Raw device API - EXPERIMENTAL
-M: Shreyansh Jain <shreyansh.jain@nxp.com>
+Raw device API
+M: Nipun Gupta <nipun.gupta@nxp.com>
 M: Hemant Agrawal <hemant.agrawal@nxp.com>
 F: lib/librte_rawdev/
 F: drivers/raw/skeleton/
@@ -728,17 +731,17 @@ F: doc/guides/nics/features/octeontx2*.ini
 F: doc/guides/nics/octeontx2.rst
 
 Mellanox mlx4
-M: Matan Azrad <matan@mellanox.com>
-M: Shahaf Shuler <shahafs@mellanox.com>
+M: Matan Azrad <matan@nvidia.com>
+M: Shahaf Shuler <shahafs@nvidia.com>
 T: git://dpdk.org/next/dpdk-next-net-mlx
 F: drivers/net/mlx4/
 F: doc/guides/nics/mlx4.rst
 F: doc/guides/nics/features/mlx4.ini
 
 Mellanox mlx5
-M: Matan Azrad <matan@mellanox.com>
-M: Shahaf Shuler <shahafs@mellanox.com>
-M: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
+M: Matan Azrad <matan@nvidia.com>
+M: Shahaf Shuler <shahafs@nvidia.com>
+M: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
 T: git://dpdk.org/next/dpdk-next-net-mlx
 F: drivers/net/mlx5/
 F: buildtools/options-ibverbs-static.sh
@@ -746,7 +749,7 @@ F: doc/guides/nics/mlx5.rst
 F: doc/guides/nics/features/mlx5.ini
 
 Microsoft vdev_netvsc - EXPERIMENTAL
-M: Matan Azrad <matan@mellanox.com>
+M: Matan Azrad <matan@nvidia.com>
 F: drivers/net/vdev_netvsc/
 F: doc/guides/nics/vdev_netvsc.rst
 F: doc/guides/nics/features/vdev_netvsc.ini
@@ -910,7 +913,7 @@ F: drivers/net/null/
 F: doc/guides/nics/features/null.ini
 
 Fail-safe PMD
-M: Gaetan Rivet <gaetan.rivet@6wind.com>
+M: Gaetan Rivet <grive@u256.net>
 F: drivers/net/failsafe/
 F: doc/guides/nics/fail_safe.rst
 F: doc/guides/nics/features/failsafe.ini
@@ -1373,7 +1376,7 @@ F: app/test/test_rcu*
 F: doc/guides/prog_guide/rcu_lib.rst
 
 PCI
-M: Gaetan Rivet <gaetan.rivet@6wind.com>
+M: Gaetan Rivet <grive@u256.net>
 F: lib/librte_pci/
 
 Power management
@@ -1434,6 +1437,7 @@ Unit tests framework
 F: app/test/Makefile
 F: app/test/autotest*
 F: app/test/commands.c
+F: app/test/get-coremask.sh
 F: app/test/packet_burst_generator.c
 F: app/test/packet_burst_generator.h
 F: app/test/process.h
@@ -1490,7 +1494,7 @@ M: Marko Kovacevic <marko.kovacevic@intel.com>
 F: examples/fips_validation/
 F: doc/guides/sample_app_ug/fips_validation.rst
 
-M: Ori Kam <orika@mellanox.com>
+M: Ori Kam <orika@nvidia.com>
 F: examples/flow_filtering/
 F: doc/guides/sample_app_ug/flow_filtering.rst
 
Louis Abel's avatar
Louis Abel committed
2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200
diff --git a/dpdk/VERSION b/dpdk/VERSION
index 22131b00aa..8bda73742f 100644
--- a/dpdk/VERSION
+++ b/dpdk/VERSION
@@ -1 +1 @@
-19.11.0
+19.11.7
diff --git a/dpdk/app/meson.build b/dpdk/app/meson.build
index 71109cc422..c7f689eb79 100644
--- a/dpdk/app/meson.build
+++ b/dpdk/app/meson.build
@@ -22,6 +22,10 @@ apps = [
 lib_execinfo = cc.find_library('execinfo', required: false)
 
 default_cflags = machine_args
+default_ldflags = []
+if get_option('default_library') == 'static' and not is_windows
+	default_ldflags += ['-Wl,--export-dynamic']
+endif
 
 foreach app:apps
 	build = true
@@ -30,6 +34,7 @@ foreach app:apps
 	sources = []
 	includes = []
 	cflags = default_cflags
+	ldflags = default_ldflags
 	objs = [] # other object files to link against, used e.g. for
 	          # instruction-set optimized versions of code
 
@@ -60,8 +65,10 @@ foreach app:apps
 		executable('dpdk-' + name,
 				sources,
 				c_args: cflags,
+				link_args: ldflags,
 				link_whole: link_libs,
 				dependencies: dep_objs,
+				include_directories: includes,
 				install_rpath: join_paths(get_option('prefix'),
 						 driver_install_path),
 				install: true)
diff --git a/dpdk/app/pdump/main.c b/dpdk/app/pdump/main.c
index 903d02f482..c38c53719e 100644
--- a/dpdk/app/pdump/main.c
+++ b/dpdk/app/pdump/main.c
@@ -151,7 +151,7 @@ static uint8_t multiple_core_capture;
 static void
 pdump_usage(const char *prgname)
 {
-	printf("usage: %s [EAL options]"
+	printf("usage: %s [EAL options] --"
 			" --["CMD_LINE_OPT_MULTI"]\n"
 			" --"CMD_LINE_OPT_PDUMP" "
 			"'(port=<port id> | device_id=<pci id or vdev name>),"
@@ -595,7 +595,7 @@ configure_vdev(uint16_t port_id)
 	if (ret != 0)
 		rte_exit(EXIT_FAILURE, "dev config failed\n");
 
-	 for (q = 0; q < txRings; q++) {
+	for (q = 0; q < txRings; q++) {
 		ret = rte_eth_tx_queue_setup(port_id, q, TX_DESC_PER_QUEUE,
 				rte_eth_dev_socket_id(port_id), NULL);
 		if (ret < 0)
diff --git a/dpdk/app/proc-info/main.c b/dpdk/app/proc-info/main.c
index abeca4aab4..f6d19cdac2 100644
--- a/dpdk/app/proc-info/main.c
+++ b/dpdk/app/proc-info/main.c
@@ -310,14 +310,13 @@ proc_info_parse_args(int argc, char **argv)
 			} else if (!strncmp(long_option[option_index].name,
 					"xstats-ids",
 					MAX_LONG_OPT_SZ))	{
-				nb_xstats_ids = parse_xstats_ids(optarg,
+				int ret = parse_xstats_ids(optarg,
 						xstats_ids, MAX_NB_XSTATS_IDS);
-
-				if (nb_xstats_ids <= 0) {
+				if (ret <= 0) {
 					printf("xstats-id list parse error.\n");
 					return -1;
 				}
-
+				nb_xstats_ids = ret;
 			}
 			break;
 		default:
@@ -429,11 +428,9 @@ static void collectd_resolve_cnt_type(char *cnt_type, size_t cnt_type_len,
 	} else if ((type_end != NULL) &&
 		   (strncmp(cnt_name, "flow_", strlen("flow_"))) == 0) {
 		if (strncmp(type_end, "_filters", strlen("_filters")) == 0)
-			strlcpy(cnt_type, "operations", cnt_type_len);
+			strlcpy(cnt_type, "filter_result", cnt_type_len);
 		else if (strncmp(type_end, "_errors", strlen("_errors")) == 0)
 			strlcpy(cnt_type, "errors", cnt_type_len);
-		else if (strncmp(type_end, "_filters", strlen("_filters")) == 0)
-			strlcpy(cnt_type, "filter_result", cnt_type_len);
 	} else if ((type_end != NULL) &&
 		   (strncmp(cnt_name, "mac_", strlen("mac_"))) == 0) {
 		if (strncmp(type_end, "_errors", strlen("_errors")) == 0)
@@ -1110,7 +1107,6 @@ show_crypto(void)
 
 		display_crypto_feature_info(dev_info.feature_flags);
 
-		memset(&stats, 0, sizeof(0));
 		if (rte_cryptodev_stats_get(i, &stats) == 0) {
 			printf("\t  -- stats\n");
 			printf("\t\t  + enqueue count (%"PRIu64")"
diff --git a/dpdk/app/test-acl/main.c b/dpdk/app/test-acl/main.c
index 57f23942eb..08f06c1fa3 100644
--- a/dpdk/app/test-acl/main.c
+++ b/dpdk/app/test-acl/main.c
@@ -12,7 +12,7 @@
 #include <rte_lcore.h>
 #include <rte_ip.h>
 
-#define	PRINT_USAGE_START	"%s [EAL options]\n"
+#define	PRINT_USAGE_START	"%s [EAL options] --\n"
 
 #define	RTE_LOGTYPE_TESTACL	RTE_LOGTYPE_USER1
 
diff --git a/dpdk/app/test-bbdev/ldpc_enc_default.data b/dpdk/app/test-bbdev/ldpc_enc_default.data
index 371cbc692d..52d51ae330 120000
--- a/dpdk/app/test-bbdev/ldpc_enc_default.data
+++ b/dpdk/app/test-bbdev/ldpc_enc_default.data
@@ -1 +1 @@
-test_vectors/turbo_dec_c1_k6144_r0_e10376_crc24b_sbd_negllr_high_snr.data
\ No newline at end of file
+test_vectors/ldpc_enc_v2342.data
\ No newline at end of file
diff --git a/dpdk/app/test-crypto-perf/cperf_options_parsing.c b/dpdk/app/test-crypto-perf/cperf_options_parsing.c
index f43c5bede7..49b469781c 100644
--- a/dpdk/app/test-crypto-perf/cperf_options_parsing.c
+++ b/dpdk/app/test-crypto-perf/cperf_options_parsing.c
@@ -23,7 +23,7 @@ usage(char *progname)
 {
 	printf("%s [EAL options] --\n"
 		" --silent: disable options dump\n"
-		" --ptest throughput / latency / verify / pmd-cycleount :"
+		" --ptest throughput / latency / verify / pmd-cyclecount :"
 		" set test type\n"
 		" --pool_sz N: set the number of crypto ops/mbufs allocated\n"
 		" --total-ops N: set the number of total operations performed\n"
diff --git a/dpdk/app/test-crypto-perf/cperf_test_latency.c b/dpdk/app/test-crypto-perf/cperf_test_latency.c
index 62478a2df5..951b4d10ac 100644
--- a/dpdk/app/test-crypto-perf/cperf_test_latency.c
+++ b/dpdk/app/test-crypto-perf/cperf_test_latency.c
@@ -313,11 +313,11 @@ cperf_latency_test_runner(void *arg)
 		if (ctx->options->csv) {
 			if (rte_atomic16_test_and_set(&display_once))
 				printf("\n# lcore, Buffer Size, Burst Size, Pakt Seq #, "
-						"Packet Size, cycles, time (us)");
+						"cycles, time (us)");
 
 			for (i = 0; i < ctx->options->total_ops; i++) {
 
-				printf("\n%u;%u;%u;%"PRIu64";%"PRIu64";%.3f",
+				printf("\n%u,%u,%u,%"PRIu64",%"PRIu64",%.3f",
 					ctx->lcore_id, ctx->options->test_buffer_size,
 					test_burst_size, i + 1,
 					ctx->res[i].tsc_end - ctx->res[i].tsc_start,
diff --git a/dpdk/app/test-crypto-perf/cperf_test_pmd_cyclecount.c b/dpdk/app/test-crypto-perf/cperf_test_pmd_cyclecount.c
index 74371faa8d..de01e3bc51 100644
--- a/dpdk/app/test-crypto-perf/cperf_test_pmd_cyclecount.c
+++ b/dpdk/app/test-crypto-perf/cperf_test_pmd_cyclecount.c
@@ -16,7 +16,7 @@
 #define PRETTY_HDR_FMT "%12s%12s%12s%12s%12s%12s%12s%12s%12s%12s\n\n"
 #define PRETTY_LINE_FMT "%12u%12u%12u%12u%12u%12u%12u%12.0f%12.0f%12.0f\n"
 #define CSV_HDR_FMT "%s,%s,%s,%s,%s,%s,%s,%s,%s,%s\n"
-#define CSV_LINE_FMT "%10u;%10u;%u;%u;%u;%u;%u;%.3f;%.3f;%.3f\n"
+#define CSV_LINE_FMT "%10u,%10u,%u,%u,%u,%u,%u,%.3f,%.3f,%.3f\n"
 
 struct cperf_pmd_cyclecount_ctx {
 	uint8_t dev_id;
diff --git a/dpdk/app/test-crypto-perf/cperf_test_throughput.c b/dpdk/app/test-crypto-perf/cperf_test_throughput.c
index 35c51026fe..2528f39571 100644
--- a/dpdk/app/test-crypto-perf/cperf_test_throughput.c
+++ b/dpdk/app/test-crypto-perf/cperf_test_throughput.c
@@ -298,8 +298,8 @@ cperf_throughput_test_runner(void *test_ctx)
 					"Failed Deq,Ops(Millions),Throughput(Gbps),"
 					"Cycles/Buf\n\n");
 
-			printf("%u;%u;%u;%"PRIu64";%"PRIu64";%"PRIu64";%"PRIu64";"
-					"%.3f;%.3f;%.3f\n",
+			printf("%u,%u,%u,%"PRIu64",%"PRIu64",%"PRIu64",%"PRIu64","
+					"%.3f,%.3f,%.3f\n",
 					ctx->lcore_id,
 					ctx->options->test_buffer_size,
 					test_burst_size,
diff --git a/dpdk/app/test-crypto-perf/cperf_test_verify.c b/dpdk/app/test-crypto-perf/cperf_test_verify.c
index 833bc9a552..2939aeaa93 100644
--- a/dpdk/app/test-crypto-perf/cperf_test_verify.c
+++ b/dpdk/app/test-crypto-perf/cperf_test_verify.c
@@ -406,7 +406,7 @@ cperf_verify_test_runner(void *test_ctx)
 				"Burst Size,Enqueued,Dequeued,Failed Enq,"
 				"Failed Deq,Failed Ops\n");
 
-		printf("%10u;%10u;%u;%"PRIu64";%"PRIu64";%"PRIu64";%"PRIu64";"
+		printf("%10u,%10u,%u,%"PRIu64",%"PRIu64",%"PRIu64",%"PRIu64","
 				"%"PRIu64"\n",
 				ctx->lcore_id,
 				ctx->options->max_buffer_size,
diff --git a/dpdk/app/test-crypto-perf/main.c b/dpdk/app/test-crypto-perf/main.c
index 52a1860fbf..048b10c652 100644
--- a/dpdk/app/test-crypto-perf/main.c
+++ b/dpdk/app/test-crypto-perf/main.c
@@ -380,7 +380,7 @@ cperf_check_test_vector(struct cperf_options *opts,
 		if (opts->cipher_algo == RTE_CRYPTO_CIPHER_NULL) {
 			if (test_vec->plaintext.data == NULL)
 				return -1;
-		} else if (opts->cipher_algo != RTE_CRYPTO_CIPHER_NULL) {
+		} else {
 			if (test_vec->plaintext.data == NULL)
 				return -1;
 			if (test_vec->plaintext.length < opts->max_buffer_size)
@@ -430,7 +430,7 @@ cperf_check_test_vector(struct cperf_options *opts,
 				return -1;
 			if (test_vec->plaintext.length < opts->max_buffer_size)
 				return -1;
-		} else if (opts->cipher_algo != RTE_CRYPTO_CIPHER_NULL) {
+		} else {
 			if (test_vec->plaintext.data == NULL)
 				return -1;
 			if (test_vec->plaintext.length < opts->max_buffer_size)
@@ -520,14 +520,14 @@ main(int argc, char **argv)
 
 	ret = cperf_options_parse(&opts, argc, argv);
 	if (ret) {
-		RTE_LOG(ERR, USER1, "Parsing on or more user options failed\n");
+		RTE_LOG(ERR, USER1, "Parsing one or more user options failed\n");
 		goto err;
 	}
 
 	ret = cperf_options_check(&opts);
 	if (ret) {
 		RTE_LOG(ERR, USER1,
-				"Checking on or more user options failed\n");
+				"Checking one or more user options failed\n");
 		goto err;
 	}
 
@@ -582,7 +582,8 @@ main(int argc, char **argv)
 		goto err;
 	}
 
-	if (!opts.silent)
+	if (!opts.silent && opts.test != CPERF_TEST_TYPE_THROUGHPUT &&
+			opts.test != CPERF_TEST_TYPE_LATENCY)
 		show_test_vector(t_vec);
 
 	total_nb_qps = nb_cryptodevs * opts.nb_qps;
diff --git a/dpdk/app/test-crypto-perf/meson.build b/dpdk/app/test-crypto-perf/meson.build
index 0674396da8..dcc4bf9cbc 100644
--- a/dpdk/app/test-crypto-perf/meson.build
+++ b/dpdk/app/test-crypto-perf/meson.build
@@ -13,3 +13,6 @@ sources = files('cperf_ops.c',
 		'cperf_test_verify.c',
 		'main.c')
 deps += ['cryptodev', 'security']
+if dpdk_conf.has('RTE_LIBRTE_CRYPTO_SCHEDULER_PMD')
+	deps += 'pmd_crypto_scheduler'
+endif
diff --git a/dpdk/app/test-eventdev/evt_options.c b/dpdk/app/test-eventdev/evt_options.c
index c60b61a904..4f4800d99d 100644
--- a/dpdk/app/test-eventdev/evt_options.c
+++ b/dpdk/app/test-eventdev/evt_options.c
@@ -197,6 +197,10 @@ evt_parse_nb_timer_adptrs(struct evt_options *opt, const char *arg)
 	int ret;
 
 	ret = parser_read_uint8(&(opt->nb_timer_adptrs), arg);
+	if (opt->nb_timer_adptrs <= 0) {
+		evt_err("Number of timer adapters cannot be <= 0");
+		return -EINVAL;
+	}
 
 	return ret;
 }
diff --git a/dpdk/app/test-eventdev/meson.build b/dpdk/app/test-eventdev/meson.build
index 7ff2b786cf..9e588d9ec7 100644
--- a/dpdk/app/test-eventdev/meson.build
+++ b/dpdk/app/test-eventdev/meson.build
@@ -10,5 +10,8 @@ sources = files('evt_main.c',
 		'test_order_queue.c',
 		'test_perf_common.c',
 		'test_perf_atq.c',
-		'test_perf_queue.c')
+		'test_perf_queue.c',
+		'test_pipeline_common.c',
+		'test_pipeline_atq.c',
+		'test_pipeline_queue.c')
 deps += 'eventdev'
diff --git a/dpdk/app/test-eventdev/test_perf_common.h b/dpdk/app/test-eventdev/test_perf_common.h
index d8fbee6d89..e095da9a47 100644
--- a/dpdk/app/test-eventdev/test_perf_common.h
+++ b/dpdk/app/test-eventdev/test_perf_common.h
@@ -97,8 +97,13 @@ perf_process_last_stage(struct rte_mempool *const pool,
 		void *bufs[], int const buf_sz, uint8_t count)
 {
 	bufs[count++] = ev->event_ptr;
-	w->processed_pkts++;
+
+	/* wmb here ensures event_prt is stored before
+	 * updating the number of processed packets
+	 * for worker lcores
+	 */
 	rte_smp_wmb();
+	w->processed_pkts++;
 
 	if (unlikely(count == buf_sz)) {
 		count = 0;
@@ -116,6 +121,12 @@ perf_process_last_stage_latency(struct rte_mempool *const pool,
 	struct perf_elt *const m = ev->event_ptr;
 
 	bufs[count++] = ev->event_ptr;
+
+	/* wmb here ensures event_prt is stored before
+	 * updating the number of processed packets
+	 * for worker lcores
+	 */
+	rte_smp_wmb();
 	w->processed_pkts++;
 
 	if (unlikely(count == buf_sz)) {
@@ -127,7 +138,6 @@ perf_process_last_stage_latency(struct rte_mempool *const pool,
 	}
 
 	w->latency += latency;
-	rte_smp_wmb();
 	return count;
 }
 
diff --git a/dpdk/app/test-eventdev/test_pipeline_atq.c b/dpdk/app/test-eventdev/test_pipeline_atq.c
index 8e8686c145..0872b25b53 100644
--- a/dpdk/app/test-eventdev/test_pipeline_atq.c
+++ b/dpdk/app/test-eventdev/test_pipeline_atq.c
@@ -495,6 +495,8 @@ pipeline_atq_capability_check(struct evt_options *opt)
 			evt_nr_active_lcores(opt->wlcores),
 			dev_info.max_event_ports);
 	}
+	if (!evt_has_all_types_queue(opt->dev_id))
+		return false;
 
 	return true;
 }
diff --git a/dpdk/app/test-eventdev/test_pipeline_common.c b/dpdk/app/test-eventdev/test_pipeline_common.c
index fa91bf2290..126e2165a3 100644
--- a/dpdk/app/test-eventdev/test_pipeline_common.c
+++ b/dpdk/app/test-eventdev/test_pipeline_common.c
@@ -385,12 +385,16 @@ pipeline_event_tx_adapter_setup(struct evt_options *opt,
 		if (!(cap & RTE_EVENT_ETH_TX_ADAPTER_CAP_INTERNAL_PORT)) {
 			uint32_t service_id = -1U;
 
-			rte_event_eth_tx_adapter_service_id_get(consm,
-					&service_id);
+			ret = rte_event_eth_tx_adapter_service_id_get(consm,
+								   &service_id);
+			if (ret != -ESRCH && ret != 0) {
+				evt_err("Failed to get Tx adptr service ID");
+				return ret;
+			}
 			ret = evt_service_setup(service_id);
 			if (ret) {
 				evt_err("Failed to setup service core"
-						" for Tx adapter\n");
+						" for Tx adapter");
 				return ret;
 			}
 		}
diff --git a/dpdk/app/test-eventdev/test_pipeline_queue.c b/dpdk/app/test-eventdev/test_pipeline_queue.c
index 7bebac34fc..9a9febb199 100644
--- a/dpdk/app/test-eventdev/test_pipeline_queue.c
+++ b/dpdk/app/test-eventdev/test_pipeline_queue.c
@@ -83,16 +83,15 @@ pipeline_queue_worker_single_stage_burst_tx(void *arg)
 			rte_prefetch0(ev[i + 1].mbuf);
 			if (ev[i].sched_type == RTE_SCHED_TYPE_ATOMIC) {
 				pipeline_event_tx(dev, port, &ev[i]);
-				ev[i].op = RTE_EVENT_OP_RELEASE;
 				w->processed_pkts++;
 			} else {
 				ev[i].queue_id++;
 				pipeline_fwd_event(&ev[i],
 						RTE_SCHED_TYPE_ATOMIC);
+				pipeline_event_enqueue_burst(dev, port, ev,
+						nb_rx);
 			}
 		}
-
-		pipeline_event_enqueue_burst(dev, port, ev, nb_rx);
 	}
 
 	return 0;
@@ -180,13 +179,13 @@ pipeline_queue_worker_multi_stage_fwd(void *arg)
 			ev.queue_id = tx_queue[ev.mbuf->port];
 			rte_event_eth_tx_adapter_txq_set(ev.mbuf, 0);
 			pipeline_fwd_event(&ev, RTE_SCHED_TYPE_ATOMIC);
+			pipeline_event_enqueue(dev, port, &ev);
 			w->processed_pkts++;
 		} else {
 			ev.queue_id++;
 			pipeline_fwd_event(&ev, sched_type_list[cq_id]);
+			pipeline_event_enqueue(dev, port, &ev);
 		}
-
-		pipeline_event_enqueue(dev, port, &ev);
 	}
 
 	return 0;
@@ -213,7 +212,6 @@ pipeline_queue_worker_multi_stage_burst_tx(void *arg)
 
 			if (ev[i].queue_id == tx_queue[ev[i].mbuf->port]) {
 				pipeline_event_tx(dev, port, &ev[i]);
-				ev[i].op = RTE_EVENT_OP_RELEASE;
 				w->processed_pkts++;
 				continue;
 			}
@@ -222,9 +220,8 @@ pipeline_queue_worker_multi_stage_burst_tx(void *arg)
 			pipeline_fwd_event(&ev[i], cq_id != last_queue ?
 					sched_type_list[cq_id] :
 					RTE_SCHED_TYPE_ATOMIC);
+			pipeline_event_enqueue_burst(dev, port, ev, nb_rx);
 		}
-
-		pipeline_event_enqueue_burst(dev, port, ev, nb_rx);
 	}
 
 	return 0;
@@ -237,6 +234,7 @@ pipeline_queue_worker_multi_stage_burst_fwd(void *arg)
 	const uint8_t *tx_queue = t->tx_evqueue_id;
 
 	while (t->done == false) {
+		uint16_t processed_pkts = 0;
 		uint16_t nb_rx = rte_event_dequeue_burst(dev, port, ev,
 				BURST_SIZE, 0);
 
@@ -254,7 +252,7 @@ pipeline_queue_worker_multi_stage_burst_fwd(void *arg)
 				rte_event_eth_tx_adapter_txq_set(ev[i].mbuf, 0);
 				pipeline_fwd_event(&ev[i],
 						RTE_SCHED_TYPE_ATOMIC);
-				w->processed_pkts++;
+				processed_pkts++;
 			} else {
 				ev[i].queue_id++;
 				pipeline_fwd_event(&ev[i],
@@ -263,6 +261,7 @@ pipeline_queue_worker_multi_stage_burst_fwd(void *arg)
 		}
 
 		pipeline_event_enqueue_burst(dev, port, ev, nb_rx);
+		w->processed_pkts += processed_pkts;
 	}
 
 	return 0;
diff --git a/dpdk/app/test-pipeline/config.c b/dpdk/app/test-pipeline/config.c
index 28ac9fcc0e..33f3f1c827 100644
--- a/dpdk/app/test-pipeline/config.c
+++ b/dpdk/app/test-pipeline/config.c
@@ -42,8 +42,6 @@
 
 #include "main.h"
 
-struct app_params app;
-
 static const char usage[] = "\n";
 
 void
diff --git a/dpdk/app/test-pmd/bpf_cmd.c b/dpdk/app/test-pmd/bpf_cmd.c
index 830bfc13a5..d2deadd4e6 100644
--- a/dpdk/app/test-pmd/bpf_cmd.c
+++ b/dpdk/app/test-pmd/bpf_cmd.c
@@ -55,7 +55,7 @@ static const struct rte_bpf_xsym bpf_xsym[] = {
 struct cmd_bpf_ld_result {
 	cmdline_fixed_string_t bpf;
 	cmdline_fixed_string_t dir;
-	uint8_t port;
+	uint16_t port;
 	uint16_t queue;
 	cmdline_fixed_string_t op;
 	cmdline_fixed_string_t flags;
@@ -153,7 +153,7 @@ cmdline_parse_inst_t cmd_operate_bpf_ld_parse = {
 struct cmd_bpf_unld_result {
 	cmdline_fixed_string_t bpf;
 	cmdline_fixed_string_t dir;
-	uint8_t port;
+	uint16_t port;
 	uint16_t queue;
 };
 
diff --git a/dpdk/app/test-pmd/cmdline.c b/dpdk/app/test-pmd/cmdline.c
index 9f3e0b251b..9a9da744a1 100644
--- a/dpdk/app/test-pmd/cmdline.c
+++ b/dpdk/app/test-pmd/cmdline.c
@@ -94,7 +94,7 @@ static void cmd_help_brief_parsed(__attribute__((unused)) void *parsed_result,
 		"    help ports                      : Configuring ports.\n"
 		"    help registers                  : Reading and setting port registers.\n"
 		"    help filters                    : Filters configuration help.\n"
-		"    help traffic_management         : Traffic Management commmands.\n"
+		"    help traffic_management         : Traffic Management commands.\n"
 		"    help devices                    : Device related cmds.\n"
 		"    help all                        : All of the above sections.\n\n"
 	);
@@ -614,7 +614,7 @@ static void cmd_help_long_parsed(void *parsed_result,
 			"set bonding mode IEEE802.3AD aggregator policy (port_id) (agg_name)"
 			"	Set Aggregation mode for IEEE802.3AD (mode 4)"
 
-			"set bonding xmit_balance_policy (port_id) (l2|l23|l34)\n"
+			"set bonding balance_xmit_policy (port_id) (l2|l23|l34)\n"
 			"	Set the transmit balance policy for bonded device running in balance mode.\n\n"
 
 			"set bonding mon_period (port_id) (value)\n"
@@ -1437,7 +1437,7 @@ cmdline_parse_inst_t cmd_set_port_setup_on = {
 struct cmd_operate_attach_port_result {
 	cmdline_fixed_string_t port;
 	cmdline_fixed_string_t keyword;
-	cmdline_fixed_string_t identifier;
+	cmdline_multi_string_t identifier;
 };
 
 static void cmd_operate_attach_port_parsed(void *parsed_result,
@@ -1460,7 +1460,7 @@ cmdline_parse_token_string_t cmd_operate_attach_port_keyword =
 			keyword, "attach");
 cmdline_parse_token_string_t cmd_operate_attach_port_identifier =
 	TOKEN_STRING_INITIALIZER(struct cmd_operate_attach_port_result,
-			identifier, NULL);
+			identifier, TOKEN_STRING_MULTI);
 
 cmdline_parse_inst_t cmd_operate_attach_port = {
 	.f = cmd_operate_attach_port_parsed,
@@ -1488,10 +1488,12 @@ static void cmd_operate_detach_port_parsed(void *parsed_result,
 {
 	struct cmd_operate_detach_port_result *res = parsed_result;
 
-	if (!strcmp(res->keyword, "detach"))
+	if (!strcmp(res->keyword, "detach")) {
+		RTE_ETH_VALID_PORTID_OR_RET(res->port_id);
 		detach_port_device(res->port_id);
-	else
+	} else {
 		printf("Unknown parameter\n");
+	}
 }
 
 cmdline_parse_token_string_t cmd_operate_detach_port_port =
@@ -1530,7 +1532,7 @@ static void cmd_operate_detach_device_parsed(void *parsed_result,
 	struct cmd_operate_detach_device_result *res = parsed_result;
 
 	if (!strcmp(res->keyword, "detach"))
-		detach_device(res->identifier);
+		detach_devargs(res->identifier);
 	else
 		printf("Unknown parameter\n");
 }
@@ -1911,18 +1913,13 @@ cmd_config_rx_tx_parsed(void *parsed_result,
 		nb_txq = res->value;
 	}
 	else if (!strcmp(res->name, "rxd")) {
-		if (res->value <= 0 || res->value > RTE_TEST_RX_DESC_MAX) {
-			printf("rxd %d invalid - must be > 0 && <= %d\n",
-					res->value, RTE_TEST_RX_DESC_MAX);
+		if (check_nb_rxd(res->value) != 0)
 			return;
-		}
 		nb_rxd = res->value;
 	} else if (!strcmp(res->name, "txd")) {
-		if (res->value <= 0 || res->value > RTE_TEST_TX_DESC_MAX) {
-			printf("txd %d invalid - must be > 0 && <= %d\n",
-					res->value, RTE_TEST_TX_DESC_MAX);
+		if (check_nb_txd(res->value) != 0)
 			return;
-		}
+
 		nb_txd = res->value;
 	} else {
 		printf("Unknown parameter\n");
@@ -1977,7 +1974,9 @@ cmd_config_max_pkt_len_parsed(void *parsed_result,
 				__attribute__((unused)) void *data)
 {
 	struct cmd_config_max_pkt_len_result *res = parsed_result;
+	uint32_t max_rx_pkt_len_backup = 0;
 	portid_t pid;
+	int ret;
 
 	if (!all_ports_stopped()) {
 		printf("Please stop all ports first\n");
@@ -1986,7 +1985,6 @@ cmd_config_max_pkt_len_parsed(void *parsed_result,
 
 	RTE_ETH_FOREACH_DEV(pid) {
 		struct rte_port *port = &ports[pid];
-		uint64_t rx_offloads = port->dev_conf.rxmode.offloads;
 
 		if (!strcmp(res->name, "max-pkt-len")) {
 			if (res->value < RTE_ETHER_MIN_LEN) {
@@ -1997,12 +1995,18 @@ cmd_config_max_pkt_len_parsed(void *parsed_result,
 			if (res->value == port->dev_conf.rxmode.max_rx_pkt_len)
 				return;
 
+			ret = eth_dev_info_get_print_err(pid, &port->dev_info);
+			if (ret != 0) {
+				printf("rte_eth_dev_info_get() failed for port %u\n",
+					pid);
+				return;
+			}
+
+			max_rx_pkt_len_backup = port->dev_conf.rxmode.max_rx_pkt_len;
+
 			port->dev_conf.rxmode.max_rx_pkt_len = res->value;
-			if (res->value > RTE_ETHER_MAX_LEN)
-				rx_offloads |= DEV_RX_OFFLOAD_JUMBO_FRAME;
-			else
-				rx_offloads &= ~DEV_RX_OFFLOAD_JUMBO_FRAME;
-			port->dev_conf.rxmode.offloads = rx_offloads;
+			if (update_jumbo_frame_offload(pid) != 0)
+				port->dev_conf.rxmode.max_rx_pkt_len = max_rx_pkt_len_backup;
 		} else {
 			printf("Unknown parameter\n");
 			return;
@@ -4171,6 +4175,9 @@ cmd_tx_vlan_set_parsed(void *parsed_result,
 {
 	struct cmd_tx_vlan_set_result *res = parsed_result;
 
+	if (port_id_is_invalid(res->port_id, ENABLED_WARN))
+		return;
+
 	if (!port_is_stopped(res->port_id)) {
 		printf("Please stop port %d first\n", res->port_id);
 		return;
@@ -4225,6 +4232,9 @@ cmd_tx_vlan_set_qinq_parsed(void *parsed_result,
 {
 	struct cmd_tx_vlan_set_qinq_result *res = parsed_result;
 
+	if (port_id_is_invalid(res->port_id, ENABLED_WARN))
+		return;
+
 	if (!port_is_stopped(res->port_id)) {
 		printf("Please stop port %d first\n", res->port_id);
 		return;
@@ -4338,6 +4348,9 @@ cmd_tx_vlan_reset_parsed(void *parsed_result,
 {
 	struct cmd_tx_vlan_reset_result *res = parsed_result;
 
+	if (port_id_is_invalid(res->port_id, ENABLED_WARN))
+		return;
+
 	if (!port_is_stopped(res->port_id)) {
 		printf("Please stop port %d first\n", res->port_id);
 		return;
@@ -5120,7 +5133,7 @@ cmd_gso_size_parsed(void *parsed_result,
 
 	if (test_done == 0) {
 		printf("Before setting GSO segsz, please first"
-				" stop fowarding\n");
+				" stop forwarding\n");
 		return;
 	}
 
@@ -7078,9 +7091,10 @@ cmd_priority_flow_ctrl_set_parsed(void *parsed_result,
 	 * the RTE_FC_RX_PAUSE, Respond to the pause frame at the Tx side.
 	 */
 	static enum rte_eth_fc_mode rx_tx_onoff_2_pfc_mode[2][2] = {
-			{RTE_FC_NONE, RTE_FC_RX_PAUSE}, {RTE_FC_TX_PAUSE, RTE_FC_FULL}
+		{RTE_FC_NONE, RTE_FC_TX_PAUSE}, {RTE_FC_RX_PAUSE, RTE_FC_FULL}
 	};
 
+	memset(&pfc_conf, 0, sizeof(struct rte_eth_pfc_conf));
 	rx_fc_enable = (!strncmp(res->rx_pfc_mode, "on",2)) ? 1 : 0;
 	tx_fc_enable = (!strncmp(res->tx_pfc_mode, "on",2)) ? 1 : 0;
 	pfc_conf.fc.mode       = rx_tx_onoff_2_pfc_mode[rx_fc_enable][tx_fc_enable];
@@ -16802,8 +16816,10 @@ cmd_ddp_get_list_parsed(
 #ifdef RTE_LIBRTE_I40E_PMD
 	size = PROFILE_INFO_SIZE * MAX_PROFILE_NUM + 4;
 	p_list = (struct rte_pmd_i40e_profile_list *)malloc(size);
-	if (!p_list)
+	if (!p_list) {
 		printf("%s: Failed to malloc buffer\n", __func__);
+		return;
+	}
 
 	if (ret == -ENOTSUP)
 		ret = rte_pmd_i40e_get_ddp_list(res->port_id,
@@ -19494,6 +19510,7 @@ cmdline_read_from_file(const char *filename)
 void
 prompt(void)
 {
+	int ret;
 	/* initialize non-constant commands */
 	cmd_set_fwd_mode_init();
 	cmd_set_fwd_retry_mode_init();
@@ -19501,15 +19518,23 @@ prompt(void)
 	testpmd_cl = cmdline_stdin_new(main_ctx, "testpmd> ");
 	if (testpmd_cl == NULL)
 		return;
+
+	ret = atexit(prompt_exit);
+	if (ret != 0)
+		printf("Cannot set exit function for cmdline\n");
+
 	cmdline_interact(testpmd_cl);
-	cmdline_stdin_exit(testpmd_cl);
+	if (ret != 0)
+		cmdline_stdin_exit(testpmd_cl);
 }
 
 void
 prompt_exit(void)
 {
-	if (testpmd_cl != NULL)
+	if (testpmd_cl != NULL) {
 		cmdline_quit(testpmd_cl);
+		cmdline_stdin_exit(testpmd_cl);
+	}
 }
 
 static void
diff --git a/dpdk/app/test-pmd/cmdline_flow.c b/dpdk/app/test-pmd/cmdline_flow.c
index 99dade7d8c..da3533c557 100644
--- a/dpdk/app/test-pmd/cmdline_flow.c
+++ b/dpdk/app/test-pmd/cmdline_flow.c
@@ -1005,7 +1005,6 @@ static const enum index item_pppoes[] = {
 };
 
 static const enum index item_pppoe_proto_id[] = {
-	ITEM_PPPOE_PROTO_ID,
 	ITEM_NEXT,
 	ZERO,
 };
@@ -2544,11 +2543,14 @@ static const struct token token_list[] = {
 					session_id)),
 	},
 	[ITEM_PPPOE_PROTO_ID] = {
-		.name = "proto_id",
+		.name = "pppoe_proto_id",
 		.help = "match PPPoE session protocol identifier",
 		.priv = PRIV_ITEM(PPPOE_PROTO_ID,
 				sizeof(struct rte_flow_item_pppoe_proto_id)),
-		.next = NEXT(item_pppoe_proto_id),
+		.next = NEXT(item_pppoe_proto_id, NEXT_ENTRY(UNSIGNED),
+			     item_param),
+		.args = ARGS(ARGS_ENTRY_HTON
+			     (struct rte_flow_item_pppoe_proto_id, proto_id)),
 		.call = parse_vc,
 	},
 	[ITEM_HIGIG2] = {
@@ -2766,7 +2768,10 @@ static const struct token token_list[] = {
 		.name = "key",
 		.help = "RSS hash key",
 		.next = NEXT(action_rss, NEXT_ENTRY(HEX)),
-		.args = ARGS(ARGS_ENTRY_ARB(0, 0),
+		.args = ARGS(ARGS_ENTRY_ARB
+			     (offsetof(struct action_rss_data, conf) +
+			      offsetof(struct rte_flow_action_rss, key),
+			      sizeof(((struct rte_flow_action_rss *)0)->key)),
 			     ARGS_ENTRY_ARB
 			     (offsetof(struct action_rss_data, conf) +
 			      offsetof(struct rte_flow_action_rss, key_len),
@@ -3898,30 +3903,15 @@ parse_vc_action_rss(struct context *ctx, const struct token *token,
 			.func = RTE_ETH_HASH_FUNCTION_DEFAULT,
 			.level = 0,
 			.types = rss_hf,
-			.key_len = sizeof(action_rss_data->key),
+			.key_len = 0,
 			.queue_num = RTE_MIN(nb_rxq, ACTION_RSS_QUEUE_NUM),
-			.key = action_rss_data->key,
+			.key = NULL,
 			.queue = action_rss_data->queue,
 		},
-		.key = "testpmd's default RSS hash key, "
-			"override it for better balancing",
 		.queue = { 0 },
 	};
 	for (i = 0; i < action_rss_data->conf.queue_num; ++i)
 		action_rss_data->queue[i] = i;
-	if (!port_id_is_invalid(ctx->port, DISABLED_WARN) &&
-	    ctx->port != (portid_t)RTE_PORT_ALL) {
-		struct rte_eth_dev_info info;
-		int ret2;
-
-		ret2 = rte_eth_dev_info_get(ctx->port, &info);
-		if (ret2 != 0)
-			return ret2;
-
-		action_rss_data->conf.key_len =
-			RTE_MIN(sizeof(action_rss_data->key),
-				info.hash_key_size);
-	}
 	action->conf = &action_rss_data->conf;
 	return ret;
 }
@@ -4534,7 +4524,9 @@ parse_vc_action_mplsogre_decap(struct context *ctx, const struct token *token,
 	struct rte_flow_item_gre gre = {
 		.protocol = rte_cpu_to_be_16(ETHER_TYPE_MPLS_UNICAST),
 	};
-	struct rte_flow_item_mpls mpls;
+	struct rte_flow_item_mpls mpls = {
+		.ttl = 0,
+	};
 	uint8_t *header;
 	int ret;
 
@@ -6236,6 +6228,9 @@ flow_item_default_mask(const struct rte_flow_item *item)
 	case RTE_FLOW_ITEM_TYPE_GTP_PSC:
 		mask = &rte_flow_item_gtp_psc_mask;
 		break;
+	case RTE_FLOW_ITEM_TYPE_GENEVE:
+		mask = &rte_flow_item_geneve_mask;
+		break;
 	case RTE_FLOW_ITEM_TYPE_PPPOE_PROTO_ID:
 		mask = &rte_flow_item_pppoe_proto_id_mask;
 	default:
diff --git a/dpdk/app/test-pmd/cmdline_mtr.c b/dpdk/app/test-pmd/cmdline_mtr.c
index ab5c8642db..c6e7529b3d 100644
--- a/dpdk/app/test-pmd/cmdline_mtr.c
+++ b/dpdk/app/test-pmd/cmdline_mtr.c
@@ -312,7 +312,7 @@ static void cmd_show_port_meter_cap_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_show_port_meter_cap = {
 	.f = cmd_show_port_meter_cap_parsed,
 	.data = NULL,
-	.help_str = "Show port meter cap",
+	.help_str = "show port meter cap <port_id>",
 	.tokens = {
 		(void *)&cmd_show_port_meter_cap_show,
 		(void *)&cmd_show_port_meter_cap_port,
@@ -408,7 +408,7 @@ static void cmd_add_port_meter_profile_srtcm_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_add_port_meter_profile_srtcm = {
 	.f = cmd_add_port_meter_profile_srtcm_parsed,
 	.data = NULL,
-	.help_str = "Add port meter profile srtcm (rfc2697)",
+	.help_str = "add port meter profile srtcm_rfc2697 <port_id> <profile_id> <cir> <cbs> <ebs>",
 	.tokens = {
 		(void *)&cmd_add_port_meter_profile_srtcm_add,
 		(void *)&cmd_add_port_meter_profile_srtcm_port,
@@ -515,7 +515,7 @@ static void cmd_add_port_meter_profile_trtcm_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_add_port_meter_profile_trtcm = {
 	.f = cmd_add_port_meter_profile_trtcm_parsed,
 	.data = NULL,
-	.help_str = "Add port meter profile trtcm (rfc2698)",
+	.help_str = "add port meter profile trtcm_rfc2698 <port_id> <profile_id> <cir> <pir> <cbs> <pbs>",
 	.tokens = {
 		(void *)&cmd_add_port_meter_profile_trtcm_add,
 		(void *)&cmd_add_port_meter_profile_trtcm_port,
@@ -627,7 +627,7 @@ static void cmd_add_port_meter_profile_trtcm_rfc4115_parsed(
 cmdline_parse_inst_t cmd_add_port_meter_profile_trtcm_rfc4115 = {
 	.f = cmd_add_port_meter_profile_trtcm_rfc4115_parsed,
 	.data = NULL,
-	.help_str = "Add port meter profile trtcm (rfc4115)",
+	.help_str = "add port meter profile trtcm_rfc4115 <port_id> <profile_id> <cir> <eir> <cbs> <ebs>",
 	.tokens = {
 		(void *)&cmd_add_port_meter_profile_trtcm_rfc4115_add,
 		(void *)&cmd_add_port_meter_profile_trtcm_rfc4115_port,
@@ -702,7 +702,7 @@ static void cmd_del_port_meter_profile_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_del_port_meter_profile = {
 	.f = cmd_del_port_meter_profile_parsed,
 	.data = NULL,
-	.help_str = "Delete port meter profile",
+	.help_str = "del port meter profile <port_id> <profile_id>",
 	.tokens = {
 		(void *)&cmd_del_port_meter_profile_del,
 		(void *)&cmd_del_port_meter_profile_port,
@@ -827,7 +827,10 @@ static void cmd_create_port_meter_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_create_port_meter = {
 	.f = cmd_create_port_meter_parsed,
 	.data = NULL,
-	.help_str = "Create port meter",
+	.help_str = "create port meter <port_id> <mtr_id> <profile_id> <meter_enable>(yes|no) "
+		"<g_action>(R|Y|G|D) <y_action>(R|Y|G|D) <r_action>(R|Y|G|D) "
+		"<stats_mask> <shared> <use_pre_meter_color> "
+		"[<dscp_tbl_entry0> <dscp_tbl_entry1> ...<dscp_tbl_entry63>]",
 	.tokens = {
 		(void *)&cmd_create_port_meter_create,
 		(void *)&cmd_create_port_meter_port,
@@ -896,7 +899,7 @@ static void cmd_enable_port_meter_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_enable_port_meter = {
 	.f = cmd_enable_port_meter_parsed,
 	.data = NULL,
-	.help_str = "Enable port meter",
+	.help_str = "enable port meter <port_id> <mtr_id>",
 	.tokens = {
 		(void *)&cmd_enable_port_meter_enable,
 		(void *)&cmd_enable_port_meter_port,
@@ -957,7 +960,7 @@ static void cmd_disable_port_meter_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_disable_port_meter = {
 	.f = cmd_disable_port_meter_parsed,
 	.data = NULL,
-	.help_str = "Disable port meter",
+	.help_str = "disable port meter <port_id> <mtr_id>",
 	.tokens = {
 		(void *)&cmd_disable_port_meter_disable,
 		(void *)&cmd_disable_port_meter_port,
@@ -1018,7 +1021,7 @@ static void cmd_del_port_meter_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_del_port_meter = {
 	.f = cmd_del_port_meter_parsed,
 	.data = NULL,
-	.help_str = "Delete port meter",
+	.help_str = "del port meter <port_id> <mtr_id>",
 	.tokens = {
 		(void *)&cmd_del_port_meter_del,
 		(void *)&cmd_del_port_meter_port,
@@ -1089,7 +1092,7 @@ static void cmd_set_port_meter_profile_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_set_port_meter_profile = {
 	.f = cmd_set_port_meter_profile_parsed,
 	.data = NULL,
-	.help_str = "Set port meter profile",
+	.help_str = "set port meter profile <port_id> <mtr_id> <profile_id>",
 	.tokens = {
 		(void *)&cmd_set_port_meter_profile_set,
 		(void *)&cmd_set_port_meter_profile_port,
@@ -1163,7 +1166,8 @@ static void cmd_set_port_meter_dscp_table_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_set_port_meter_dscp_table = {
 	.f = cmd_set_port_meter_dscp_table_parsed,
 	.data = NULL,
-	.help_str = "Update port meter dscp table",
+	.help_str = "set port meter dscp table <port_id> <mtr_id> "
+		"[<dscp_tbl_entry0> <dscp_tbl_entry1> ... <dscp_tbl_entry63>]",
 	.tokens = {
 		(void *)&cmd_set_port_meter_dscp_table_set,
 		(void *)&cmd_set_port_meter_dscp_table_port,
@@ -1262,6 +1266,7 @@ static void cmd_set_port_meter_policer_action_parsed(void *parsed_result,
 	ret = rte_mtr_policer_actions_update(port_id, mtr_id,
 		action_mask, actions, &error);
 	if (ret != 0) {
+		free(actions);
 		print_err_msg(&error);
 		return;
 	}
@@ -1272,7 +1277,8 @@ static void cmd_set_port_meter_policer_action_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_set_port_meter_policer_action = {
 	.f = cmd_set_port_meter_policer_action_parsed,
 	.data = NULL,
-	.help_str = "Set port meter policer action",
+	.help_str = "set port meter policer action <port_id> <mtr_id> "
+		"<action_mask> <action0> [<action1> <action2>]",
 	.tokens = {
 		(void *)&cmd_set_port_meter_policer_action_set,
 		(void *)&cmd_set_port_meter_policer_action_port,
@@ -1349,7 +1355,7 @@ static void cmd_set_port_meter_stats_mask_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_set_port_meter_stats_mask = {
 	.f = cmd_set_port_meter_stats_mask_parsed,
 	.data = NULL,
-	.help_str = "Set port meter stats mask",
+	.help_str = "set port meter stats mask <port_id> <mtr_id> <stats_mask>",
 	.tokens = {
 		(void *)&cmd_set_port_meter_stats_mask_set,
 		(void *)&cmd_set_port_meter_stats_mask_port,
@@ -1453,7 +1459,7 @@ static void cmd_show_port_meter_stats_parsed(void *parsed_result,
 cmdline_parse_inst_t cmd_show_port_meter_stats = {
 	.f = cmd_show_port_meter_stats_parsed,
 	.data = NULL,
-	.help_str = "Show port meter stats",
+	.help_str = "show port meter stats <port_id> <mtr_id> <clear>(yes|no)",
 	.tokens = {
 		(void *)&cmd_show_port_meter_stats_show,
 		(void *)&cmd_show_port_meter_stats_port,
diff --git a/dpdk/app/test-pmd/config.c b/dpdk/app/test-pmd/config.c
index d599682788..e14ff42745 100644
--- a/dpdk/app/test-pmd/config.c
+++ b/dpdk/app/test-pmd/config.c
@@ -53,6 +53,14 @@
 
 #include "testpmd.h"
 
+#ifdef CLOCK_MONOTONIC_RAW /* Defined in glibc bits/time.h */
+#define CLOCK_TYPE_ID CLOCK_MONOTONIC_RAW
+#else
+#define CLOCK_TYPE_ID CLOCK_MONOTONIC
+#endif
+
+#define NS_PER_SEC 1E9
+
 static char *flowtype_to_str(uint16_t flow_type);
 
 static const struct {
@@ -125,9 +133,10 @@ nic_stats_display(portid_t port_id)
 	static uint64_t prev_pkts_tx[RTE_MAX_ETHPORTS];
 	static uint64_t prev_bytes_rx[RTE_MAX_ETHPORTS];
 	static uint64_t prev_bytes_tx[RTE_MAX_ETHPORTS];
-	static uint64_t prev_cycles[RTE_MAX_ETHPORTS];
+	static uint64_t prev_ns[RTE_MAX_ETHPORTS];
+	struct timespec cur_time;
 	uint64_t diff_pkts_rx, diff_pkts_tx, diff_bytes_rx, diff_bytes_tx,
-								diff_cycles;
+								diff_ns;
 	uint64_t mpps_rx, mpps_tx, mbps_rx, mbps_tx;
 	struct rte_eth_stats stats;
 	struct rte_port *port = &ports[port_id];
@@ -184,10 +193,17 @@ nic_stats_display(portid_t port_id)
 		}
 	}
 
-	diff_cycles = prev_cycles[port_id];
-	prev_cycles[port_id] = rte_rdtsc();
-	if (diff_cycles > 0)
-		diff_cycles = prev_cycles[port_id] - diff_cycles;
+	diff_ns = 0;
+	if (clock_gettime(CLOCK_TYPE_ID, &cur_time) == 0) {
+		uint64_t ns;
+
+		ns = cur_time.tv_sec * NS_PER_SEC;
+		ns += cur_time.tv_nsec;
+
+		if (prev_ns[port_id] != 0)
+			diff_ns = ns - prev_ns[port_id];
+		prev_ns[port_id] = ns;
+	}
 
 	diff_pkts_rx = (stats.ipackets > prev_pkts_rx[port_id]) ?
 		(stats.ipackets - prev_pkts_rx[port_id]) : 0;
@@ -195,10 +211,10 @@ nic_stats_display(portid_t port_id)
 		(stats.opackets - prev_pkts_tx[port_id]) : 0;
 	prev_pkts_rx[port_id] = stats.ipackets;
 	prev_pkts_tx[port_id] = stats.opackets;
-	mpps_rx = diff_cycles > 0 ?
-		diff_pkts_rx * rte_get_tsc_hz() / diff_cycles : 0;
-	mpps_tx = diff_cycles > 0 ?
-		diff_pkts_tx * rte_get_tsc_hz() / diff_cycles : 0;
+	mpps_rx = diff_ns > 0 ?
+		(double)diff_pkts_rx / diff_ns * NS_PER_SEC : 0;
+	mpps_tx = diff_ns > 0 ?
+		(double)diff_pkts_tx / diff_ns * NS_PER_SEC : 0;
 
 	diff_bytes_rx = (stats.ibytes > prev_bytes_rx[port_id]) ?
 		(stats.ibytes - prev_bytes_rx[port_id]) : 0;
@@ -206,10 +222,10 @@ nic_stats_display(portid_t port_id)
 		(stats.obytes - prev_bytes_tx[port_id]) : 0;
 	prev_bytes_rx[port_id] = stats.ibytes;
 	prev_bytes_tx[port_id] = stats.obytes;
-	mbps_rx = diff_cycles > 0 ?
-		diff_bytes_rx * rte_get_tsc_hz() / diff_cycles : 0;
-	mbps_tx = diff_cycles > 0 ?
-		diff_bytes_tx * rte_get_tsc_hz() / diff_cycles : 0;
+	mbps_rx = diff_ns > 0 ?
+		(double)diff_bytes_rx / diff_ns * NS_PER_SEC : 0;
+	mbps_tx = diff_ns > 0 ?
+		(double)diff_bytes_tx / diff_ns * NS_PER_SEC : 0;
 
 	printf("\n  Throughput (since last show)\n");
 	printf("  Rx-pps: %12"PRIu64"          Rx-bps: %12"PRIu64"\n  Tx-pps: %12"
@@ -223,11 +239,28 @@ nic_stats_display(portid_t port_id)
 void
 nic_stats_clear(portid_t port_id)
 {
+	int ret;
+
 	if (port_id_is_invalid(port_id, ENABLED_WARN)) {
 		print_valid_ports();
 		return;
 	}
-	rte_eth_stats_reset(port_id);
+
+	ret = rte_eth_stats_reset(port_id);
+	if (ret != 0) {
+		printf("%s: Error: failed to reset stats (port %u): %s",
+		       __func__, port_id, strerror(-ret));
+		return;
+	}
+
+	ret = rte_eth_stats_get(port_id, &ports[port_id].stats);
+	if (ret != 0) {
+		if (ret < 0)
+			ret = -ret;
+		printf("%s: Error: failed to get stats (port %u): %s",
+		       __func__, port_id, strerror(ret));
+		return;
+	}
 	printf("\n  NIC statistics for port %d cleared\n", port_id);
 }
 
@@ -303,10 +336,21 @@ nic_xstats_clear(portid_t port_id)
 		print_valid_ports();
 		return;
 	}
+
 	ret = rte_eth_xstats_reset(port_id);
 	if (ret != 0) {
 		printf("%s: Error: failed to reset xstats (port %u): %s",
+		       __func__, port_id, strerror(-ret));
+		return;
+	}
+
+	ret = rte_eth_stats_get(port_id, &ports[port_id].stats);
+	if (ret != 0) {
+		if (ret < 0)
+			ret = -ret;
+		printf("%s: Error: failed to get stats (port %u): %s",
 		       __func__, port_id, strerror(ret));
+		return;
 	}
 }
 
@@ -1216,7 +1260,9 @@ void
 port_mtu_set(portid_t port_id, uint16_t mtu)
 {
 	int diag;
+	struct rte_port *rte_port = &ports[port_id];
 	struct rte_eth_dev_info dev_info;
+	uint16_t eth_overhead;
 	int ret;
 
 	if (port_id_is_invalid(port_id, ENABLED_WARN))
@@ -1232,9 +1278,24 @@ port_mtu_set(portid_t port_id, uint16_t mtu)
 		return;
 	}
 	diag = rte_eth_dev_set_mtu(port_id, mtu);
-	if (diag == 0)
-		return;
-	printf("Set MTU failed. diag=%d\n", diag);
+	if (diag)
+		printf("Set MTU failed. diag=%d\n", diag);
+	else if (dev_info.rx_offload_capa & DEV_RX_OFFLOAD_JUMBO_FRAME) {
+		/*
+		 * Ether overhead in driver is equal to the difference of
+		 * max_rx_pktlen and max_mtu in rte_eth_dev_info when the
+		 * device supports jumbo frame.
+		 */
+		eth_overhead = dev_info.max_rx_pktlen - dev_info.max_mtu;
+		if (mtu > RTE_ETHER_MTU) {
+			rte_port->dev_conf.rxmode.offloads |=
+						DEV_RX_OFFLOAD_JUMBO_FRAME;
+			rte_port->dev_conf.rxmode.max_rx_pkt_len =
+						mtu + eth_overhead;
+		} else
+			rte_port->dev_conf.rxmode.offloads &=
+						~DEV_RX_OFFLOAD_JUMBO_FRAME;
+	}
 }
 
 /* Generic flow management functions. */
@@ -1507,7 +1568,7 @@ port_flow_query(portid_t port_id, uint32_t rule,
 
 /** List flow rules. */
 void
-port_flow_list(portid_t port_id, uint32_t n, const uint32_t group[n])
+port_flow_list(portid_t port_id, uint32_t n, const uint32_t *group)
 {
 	struct rte_port *port;
 	struct port_flow *pf;
@@ -1624,22 +1685,102 @@ tx_queue_id_is_invalid(queueid_t txq_id)
 }
 
 static int
-rx_desc_id_is_invalid(uint16_t rxdesc_id)
+get_rx_ring_size(portid_t port_id, queueid_t rxq_id, uint16_t *ring_size)
 {
-	if (rxdesc_id < nb_rxd)
+	struct rte_port *port = &ports[port_id];
+	struct rte_eth_rxq_info rx_qinfo;
+	int ret;
+
+	ret = rte_eth_rx_queue_info_get(port_id, rxq_id, &rx_qinfo);
+	if (ret == 0) {
+		*ring_size = rx_qinfo.nb_desc;
+		return ret;
+	}
+
+	if (ret != -ENOTSUP)
+		return ret;
+	/*
+	 * If the rte_eth_rx_queue_info_get is not support for this PMD,
+	 * ring_size stored in testpmd will be used for validity verification.
+	 * When configure the rxq by rte_eth_rx_queue_setup with nb_rx_desc
+	 * being 0, it will use a default value provided by PMDs to setup this
+	 * rxq. If the default value is 0, it will use the
+	 * RTE_ETH_DEV_FALLBACK_RX_RINGSIZE to setup this rxq.
+	 */
+	if (port->nb_rx_desc[rxq_id])
+		*ring_size = port->nb_rx_desc[rxq_id];
+	else if (port->dev_info.default_rxportconf.ring_size)
+		*ring_size = port->dev_info.default_rxportconf.ring_size;
+	else
+		*ring_size = RTE_ETH_DEV_FALLBACK_RX_RINGSIZE;
+	return 0;
+}
+
+static int
+get_tx_ring_size(portid_t port_id, queueid_t txq_id, uint16_t *ring_size)
+{
+	struct rte_port *port = &ports[port_id];
+	struct rte_eth_txq_info tx_qinfo;
+	int ret;
+
+	ret = rte_eth_tx_queue_info_get(port_id, txq_id, &tx_qinfo);
+	if (ret == 0) {
+		*ring_size = tx_qinfo.nb_desc;
+		return ret;
+	}
+
+	if (ret != -ENOTSUP)
+		return ret;
+	/*
+	 * If the rte_eth_tx_queue_info_get is not support for this PMD,
+	 * ring_size stored in testpmd will be used for validity verification.
+	 * When configure the txq by rte_eth_tx_queue_setup with nb_tx_desc
+	 * being 0, it will use a default value provided by PMDs to setup this
+	 * txq. If the default value is 0, it will use the
+	 * RTE_ETH_DEV_FALLBACK_TX_RINGSIZE to setup this txq.
+	 */
+	if (port->nb_tx_desc[txq_id])
+		*ring_size = port->nb_tx_desc[txq_id];
+	else if (port->dev_info.default_txportconf.ring_size)
+		*ring_size = port->dev_info.default_txportconf.ring_size;
+	else
+		*ring_size = RTE_ETH_DEV_FALLBACK_TX_RINGSIZE;
+	return 0;
+}
+
+static int
+rx_desc_id_is_invalid(portid_t port_id, queueid_t rxq_id, uint16_t rxdesc_id)
+{
+	uint16_t ring_size;
+	int ret;
+
+	ret = get_rx_ring_size(port_id, rxq_id, &ring_size);
+	if (ret)
+		return 1;
+
+	if (rxdesc_id < ring_size)
 		return 0;
-	printf("Invalid RX descriptor %d (must be < nb_rxd=%d)\n",
-	       rxdesc_id, nb_rxd);
+
+	printf("Invalid RX descriptor %u (must be < ring_size=%u)\n",
+	       rxdesc_id, ring_size);
 	return 1;
 }
 
 static int
-tx_desc_id_is_invalid(uint16_t txdesc_id)
+tx_desc_id_is_invalid(portid_t port_id, queueid_t txq_id, uint16_t txdesc_id)
 {
-	if (txdesc_id < nb_txd)
+	uint16_t ring_size;
+	int ret;
+
+	ret = get_tx_ring_size(port_id, txq_id, &ring_size);
+	if (ret)
+		return 1;
+
+	if (txdesc_id < ring_size)
 		return 0;
-	printf("Invalid TX descriptor %d (must be < nb_txd=%d)\n",
-	       txdesc_id, nb_txd);
+
+	printf("Invalid TX descriptor %u (must be < ring_size=%u)\n",
+	       txdesc_id, ring_size);
 	return 1;
 }
 
@@ -1760,11 +1901,7 @@ rx_ring_desc_display(portid_t port_id, queueid_t rxq_id, uint16_t rxd_id)
 {
 	const struct rte_memzone *rx_mz;
 
-	if (port_id_is_invalid(port_id, ENABLED_WARN))
-		return;
-	if (rx_queue_id_is_invalid(rxq_id))
-		return;
-	if (rx_desc_id_is_invalid(rxd_id))
+	if (rx_desc_id_is_invalid(port_id, rxq_id, rxd_id))
 		return;
 	rx_mz = ring_dma_zone_lookup("rx_ring", port_id, rxq_id);
 	if (rx_mz == NULL)
@@ -1777,11 +1914,7 @@ tx_ring_desc_display(portid_t port_id, queueid_t txq_id, uint16_t txd_id)
 {
 	const struct rte_memzone *tx_mz;
 
-	if (port_id_is_invalid(port_id, ENABLED_WARN))
-		return;
-	if (tx_queue_id_is_invalid(txq_id))
-		return;
-	if (tx_desc_id_is_invalid(txd_id))
+	if (tx_desc_id_is_invalid(port_id, txq_id, txd_id))
 		return;
 	tx_mz = ring_dma_zone_lookup("tx_ring", port_id, txq_id);
 	if (tx_mz == NULL)
@@ -1822,10 +1955,17 @@ rxtx_config_display(void)
 		struct rte_eth_txconf *tx_conf = &ports[pid].tx_conf[0];
 		uint16_t *nb_rx_desc = &ports[pid].nb_rx_desc[0];
 		uint16_t *nb_tx_desc = &ports[pid].nb_tx_desc[0];
-		uint16_t nb_rx_desc_tmp;
-		uint16_t nb_tx_desc_tmp;
 		struct rte_eth_rxq_info rx_qinfo;
 		struct rte_eth_txq_info tx_qinfo;
+		uint16_t rx_free_thresh_tmp;
+		uint16_t tx_free_thresh_tmp;
+		uint16_t tx_rs_thresh_tmp;
+		uint16_t nb_rx_desc_tmp;
+		uint16_t nb_tx_desc_tmp;
+		uint64_t offloads_tmp;
+		uint8_t pthresh_tmp;
+		uint8_t hthresh_tmp;
+		uint8_t wthresh_tmp;
 		int32_t rc;
 
 		/* per port config */
@@ -1839,41 +1979,64 @@ rxtx_config_display(void)
 		/* per rx queue config only for first queue to be less verbose */
 		for (qid = 0; qid < 1; qid++) {
 			rc = rte_eth_rx_queue_info_get(pid, qid, &rx_qinfo);
-			if (rc)
+			if (rc) {
 				nb_rx_desc_tmp = nb_rx_desc[qid];
-			else
+				rx_free_thresh_tmp =
+					rx_conf[qid].rx_free_thresh;
+				pthresh_tmp = rx_conf[qid].rx_thresh.pthresh;
+				hthresh_tmp = rx_conf[qid].rx_thresh.hthresh;
+				wthresh_tmp = rx_conf[qid].rx_thresh.wthresh;
+				offloads_tmp = rx_conf[qid].offloads;
+			} else {
 				nb_rx_desc_tmp = rx_qinfo.nb_desc;
+				rx_free_thresh_tmp =
+						rx_qinfo.conf.rx_free_thresh;
+				pthresh_tmp = rx_qinfo.conf.rx_thresh.pthresh;
+				hthresh_tmp = rx_qinfo.conf.rx_thresh.hthresh;
+				wthresh_tmp = rx_qinfo.conf.rx_thresh.wthresh;
+				offloads_tmp = rx_qinfo.conf.offloads;
+			}
 
 			printf("    RX queue: %d\n", qid);
 			printf("      RX desc=%d - RX free threshold=%d\n",
-				nb_rx_desc_tmp, rx_conf[qid].rx_free_thresh);
+				nb_rx_desc_tmp, rx_free_thresh_tmp);
 			printf("      RX threshold registers: pthresh=%d hthresh=%d "
 				" wthresh=%d\n",
-				rx_conf[qid].rx_thresh.pthresh,
-				rx_conf[qid].rx_thresh.hthresh,
-				rx_conf[qid].rx_thresh.wthresh);
-			printf("      RX Offloads=0x%"PRIx64"\n",
-				rx_conf[qid].offloads);
+				pthresh_tmp, hthresh_tmp, wthresh_tmp);
+			printf("      RX Offloads=0x%"PRIx64"\n", offloads_tmp);
 		}
 
 		/* per tx queue config only for first queue to be less verbose */
 		for (qid = 0; qid < 1; qid++) {
 			rc = rte_eth_tx_queue_info_get(pid, qid, &tx_qinfo);
-			if (rc)
+			if (rc) {
 				nb_tx_desc_tmp = nb_tx_desc[qid];
-			else
+				tx_free_thresh_tmp =
+					tx_conf[qid].tx_free_thresh;
+				pthresh_tmp = tx_conf[qid].tx_thresh.pthresh;
+				hthresh_tmp = tx_conf[qid].tx_thresh.hthresh;
+				wthresh_tmp = tx_conf[qid].tx_thresh.wthresh;
+				offloads_tmp = tx_conf[qid].offloads;
+				tx_rs_thresh_tmp = tx_conf[qid].tx_rs_thresh;
+			} else {
 				nb_tx_desc_tmp = tx_qinfo.nb_desc;
+				tx_free_thresh_tmp =
+						tx_qinfo.conf.tx_free_thresh;
+				pthresh_tmp = tx_qinfo.conf.tx_thresh.pthresh;
+				hthresh_tmp = tx_qinfo.conf.tx_thresh.hthresh;
+				wthresh_tmp = tx_qinfo.conf.tx_thresh.wthresh;
+				offloads_tmp = tx_qinfo.conf.offloads;
+				tx_rs_thresh_tmp = tx_qinfo.conf.tx_rs_thresh;
+			}
 
 			printf("    TX queue: %d\n", qid);
 			printf("      TX desc=%d - TX free threshold=%d\n",
-				nb_tx_desc_tmp, tx_conf[qid].tx_free_thresh);
+				nb_tx_desc_tmp, tx_free_thresh_tmp);
 			printf("      TX threshold registers: pthresh=%d hthresh=%d "
 				" wthresh=%d\n",
-				tx_conf[qid].tx_thresh.pthresh,
-				tx_conf[qid].tx_thresh.hthresh,
-				tx_conf[qid].tx_thresh.wthresh);
+				pthresh_tmp, hthresh_tmp, wthresh_tmp);
 			printf("      TX offloads=0x%"PRIx64" - TX RS bit threshold=%d\n",
-				tx_conf[qid].offloads, tx_conf->tx_rs_thresh);
+				offloads_tmp, tx_rs_thresh_tmp);
 		}
 	}
 }
@@ -2518,6 +2681,10 @@ set_fwd_lcores_mask(uint64_t lcoremask)
 void
 set_fwd_lcores_number(uint16_t nb_lc)
 {
+	if (test_done == 0) {
+		printf("Please stop forwarding first\n");
+		return;
+	}
 	if (nb_lc > nb_cfg_lcores) {
 		printf("nb fwd cores %u > %u (max. number of configured "
 		       "lcores) - ignored\n",
@@ -2665,17 +2832,41 @@ show_tx_pkt_segments(void)
 	printf("Split packet: %s\n", split);
 }
 
+static bool
+nb_segs_is_invalid(unsigned int nb_segs)
+{
+	uint16_t ring_size;
+	uint16_t queue_id;
+	uint16_t port_id;
+	int ret;
+
+	RTE_ETH_FOREACH_DEV(port_id) {
+		for (queue_id = 0; queue_id < nb_txq; queue_id++) {
+			ret = get_tx_ring_size(port_id, queue_id, &ring_size);
+
+			if (ret)
+				return true;
+
+			if (ring_size < nb_segs) {
+				printf("nb segments per TX packets=%u >= "
+				       "TX queue(%u) ring_size=%u - ignored\n",
+				       nb_segs, queue_id, ring_size);
+				return true;
+			}
+		}
+	}
+
+	return false;
+}
+
 void
 set_tx_pkt_segments(unsigned *seg_lengths, unsigned nb_segs)
 {
 	uint16_t tx_pkt_len;
 	unsigned i;
 
-	if (nb_segs >= (unsigned) nb_txd) {
-		printf("nb segments per TX packets=%u >= nb_txd=%u - ignored\n",
-		       nb_segs, (unsigned int) nb_txd);
+	if (nb_segs_is_invalid(nb_segs))
 		return;
-	}
 
 	/*
 	 * Check that each segment length is greater or equal than
@@ -3019,9 +3210,11 @@ vlan_extend_set(portid_t port_id, int on)
 	}
 
 	diag = rte_eth_dev_set_vlan_offload(port_id, vlan_offload);
-	if (diag < 0)
+	if (diag < 0) {
 		printf("rx_vlan_extend_set(port_pi=%d, on=%d) failed "
 	       "diag=%d\n", port_id, on, diag);
+		return;
+	}
 	ports[port_id].dev_conf.rxmode.offloads = port_rx_offloads;
 }
 
@@ -3046,9 +3239,11 @@ rx_vlan_strip_set(portid_t port_id, int on)
 	}
 
 	diag = rte_eth_dev_set_vlan_offload(port_id, vlan_offload);
-	if (diag < 0)
+	if (diag < 0) {
 		printf("rx_vlan_strip_set(port_pi=%d, on=%d) failed "
 	       "diag=%d\n", port_id, on, diag);
+		return;
+	}
 	ports[port_id].dev_conf.rxmode.offloads = port_rx_offloads;
 }
 
@@ -3087,9 +3282,11 @@ rx_vlan_filter_set(portid_t port_id, int on)
 	}
 
 	diag = rte_eth_dev_set_vlan_offload(port_id, vlan_offload);
-	if (diag < 0)
+	if (diag < 0) {
 		printf("rx_vlan_filter_set(port_pi=%d, on=%d) failed "
 	       "diag=%d\n", port_id, on, diag);
+		return;
+	}
 	ports[port_id].dev_conf.rxmode.offloads = port_rx_offloads;
 }
 
@@ -3114,9 +3311,11 @@ rx_vlan_qinq_strip_set(portid_t port_id, int on)
 	}
 
 	diag = rte_eth_dev_set_vlan_offload(port_id, vlan_offload);
-	if (diag < 0)
+	if (diag < 0) {
 		printf("%s(port_pi=%d, on=%d) failed "
 	       "diag=%d\n", __func__, port_id, on, diag);
+		return;
+	}
 	ports[port_id].dev_conf.rxmode.offloads = port_rx_offloads;
 }
 
@@ -3174,8 +3373,6 @@ tx_vlan_set(portid_t port_id, uint16_t vlan_id)
 	struct rte_eth_dev_info dev_info;
 	int ret;
 
-	if (port_id_is_invalid(port_id, ENABLED_WARN))
-		return;
 	if (vlan_id_is_invalid(vlan_id))
 		return;
 
@@ -3206,8 +3403,6 @@ tx_qinq_set(portid_t port_id, uint16_t vlan_id, uint16_t vlan_id_outer)
 	struct rte_eth_dev_info dev_info;
 	int ret;
 
-	if (port_id_is_invalid(port_id, ENABLED_WARN))
-		return;
 	if (vlan_id_is_invalid(vlan_id))
 		return;
 	if (vlan_id_is_invalid(vlan_id_outer))
@@ -3233,8 +3428,6 @@ tx_qinq_set(portid_t port_id, uint16_t vlan_id, uint16_t vlan_id_outer)
 void
 tx_vlan_reset(portid_t port_id)
 {
-	if (port_id_is_invalid(port_id, ENABLED_WARN))
-		return;
 	ports[port_id].dev_conf.txmode.offloads &=
 				~(DEV_TX_OFFLOAD_VLAN_INSERT |
 				  DEV_TX_OFFLOAD_QINQ_INSERT);
@@ -3707,6 +3900,14 @@ mcast_addr_pool_extend(struct rte_port *port)
 
 }
 
+static void
+mcast_addr_pool_append(struct rte_port *port, struct rte_ether_addr *mc_addr)
+{
+	if (mcast_addr_pool_extend(port) != 0)
+		return;
+	rte_ether_addr_copy(mc_addr, &port->mc_addr_pool[port->mc_addr_nb - 1]);
+}
+
 static void
 mcast_addr_pool_remove(struct rte_port *port, uint32_t addr_idx)
 {
@@ -3725,7 +3926,7 @@ mcast_addr_pool_remove(struct rte_port *port, uint32_t addr_idx)
 		sizeof(struct rte_ether_addr) * (port->mc_addr_nb - addr_idx));
 }
 
-static void
+static int
 eth_port_multicast_addr_list_set(portid_t port_id)
 {
 	struct rte_port *port;
@@ -3734,10 +3935,11 @@ eth_port_multicast_addr_list_set(portid_t port_id)
 	port = &ports[port_id];
 	diag = rte_eth_dev_set_mc_addr_list(port_id, port->mc_addr_pool,
 					    port->mc_addr_nb);
-	if (diag == 0)
-		return;
-	printf("rte_eth_dev_set_mc_addr_list(port=%d, nb=%u) failed. diag=%d\n",
-	       port->mc_addr_nb, port_id, -diag);
+	if (diag < 0)
+		printf("rte_eth_dev_set_mc_addr_list(port=%d, nb=%u) failed. diag=%d\n",
+			port_id, port->mc_addr_nb, diag);
+
+	return diag;
 }
 
 void
@@ -3762,10 +3964,10 @@ mcast_addr_add(portid_t port_id, struct rte_ether_addr *mc_addr)
 		}
 	}
 
-	if (mcast_addr_pool_extend(port) != 0)
-		return;
-	rte_ether_addr_copy(mc_addr, &port->mc_addr_pool[i]);
-	eth_port_multicast_addr_list_set(port_id);
+	mcast_addr_pool_append(port, mc_addr);
+	if (eth_port_multicast_addr_list_set(port_id) < 0)
+		/* Rollback on failure, remove the address from the pool */
+		mcast_addr_pool_remove(port, i);
 }
 
 void
@@ -3792,7 +3994,9 @@ mcast_addr_remove(portid_t port_id, struct rte_ether_addr *mc_addr)
 	}
 
 	mcast_addr_pool_remove(port, i);
-	eth_port_multicast_addr_list_set(port_id);
+	if (eth_port_multicast_addr_list_set(port_id) < 0)
+		/* Rollback on failure, add the address back into the pool */
+		mcast_addr_pool_append(port, mc_addr);
 }
 
 void
diff --git a/dpdk/app/test-pmd/csumonly.c b/dpdk/app/test-pmd/csumonly.c
index 25091de881..7b92ab1195 100644
--- a/dpdk/app/test-pmd/csumonly.c
+++ b/dpdk/app/test-pmd/csumonly.c
@@ -139,22 +139,23 @@ parse_ipv6(struct rte_ipv6_hdr *ipv6_hdr, struct testpmd_offload_info *info)
 
 /*
  * Parse an ethernet header to fill the ethertype, l2_len, l3_len and
- * ipproto. This function is able to recognize IPv4/IPv6 with one optional vlan
- * header. The l4_len argument is only set in case of TCP (useful for TSO).
+ * ipproto. This function is able to recognize IPv4/IPv6 with optional VLAN
+ * headers. The l4_len argument is only set in case of TCP (useful for TSO).
  */
 static void
 parse_ethernet(struct rte_ether_hdr *eth_hdr, struct testpmd_offload_info *info)
 {
 	struct rte_ipv4_hdr *ipv4_hdr;
 	struct rte_ipv6_hdr *ipv6_hdr;
+	struct rte_vlan_hdr *vlan_hdr;
 
 	info->l2_len = sizeof(struct rte_ether_hdr);
 	info->ethertype = eth_hdr->ether_type;
 
-	if (info->ethertype == _htons(RTE_ETHER_TYPE_VLAN)) {
-		struct rte_vlan_hdr *vlan_hdr = (
-			struct rte_vlan_hdr *)(eth_hdr + 1);
-
+	while (info->ethertype == _htons(RTE_ETHER_TYPE_VLAN) ||
+	       info->ethertype == _htons(RTE_ETHER_TYPE_QINQ)) {
+		vlan_hdr = (struct rte_vlan_hdr *)
+			((char *)eth_hdr + info->l2_len);
 		info->l2_len  += sizeof(struct rte_vlan_hdr);
 		info->ethertype = vlan_hdr->eth_proto;
 	}
diff --git a/dpdk/app/test-pmd/flowgen.c b/dpdk/app/test-pmd/flowgen.c
index 03b72aaa56..3e1335b627 100644
--- a/dpdk/app/test-pmd/flowgen.c
+++ b/dpdk/app/test-pmd/flowgen.c
@@ -1,35 +1,5 @@
-/*-
- *   BSD LICENSE
- *
- *   Copyright(c) 2010-2013 Tilera Corporation. All rights reserved.
- *   All rights reserved.
- *
- *   Redistribution and use in source and binary forms, with or without
- *   modification, are permitted provided that the following conditions
- *   are met:
- *
- *     * Redistributions of source code must retain the above copyright
- *       notice, this list of conditions and the following disclaimer.
- *     * Redistributions in binary form must reproduce the above copyright
- *       notice, this list of conditions and the following disclaimer in
- *       the documentation and/or other materials provided with the
- *       distribution.
- *     * Neither the name of Tilera Corporation nor the names of its
- *       contributors may be used to endorse or promote products derived
- *       from this software without specific prior written permission.
- *
- *   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- *   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- *   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- *   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- *   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- *   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- *   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- *   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- *   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- *   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- *   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+/* SPDX-License-Identifier: BSD-3-Clause
+ * Copyright 2014-2020 Mellanox Technologies, Ltd
  */
 
 #include <stdarg.h>
@@ -83,8 +53,11 @@ static struct rte_ether_addr cfg_ether_dst =
 
 #define IP_DEFTTL  64   /* from RFC 1340. */
 
+/* Use this type to inform GCC that ip_sum violates aliasing rules. */
+typedef unaligned_uint16_t alias_int16_t __attribute__((__may_alias__));
+
 static inline uint16_t
-ip_sum(const unaligned_uint16_t *hdr, int hdr_len)
+ip_sum(const alias_int16_t *hdr, int hdr_len)
 {
 	uint32_t sum = 0;
 
@@ -186,7 +159,7 @@ pkt_burst_flow_gen(struct fwd_stream *fs)
 							   next_flow);
 		ip_hdr->total_length	= RTE_CPU_TO_BE_16(pkt_size -
 							   sizeof(*eth_hdr));
-		ip_hdr->hdr_checksum	= ip_sum((unaligned_uint16_t *)ip_hdr,
+		ip_hdr->hdr_checksum	= ip_sum((const alias_int16_t *)ip_hdr,
 						 sizeof(*ip_hdr));
 
 		/* Initialize UDP header. */
diff --git a/dpdk/app/test-pmd/macswap.c b/dpdk/app/test-pmd/macswap.c
index 71af916fc3..8428c26d85 100644
--- a/dpdk/app/test-pmd/macswap.c
+++ b/dpdk/app/test-pmd/macswap.c
@@ -1,34 +1,5 @@
-/*-
- *   BSD LICENSE
- *
- *   Copyright(c) 2014 Tilera Corporation. All rights reserved.
- *
- *   Redistribution and use in source and binary forms, with or without
- *   modification, are permitted provided that the following conditions
- *   are met:
- *
- *     * Redistributions of source code must retain the above copyright
- *       notice, this list of conditions and the following disclaimer.
- *     * Redistributions in binary form must reproduce the above copyright
- *       notice, this list of conditions and the following disclaimer in
- *       the documentation and/or other materials provided with the
- *       distribution.
- *     * Neither the name of Tilera Corporation nor the names of its
- *       contributors may be used to endorse or promote products derived
- *       from this software without specific prior written permission.
- *
- *   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- *   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- *   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- *   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- *   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- *   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- *   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- *   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- *   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- *   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- *   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+/* SPDX-License-Identifier: BSD-3-Clause
+ * Copyright 2014-2020 Mellanox Technologies, Ltd
  */
 
 #include <stdarg.h>
diff --git a/dpdk/app/test-pmd/meson.build b/dpdk/app/test-pmd/meson.build
index 6006c60f99..b0249bdb3c 100644
--- a/dpdk/app/test-pmd/meson.build
+++ b/dpdk/app/test-pmd/meson.build
@@ -28,6 +28,18 @@ deps += ['ethdev', 'gro', 'gso', 'cmdline', 'metrics', 'meter', 'bus_pci']
 if dpdk_conf.has('RTE_LIBRTE_PDUMP')
 	deps += 'pdump'
 endif
+if dpdk_conf.has('RTE_LIBRTE_BITRATESTATS')
+	deps += 'bitratestats'
+endif
+if dpdk_conf.has('RTE_LIBRTE_LATENCYSTATS')
+	deps += 'latencystats'
+endif
+if dpdk_conf.has('RTE_LIBRTE_PMD_CRYPTO_SCHEDULER')
+	deps += 'pmd_crypto_scheduler'
+endif
+if dpdk_conf.has('RTE_LIBRTE_BOND_PMD')
+	deps += 'pmd_bond'
+endif
 if dpdk_conf.has('RTE_LIBRTE_BNXT_PMD')
 	deps += 'pmd_bnxt'
 endif
diff --git a/dpdk/app/test-pmd/parameters.c b/dpdk/app/test-pmd/parameters.c
index 2e7a504415..a1c08a411a 100644
--- a/dpdk/app/test-pmd/parameters.c
+++ b/dpdk/app/test-pmd/parameters.c
@@ -49,7 +49,7 @@
 static void
 usage(char* progname)
 {
-	printf("usage: %s "
+	printf("usage: %s [EAL options] -- "
 #ifdef RTE_LIBRTE_CMDLINE
 	       "[--interactive|-i] "
 	       "[--cmdline-file=FILENAME] "
@@ -884,12 +884,9 @@ launch_args_parse(int argc, char** argv)
 			}
 			if (!strcmp(lgopts[opt_idx].name, "max-pkt-len")) {
 				n = atoi(optarg);
-				if (n >= RTE_ETHER_MIN_LEN) {
+				if (n >= RTE_ETHER_MIN_LEN)
 					rx_mode.max_rx_pkt_len = (uint32_t) n;
-					if (n > RTE_ETHER_MAX_LEN)
-						rx_offloads |=
-							DEV_RX_OFFLOAD_JUMBO_FRAME;
-				} else
+				else
 					rte_exit(EXIT_FAILURE,
 						 "Invalid max-pkt-len=%d - should be > %d\n",
 						 n, RTE_ETHER_MIN_LEN);
diff --git a/dpdk/app/test-pmd/testpmd.c b/dpdk/app/test-pmd/testpmd.c
index b374682236..0c3361e817 100644
--- a/dpdk/app/test-pmd/testpmd.c
+++ b/dpdk/app/test-pmd/testpmd.c
@@ -421,8 +421,11 @@ lcoreid_t latencystats_lcore_id = -1;
  * Ethernet device configuration.
  */
 struct rte_eth_rxmode rx_mode = {
-	.max_rx_pkt_len = RTE_ETHER_MAX_LEN,
-		/**< Default maximum frame length. */
+	/* Default maximum frame length.
+	 * Zero is converted to "RTE_ETHER_MTU + PMD Ethernet overhead"
+	 * in init_config().
+	 */
+	.max_rx_pkt_len = 0,
 };
 
 struct rte_eth_txmode tx_mode = {
@@ -1071,6 +1074,177 @@ check_nb_txq(queueid_t txq)
 	return 0;
 }
 
+/*
+ * Get the allowed maximum number of RXDs of every rx queue.
+ * *pid return the port id which has minimal value of
+ * max_rxd in all queues of all ports.
+ */
+static uint16_t
+get_allowed_max_nb_rxd(portid_t *pid)
+{
+	uint16_t allowed_max_rxd = UINT16_MAX;
+	portid_t pi;
+	struct rte_eth_dev_info dev_info;
+
+	RTE_ETH_FOREACH_DEV(pi) {
+		if (eth_dev_info_get_print_err(pi, &dev_info) != 0)
+			continue;
+
+		if (dev_info.rx_desc_lim.nb_max < allowed_max_rxd) {
+			allowed_max_rxd = dev_info.rx_desc_lim.nb_max;
+			*pid = pi;
+		}
+	}
+	return allowed_max_rxd;
+}
+
+/*
+ * Get the allowed minimal number of RXDs of every rx queue.
+ * *pid return the port id which has minimal value of
+ * min_rxd in all queues of all ports.
+ */
+static uint16_t
+get_allowed_min_nb_rxd(portid_t *pid)
+{
+	uint16_t allowed_min_rxd = 0;
+	portid_t pi;
+	struct rte_eth_dev_info dev_info;
+
+	RTE_ETH_FOREACH_DEV(pi) {
+		if (eth_dev_info_get_print_err(pi, &dev_info) != 0)
+			continue;
+
+		if (dev_info.rx_desc_lim.nb_min > allowed_min_rxd) {
+			allowed_min_rxd = dev_info.rx_desc_lim.nb_min;
+			*pid = pi;
+		}
+	}
+
+	return allowed_min_rxd;
+}
+
+/*
+ * Check input rxd is valid or not.
+ * If input rxd is not greater than any of maximum number
+ * of RXDs of every Rx queues and is not less than any of
+ * minimal number of RXDs of every Rx queues, it is valid.
+ * if valid, return 0, else return -1
+ */
+int
+check_nb_rxd(queueid_t rxd)
+{
+	uint16_t allowed_max_rxd;
+	uint16_t allowed_min_rxd;
+	portid_t pid = 0;
+
+	allowed_max_rxd = get_allowed_max_nb_rxd(&pid);
+	if (rxd > allowed_max_rxd) {
+		printf("Fail: input rxd (%u) can't be greater "
+		       "than max_rxds (%u) of port %u\n",
+		       rxd,
+		       allowed_max_rxd,
+		       pid);
+		return -1;
+	}
+
+	allowed_min_rxd = get_allowed_min_nb_rxd(&pid);
+	if (rxd < allowed_min_rxd) {
+		printf("Fail: input rxd (%u) can't be less "
+		       "than min_rxds (%u) of port %u\n",
+		       rxd,
+		       allowed_min_rxd,
+		       pid);
+		return -1;
+	}
+
+	return 0;
+}
+
+/*
+ * Get the allowed maximum number of TXDs of every rx queues.
+ * *pid return the port id which has minimal value of
+ * max_txd in every tx queue.
+ */
+static uint16_t
+get_allowed_max_nb_txd(portid_t *pid)
+{
+	uint16_t allowed_max_txd = UINT16_MAX;
+	portid_t pi;
+	struct rte_eth_dev_info dev_info;
+
+	RTE_ETH_FOREACH_DEV(pi) {
+		if (eth_dev_info_get_print_err(pi, &dev_info) != 0)
+			continue;
+
+		if (dev_info.tx_desc_lim.nb_max < allowed_max_txd) {
+			allowed_max_txd = dev_info.tx_desc_lim.nb_max;
+			*pid = pi;
+		}
+	}
+	return allowed_max_txd;
+}
+
+/*
+ * Get the allowed maximum number of TXDs of every tx queues.
+ * *pid return the port id which has minimal value of
+ * min_txd in every tx queue.
+ */
+static uint16_t
+get_allowed_min_nb_txd(portid_t *pid)
+{
+	uint16_t allowed_min_txd = 0;
+	portid_t pi;
+	struct rte_eth_dev_info dev_info;
+
+	RTE_ETH_FOREACH_DEV(pi) {
+		if (eth_dev_info_get_print_err(pi, &dev_info) != 0)
+			continue;
+
+		if (dev_info.tx_desc_lim.nb_min > allowed_min_txd) {
+			allowed_min_txd = dev_info.tx_desc_lim.nb_min;
+			*pid = pi;
+		}
+	}
+
+	return allowed_min_txd;
+}
+
+/*
+ * Check input txd is valid or not.
+ * If input txd is not greater than any of maximum number
+ * of TXDs of every Rx queues, it is valid.
+ * if valid, return 0, else return -1
+ */
+int
+check_nb_txd(queueid_t txd)
+{
+	uint16_t allowed_max_txd;
+	uint16_t allowed_min_txd;
+	portid_t pid = 0;
+
+	allowed_max_txd = get_allowed_max_nb_txd(&pid);
+	if (txd > allowed_max_txd) {
+		printf("Fail: input txd (%u) can't be greater "
+		       "than max_txds (%u) of port %u\n",
+		       txd,
+		       allowed_max_txd,
+		       pid);
+		return -1;
+	}
+
+	allowed_min_txd = get_allowed_min_nb_txd(&pid);
+	if (txd < allowed_min_txd) {
+		printf("Fail: input txd (%u) can't be less "
+		       "than min_txds (%u) of port %u\n",
+		       txd,
+		       allowed_min_txd,
+		       pid);
+		return -1;
+	}
+	return 0;
+}
+
+
 /*
  * Get the allowed maximum number of hairpin queues.
  * *pid return the port id which has minimal value of
@@ -1166,6 +1340,11 @@ init_config(void)
 			rte_exit(EXIT_FAILURE,
 				 "rte_eth_dev_info_get() failed\n");
 
+		ret = update_jumbo_frame_offload(pid);
+		if (ret != 0)
+			printf("Updating jumbo frame offload failed for port %u\n",
+				pid);
+
 		if (!(port->dev_info.tx_offload_capa &
 		      DEV_TX_OFFLOAD_MBUF_FAST_FREE))
 			port->dev_conf.txmode.offloads &=
@@ -1430,9 +1609,9 @@ init_fwd_streams(void)
 static void
 pkt_burst_stats_display(const char *rx_tx, struct pkt_burst_stats *pbs)
 {
-	unsigned int total_burst;
-	unsigned int nb_burst;
-	unsigned int burst_stats[3];
+	uint64_t total_burst;
+	uint64_t nb_burst;
+	uint64_t burst_stats[3];
 	uint16_t pktnb_stats[3];
 	uint16_t nb_pkt;
 	int burst_percent[3];
@@ -1461,8 +1640,8 @@ pkt_burst_stats_display(const char *rx_tx, struct pkt_burst_stats *pbs)
 	}
 	if (total_burst == 0)
 		return;
-	burst_percent[0] = (burst_stats[0] * 100) / total_burst;
-	printf("  %s-bursts : %u [%d%% of %d pkts", rx_tx, total_burst,
+	burst_percent[0] = (double)burst_stats[0] / total_burst * 100;
+	printf("  %s-bursts : %"PRIu64" [%d%% of %d pkts", rx_tx, total_burst,
 	       burst_percent[0], (int) pktnb_stats[0]);
 	if (burst_stats[0] == total_burst) {
 		printf("]\n");
@@ -1473,7 +1652,7 @@ pkt_burst_stats_display(const char *rx_tx, struct pkt_burst_stats *pbs)
 		       100 - burst_percent[0], pktnb_stats[1]);
 		return;
 	}
-	burst_percent[1] = (burst_stats[1] * 100) / total_burst;
+	burst_percent[1] = (double)burst_stats[1] / total_burst * 100;
 	burst_percent[2] = 100 - (burst_percent[0] + burst_percent[1]);
 	if ((burst_percent[1] == 0) || (burst_percent[2] == 0)) {
 		printf(" + %d%% of others]\n", 100 - burst_percent[0]);
Louis Abel's avatar
Louis Abel committed
4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200
@@ -1698,11 +1877,22 @@ fwd_stats_display(void)
 	       "%s\n",
 	       acc_stats_border, acc_stats_border);
 #ifdef RTE_TEST_PMD_RECORD_CORE_CYCLES
-	if (total_recv > 0)
-		printf("\n  CPU cycles/packet=%u (total cycles="
-		       "%"PRIu64" / total RX packets=%"PRIu64")\n",
-		       (unsigned int)(fwd_cycles / total_recv),
-		       fwd_cycles, total_recv);
+#define CYC_PER_MHZ 1E6
+	if (total_recv > 0 || total_xmit > 0) {
+		uint64_t total_pkts = 0;
+		if (strcmp(cur_fwd_eng->fwd_mode_name, "txonly") == 0 ||
+		    strcmp(cur_fwd_eng->fwd_mode_name, "flowgen") == 0)
+			total_pkts = total_xmit;
+		else
+			total_pkts = total_recv;
+
+		printf("\n  CPU cycles/packet=%.2F (total cycles="
+		       "%"PRIu64" / total %s packets=%"PRIu64") at %"PRIu64
+		       " MHz Clock\n",
+		       (double) fwd_cycles / total_pkts,
+		       fwd_cycles, cur_fwd_eng->fwd_mode_name, total_pkts,
+		       (uint64_t)(rte_get_tsc_hz() / CYC_PER_MHZ));
+	}
 #endif
 }
 
@@ -2549,32 +2739,17 @@ setup_attached_port(portid_t pi)
 	printf("Done\n");
 }
 
-void
-detach_port_device(portid_t port_id)
+static void
+detach_device(struct rte_device *dev)
 {
-	struct rte_device *dev;
 	portid_t sibling;
 
-	printf("Removing a device...\n");
-
-	if (port_id_is_invalid(port_id, ENABLED_WARN))
-		return;
-
-	dev = rte_eth_devices[port_id].device;
 	if (dev == NULL) {
 		printf("Device already removed\n");
 		return;
 	}
 
-	if (ports[port_id].port_status != RTE_PORT_CLOSED) {
-		if (ports[port_id].port_status != RTE_PORT_STOPPED) {
-			printf("Port not stopped\n");
-			return;
-		}
-		printf("Port was not closed\n");
-		if (ports[port_id].flow_list)
-			port_flow_flush(port_id);
-	}
+	printf("Removing a device...\n");
 
 	if (rte_dev_remove(dev) < 0) {
 		TESTPMD_LOG(ERR, "Failed to detach device %s\n", dev->name);
@@ -2592,14 +2767,33 @@ detach_port_device(portid_t port_id)
 
 	remove_invalid_ports();
 
-	printf("Device of port %u is detached\n", port_id);
+	printf("Device is detached\n");
 	printf("Now total ports is %d\n", nb_ports);
 	printf("Done\n");
 	return;
 }
 
 void
-detach_device(char *identifier)
+detach_port_device(portid_t port_id)
+{
+	if (port_id_is_invalid(port_id, ENABLED_WARN))
+		return;
+
+	if (ports[port_id].port_status != RTE_PORT_CLOSED) {
+		if (ports[port_id].port_status != RTE_PORT_STOPPED) {
+			printf("Port not stopped\n");
+			return;
+		}
+		printf("Port was not closed\n");
+		if (ports[port_id].flow_list)
+			port_flow_flush(port_id);
+	}
+
+	detach_device(rte_eth_devices[port_id].device);
+}
+
+void
+detach_devargs(char *identifier)
 {
 	struct rte_dev_iterator iterator;
 	struct rte_devargs da;
@@ -2748,7 +2942,7 @@ check_all_ports_link_status(uint32_t port_mask)
 					"Port%d Link Up. speed %u Mbps- %s\n",
 					portid, link.link_speed,
 				(link.link_duplex == ETH_LINK_FULL_DUPLEX) ?
-					("full-duplex") : ("half-duplex\n"));
+					("full-duplex") : ("half-duplex"));
 				else
 					printf("Port %d Link Down\n", portid);
 				continue;
@@ -2790,6 +2984,7 @@ rmv_port_callback(void *arg)
 	int need_to_start = 0;
 	int org_no_link_check = no_link_check;
 	portid_t port_id = (intptr_t)arg;
+	struct rte_device *dev;
 
 	RTE_ETH_VALID_PORTID_OR_RET(port_id);
 
@@ -2800,8 +2995,12 @@ rmv_port_callback(void *arg)
 	no_link_check = 1;
 	stop_port(port_id);
 	no_link_check = org_no_link_check;
+
+	/* Save rte_device pointer before closing ethdev port */
+	dev = rte_eth_devices[port_id].device;
 	close_port(port_id);
-	detach_port_device(port_id);
+	detach_device(dev); /* might be already removed or have more ports */
+
 	if (need_to_start)
 		start_packet_forwarding(0);
 }
@@ -3049,6 +3248,80 @@ rxtx_port_config(struct rte_port *port)
 	}
 }
 
+/*
+ * Helper function to arrange max_rx_pktlen value and JUMBO_FRAME offload,
+ * MTU is also aligned if JUMBO_FRAME offload is not set.
+ *
+ * port->dev_info should be set before calling this function.
+ *
+ * return 0 on success, negative on error
+ */
+int
+update_jumbo_frame_offload(portid_t portid)
+{
+	struct rte_port *port = &ports[portid];
+	uint32_t eth_overhead;
+	uint64_t rx_offloads;
+	int ret;
+	bool on;
+
+	/* Update the max_rx_pkt_len to have MTU as RTE_ETHER_MTU */
+	if (port->dev_info.max_mtu != UINT16_MAX &&
+	    port->dev_info.max_rx_pktlen > port->dev_info.max_mtu)
+		eth_overhead = port->dev_info.max_rx_pktlen -
+				port->dev_info.max_mtu;
+	else
+		eth_overhead = RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN;
+
+	rx_offloads = port->dev_conf.rxmode.offloads;
+
+	/* Default config value is 0 to use PMD specific overhead */
+	if (port->dev_conf.rxmode.max_rx_pkt_len == 0)
+		port->dev_conf.rxmode.max_rx_pkt_len = RTE_ETHER_MTU + eth_overhead;
+
+	if (port->dev_conf.rxmode.max_rx_pkt_len <= RTE_ETHER_MTU + eth_overhead) {
+		rx_offloads &= ~DEV_RX_OFFLOAD_JUMBO_FRAME;
+		on = false;
+	} else {
+		if ((port->dev_info.rx_offload_capa & DEV_RX_OFFLOAD_JUMBO_FRAME) == 0) {
+			printf("Frame size (%u) is not supported by port %u\n",
+				port->dev_conf.rxmode.max_rx_pkt_len,
+				portid);
+			return -1;
+		}
+		rx_offloads |= DEV_RX_OFFLOAD_JUMBO_FRAME;
+		on = true;
+	}
+
+	if (rx_offloads != port->dev_conf.rxmode.offloads) {
+		uint16_t qid;
+
+		port->dev_conf.rxmode.offloads = rx_offloads;
+
+		/* Apply JUMBO_FRAME offload configuration to Rx queue(s) */
+		for (qid = 0; qid < port->dev_info.nb_rx_queues; qid++) {
+			if (on)
+				port->rx_conf[qid].offloads |= DEV_RX_OFFLOAD_JUMBO_FRAME;
+			else
+				port->rx_conf[qid].offloads &= ~DEV_RX_OFFLOAD_JUMBO_FRAME;
+		}
+	}
+
+	/* If JUMBO_FRAME is set MTU conversion done by ethdev layer,
+	 * if unset do it here
+	 */
+	if ((rx_offloads & DEV_RX_OFFLOAD_JUMBO_FRAME) == 0) {
+		ret = rte_eth_dev_set_mtu(portid,
+				port->dev_conf.rxmode.max_rx_pkt_len - eth_overhead);
+		if (ret)
+			printf("Failed to set MTU to %u for port %u\n",
+				port->dev_conf.rxmode.max_rx_pkt_len - eth_overhead,
+				portid);
+	}
+
+	return 0;
+}
+
 void
 init_port_config(void)
 {
@@ -3184,6 +3457,8 @@ get_eth_dcb_conf(portid_t pid, struct rte_eth_conf *eth_conf,
 		struct rte_eth_dcb_tx_conf *tx_conf =
 				&eth_conf->tx_adv_conf.dcb_tx_conf;
 
+		memset(&rss_conf, 0, sizeof(struct rte_eth_rss_conf));
+
 		rc = rte_eth_dev_rss_hash_conf_get(pid, &rss_conf);
 		if (rc != 0)
 			return rc;
@@ -3570,5 +3845,10 @@ main(int argc, char** argv)
 			return 1;
 	}
 
-	return 0;
+	ret = rte_eal_cleanup();
+	if (ret != 0)
+		rte_exit(EXIT_FAILURE,
+			 "EAL cleanup failed: %s\n", strerror(-ret));
+
+	return EXIT_SUCCESS;
 }
diff --git a/dpdk/app/test-pmd/testpmd.h b/dpdk/app/test-pmd/testpmd.h
index 217d577018..4dbcee3a62 100644
--- a/dpdk/app/test-pmd/testpmd.h
+++ b/dpdk/app/test-pmd/testpmd.h
@@ -797,7 +797,7 @@ void stop_port(portid_t pid);
 void close_port(portid_t pid);
 void reset_port(portid_t pid);
 void attach_port(char *identifier);
-void detach_device(char *identifier);
+void detach_devargs(char *identifier);
 void detach_port_device(portid_t port_id);
 int all_ports_stopped(void);
 int port_is_stopped(portid_t port_id);
@@ -859,6 +859,8 @@ queueid_t get_allowed_max_nb_rxq(portid_t *pid);
 int check_nb_rxq(queueid_t rxq);
 queueid_t get_allowed_max_nb_txq(portid_t *pid);
 int check_nb_txq(queueid_t txq);
+int check_nb_rxd(queueid_t rxd);
+int check_nb_txd(queueid_t txd);
 queueid_t get_allowed_max_nb_hairpinq(portid_t *pid);
 int check_nb_hairpinq(queueid_t hairpinq);
 
@@ -881,6 +883,8 @@ uint16_t tx_pkt_set_md(uint16_t port_id, __rte_unused uint16_t queue,
 void add_tx_md_callback(portid_t portid);
 void remove_tx_md_callback(portid_t portid);
 
+int update_jumbo_frame_offload(portid_t portid);
+
 /*
  * Work-around of a compilation error with ICC on invocations of the
  * rte_be_to_cpu_16() function.
diff --git a/dpdk/app/test-pmd/txonly.c b/dpdk/app/test-pmd/txonly.c
index 3caf281cb8..a1822c631d 100644
--- a/dpdk/app/test-pmd/txonly.c
+++ b/dpdk/app/test-pmd/txonly.c
@@ -45,8 +45,8 @@ uint16_t tx_udp_src_port = 9;
 uint16_t tx_udp_dst_port = 9;
 
 /* use RFC5735 / RFC2544 reserved network test addresses */
-uint32_t tx_ip_src_addr = (192U << 24) | (18 << 16) | (0 << 8) | 1;
-uint32_t tx_ip_dst_addr = (192U << 24) | (18 << 16) | (0 << 8) | 2;
+uint32_t tx_ip_src_addr = (198U << 24) | (18 << 16) | (0 << 8) | 1;
+uint32_t tx_ip_dst_addr = (198U << 24) | (18 << 16) | (0 << 8) | 2;
 
 #define IP_DEFTTL  64   /* from RFC 1340. */
 
@@ -147,13 +147,40 @@ setup_pkt_udp_ip_headers(struct rte_ipv4_hdr *ip_hdr,
 	ip_hdr->hdr_checksum = (uint16_t) ip_cksum;
 }
 
+static inline void
+update_pkt_header(struct rte_mbuf *pkt, uint32_t total_pkt_len)
+{
+	struct rte_ipv4_hdr *ip_hdr;
+	struct rte_udp_hdr *udp_hdr;
+	uint16_t pkt_data_len;
+	uint16_t pkt_len;
+
+	pkt_data_len = (uint16_t) (total_pkt_len - (
+					sizeof(struct rte_ether_hdr) +
+					sizeof(struct rte_ipv4_hdr) +
+					sizeof(struct rte_udp_hdr)));
+	/* updata udp pkt length */
+	udp_hdr = rte_pktmbuf_mtod_offset(pkt, struct rte_udp_hdr *,
+				sizeof(struct rte_ether_hdr) +
+				sizeof(struct rte_ipv4_hdr));
+	pkt_len = (uint16_t) (pkt_data_len + sizeof(struct rte_udp_hdr));
+	udp_hdr->dgram_len = RTE_CPU_TO_BE_16(pkt_len);
+
+	/* updata ip pkt length and csum */
+	ip_hdr = rte_pktmbuf_mtod_offset(pkt, struct rte_ipv4_hdr *,
+				sizeof(struct rte_ether_hdr));
+	ip_hdr->hdr_checksum = 0;
+	pkt_len = (uint16_t) (pkt_len + sizeof(struct rte_ipv4_hdr));
+	ip_hdr->total_length = RTE_CPU_TO_BE_16(pkt_len);
+	ip_hdr->hdr_checksum = rte_ipv4_cksum(ip_hdr);
+}
+
 static inline bool
 pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
 		struct rte_ether_hdr *eth_hdr, const uint16_t vlan_tci,
 		const uint16_t vlan_tci_outer, const uint64_t ol_flags)
 {
 	struct rte_mbuf *pkt_segs[RTE_MAX_SEGS_PER_PKT];
-	uint8_t  ip_var = RTE_PER_LCORE(_ip_var);
 	struct rte_mbuf *pkt_seg;
 	uint32_t nb_segs, pkt_len;
 	uint8_t i;
@@ -192,6 +219,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
 	copy_buf_to_pkt(&pkt_ip_hdr, sizeof(pkt_ip_hdr), pkt,
 			sizeof(struct rte_ether_hdr));
 	if (txonly_multi_flow) {
+		uint8_t  ip_var = RTE_PER_LCORE(_ip_var);
 		struct rte_ipv4_hdr *ip_hdr;
 		uint32_t addr;
 
@@ -207,10 +235,15 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct rte_mempool *mbp,
 		 */
 		addr = (tx_ip_dst_addr | (ip_var++ << 8)) + rte_lcore_id();
 		ip_hdr->src_addr = rte_cpu_to_be_32(addr);
+		RTE_PER_LCORE(_ip_var) = ip_var;
 	}
 	copy_buf_to_pkt(&pkt_udp_hdr, sizeof(pkt_udp_hdr), pkt,
 			sizeof(struct rte_ether_hdr) +
 			sizeof(struct rte_ipv4_hdr));
+
+	if (unlikely(tx_pkt_split == TX_PKT_SPLIT_RND) || txonly_multi_flow)
+		update_pkt_header(pkt, pkt_len);
+
 	/*
 	 * Complete first mbuf of packet and append it to the
 	 * burst of packets to be transmitted.
@@ -314,7 +347,7 @@ pkt_burst_transmit(struct fwd_stream *fs)
 	fs->tx_packets += nb_tx;
 
 	if (txonly_multi_flow)
-		RTE_PER_LCORE(_ip_var) += nb_tx;
+		RTE_PER_LCORE(_ip_var) -= nb_pkt - nb_tx;
 
 #ifdef RTE_TEST_PMD_RECORD_BURST_STATS
 	fs->tx_burst_stats.pkt_burst_spread[nb_tx]++;
diff --git a/dpdk/app/test-pmd/util.c b/dpdk/app/test-pmd/util.c
index b514be5e16..487260d59d 100644
--- a/dpdk/app/test-pmd/util.c
+++ b/dpdk/app/test-pmd/util.c
@@ -1,6 +1,6 @@
 /* SPDX-License-Identifier: BSD-3-Clause
  * Copyright(c) 2010-2014 Intel Corporation
- * Copyright(c) 2018 Mellanox Technology
+ * Copyright 2018 Mellanox Technologies, Ltd
  */
 
 #include <stdio.h>
@@ -14,12 +14,23 @@
 
 #include "testpmd.h"
 
+#define MAX_STRING_LEN 8192
+
+#define MKDUMPSTR(buf, buf_size, cur_len, ...) \
+do { \
+	if (cur_len >= buf_size) \
+		break; \
+	cur_len += snprintf(buf + cur_len, buf_size - cur_len, __VA_ARGS__); \
+} while (0)
+
 static inline void
-print_ether_addr(const char *what, const struct rte_ether_addr *eth_addr)
+print_ether_addr(const char *what, const struct rte_ether_addr *eth_addr,
+		 char print_buf[], size_t buf_size, size_t *cur_len)
 {
 	char buf[RTE_ETHER_ADDR_FMT_SIZE];
+
 	rte_ether_format_addr(buf, RTE_ETHER_ADDR_FMT_SIZE, eth_addr);
-	printf("%s%s", what, buf);
+	MKDUMPSTR(print_buf, buf_size, *cur_len, "%s%s", what, buf);
 }
 
 static inline void
@@ -39,13 +50,15 @@ dump_pkt_burst(uint16_t port_id, uint16_t queue, struct rte_mbuf *pkts[],
 	uint16_t udp_port;
 	uint32_t vx_vni;
 	const char *reason;
+	char print_buf[MAX_STRING_LEN];
+	size_t buf_size = MAX_STRING_LEN;
+	size_t cur_len = 0;
 
 	if (!nb_pkts)
 		return;
-	printf("port %u/queue %u: %s %u packets\n",
-		port_id, queue,
-	       is_rx ? "received" : "sent",
-	       (unsigned int) nb_pkts);
+	MKDUMPSTR(print_buf, buf_size, cur_len,
+		  "port %u/queue %u: %s %u packets\n", port_id, queue,
+		  is_rx ? "received" : "sent", (unsigned int) nb_pkts);
 	for (i = 0; i < nb_pkts; i++) {
 		mb = pkts[i];
 		eth_hdr = rte_pktmbuf_read(mb, 0, sizeof(_eth_hdr), &_eth_hdr);
@@ -54,62 +67,84 @@ dump_pkt_burst(uint16_t port_id, uint16_t queue, struct rte_mbuf *pkts[],
 		packet_type = mb->packet_type;
 		is_encapsulation = RTE_ETH_IS_TUNNEL_PKT(packet_type);
 
-		print_ether_addr("  src=", &eth_hdr->s_addr);
-		print_ether_addr(" - dst=", &eth_hdr->d_addr);
-		printf(" - type=0x%04x - length=%u - nb_segs=%d",
-		       eth_type, (unsigned int) mb->pkt_len,
-		       (int)mb->nb_segs);
+		print_ether_addr("  src=", &eth_hdr->s_addr,
+				 print_buf, buf_size, &cur_len);
+		print_ether_addr(" - dst=", &eth_hdr->d_addr,
+				 print_buf, buf_size, &cur_len);
+		MKDUMPSTR(print_buf, buf_size, cur_len,
+			  " - type=0x%04x - length=%u - nb_segs=%d",
+			  eth_type, (unsigned int) mb->pkt_len,
+			  (int)mb->nb_segs);
 		if (ol_flags & PKT_RX_RSS_HASH) {
-			printf(" - RSS hash=0x%x", (unsigned int) mb->hash.rss);
-			printf(" - RSS queue=0x%x", (unsigned int) queue);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - RSS hash=0x%x",
+				  (unsigned int) mb->hash.rss);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - RSS queue=0x%x", (unsigned int) queue);
 		}
 		if (ol_flags & PKT_RX_FDIR) {
-			printf(" - FDIR matched ");
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - FDIR matched ");
 			if (ol_flags & PKT_RX_FDIR_ID)
-				printf("ID=0x%x",
-				       mb->hash.fdir.hi);
+				MKDUMPSTR(print_buf, buf_size, cur_len,
+					  "ID=0x%x", mb->hash.fdir.hi);
 			else if (ol_flags & PKT_RX_FDIR_FLX)
-				printf("flex bytes=0x%08x %08x",
-				       mb->hash.fdir.hi, mb->hash.fdir.lo);
+				MKDUMPSTR(print_buf, buf_size, cur_len,
+					  "flex bytes=0x%08x %08x",
+					  mb->hash.fdir.hi, mb->hash.fdir.lo);
 			else
-				printf("hash=0x%x ID=0x%x ",
-				       mb->hash.fdir.hash, mb->hash.fdir.id);
+				MKDUMPSTR(print_buf, buf_size, cur_len,
+					  "hash=0x%x ID=0x%x ",
+					  mb->hash.fdir.hash, mb->hash.fdir.id);
 		}
 		if (ol_flags & PKT_RX_TIMESTAMP)
-			printf(" - timestamp %"PRIu64" ", mb->timestamp);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - timestamp %"PRIu64" ", mb->timestamp);
 		if (ol_flags & PKT_RX_QINQ)
-			printf(" - QinQ VLAN tci=0x%x, VLAN tci outer=0x%x",
-			       mb->vlan_tci, mb->vlan_tci_outer);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - QinQ VLAN tci=0x%x, VLAN tci outer=0x%x",
+				  mb->vlan_tci, mb->vlan_tci_outer);
 		else if (ol_flags & PKT_RX_VLAN)
-			printf(" - VLAN tci=0x%x", mb->vlan_tci);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - VLAN tci=0x%x", mb->vlan_tci);
 		if (!is_rx && (ol_flags & PKT_TX_DYNF_METADATA))
-			printf(" - Tx metadata: 0x%x",
-			       *RTE_FLOW_DYNF_METADATA(mb));
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - Tx metadata: 0x%x",
+				  *RTE_FLOW_DYNF_METADATA(mb));
 		if (is_rx && (ol_flags & PKT_RX_DYNF_METADATA))
-			printf(" - Rx metadata: 0x%x",
-			       *RTE_FLOW_DYNF_METADATA(mb));
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - Rx metadata: 0x%x",
+				  *RTE_FLOW_DYNF_METADATA(mb));
 		if (mb->packet_type) {
 			rte_get_ptype_name(mb->packet_type, buf, sizeof(buf));
-			printf(" - hw ptype: %s", buf);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - hw ptype: %s", buf);
 		}
 		sw_packet_type = rte_net_get_ptype(mb, &hdr_lens,
 					RTE_PTYPE_ALL_MASK);
 		rte_get_ptype_name(sw_packet_type, buf, sizeof(buf));
-		printf(" - sw ptype: %s", buf);
+		MKDUMPSTR(print_buf, buf_size, cur_len, " - sw ptype: %s", buf);
 		if (sw_packet_type & RTE_PTYPE_L2_MASK)
-			printf(" - l2_len=%d", hdr_lens.l2_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len, " - l2_len=%d",
+				  hdr_lens.l2_len);
 		if (sw_packet_type & RTE_PTYPE_L3_MASK)
-			printf(" - l3_len=%d", hdr_lens.l3_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len, " - l3_len=%d",
+				  hdr_lens.l3_len);
 		if (sw_packet_type & RTE_PTYPE_L4_MASK)
-			printf(" - l4_len=%d", hdr_lens.l4_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len, " - l4_len=%d",
+				  hdr_lens.l4_len);
 		if (sw_packet_type & RTE_PTYPE_TUNNEL_MASK)
-			printf(" - tunnel_len=%d", hdr_lens.tunnel_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - tunnel_len=%d", hdr_lens.tunnel_len);
 		if (sw_packet_type & RTE_PTYPE_INNER_L2_MASK)
-			printf(" - inner_l2_len=%d", hdr_lens.inner_l2_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - inner_l2_len=%d", hdr_lens.inner_l2_len);
 		if (sw_packet_type & RTE_PTYPE_INNER_L3_MASK)
-			printf(" - inner_l3_len=%d", hdr_lens.inner_l3_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - inner_l3_len=%d", hdr_lens.inner_l3_len);
 		if (sw_packet_type & RTE_PTYPE_INNER_L4_MASK)
-			printf(" - inner_l4_len=%d", hdr_lens.inner_l4_len);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  " - inner_l4_len=%d", hdr_lens.inner_l4_len);
 		if (is_encapsulation) {
 			struct rte_ipv4_hdr *ipv4_hdr;
 			struct rte_ipv6_hdr *ipv6_hdr;
@@ -146,18 +181,27 @@ dump_pkt_burst(uint16_t port_id, uint16_t queue, struct rte_mbuf *pkts[],
 				l2_len + l3_len + l4_len);
 				udp_port = RTE_BE_TO_CPU_16(udp_hdr->dst_port);
 				vx_vni = rte_be_to_cpu_32(vxlan_hdr->vx_vni);
-				printf(" - VXLAN packet: packet type =%d, "
-				       "Destination UDP port =%d, VNI = %d",
-				       packet_type, udp_port, vx_vni >> 8);
+				MKDUMPSTR(print_buf, buf_size, cur_len,
+					  " - VXLAN packet: packet type =%d, "
+					  "Destination UDP port =%d, VNI = %d",
+					  packet_type, udp_port, vx_vni >> 8);
 			}
 		}
-		printf(" - %s queue=0x%x", is_rx ? "Receive" : "Send",
-			(unsigned int) queue);
-		printf("\n");
+		MKDUMPSTR(print_buf, buf_size, cur_len,
+			  " - %s queue=0x%x", is_rx ? "Receive" : "Send",
+			  (unsigned int) queue);
+		MKDUMPSTR(print_buf, buf_size, cur_len, "\n");
 		rte_get_rx_ol_flag_list(mb->ol_flags, buf, sizeof(buf));
-		printf("  ol_flags: %s\n", buf);
+		MKDUMPSTR(print_buf, buf_size, cur_len,
+			  "  ol_flags: %s\n", buf);
 		if (rte_mbuf_check(mb, 1, &reason) < 0)
-			printf("INVALID mbuf: %s\n", reason);
+			MKDUMPSTR(print_buf, buf_size, cur_len,
+				  "INVALID mbuf: %s\n", reason);
+		if (cur_len >= buf_size)
+			printf("%s ...\n", print_buf);
+		else
+			printf("%s", print_buf);
+		cur_len = 0;
 	}
 }
 
diff --git a/dpdk/app/test-sad/main.c b/dpdk/app/test-sad/main.c
index b01e84c570..8380fad744 100644
--- a/dpdk/app/test-sad/main.c
+++ b/dpdk/app/test-sad/main.c
@@ -617,7 +617,7 @@ main(int argc, char **argv)
 {
 	int ret;
 	struct rte_ipsec_sad *sad;
-	struct rte_ipsec_sad_conf conf;
+	struct rte_ipsec_sad_conf conf = {0};
 	unsigned int lcore_id;
 
 	ret = rte_eal_init(argc, argv);
diff --git a/dpdk/app/test/Makefile b/dpdk/app/test/Makefile
index 57930c00b1..30eff33206 100644
--- a/dpdk/app/test/Makefile
+++ b/dpdk/app/test/Makefile
@@ -122,7 +122,7 @@ SRCS-$(CONFIG_RTE_LIBRTE_HASH) += test_hash_perf.c
 SRCS-$(CONFIG_RTE_LIBRTE_HASH) += test_hash_functions.c
 SRCS-$(CONFIG_RTE_LIBRTE_HASH) += test_hash_multiwriter.c
 SRCS-$(CONFIG_RTE_LIBRTE_HASH) += test_hash_readwrite.c
-SRCS-$(CONFIG_RTE_LIBRTE_HASH) += test_hash_readwrite_lf.c
+SRCS-$(CONFIG_RTE_LIBRTE_HASH) += test_hash_readwrite_lf_perf.c
 
 SRCS-$(CONFIG_RTE_LIBRTE_RIB) += test_rib.c
 SRCS-$(CONFIG_RTE_LIBRTE_RIB) += test_rib6.c
@@ -151,8 +151,12 @@ SRCS-y += test_func_reentrancy.c
 
 SRCS-y += test_service_cores.c
 
+ifeq ($(CONFIG_RTE_LIBRTE_PMD_RING),y)
+SRCS-y += sample_packet_forward.c
 SRCS-$(CONFIG_RTE_LIBRTE_BITRATE) += test_bitratestats.c
 SRCS-$(CONFIG_RTE_LIBRTE_LATENCY_STATS) += test_latencystats.c
+SRCS-$(CONFIG_RTE_LIBRTE_PDUMP) += test_pdump.c
+endif
 
 SRCS-$(CONFIG_RTE_LIBRTE_CMDLINE) += test_cmdline.c
 SRCS-$(CONFIG_RTE_LIBRTE_CMDLINE) += test_cmdline_num.c
@@ -181,11 +185,8 @@ SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) += test_distributor_perf.c
 
 SRCS-$(CONFIG_RTE_LIBRTE_REORDER) += test_reorder.c
 
-SRCS-$(CONFIG_RTE_LIBRTE_PDUMP) += test_pdump.c
-
 SRCS-y += virtual_pmd.c
 SRCS-y += packet_burst_generator.c
-SRCS-y += sample_packet_forward.c
 SRCS-$(CONFIG_RTE_LIBRTE_ACL) += test_acl.c
 
 ifeq ($(CONFIG_RTE_LIBRTE_PMD_RING),y)
@@ -215,7 +216,7 @@ ifeq ($(CONFIG_RTE_LIBRTE_EVENTDEV),y)
 SRCS-y += test_eventdev.c
 SRCS-y += test_event_ring.c
 SRCS-y += test_event_eth_rx_adapter.c
-SRCS-y += test_event_eth_tx_adapter.c
+SRCS-$(CONFIG_RTE_LIBRTE_PMD_RING) += test_event_eth_tx_adapter.c
 SRCS-y += test_event_timer_adapter.c
 SRCS-y += test_event_crypto_adapter.c
 endif
@@ -268,13 +269,6 @@ endif
 endif
 endif
 
-# Link against shared libraries when needed
-ifeq ($(CONFIG_RTE_LIBRTE_PMD_BOND),y)
-ifneq ($(CONFIG_RTE_LIBRTE_PMD_RING),y)
-$(error Link bonding tests require CONFIG_RTE_LIBRTE_PMD_RING=y)
-endif
-endif
-
 ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
 
 ifeq ($(CONFIG_RTE_LIBRTE_PMD_BOND),y)
diff --git a/dpdk/app/test/autotest_data.py b/dpdk/app/test/autotest_data.py
index 6deb97bcc1..ca29b09f31 100644
--- a/dpdk/app/test/autotest_data.py
+++ b/dpdk/app/test/autotest_data.py
@@ -670,8 +670,8 @@
         "Report":  None,
     },
     {
-        "Name":    "Hash read-write lock-free concurrency autotest",
-        "Command": "hash_readwrite_lf_autotest",
+        "Name":    "Hash read-write lock-free concurrency perf autotest",
+        "Command": "hash_readwrite_lf_perf_autotest",
         "Func":    default_autotest,
         "Report":  None,
     },
diff --git a/dpdk/app/test/get-coremask.sh b/dpdk/app/test/get-coremask.sh
new file mode 100755
index 0000000000..bb8cf404d2
--- /dev/null
+++ b/dpdk/app/test/get-coremask.sh
@@ -0,0 +1,13 @@
+#! /bin/sh -e
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+
+if [ "$(uname)" = "Linux" ] ; then
+	cat /sys/devices/system/cpu/present
+elif [ "$(uname)" = "FreeBSD" ] ; then
+	ncpus=$(/sbin/sysctl -n hw.ncpu)
+	echo 0-$(expr $ncpus - 1)
+else
+# fallback
+	echo 0-3
+fi
diff --git a/dpdk/app/test/meson.build b/dpdk/app/test/meson.build
index fb49d804ba..24fb59f74f 100644
--- a/dpdk/app/test/meson.build
+++ b/dpdk/app/test/meson.build
@@ -7,13 +7,11 @@ endif
 
 test_sources = files('commands.c',
 	'packet_burst_generator.c',
-	'sample_packet_forward.c',
 	'test.c',
 	'test_acl.c',
 	'test_alarm.c',
 	'test_atomic.c',
 	'test_barrier.c',
-	'test_bitratestats.c',
 	'test_bpf.c',
 	'test_byteorder.c',
 	'test_cmdline.c',
@@ -43,7 +41,6 @@ test_sources = files('commands.c',
 	'test_event_crypto_adapter.c',
 	'test_event_eth_rx_adapter.c',
 	'test_event_ring.c',
-	'test_event_eth_tx_adapter.c',
 	'test_event_timer_adapter.c',
 	'test_eventdev.c',
 	'test_external_mem.c',
@@ -59,15 +56,13 @@ test_sources = files('commands.c',
 	'test_hash_multiwriter.c',
 	'test_hash_readwrite.c',
 	'test_hash_perf.c',
-	'test_hash_readwrite_lf.c',
+	'test_hash_readwrite_lf_perf.c',
 	'test_interrupts.c',
 	'test_ipsec.c',
 	'test_ipsec_sad.c',
 	'test_kni.c',
 	'test_kvargs.c',
-	'test_latencystats.c',
 	'test_link_bonding.c',
-	'test_link_bonding_mode4.c',
 	'test_link_bonding_rssconf.c',
 	'test_logs.c',
 	'test_lpm.c',
@@ -88,11 +83,8 @@ test_sources = files('commands.c',
 	'test_metrics.c',
 	'test_mcslock.c',
 	'test_mp_secondary.c',
-	'test_pdump.c',
 	'test_per_lcore.c',
 	'test_pmd_perf.c',
-	'test_pmd_ring.c',
-	'test_pmd_ring_perf.c',
 	'test_power.c',
 	'test_power_cpufreq.c',
 	'test_power_kvm_vm.c',
@@ -162,92 +154,89 @@ test_deps = ['acl',
 	'timer'
 ]
 
-fast_test_names = [
-        'acl_autotest',
-        'alarm_autotest',
-        'atomic_autotest',
-        'byteorder_autotest',
-        'cmdline_autotest',
-        'common_autotest',
-        'cpuflags_autotest',
-        'cycles_autotest',
-        'debug_autotest',
-        'eal_flags_c_opt_autotest',
-        'eal_flags_master_opt_autotest',
-        'eal_flags_n_opt_autotest',
-        'eal_flags_hpet_autotest',
-        'eal_flags_no_huge_autotest',
-        'eal_flags_w_opt_autotest',
-        'eal_flags_b_opt_autotest',
-        'eal_flags_vdev_opt_autotest',
-        'eal_flags_r_opt_autotest',
-        'eal_flags_mem_autotest',
-        'eal_flags_file_prefix_autotest',
-        'eal_flags_misc_autotest',
-        'eal_fs_autotest',
-        'errno_autotest',
-        'event_ring_autotest',
-        'fib_autotest',
-        'fib6_autotest',
-        'func_reentrancy_autotest',
-        'flow_classify_autotest',
-        'hash_autotest',
-        'interrupt_autotest',
-        'logs_autotest',
-        'lpm_autotest',
-        'lpm6_autotest',
-        'malloc_autotest',
-        'mbuf_autotest',
-        'mcslock_autotest',
-        'memcpy_autotest',
-        'memory_autotest',
-        'mempool_autotest',
-        'memzone_autotest',
-        'meter_autotest',
-        'multiprocess_autotest',
-        'per_lcore_autotest',
-        'prefetch_autotest',
-        'rcu_qsbr_autotest',
-        'red_autotest',
-        'rib_autotest',
-        'rib6_autotest',
-        'ring_autotest',
-        'ring_pmd_autotest',
-        'rwlock_test1_autotest',
-        'rwlock_rda_autotest',
-        'rwlock_rds_wrm_autotest',
-        'rwlock_rde_wro_autotest',
-        'sched_autotest',
-        'spinlock_autotest',
-        'stack_autotest',
-        'stack_lf_autotest',
-        'string_autotest',
-        'table_autotest',
-        'tailq_autotest',
-        'timer_autotest',
-        'user_delay_us',
-        'version_autotest',
-        'bitratestats_autotest',
-        'crc_autotest',
-        'delay_us_sleep_autotest',
-        'distributor_autotest',
-        'eventdev_common_autotest',
-        'fbarray_autotest',
-        'hash_readwrite_autotest',
-        'hash_readwrite_lf_autotest',
-        'ipsec_autotest',
-        'kni_autotest',
-        'kvargs_autotest',
-        'latencystats_autotest',
-        'member_autotest',
-        'metrics_autotest',
-        'pdump_autotest',
-        'power_cpufreq_autotest',
-        'power_autotest',
-        'power_kvm_vm_autotest',
-        'reorder_autotest',
-        'service_autotest',
-        'thash_autotest',
+# Each test is marked with flag true/false
+# to indicate whether it can run in no-huge mode.
+fast_tests = [
+        ['acl_autotest', true],
+        ['alarm_autotest', false],
+        ['atomic_autotest', false],
+        ['byteorder_autotest', true],
+        ['cmdline_autotest', true],
+        ['common_autotest', true],
+        ['cpuflags_autotest', true],
+        ['cycles_autotest', true],
+        ['debug_autotest', true],
+        ['eal_flags_c_opt_autotest', false],
+        ['eal_flags_master_opt_autotest', false],
+        ['eal_flags_n_opt_autotest', false],
+        ['eal_flags_hpet_autotest', false],
+        ['eal_flags_no_huge_autotest', false],
+        ['eal_flags_w_opt_autotest', false],
+        ['eal_flags_b_opt_autotest', false],
+        ['eal_flags_vdev_opt_autotest', false],
+        ['eal_flags_r_opt_autotest', false],
+        ['eal_flags_mem_autotest', false],
+        ['eal_flags_file_prefix_autotest', false],
+        ['eal_flags_misc_autotest', false],
+        ['eal_fs_autotest', true],
+        ['errno_autotest', true],
+        ['event_ring_autotest', true],
+        ['fib_autotest', true],
+        ['fib6_autotest', true],
+        ['func_reentrancy_autotest', false],
+        ['flow_classify_autotest', false],
+        ['hash_autotest', true],
+        ['interrupt_autotest', true],
+        ['logs_autotest', true],
+        ['lpm_autotest', true],
+        ['lpm6_autotest', true],
+        ['malloc_autotest', false],
+        ['mbuf_autotest', false],
+        ['mcslock_autotest', false],
+        ['memcpy_autotest', true],
+        ['memory_autotest', false],
+        ['mempool_autotest', false],
+        ['memzone_autotest', false],
+        ['meter_autotest', true],
+        ['multiprocess_autotest', false],
+        ['per_lcore_autotest', true],
+        ['prefetch_autotest', true],
+        ['rcu_qsbr_autotest', true],
+        ['red_autotest', true],
+        ['rib_autotest', true],
+        ['rib6_autotest', true],
+        ['ring_autotest', true],
+        ['rwlock_test1_autotest', true],
+        ['rwlock_rda_autotest', true],
+        ['rwlock_rds_wrm_autotest', true],
+        ['rwlock_rde_wro_autotest', true],
+        ['sched_autotest', true],
+        ['spinlock_autotest', true],
+        ['stack_autotest', false],
+        ['stack_lf_autotest', false],
+        ['string_autotest', true],
+        ['table_autotest', true],
+        ['tailq_autotest', true],
+        ['timer_autotest', false],
+        ['user_delay_us', true],
+        ['version_autotest', true],
+        ['crc_autotest', true],
+        ['delay_us_sleep_autotest', true],
+        ['distributor_autotest', false],
+        ['eventdev_common_autotest', true],
+        ['fbarray_autotest', true],
+        ['hash_readwrite_autotest', false],
+        ['ipsec_autotest', true],
+        ['kni_autotest', false],
+        ['kvargs_autotest', true],
+        ['member_autotest', true],
+        ['metrics_autotest', true],
+        ['power_cpufreq_autotest', false],
+        ['power_autotest', true],
+        ['power_kvm_vm_autotest', false],
+        ['reorder_autotest', true],
+        ['service_autotest', true],
+        ['thash_autotest', true],
 ]
 
 perf_test_names = [
@@ -277,11 +266,11 @@ perf_test_names = [
         'rcu_qsbr_perf_autotest',
         'red_perf',
         'distributor_perf_autotest',
-        'ring_pmd_perf_autotest',
         'pmd_perf_autotest',
         'stack_perf_autotest',
         'stack_lf_perf_autotest',
         'rand_perf_autotest',
+        'hash_readwrite_lf_perf_autotest',
 ]
 
 driver_test_names = [
@@ -302,7 +291,6 @@ driver_test_names = [
         'eventdev_selftest_octeontx',
         'eventdev_selftest_sw',
         'link_bonding_autotest',
-        'link_bonding_mode4_autotest',
         'link_bonding_rssconf_autotest',
         'rawdev_autotest',
 ]
@@ -336,9 +324,26 @@ endif
 # they are used via a driver-specific API.
 if dpdk_conf.has('RTE_LIBRTE_BOND_PMD')
 	test_deps += 'pmd_bond'
+	if dpdk_conf.has('RTE_LIBRTE_RING_PMD')
+		test_sources += 'test_link_bonding_mode4.c'
+		driver_test_names += 'link_bonding_mode4_autotest'
+	endif
 endif
 if dpdk_conf.has('RTE_LIBRTE_RING_PMD')
 	test_deps += 'pmd_ring'
+	test_sources += 'test_pmd_ring_perf.c'
+	test_sources += 'test_pmd_ring.c'
+	test_sources += 'test_event_eth_tx_adapter.c'
+	test_sources += 'test_bitratestats.c'
+	test_sources += 'test_latencystats.c'
+	test_sources += 'sample_packet_forward.c'
+	test_sources += 'test_pdump.c'
+	fast_tests += [['ring_pmd_autotest', true]]
+	perf_test_names += 'ring_pmd_perf_autotest'
+	fast_tests += [['event_eth_tx_adapter_autotest', false]]
+	fast_tests += [['bitratestats_autotest', true]]
+	fast_tests += [['latencystats_autotest', true]]
+	fast_tests += [['pdump_autotest', true]]
 endif
 
 if dpdk_conf.has('RTE_LIBRTE_POWER')
@@ -359,19 +364,23 @@ endif
 # specify -D_GNU_SOURCE unconditionally
 cflags += '-D_GNU_SOURCE'
 
+# Enable using internal APIs in unit tests
+cflags += ['-DALLOW_INTERNAL_API']
+
 test_dep_objs = []
 if dpdk_conf.has('RTE_LIBRTE_COMPRESSDEV')
-	compress_test_dep = dependency('zlib', required: false)
+	compress_test_dep = dependency('zlib', required: false, method: 'pkg-config')
 	if compress_test_dep.found()
 		test_dep_objs += compress_test_dep
 		test_sources += 'test_compressdev.c'
 		test_deps += 'compressdev'
-		fast_test_names += 'compressdev_autotest'
+		fast_tests += [['compressdev_autotest', false]]
 	endif
 endif
 
-if dpdk_conf.has('RTE_LIBRTE_PMD_CRYPTO_SCHEDULER')
+if dpdk_conf.has('RTE_LIBRTE_CRYPTO_SCHEDULER_PMD')
 	driver_test_names += 'cryptodev_scheduler_autotest'
+	test_deps += 'pmd_crypto_scheduler'
 endif
 
 foreach d:test_deps
@@ -382,7 +391,7 @@ test_dep_objs += cc.find_library('execinfo', required: false)
 
 link_libs = []
 if get_option('default_library') == 'static'
-	link_libs = dpdk_drivers
+	link_libs = dpdk_static_libraries + dpdk_drivers
 endif
 
 dpdk_test = executable('dpdk-test',
@@ -390,53 +399,66 @@ dpdk_test = executable('dpdk-test',
 	link_whole: link_libs,
 	dependencies: test_dep_objs,
 	c_args: [cflags, '-DALLOW_EXPERIMENTAL_API'],
-	install_rpath: driver_install_path,
+	install_rpath: join_paths(get_option('prefix'),
+			 driver_install_path),
 	install: true)
 
+has_hugepage = true
+if is_linux
+	check_hugepage = run_command('cat',
+				     '/proc/sys/vm/nr_hugepages')
+	if (check_hugepage.returncode() != 0 or
+	    check_hugepage.stdout().strip() == '0')
+		has_hugepage = false
+	endif
+endif
+message('hugepage availability: @0@'.format(has_hugepage))
+
 # some perf tests (eg: memcpy perf autotest)take very long
 # to complete, so timeout to 10 minutes
 timeout_seconds = 600
 timeout_seconds_fast = 10
 
-# Retrieve the number of CPU cores, defaulting to 4.
-num_cores = '0-3'
-if host_machine.system() == 'linux'
-	num_cores = run_command('cat',
-				'/sys/devices/system/cpu/present'
-			       ).stdout().strip()
-elif host_machine.system() == 'freebsd'
-	snum_cores = run_command('/sbin/sysctl', '-n',
-				 'hw.ncpu').stdout().strip()
-	inum_cores = snum_cores.to_int() - 1
-        num_cores = '0-@0@'.format(inum_cores)
-endif
+get_coremask = find_program('get-coremask.sh')
+num_cores_arg = '-l ' + run_command(get_coremask).stdout().strip()
 
-num_cores_arg = '-l ' + num_cores
+default_test_args = [num_cores_arg]
 
-test_args = [num_cores_arg]
-foreach arg : fast_test_names
-	if host_machine.system() == 'linux'
-		test(arg, dpdk_test,
-			  env : ['DPDK_TEST=' + arg],
-			  args : test_args +
-				 ['--file-prefix=@0@'.format(arg)],
-		timeout : timeout_seconds_fast,
-		is_parallel : false,
-		suite : 'fast-tests')
-	else
-		test(arg, dpdk_test,
-			env : ['DPDK_TEST=' + arg],
+foreach arg : fast_tests
+	test_args = default_test_args
+	run_test = true
+	if not has_hugepage
+		if arg[1]
+			test_args += ['--no-huge', '-m', '2048']
+		else
+			run_test = false
+		endif
+	endif
+
+	if (get_option('default_library') == 'shared' and
+		arg[0] == 'event_eth_tx_adapter_autotest')
+		foreach drv:dpdk_drivers
+			test_args += ['-d', drv.full_path().split('.a')[0] + '.so']
+		endforeach
+	endif
+	if is_linux
+		test_args += ['--file-prefix=@0@'.format(arg[0])]
+	endif
+
+	if run_test
+		test(arg[0], dpdk_test,
+			env : ['DPDK_TEST=' + arg[0]],
 			args : test_args,
-		timeout : timeout_seconds_fast,
-		is_parallel : false,
-		suite : 'fast-tests')
+			timeout : timeout_seconds_fast,
+			is_parallel : false,
+			suite : 'fast-tests')
 	endif
 endforeach
 
 foreach arg : perf_test_names
 	test(arg, dpdk_test,
 	env : ['DPDK_TEST=' + arg],
-	args : test_args,
+	args : default_test_args,
 	timeout : timeout_seconds,
 	is_parallel : false,
 	suite : 'perf-tests')
@@ -445,7 +467,7 @@ endforeach
 foreach arg : driver_test_names
 	test(arg, dpdk_test,
 		env : ['DPDK_TEST=' + arg],
-		args : test_args,
+		args : default_test_args,
 		timeout : timeout_seconds,
 		is_parallel : false,
 		suite : 'driver-tests')
@@ -454,7 +476,7 @@ endforeach
 foreach arg : dump_test_names
 	test(arg, dpdk_test,
 		env : ['DPDK_TEST=' + arg],
-		args : test_args,
+		args : default_test_args,
 		timeout : timeout_seconds,
 		is_parallel : false,
 		suite : 'debug-tests')
diff --git a/dpdk/app/test/process.h b/dpdk/app/test/process.h
index 191d2796a9..c3b3780337 100644
--- a/dpdk/app/test/process.h
+++ b/dpdk/app/test/process.h
@@ -25,10 +25,12 @@
 #endif
 
 #ifdef RTE_LIBRTE_PDUMP
+#ifdef RTE_LIBRTE_RING_PMD
 #include <pthread.h>
 extern void *send_pkts(void *empty);
 extern uint16_t flag_for_send_pkts;
 #endif
+#endif
 
 /*
  * launches a second copy of the test process using the given argv parameters,
@@ -44,7 +46,9 @@ process_dup(const char *const argv[], int numargs, const char *env_value)
 	int i, status;
 	char path[32];
 #ifdef RTE_LIBRTE_PDUMP
+#ifdef RTE_LIBRTE_RING_PMD
 	pthread_t thread;
+#endif
 #endif
 
 	pid_t pid = fork();
@@ -121,17 +125,21 @@ process_dup(const char *const argv[], int numargs, const char *env_value)
 	}
 	/* parent process does a wait */
 #ifdef RTE_LIBRTE_PDUMP
+#ifdef RTE_LIBRTE_RING_PMD
 	if ((strcmp(env_value, "run_pdump_server_tests") == 0))
 		pthread_create(&thread, NULL, &send_pkts, NULL);
+#endif
 #endif
 
 	while (wait(&status) != pid)
 		;
 #ifdef RTE_LIBRTE_PDUMP
+#ifdef RTE_LIBRTE_RING_PMD
 	if ((strcmp(env_value, "run_pdump_server_tests") == 0)) {
 		flag_for_send_pkts = 0;
 		pthread_join(thread, NULL);
 	}
+#endif
 #endif
 	return status;
 }
diff --git a/dpdk/app/test/test.c b/dpdk/app/test/test.c
index cd7aaf645f..4736a17ff3 100644
--- a/dpdk/app/test/test.c
+++ b/dpdk/app/test/test.c
@@ -53,7 +53,9 @@ do_recursive_call(void)
 	} actions[] =  {
 			{ "run_secondary_instances", test_mp_secondary },
 #ifdef RTE_LIBRTE_PDUMP
+#ifdef RTE_LIBRTE_RING_PMD
 			{ "run_pdump_server_tests", test_pdump },
+#endif
 #endif
 			{ "test_missing_c_flag", no_action },
 			{ "test_master_lcore_flag", no_action },
@@ -162,29 +164,38 @@ main(int argc, char **argv)
 
 
 #ifdef RTE_LIBRTE_CMDLINE
-	cl = cmdline_stdin_new(main_ctx, "RTE>>");
-	if (cl == NULL) {
-		ret = -1;
-		goto out;
-	}
-
 	char *dpdk_test = getenv("DPDK_TEST");
 	if (dpdk_test && strlen(dpdk_test)) {
 		char buf[1024];
+
+		cl = cmdline_new(main_ctx, "RTE>>", 0, 1);
+		if (cl == NULL) {
+			ret = -1;
+			goto out;
+		}
+
 		snprintf(buf, sizeof(buf), "%s\n", dpdk_test);
 		if (cmdline_in(cl, buf, strlen(buf)) < 0) {
 			printf("error on cmdline input\n");
+
+			ret = -1;
+		} else {
+			ret = last_test_result;
+		}
+		cmdline_free(cl);
+		goto out;
+	} else {
+		/* if no DPDK_TEST env variable, go interactive */
+		cl = cmdline_stdin_new(main_ctx, "RTE>>");
+		if (cl == NULL) {
 			ret = -1;
 			goto out;
 		}
 
+		cmdline_interact(cl);
 		cmdline_stdin_exit(cl);
-		ret = last_test_result;
-		goto out;
+		cmdline_free(cl);
 	}
-	/* if no DPDK_TEST env variable, go interactive */
-	cmdline_interact(cl);
-	cmdline_stdin_exit(cl);
 #endif
 	ret = 0;
 
diff --git a/dpdk/app/test/test.h b/dpdk/app/test/test.h
index ac0c50616c..b07f6c1ef0 100644
--- a/dpdk/app/test/test.h
+++ b/dpdk/app/test/test.h
@@ -22,8 +22,6 @@
 # define TEST_TRACE_FAILURE(_file, _line, _func)
 #endif
 
-#define RTE_TEST_TRACE_FAILURE TEST_TRACE_FAILURE
-
 #include <rte_test.h>
 
 #define TEST_ASSERT RTE_TEST_ASSERT
diff --git a/dpdk/app/test/test_acl.c b/dpdk/app/test/test_acl.c
index 9cd9e37dbe..b78b67193a 100644
--- a/dpdk/app/test/test_acl.c
+++ b/dpdk/app/test/test_acl.c
@@ -1394,16 +1394,18 @@ test_invalid_parameters(void)
 	} else
 		rte_acl_free(acx);
 
-	/* invalid NUMA node */
-	memcpy(&param, &acl_param, sizeof(param));
-	param.socket_id = RTE_MAX_NUMA_NODES + 1;
-
-	acx = rte_acl_create(&param);
-	if (acx != NULL) {
-		printf("Line %i: ACL context creation with invalid NUMA "
-				"should have failed!\n", __LINE__);
-		rte_acl_free(acx);
-		return -1;
+	if (rte_eal_has_hugepages()) {
+		/* invalid NUMA node */
+		memcpy(&param, &acl_param, sizeof(param));
+		param.socket_id = RTE_MAX_NUMA_NODES + 1;
+
+		acx = rte_acl_create(&param);
+		if (acx != NULL) {
+			printf("Line %i: ACL context creation with invalid "
+					"NUMA should have failed!\n", __LINE__);
+			rte_acl_free(acx);
+			return -1;
+		}
 	}
 
 	/* NULL name */
diff --git a/dpdk/app/test/test_bpf.c b/dpdk/app/test/test_bpf.c
index ee534687a6..4a61a7d7cb 100644
--- a/dpdk/app/test/test_bpf.c
+++ b/dpdk/app/test/test_bpf.c
@@ -1797,13 +1797,6 @@ test_call1_check(uint64_t rc, const void *arg)
 	dummy_func1(arg, &v32, &v64);
 	v64 += v32;
 
-	if (v64 != rc) {
-		printf("%s@%d: invalid return value "
-			"expected=0x%" PRIx64 ", actual=0x%" PRIx64 "\n",
-			__func__, __LINE__, v64, rc);
-		return -1;
-	}
-	return 0;
 	return cmp_res(__func__, v64, rc, dv, dv, sizeof(*dv));
 }
 
@@ -1934,13 +1927,7 @@ test_call2_check(uint64_t rc, const void *arg)
 	dummy_func2(&a, &b);
 	v = a.u64 + a.u32 + b.u16 + b.u8;
 
-	if (v != rc) {
-		printf("%s@%d: invalid return value "
-			"expected=0x%" PRIx64 ", actual=0x%" PRIx64 "\n",
-			__func__, __LINE__, v, rc);
-		return -1;
-	}
-	return 0;
+	return cmp_res(__func__, v, rc, arg, arg, 0);
 }
 
 static const struct rte_bpf_xsym test_call2_xsym[] = {
@@ -2429,7 +2416,6 @@ test_call5_check(uint64_t rc, const void *arg)
 	v = 0;
 
 fail:
-
 	return cmp_res(__func__, v, rc, &v, &rc, sizeof(v));
 }
 
@@ -2458,6 +2444,7 @@ static const struct rte_bpf_xsym test_call5_xsym[] = {
 	},
 };
 
+/* all bpf test cases */
 static const struct bpf_test tests[] = {
 	{
 		.name = "test_store1",
@@ -2738,7 +2725,6 @@ run_test(const struct bpf_test *tst)
 	}
 
 	tst->prepare(tbuf);
-
 	rc = rte_bpf_exec(bpf, tbuf);
 	ret = tst->check_result(rc, tbuf);
 	if (ret != 0) {
@@ -2746,17 +2732,20 @@ run_test(const struct bpf_test *tst)
 			__func__, __LINE__, tst->name, ret, strerror(ret));
 	}
 
+	/* repeat the same test with jit, when possible */
 	rte_bpf_get_jit(bpf, &jit);
-	if (jit.func == NULL)
-		return 0;
-
-	tst->prepare(tbuf);
-	rc = jit.func(tbuf);
-	rv = tst->check_result(rc, tbuf);
-	ret |= rv;
-	if (rv != 0) {
-		printf("%s@%d: check_result(%s) failed, error: %d(%s);\n",
-			__func__, __LINE__, tst->name, rv, strerror(ret));
+	if (jit.func != NULL) {
+
+		tst->prepare(tbuf);
+		rc = jit.func(tbuf);
+		rv = tst->check_result(rc, tbuf);
+		ret |= rv;
+		if (rv != 0) {
+			printf("%s@%d: check_result(%s) failed, "
+				"error: %d(%s);\n",
+				__func__, __LINE__, tst->name,
+				rv, strerror(ret));
+		}
 	}
 
 	rte_bpf_destroy(bpf);
diff --git a/dpdk/app/test/test_common.c b/dpdk/app/test/test_common.c
index 2b856f8ba5..12bd1cad90 100644
--- a/dpdk/app/test/test_common.c
+++ b/dpdk/app/test/test_common.c
@@ -216,7 +216,19 @@ test_log2(void)
 	const uint32_t max = 0x10000;
 	const uint32_t step = 1;
 
-	for (i = 0; i < max; i = i + step) {
+	compare = rte_log2_u32(0);
+	if (compare != 0) {
+		printf("Wrong rte_log2_u32(0) val %x, expected 0\n", compare);
+		return TEST_FAILED;
+	}
+
+	compare = rte_log2_u64(0);
+	if (compare != 0) {
+		printf("Wrong rte_log2_u64(0) val %x, expected 0\n", compare);
+		return TEST_FAILED;
+	}
+
+	for (i = 1; i < max; i = i + step) {
 		uint64_t i64;
 
 		/* extend range for 64-bit */
diff --git a/dpdk/app/test/test_compressdev_test_buffer.h b/dpdk/app/test/test_compressdev_test_buffer.h
index c0492f89a2..d241602445 100644
--- a/dpdk/app/test/test_compressdev_test_buffer.h
+++ b/dpdk/app/test/test_compressdev_test_buffer.h
@@ -1,3 +1,7 @@
+/* SPDX-License-Identifier: (BSD-3-Clause)
+ * Copyright(c) 2018-2020 Intel Corporation
+ */
+
 #ifndef TEST_COMPRESSDEV_TEST_BUFFERS_H_
 #define TEST_COMPRESSDEV_TEST_BUFFERS_H_
 
@@ -190,106 +194,104 @@ static const char test_buf_shakespeare[] =
 	"\n"
 	"ORLANDO	Go apart, Adam, and thou shalt hear how he will\n";
 
-/* Snippet of source code in Pascal */
-static const char test_buf_pascal[] =
-	"	Ptr    = 1..DMem;\n"
-	"	Loc    = 1..IMem;\n"
-	"	Loc0   = 0..IMem;\n"
-	"	EdgeT  = (hout,lin,hin,lout); {Warning this order is important in}\n"
-	"				      {predicates such as gtS,geS}\n"
-	"	CardT  = (finite,infinite);\n"
-	"	ExpT   = Minexp..Maxexp;\n"
-	"	ManT   = Mininf..Maxinf; \n"
-	"	Pflag  = (PNull,PSoln,PTrace,PPrint);\n"
-	"	Sreal  = record\n"
-	"		    edge:EdgeT;\n"
-	"		    cardinality:CardT;\n"
-	"		    exp:ExpT; {exponent}\n"
-	"		    mantissa:ManT;\n"
-	"		 end;\n"
-	"	Int    = record\n"
-	"		    hi:Sreal;\n"
-	"		    lo:Sreal;\n"
-	"	 end;\n"
-	"	Instr  = record\n"
-	"		    Code:OpType;\n"
-	"		    Pars: array[0..Par] of 0..DMem;\n"
-	"		 end;\n"
-	"	DataMem= record\n"
-	"		    D        :array [Ptr] of Int;\n"
-	"		    S        :array [Loc] of State;\n"
-	"		    LastHalve:Loc;\n"
-	"		    RHalve   :array [Loc] of real;\n"
-	"		 end;\n"
-	"	DataFlags=record\n"
-	"		    PF	     :array [Ptr] of Pflag;\n"
-	"		 end;\n"
-	"var\n"
-	"	Debug  : (none,activity,post,trace,dump);\n"
-	"	Cut    : (once,all);\n"
-	"	GlobalEnd,Verifiable:boolean;\n"
-	"	HalveThreshold:real;\n"
-	"	I      : array [Loc] of Instr; {Memory holding instructions}\n"
-	"	End    : Loc; {last instruction in I}\n"
-	"	ParN   : array [OpType] of -1..Par; {number of parameters for each \n"
-	"			opcode. -1 means no result}\n"
-	"        ParIntersect : array [OpType] of boolean ;\n"
-	"	DInit  : DataMem; {initial memory which is cleared and \n"
-	"				used in first call}\n"
-	"	DF     : DataFlags; {hold flags for variables, e.g. print/trace}\n"
-	"	MaxDMem:0..DMem;\n"
-	"	Shift  : array[0..Digits] of 1..maxint;{array of constant multipliers}\n"
-	"						{used for alignment etc.}\n"
-	"	Dummy  :Positive;\n"
-	"	{constant intervals and Sreals}\n"
-	"	PlusInfS,MinusInfS,PlusSmallS,MinusSmallS,ZeroS,\n"
-	"	PlusFiniteS,MinusFiniteS:Sreal;\n"
-	"	Zero,All,AllFinite:Int;\n"
-	"\n"
-	"procedure deblank;\n"
-	"var Ch:char;\n"
-	"begin\n"
-	"   while (not eof) and (input^ in [' ','	']) do read(Ch);\n"
-	"end;\n"
-	"\n"
-	"procedure InitialOptions;\n"
-	"\n"
-	"#include '/user/profs/cleary/bin/options.i';\n"
-	"\n"
-	"   procedure Option;\n"
-	"   begin\n"
-	"      case Opt of\n"
-	"      'a','A':Debug:=activity;\n"
-	"      'd','D':Debug:=dump;\n"
-	"      'h','H':HalveThreshold:=StringNum/100;\n"
-	"      'n','N':Debug:=none;\n"
-	"      'p','P':Debug:=post;\n"
-	"      't','T':Debug:=trace;\n"
-	"      'v','V':Verifiable:=true;\n"
-	"      end;\n"
-	"   end;\n"
-	"\n"
-	"begin\n"
-	"   Debug:=trace;\n"
-	"   Verifiable:=false;\n"
-	"   HalveThreshold:=67/100;\n"
-	"   Options;\n"
-	"   writeln(Debug);\n"
-	"   writeln('Verifiable:',Verifiable);\n"
-	"   writeln('Halve threshold',HalveThreshold);\n"
-	"end;{InitialOptions}\n"
-	"\n"
-	"procedure NormalizeUp(E,M:integer;var S:Sreal;var Closed:boolean);\n"
-	"begin\n"
-	"with S do\n"
-	"begin\n"
-	"   if M=0 then S:=ZeroS else\n"
-	"   if M>0 then\n";
+/* Snippet of Alice's Adventures in Wonderland */
+static const char test_buf_alice2[] =
+	"`Curiouser and curiouser!' cried Alice (she was so much\n"
+	"surprised, that for the moment she quite forgot how to speak good\n"
+	"English); `now I'm opening out like the largest telescope that\n"
+	"ever was!  Good-bye, feet!' (for when she looked down at her\n"
+	"feet, they seemed to be almost out of sight, they were getting so\n"
+	"far off).  `Oh, my poor little feet, I wonder who will put on\n"
+	"your shoes and stockings for you now, dears?  I'm sure _I_ shan't\n"
+	"be able!  I shall be a great deal too far off to trouble myself\n"
+	"about you:  you must manage the best way you can; --but I must be\n"
+	"kind to them,' thought Alice, `or perhaps they won't walk the\n"
+	"way I want to go!  Let me see:  I'll give them a new pair of\n"
+	"boots every Christmas.'\n"
+	"\n"
+	"  And she went on planning to herself how she would manage it.\n"
+	"`They must go by the carrier,' she thought; `and how funny it'll\n"
+	"seem, sending presents to one's own feet!  And how odd the\n"
+	"directions will look!\n"
+	"\n"
+	"	    ALICE'S RIGHT FOOT, ESQ.\n"
+	"		HEARTHRUG,\n"
+	"		    NEAR THE FENDER,\n"
+	"			(WITH ALICE'S LOVE).\n"
+	"\n"
+	"Oh dear, what nonsense I'm talking!'\n"
+	"\n"
+	"  Just then her head struck against the roof of the hall:  in\n"
+	"fact she was now more than nine feet high, and she at once took\n"
+	"up the little golden key and hurried off to the garden door.\n"
+	"\n"
+	"  Poor Alice!  It was as much as she could do, lying down on one\n"
+	"side, to look through into the garden with one eye; but to get\n"
+	"through was more hopeless than ever:  she sat down and began to\n"
+	"cry again.\n"
+	"\n"
+	"  `You ought to be ashamed of yourself,' said Alice, `a great\n"
+	"girl like you,' (she might well say this), `to go on crying in\n"
+	"this way!  Stop this moment, I tell you!'  But she went on all\n"
+	"the same, shedding gallons of tears, until there was a large pool\n"
+	"all round her, about four inches deep and reaching half down the\n"
+	"hall.\n"
+	"\n"
+	" After a time she heard a little pattering of feet in the\n"
+	"distance, and she hastily dried her eyes to see what was coming.\n"
+	"It was the White Rabbit returning, splendidly dressed, with a\n"
+	"pair of white kid gloves in one hand and a large fan in the\n"
+	"other:  he came trotting along in a great hurry, muttering to\n"
+	"himself as he came, `Oh! the Duchess, the Duchess! Oh! won't she\n"
+	"be savage if I've kept her waiting!'  Alice felt so desperate\n"
+	"that she was ready to ask help of any one; so, when the Rabbit\n"
+	"came near her, she began, in a low, timid voice, `If you please,\n"
+	"sir--'  The Rabbit started violently, dropped the white kid\n"
+	"gloves and the fan, and skurried away into the darkness as hard\n"
+	"as he could go.\n"
+	"\n"
+	"  Alice took up the fan and gloves, and, as the hall was very\n"
+	"hot, she kept fanning herself all the time she went on talking:\n"
+	"`Dear, dear!  How queer everything is to-day!  And yesterday\n"
+	"things went on just as usual.  I wonder if I've been changed in\n"
+	"the night?  Let me think:  was I the same when I got up this\n"
+	"morning?  I almost think I can remember feeling a little\n"
+	"different.  But if I'm not the same, the next question is, Who in\n"
+	"the world am I?  Ah, THAT'S the great puzzle!'  And she began\n"
+	"thinking over all the children she knew that were of the same age\n"
+	"as herself, to see if she could have been changed for any of\n"
+	"them.\n"
+	"\n"
+	"  `I'm sure I'm not Ada,' she said, `for her hair goes in such\n"
+	"long ringlets, and mine doesn't go in ringlets at all; and I'm\n"
+	"sure I can't be Mabel, for I know all sorts of things, and she,\n"
+	"oh! she knows such a very little!  Besides, SHE'S she, and I'm I,\n"
+	"and--oh dear, how puzzling it all is!  I'll try if I know all the\n"
+	"things I used to know.  Let me see:  four times five is twelve,\n"
+	"and four times six is thirteen, and four times seven is--oh dear!\n"
+	"I shall never get to twenty at that rate!  However, the\n"
+	"Multiplication Table doesn't signify:  let's try Geography.\n"
+	"London is the capital of Paris, and Paris is the capital of Rome,\n"
+	"and Rome--no, THAT'S all wrong, I'm certain!  I must have been\n"
+	"changed for Mabel!  I'll try and say ''How doth the little--''\n"
+	"and she crossed her hands on her lap as if she were saying lessons,\n"
+	"and began to repeat it, but her voice sounded hoarse and\n"
+	"strange, and the words did not come the same as they used to do:--\n"
+	"\n"
+	"	    `How doth the little crocodile\n"
+	"	      Improve his shining tail,\n"
+	"	    And pour the waters of the Nile\n"
+	"	      On every golden scale!\n"
+	"\n"
+	"	    `How cheerfully he seems to grin,\n"
+	"	      How neatly spread his claws,\n"
+	"	    And welcome little fishes in\n"
+	"	      With gently smiling jaws!'\n";
 
 static const char * const compress_test_bufs[] = {
 	test_buf_alice,
 	test_buf_shakespeare,
-	test_buf_pascal
+	test_buf_alice2
 };
 
 #endif /* TEST_COMPRESSDEV_TEST_BUFFERS_H_ */
diff --git a/dpdk/app/test/test_cryptodev.c b/dpdk/app/test/test_cryptodev.c
index 1b561456d7..a852040ec2 100644
--- a/dpdk/app/test/test_cryptodev.c
+++ b/dpdk/app/test/test_cryptodev.c
@@ -143,7 +143,7 @@ static struct rte_crypto_op *
 process_crypto_request(uint8_t dev_id, struct rte_crypto_op *op)
 {
 	if (rte_cryptodev_enqueue_burst(dev_id, 0, &op, 1) != 1) {
-		printf("Error sending packet for encryption");
+		RTE_LOG(ERR, USER1, "Error sending packet for encryption\n");
 		return NULL;
 	}
 
@@ -152,6 +152,11 @@ process_crypto_request(uint8_t dev_id, struct rte_crypto_op *op)
 	while (rte_cryptodev_dequeue_burst(dev_id, 0, &op, 1) == 0)
 		rte_pause();
 
+	if (op->status != RTE_CRYPTO_OP_STATUS_SUCCESS) {
+		RTE_LOG(DEBUG, USER1, "Operation status %d\n", op->status);
+		return NULL;
+	}
+
 	return op;
 }
 
@@ -638,7 +643,7 @@ test_device_configure_invalid_dev_id(void)
 			"Need at least %d devices for test", 1);
 
 	/* valid dev_id values */
-	dev_id = ts_params->valid_devs[ts_params->valid_dev_count - 1];
+	dev_id = ts_params->valid_devs[0];
 
 	/* Stop the device in case it's started so it can be configured */
 	rte_cryptodev_stop(dev_id);
@@ -2696,13 +2701,15 @@ create_wireless_algo_cipher_auth_session(uint8_t dev_id,
 	/* Create Crypto session*/
 	ut_params->sess = rte_cryptodev_sym_session_create(
 			ts_params->session_mpool);
+	TEST_ASSERT_NOT_NULL(ut_params->sess, "Session creation failed");
 
 	status = rte_cryptodev_sym_session_init(dev_id, ut_params->sess,
 			&ut_params->cipher_xform,
 			ts_params->session_priv_mpool);
+	if (status == -ENOTSUP)
+		return status;
 
 	TEST_ASSERT_EQUAL(status, 0, "session init failed");
-	TEST_ASSERT_NOT_NULL(ut_params->sess, "Session creation failed");
 	return 0;
 }
 
@@ -2822,12 +2829,24 @@ create_wireless_algo_auth_cipher_session(uint8_t dev_id,
 	/* Create Crypto session*/
 	ut_params->sess = rte_cryptodev_sym_session_create(
 			ts_params->session_mpool);
+	TEST_ASSERT_NOT_NULL(ut_params->sess, "Session creation failed");
+
+	if (cipher_op == RTE_CRYPTO_CIPHER_OP_DECRYPT) {
+		ut_params->auth_xform.next = NULL;
+		ut_params->cipher_xform.next = &ut_params->auth_xform;
+		status = rte_cryptodev_sym_session_init(dev_id, ut_params->sess,
+				&ut_params->cipher_xform,
+				ts_params->session_priv_mpool);
+
+	} else
+		status = rte_cryptodev_sym_session_init(dev_id, ut_params->sess,
+				&ut_params->auth_xform,
+				ts_params->session_priv_mpool);
+
+	if (status == -ENOTSUP)
+		return status;
 
-	status = rte_cryptodev_sym_session_init(dev_id, ut_params->sess,
-			&ut_params->auth_xform,
-			ts_params->session_priv_mpool);
 	TEST_ASSERT_EQUAL(status, 0, "session init failed");
-	TEST_ASSERT_NOT_NULL(ut_params->sess, "Session creation failed");
 
 	return 0;
 }
@@ -2971,6 +2990,11 @@ create_wireless_algo_cipher_hash_operation(const uint8_t *auth_tag,
 	struct crypto_testsuite_params *ts_params = &testsuite_params;
 	struct crypto_unittest_params *ut_params = &unittest_params;
 
+	enum rte_crypto_cipher_algorithm cipher_algo =
+			ut_params->cipher_xform.cipher.algo;
+	enum rte_crypto_auth_algorithm auth_algo =
+			ut_params->auth_xform.auth.algo;
+
 	/* Generate Crypto op data structure */
 	ut_params->op = rte_crypto_op_alloc(ts_params->op_mpool,
 			RTE_CRYPTO_OP_TYPE_SYMMETRIC);
@@ -2991,8 +3015,22 @@ create_wireless_algo_cipher_hash_operation(const uint8_t *auth_tag,
 	TEST_ASSERT_NOT_NULL(sym_op->auth.digest.data,
 			"no room to append auth tag");
 	ut_params->digest = sym_op->auth.digest.data;
-	sym_op->auth.digest.phys_addr = rte_pktmbuf_iova_offset(
-			ut_params->ibuf, data_pad_len);
+
+	if (rte_pktmbuf_is_contiguous(ut_params->ibuf)) {
+		sym_op->auth.digest.phys_addr = rte_pktmbuf_iova_offset(
+				ut_params->ibuf, data_pad_len);
+	} else {
+		struct rte_mbuf *m = ut_params->ibuf;
+		unsigned int offset = data_pad_len;
+
+		while (offset > m->data_len && m->next != NULL) {
+			offset -= m->data_len;
+			m = m->next;
+		}
+		sym_op->auth.digest.phys_addr = rte_pktmbuf_iova_offset(
+			m, offset);
+	}
+
 	if (op == RTE_CRYPTO_AUTH_OP_GENERATE)
 		memset(sym_op->auth.digest.data, 0, auth_tag_len);
 	else
@@ -3009,22 +3047,38 @@ create_wireless_algo_cipher_hash_operation(const uint8_t *auth_tag,
 	iv_ptr += cipher_iv_len;
 	rte_memcpy(iv_ptr, auth_iv, auth_iv_len);
 
-	sym_op->cipher.data.length = cipher_len;
-	sym_op->cipher.data.offset = cipher_offset;
-	sym_op->auth.data.length = auth_len;
-	sym_op->auth.data.offset = auth_offset;
+	if (cipher_algo == RTE_CRYPTO_CIPHER_SNOW3G_UEA2 ||
+		cipher_algo == RTE_CRYPTO_CIPHER_KASUMI_F8 ||
+		cipher_algo == RTE_CRYPTO_CIPHER_ZUC_EEA3) {
+		sym_op->cipher.data.length = cipher_len;
+		sym_op->cipher.data.offset = cipher_offset;
+	} else {
+		sym_op->cipher.data.length = cipher_len >> 3;
+		sym_op->cipher.data.offset = cipher_offset >> 3;
+	}
+
+	if (auth_algo == RTE_CRYPTO_AUTH_SNOW3G_UIA2 ||
+		auth_algo == RTE_CRYPTO_AUTH_KASUMI_F9 ||
+		auth_algo == RTE_CRYPTO_AUTH_ZUC_EIA3) {
+		sym_op->auth.data.length = auth_len;
+		sym_op->auth.data.offset = auth_offset;
+	} else {
+		sym_op->auth.data.length = auth_len >> 3;
+		sym_op->auth.data.offset = auth_offset >> 3;
+	}
 
 	return 0;
 }
 
 static int
-create_wireless_algo_auth_cipher_operation(unsigned int auth_tag_len,
+create_wireless_algo_auth_cipher_operation(
+		const uint8_t *auth_tag, unsigned int auth_tag_len,
 		const uint8_t *cipher_iv, uint8_t cipher_iv_len,
 		const uint8_t *auth_iv, uint8_t auth_iv_len,
 		unsigned int data_pad_len,
 		unsigned int cipher_len, unsigned int cipher_offset,
 		unsigned int auth_len, unsigned int auth_offset,
-		uint8_t op_mode, uint8_t do_sgl)
+		uint8_t op_mode, uint8_t do_sgl, uint8_t verify)
 {
 	struct crypto_testsuite_params *ts_params = &testsuite_params;
 	struct crypto_unittest_params *ut_params = &unittest_params;
@@ -3081,6 +3135,10 @@ create_wireless_algo_auth_cipher_operation(unsigned int auth_tag_len,
 		}
 	}
 
+	/* Copy digest for the verification */
+	if (verify)
+		memcpy(sym_op->auth.digest.data, auth_tag, auth_tag_len);
+
 	/* Copy cipher and auth IVs at the end of the crypto operation */
 	uint8_t *iv_ptr = rte_crypto_op_ctod_offset(
 			ut_params->op, uint8_t *, IV_OFFSET);
@@ -4643,7 +4701,7 @@ test_snow3g_auth_cipher(const struct snow3g_test_data *tdata,
 
 	/* Create SNOW 3G operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-		tdata->digest.len,
+		tdata->digest.data, tdata->digest.len,
 		tdata->cipher_iv.data, tdata->cipher_iv.len,
 		tdata->auth_iv.data, tdata->auth_iv.len,
 		(tdata->digest.offset_bytes == 0 ?
@@ -4653,7 +4711,7 @@ test_snow3g_auth_cipher(const struct snow3g_test_data *tdata,
 		tdata->cipher.offset_bits,
 		tdata->validAuthLenInBits.len,
 		tdata->auth.offset_bits,
-		op_mode, 0);
+		op_mode, 0, verify);
 
 	if (retval < 0)
 		return retval;
@@ -4819,7 +4877,7 @@ test_snow3g_auth_cipher_sgl(const struct snow3g_test_data *tdata,
 
 	/* Create SNOW 3G operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-		tdata->digest.len,
+		tdata->digest.data, tdata->digest.len,
 		tdata->cipher_iv.data, tdata->cipher_iv.len,
 		tdata->auth_iv.data, tdata->auth_iv.len,
 		(tdata->digest.offset_bytes == 0 ?
@@ -4829,7 +4887,7 @@ test_snow3g_auth_cipher_sgl(const struct snow3g_test_data *tdata,
 		tdata->cipher.offset_bits,
 		tdata->validAuthLenInBits.len,
 		tdata->auth.offset_bits,
-		op_mode, 1);
+		op_mode, 1, verify);
 
 	if (retval < 0)
 		return retval;
@@ -4988,7 +5046,7 @@ test_kasumi_auth_cipher(const struct kasumi_test_data *tdata,
 
 	/* Create KASUMI operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-		tdata->digest.len,
+		tdata->digest.data, tdata->digest.len,
 		tdata->cipher_iv.data, tdata->cipher_iv.len,
 		NULL, 0,
 		(tdata->digest.offset_bytes == 0 ?
@@ -4998,7 +5056,7 @@ test_kasumi_auth_cipher(const struct kasumi_test_data *tdata,
 		tdata->validCipherOffsetInBits.len,
 		tdata->validAuthLenInBits.len,
 		0,
-		op_mode, 0);
+		op_mode, 0, verify);
 
 	if (retval < 0)
 		return retval;
@@ -5165,7 +5223,7 @@ test_kasumi_auth_cipher_sgl(const struct kasumi_test_data *tdata,
 
 	/* Create KASUMI operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-		tdata->digest.len,
+		tdata->digest.data, tdata->digest.len,
 		tdata->cipher_iv.data, tdata->cipher_iv.len,
 		NULL, 0,
 		(tdata->digest.offset_bytes == 0 ?
@@ -5175,7 +5233,7 @@ test_kasumi_auth_cipher_sgl(const struct kasumi_test_data *tdata,
 		tdata->validCipherOffsetInBits.len,
 		tdata->validAuthLenInBits.len,
 		0,
-		op_mode, 1);
+		op_mode, 1, verify);
 
 	if (retval < 0)
 		return retval;
@@ -5666,7 +5724,7 @@ test_zuc_auth_cipher(const struct wireless_test_data *tdata,
 
 	/* Create ZUC operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-		tdata->digest.len,
+		tdata->digest.data, tdata->digest.len,
 		tdata->cipher_iv.data, tdata->cipher_iv.len,
 		tdata->auth_iv.data, tdata->auth_iv.len,
 		(tdata->digest.offset_bytes == 0 ?
@@ -5676,7 +5734,7 @@ test_zuc_auth_cipher(const struct wireless_test_data *tdata,
 		tdata->validCipherOffsetInBits.len,
 		tdata->validAuthLenInBits.len,
 		0,
-		op_mode, 0);
+		op_mode, 0, verify);
 
 	if (retval < 0)
 		return retval;
@@ -5852,7 +5910,7 @@ test_zuc_auth_cipher_sgl(const struct wireless_test_data *tdata,
 
 	/* Create ZUC operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-		tdata->digest.len,
+		tdata->digest.data, tdata->digest.len,
 		tdata->cipher_iv.data, tdata->cipher_iv.len,
 		NULL, 0,
 		(tdata->digest.offset_bytes == 0 ?
@@ -5862,7 +5920,7 @@ test_zuc_auth_cipher_sgl(const struct wireless_test_data *tdata,
 		tdata->validCipherOffsetInBits.len,
 		tdata->validAuthLenInBits.len,
 		0,
-		op_mode, 1);
+		op_mode, 1, verify);
 
 	if (retval < 0)
 		return retval;
@@ -6576,8 +6634,9 @@ test_mixed_auth_cipher(const struct mixed_cipher_auth_test_data *tdata,
 	unsigned int ciphertext_len;
 
 	struct rte_cryptodev_info dev_info;
+	struct rte_crypto_op *op;
 
-	/* Check if device supports particular algorithms */
+	/* Check if device supports particular algorithms separately */
 	if (test_mixed_check_if_unsupported(tdata))
 		return -ENOTSUP;
 
@@ -6593,18 +6652,26 @@ test_mixed_auth_cipher(const struct mixed_cipher_auth_test_data *tdata,
 	}
 
 	/* Create the session */
-	retval = create_wireless_algo_auth_cipher_session(
-			ts_params->valid_devs[0],
-			(verify ? RTE_CRYPTO_CIPHER_OP_DECRYPT
-					: RTE_CRYPTO_CIPHER_OP_ENCRYPT),
-			(verify ? RTE_CRYPTO_AUTH_OP_VERIFY
-					: RTE_CRYPTO_AUTH_OP_GENERATE),
-			tdata->auth_algo,
-			tdata->cipher_algo,
-			tdata->auth_key.data, tdata->auth_key.len,
-			tdata->auth_iv.len, tdata->digest_enc.len,
-			tdata->cipher_iv.len);
-
+	if (verify)
+		retval = create_wireless_algo_cipher_auth_session(
+				ts_params->valid_devs[0],
+				RTE_CRYPTO_CIPHER_OP_DECRYPT,
+				RTE_CRYPTO_AUTH_OP_VERIFY,
+				tdata->auth_algo,
+				tdata->cipher_algo,
+				tdata->auth_key.data, tdata->auth_key.len,
+				tdata->auth_iv.len, tdata->digest_enc.len,
+				tdata->cipher_iv.len);
+	else
+		retval = create_wireless_algo_auth_cipher_session(
+				ts_params->valid_devs[0],
+				RTE_CRYPTO_CIPHER_OP_ENCRYPT,
+				RTE_CRYPTO_AUTH_OP_GENERATE,
+				tdata->auth_algo,
+				tdata->cipher_algo,
+				tdata->auth_key.data, tdata->auth_key.len,
+				tdata->auth_iv.len, tdata->digest_enc.len,
+				tdata->cipher_iv.len);
 	if (retval < 0)
 		return retval;
 
@@ -6643,24 +6710,34 @@ test_mixed_auth_cipher(const struct mixed_cipher_auth_test_data *tdata,
 
 	/* Create the operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-			tdata->digest_enc.len,
+			tdata->digest_enc.data, tdata->digest_enc.len,
 			tdata->cipher_iv.data, tdata->cipher_iv.len,
 			tdata->auth_iv.data, tdata->auth_iv.len,
 			(tdata->digest_enc.offset == 0 ?
-			(verify ? ciphertext_pad_len : plaintext_pad_len)
+				plaintext_pad_len
 				: tdata->digest_enc.offset),
 			tdata->validCipherLen.len_bits,
 			tdata->cipher.offset_bits,
 			tdata->validAuthLen.len_bits,
 			tdata->auth.offset_bits,
-			op_mode, 0);
+			op_mode, 0, verify);
 
 	if (retval < 0)
 		return retval;
 
-	ut_params->op = process_crypto_request(ts_params->valid_devs[0],
+	op = process_crypto_request(ts_params->valid_devs[0],
 			ut_params->op);
 
+	/* Check if the op failed because the device doesn't */
+	/* support this particular combination of algorithms */
+	if (op == NULL && ut_params->op->status ==
+			RTE_CRYPTO_OP_STATUS_INVALID_SESSION) {
+		printf("Device doesn't support this mixed combination. "
+				"Test Skipped.\n");
+		return -ENOTSUP;
+	}
+	ut_params->op = op;
+
 	TEST_ASSERT_NOT_NULL(ut_params->op, "failed to retrieve obuf");
 
 	ut_params->obuf = (op_mode == IN_PLACE ?
@@ -6675,12 +6752,10 @@ test_mixed_auth_cipher(const struct mixed_cipher_auth_test_data *tdata,
 					(tdata->cipher.offset_bits >> 3);
 
 		debug_hexdump(stdout, "plaintext:", plaintext,
-				(tdata->plaintext.len_bits >> 3) -
-				tdata->digest_enc.len);
+				tdata->plaintext.len_bits >> 3);
 		debug_hexdump(stdout, "plaintext expected:",
 				tdata->plaintext.data,
-				(tdata->plaintext.len_bits >> 3) -
-				tdata->digest_enc.len);
+				tdata->plaintext.len_bits >> 3);
 	} else {
 		if (ut_params->obuf)
 			ciphertext = rte_pktmbuf_mtod(ut_params->obuf,
@@ -6725,6 +6800,10 @@ test_mixed_auth_cipher(const struct mixed_cipher_auth_test_data *tdata,
 				DIGEST_BYTE_LENGTH_SNOW3G_UIA2,
 				"Generated auth tag not as expected");
 	}
+
+	TEST_ASSERT_EQUAL(ut_params->op->status, RTE_CRYPTO_OP_STATUS_SUCCESS,
+			"crypto op processing failed");
+
 	return 0;
 }
 
@@ -6748,6 +6827,7 @@ test_mixed_auth_cipher_sgl(const struct mixed_cipher_auth_test_data *tdata,
 	uint8_t digest_buffer[10000];
 
 	struct rte_cryptodev_info dev_info;
+	struct rte_crypto_op *op;
 
 	/* Check if device supports particular algorithms */
 	if (test_mixed_check_if_unsupported(tdata))
@@ -6776,18 +6856,26 @@ test_mixed_auth_cipher_sgl(const struct mixed_cipher_auth_test_data *tdata,
 	}
 
 	/* Create the session */
-	retval = create_wireless_algo_auth_cipher_session(
-			ts_params->valid_devs[0],
-			(verify ? RTE_CRYPTO_CIPHER_OP_DECRYPT
-					: RTE_CRYPTO_CIPHER_OP_ENCRYPT),
Louis Abel's avatar
Louis Abel committed
6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722 7723 7724 7725 7726 7727 7728 7729 7730 7731 7732 7733 7734 7735 7736 7737 7738 7739 7740 7741 7742 7743 7744 7745 7746 7747 7748 7749 7750 7751 7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774 7775 7776 7777 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 7788 7789 7790 7791 7792 7793 7794 7795 7796 7797 7798 7799 7800 7801 7802 7803 7804 7805 7806 7807 7808 7809 7810 7811 7812 7813 7814 7815 7816 7817 7818 7819 7820 7821 7822 7823 7824 7825 7826 7827 7828 7829 7830 7831 7832 7833 7834 7835 7836 7837 7838 7839 7840 7841 7842 7843 7844 7845 7846 7847 7848 7849 7850 7851 7852 7853 7854 7855 7856 7857 7858 7859 7860 7861 7862 7863 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 7898 7899 7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914 7915 7916 7917 7918 7919 7920 7921 7922 7923 7924 7925 7926 7927 7928 7929 7930 7931 7932 7933 7934 7935 7936 7937 7938 7939 7940 7941 7942 7943 7944 7945 7946 7947 7948 7949 7950 7951 7952 7953 7954 7955 7956 7957 7958 7959 7960 7961 7962 7963 7964 7965 7966 7967 7968 7969 7970 7971 7972 7973 7974 7975 7976 7977 7978 7979 7980 7981 7982 7983 7984 7985 7986 7987 7988 7989 7990 7991 7992 7993 7994 7995 7996 7997 7998 7999 8000 8001 8002 8003 8004 8005 8006 8007 8008 8009 8010 8011 8012 8013 8014 8015 8016 8017 8018 8019 8020 8021 8022 8023 8024 8025 8026 8027 8028 8029 8030 8031 8032 8033 8034 8035 8036 8037 8038 8039 8040 8041 8042 8043 8044 8045 8046 8047 8048 8049 8050 8051 8052 8053 8054 8055 8056 8057 8058 8059 8060 8061 8062 8063 8064 8065 8066 8067 8068 8069 8070 8071 8072 8073 8074 8075 8076 8077 8078 8079 8080 8081 8082 8083 8084 8085 8086 8087 8088 8089 8090 8091 8092 8093 8094 8095 8096 8097 8098 8099 8100 8101 8102 8103 8104 8105 8106 8107 8108 8109 8110 8111 8112 8113 8114 8115 8116 8117 8118 8119 8120 8121 8122 8123 8124 8125 8126 8127 8128 8129 8130 8131 8132 8133 8134 8135 8136 8137 8138 8139 8140 8141 8142 8143 8144 8145 8146 8147 8148 8149 8150 8151 8152 8153 8154 8155 8156 8157 8158 8159 8160 8161 8162 8163 8164 8165 8166 8167 8168 8169 8170 8171 8172 8173 8174 8175 8176 8177 8178 8179 8180 8181 8182 8183 8184 8185 8186 8187 8188 8189 8190 8191 8192 8193 8194 8195 8196 8197 8198 8199 8200
-			(verify ? RTE_CRYPTO_AUTH_OP_VERIFY
-					: RTE_CRYPTO_AUTH_OP_GENERATE),
-			tdata->auth_algo,
-			tdata->cipher_algo,
-			tdata->auth_key.data, tdata->auth_key.len,
-			tdata->auth_iv.len, tdata->digest_enc.len,
-			tdata->cipher_iv.len);
-
+	if (verify)
+		retval = create_wireless_algo_cipher_auth_session(
+				ts_params->valid_devs[0],
+				RTE_CRYPTO_CIPHER_OP_DECRYPT,
+				RTE_CRYPTO_AUTH_OP_VERIFY,
+				tdata->auth_algo,
+				tdata->cipher_algo,
+				tdata->auth_key.data, tdata->auth_key.len,
+				tdata->auth_iv.len, tdata->digest_enc.len,
+				tdata->cipher_iv.len);
+	else
+		retval = create_wireless_algo_auth_cipher_session(
+				ts_params->valid_devs[0],
+				RTE_CRYPTO_CIPHER_OP_ENCRYPT,
+				RTE_CRYPTO_AUTH_OP_GENERATE,
+				tdata->auth_algo,
+				tdata->cipher_algo,
+				tdata->auth_key.data, tdata->auth_key.len,
+				tdata->auth_iv.len, tdata->digest_enc.len,
+				tdata->cipher_iv.len);
 	if (retval < 0)
 		return retval;
 
@@ -6797,7 +6885,7 @@ test_mixed_auth_cipher_sgl(const struct mixed_cipher_auth_test_data *tdata,
 	plaintext_pad_len = RTE_ALIGN_CEIL(plaintext_len, 16);
 
 	ut_params->ibuf = create_segmented_mbuf(ts_params->mbuf_pool,
-			plaintext_pad_len, 15, 0);
+			ciphertext_pad_len, 15, 0);
 	TEST_ASSERT_NOT_NULL(ut_params->ibuf,
 			"Failed to allocate input buffer in mempool");
 
@@ -6827,24 +6915,35 @@ test_mixed_auth_cipher_sgl(const struct mixed_cipher_auth_test_data *tdata,
 
 	/* Create the operation */
 	retval = create_wireless_algo_auth_cipher_operation(
-			tdata->digest_enc.len,
+			tdata->digest_enc.data, tdata->digest_enc.len,
 			tdata->cipher_iv.data, tdata->cipher_iv.len,
 			tdata->auth_iv.data, tdata->auth_iv.len,
 			(tdata->digest_enc.offset == 0 ?
-			(verify ? ciphertext_pad_len : plaintext_pad_len)
+				plaintext_pad_len
 				: tdata->digest_enc.offset),
 			tdata->validCipherLen.len_bits,
 			tdata->cipher.offset_bits,
 			tdata->validAuthLen.len_bits,
 			tdata->auth.offset_bits,
-			op_mode, 1);
+			op_mode, 1, verify);
 
 	if (retval < 0)
 		return retval;
 
-	ut_params->op = process_crypto_request(ts_params->valid_devs[0],
+	op = process_crypto_request(ts_params->valid_devs[0],
 			ut_params->op);
 
+	/* Check if the op failed because the device doesn't */
+	/* support this particular combination of algorithms */
+	if (op == NULL && ut_params->op->status ==
+			RTE_CRYPTO_OP_STATUS_INVALID_SESSION) {
+		printf("Device doesn't support this mixed combination. "
+				"Test Skipped.\n");
+		return -ENOTSUP;
+	}
+
+	ut_params->op = op;
+
 	TEST_ASSERT_NOT_NULL(ut_params->op, "failed to retrieve obuf");
 
 	ut_params->obuf = (op_mode == IN_PLACE ?
@@ -6917,6 +7016,10 @@ test_mixed_auth_cipher_sgl(const struct mixed_cipher_auth_test_data *tdata,
 				tdata->digest_enc.len,
 				"Generated auth tag not as expected");
 	}
+
+	TEST_ASSERT_EQUAL(ut_params->op->status, RTE_CRYPTO_OP_STATUS_SUCCESS,
+			"crypto op processing failed");
+
 	return 0;
 }
 
@@ -6978,6 +7081,176 @@ test_verify_aes_cmac_aes_ctr_digest_enc_test_case_1_oop_sgl(void)
 		&auth_aes_cmac_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 1);
 }
 
+/** MIXED AUTH + CIPHER */
+
+static int
+test_auth_zuc_cipher_snow_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_zuc_cipher_snow_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_zuc_cipher_snow_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_zuc_cipher_snow_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_aes_cmac_cipher_snow_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_aes_cmac_cipher_snow_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_aes_cmac_cipher_snow_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_aes_cmac_cipher_snow_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_zuc_cipher_aes_ctr_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_zuc_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_zuc_cipher_aes_ctr_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_zuc_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_snow_cipher_aes_ctr_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_snow_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_snow_cipher_aes_ctr_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_snow_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_snow_cipher_zuc_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_snow_cipher_zuc_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_snow_cipher_zuc_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_snow_cipher_zuc_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_aes_cmac_cipher_zuc_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_aes_cmac_cipher_zuc_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_aes_cmac_cipher_zuc_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_aes_cmac_cipher_zuc_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_null_cipher_snow_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_null_cipher_snow_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_null_cipher_snow_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_null_cipher_snow_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_null_cipher_zuc_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_null_cipher_zuc_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_null_cipher_zuc_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_null_cipher_zuc_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_snow_cipher_null_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_snow_cipher_null_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_snow_cipher_null_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_snow_cipher_null_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_zuc_cipher_null_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_zuc_cipher_null_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_zuc_cipher_null_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_zuc_cipher_null_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_null_cipher_aes_ctr_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_null_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_null_cipher_aes_ctr_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_null_cipher_aes_ctr_test_case_1, OUT_OF_PLACE, 1);
+}
+
+static int
+test_auth_aes_cmac_cipher_null_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_aes_cmac_cipher_null_test_case_1, OUT_OF_PLACE, 0);
+}
+
+static int
+test_verify_auth_aes_cmac_cipher_null_test_case_1(void)
+{
+	return test_mixed_auth_cipher(
+		&auth_aes_cmac_cipher_null_test_case_1, OUT_OF_PLACE, 1);
+}
+
 static int
 test_3DES_chain_qat_all(void)
 {
@@ -9139,8 +9412,10 @@ test_stats(void)
 {
 	struct crypto_testsuite_params *ts_params = &testsuite_params;
 	struct rte_cryptodev_stats stats;
-	struct rte_cryptodev *dev;
-	cryptodev_stats_get_t temp_pfn;
+
+	if (rte_cryptodev_stats_get(ts_params->valid_devs[0], &stats)
+			== -ENOTSUP)
+		return -ENOTSUP;
 
 	rte_cryptodev_stats_reset(ts_params->valid_devs[0]);
 	TEST_ASSERT((rte_cryptodev_stats_get(ts_params->valid_devs[0] + 600,
@@ -9148,18 +9423,9 @@ test_stats(void)
 		"rte_cryptodev_stats_get invalid dev failed");
 	TEST_ASSERT((rte_cryptodev_stats_get(ts_params->valid_devs[0], 0) != 0),
 		"rte_cryptodev_stats_get invalid Param failed");
-	dev = &rte_cryptodevs[ts_params->valid_devs[0]];
-	temp_pfn = dev->dev_ops->stats_get;
-	dev->dev_ops->stats_get = (cryptodev_stats_get_t)0;
-	TEST_ASSERT((rte_cryptodev_stats_get(ts_params->valid_devs[0], &stats)
-			== -ENOTSUP),
-		"rte_cryptodev_stats_get invalid Param failed");
-	dev->dev_ops->stats_get = temp_pfn;
 
 	/* Test expected values */
-	ut_setup();
 	test_AES_CBC_HMAC_SHA1_encrypt_digest();
-	ut_teardown();
 	TEST_ASSERT_SUCCESS(rte_cryptodev_stats_get(ts_params->valid_devs[0],
 			&stats),
 		"rte_cryptodev_stats_get failed");
@@ -10450,7 +10716,7 @@ aes128cbc_hmac_sha1_test_vector = {
 static const struct test_crypto_vector
 aes128cbc_hmac_sha1_aad_test_vector = {
 	.crypto_algo = RTE_CRYPTO_CIPHER_AES_CBC,
-	.cipher_offset = 12,
+	.cipher_offset = 8,
 	.cipher_len = 496,
 	.cipher_key = {
 		.data = {
@@ -10486,9 +10752,9 @@ aes128cbc_hmac_sha1_aad_test_vector = {
 	},
 	.digest = {
 		.data = {
-			0x1F, 0x6A, 0xD2, 0x8B, 0x4B, 0xB3, 0xC0, 0x9E,
-			0x86, 0x9B, 0x3A, 0xF2, 0x00, 0x5B, 0x4F, 0x08,
-			0x62, 0x8D, 0x62, 0x65
+			0x6D, 0xF3, 0x50, 0x79, 0x7A, 0x2A, 0xAC, 0x7F,
+			0xA6, 0xF0, 0xC6, 0x38, 0x1F, 0xA4, 0xDD, 0x9B,
+			0x62, 0x0F, 0xFB, 0x10
 		},
 		.len = 20
 	}
@@ -10818,13 +11084,8 @@ test_authentication_verify_fail_when_data_corruption(
 
 	ut_params->op = process_crypto_request(ts_params->valid_devs[0],
 			ut_params->op);
-	TEST_ASSERT_NOT_NULL(ut_params->op, "failed crypto process");
-	TEST_ASSERT_NOT_EQUAL(ut_params->op->status,
-			RTE_CRYPTO_OP_STATUS_SUCCESS,
-			"authentication not failed");
 
-	ut_params->obuf = ut_params->op->sym->m_src;
-	TEST_ASSERT_NOT_NULL(ut_params->obuf, "failed to retrieve obuf");
+	TEST_ASSERT_NULL(ut_params->op, "authentication not failed");
 
 	return 0;
 }
@@ -10879,13 +11140,8 @@ test_authentication_verify_GMAC_fail_when_corruption(
 
 	ut_params->op = process_crypto_request(ts_params->valid_devs[0],
 			ut_params->op);
-	TEST_ASSERT_NOT_NULL(ut_params->op, "failed crypto process");
-	TEST_ASSERT_NOT_EQUAL(ut_params->op->status,
-			RTE_CRYPTO_OP_STATUS_SUCCESS,
-			"authentication not failed");
 
-	ut_params->obuf = ut_params->op->sym->m_src;
-	TEST_ASSERT_NOT_NULL(ut_params->obuf, "failed to retrieve obuf");
+	TEST_ASSERT_NULL(ut_params->op, "authentication not failed");
 
 	return 0;
 }
@@ -10940,13 +11196,7 @@ test_authenticated_decryption_fail_when_corruption(
 	ut_params->op = process_crypto_request(ts_params->valid_devs[0],
 			ut_params->op);
 
-	TEST_ASSERT_NOT_NULL(ut_params->op, "failed crypto process");
-	TEST_ASSERT_NOT_EQUAL(ut_params->op->status,
-			RTE_CRYPTO_OP_STATUS_SUCCESS,
-			"authentication not failed");
-
-	ut_params->obuf = ut_params->op->sym->m_src;
-	TEST_ASSERT_NOT_NULL(ut_params->obuf, "failed to retrieve obuf");
+	TEST_ASSERT_NULL(ut_params->op, "authentication not failed");
 
 	return 0;
 }
@@ -11149,6 +11399,7 @@ create_aead_operation_SGL(enum rte_crypto_aead_operation op,
 	const unsigned int auth_tag_len = tdata->auth_tag.len;
 	const unsigned int iv_len = tdata->iv.len;
 	unsigned int aad_len = tdata->aad.len;
+	unsigned int aad_len_pad = 0;
 
 	/* Generate Crypto op data structure */
 	ut_params->op = rte_crypto_op_alloc(ts_params->op_mpool,
@@ -11203,8 +11454,10 @@ create_aead_operation_SGL(enum rte_crypto_aead_operation op,
 
 		rte_memcpy(iv_ptr, tdata->iv.data, iv_len);
 
+		aad_len_pad = RTE_ALIGN_CEIL(aad_len, 16);
+
 		sym_op->aead.aad.data = (uint8_t *)rte_pktmbuf_prepend(
-				ut_params->ibuf, aad_len);
+				ut_params->ibuf, aad_len_pad);
 		TEST_ASSERT_NOT_NULL(sym_op->aead.aad.data,
 				"no room to prepend aad");
 		sym_op->aead.aad.phys_addr = rte_pktmbuf_iova(
@@ -11219,7 +11472,7 @@ create_aead_operation_SGL(enum rte_crypto_aead_operation op,
 	}
 
 	sym_op->aead.data.length = tdata->plaintext.len;
-	sym_op->aead.data.offset = aad_len;
+	sym_op->aead.data.offset = aad_len_pad;
 
 	return 0;
 }
@@ -11252,7 +11505,7 @@ test_authenticated_encryption_SGL(const struct aead_test_data *tdata,
 	int ecx = 0;
 	void *digest_mem = NULL;
 
-	uint32_t prepend_len = tdata->aad.len;
+	uint32_t prepend_len = RTE_ALIGN_CEIL(tdata->aad.len, 16);
 
 	if (tdata->plaintext.len % fragsz != 0) {
 		if (tdata->plaintext.len / fragsz + 1 > SGL_MAX_NO)
@@ -11915,6 +12168,8 @@ static struct unit_test_suite cryptodev_qat_testsuite  = {
 			test_AES_GCM_auth_encrypt_SGL_out_of_place_400B_400B),
 		TEST_CASE_ST(ut_setup, ut_teardown,
 			test_AES_GCM_auth_encrypt_SGL_out_of_place_1500B_2000B),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_AES_GCM_auth_encrypt_SGL_out_of_place_400B_1seg),
 		TEST_CASE_ST(ut_setup, ut_teardown,
 			test_AES_GCM_authenticated_encryption_test_case_1),
 		TEST_CASE_ST(ut_setup, ut_teardown,
@@ -12288,6 +12543,68 @@ static struct unit_test_suite cryptodev_qat_testsuite  = {
 		TEST_CASE_ST(ut_setup, ut_teardown,
 		   test_verify_aes_cmac_aes_ctr_digest_enc_test_case_1_oop_sgl),
 
+		/** AUTH ZUC + CIPHER SNOW3G */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_zuc_cipher_snow_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_zuc_cipher_snow_test_case_1),
+		/** AUTH AES CMAC + CIPHER SNOW3G */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_aes_cmac_cipher_snow_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_aes_cmac_cipher_snow_test_case_1),
+		/** AUTH ZUC + CIPHER AES CTR */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_zuc_cipher_aes_ctr_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_zuc_cipher_aes_ctr_test_case_1),
+		/** AUTH SNOW3G + CIPHER AES CTR */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_snow_cipher_aes_ctr_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_snow_cipher_aes_ctr_test_case_1),
+		/** AUTH SNOW3G + CIPHER ZUC */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_snow_cipher_zuc_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_snow_cipher_zuc_test_case_1),
+		/** AUTH AES CMAC + CIPHER ZUC */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_aes_cmac_cipher_zuc_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_aes_cmac_cipher_zuc_test_case_1),
+
+		/** AUTH NULL + CIPHER SNOW3G */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_null_cipher_snow_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_null_cipher_snow_test_case_1),
+		/** AUTH NULL + CIPHER ZUC */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_null_cipher_zuc_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_null_cipher_zuc_test_case_1),
+		/** AUTH SNOW3G + CIPHER NULL */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_snow_cipher_null_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_snow_cipher_null_test_case_1),
+		/** AUTH ZUC + CIPHER NULL */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_zuc_cipher_null_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_zuc_cipher_null_test_case_1),
+		/** AUTH NULL + CIPHER AES CTR */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_null_cipher_aes_ctr_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_null_cipher_aes_ctr_test_case_1),
+		/** AUTH AES CMAC + CIPHER NULL */
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_auth_aes_cmac_cipher_null_test_case_1),
+		TEST_CASE_ST(ut_setup, ut_teardown,
+			test_verify_auth_aes_cmac_cipher_null_test_case_1),
+
 		TEST_CASES_END() /**< NULL terminate unit test array */
 	}
 };
diff --git a/dpdk/app/test/test_cryptodev_aes_test_vectors.h b/dpdk/app/test/test_cryptodev_aes_test_vectors.h
index 8307fcf9ae..66994b659a 100644
--- a/dpdk/app/test/test_cryptodev_aes_test_vectors.h
+++ b/dpdk/app/test/test_cryptodev_aes_test_vectors.h
@@ -358,69 +358,69 @@ static const struct blockcipher_test_data null_test_data_chain_x1_multiple = {
 
 static const uint8_t ciphertext512_aes128cbc_aad[] = {
 	0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
-	0x6F, 0x75, 0x73, 0x79, 0x6D, 0x70, 0xB4, 0xAD,
-	0x09, 0x7C, 0xD7, 0x52, 0xD6, 0xF2, 0xBF, 0xD1,
-	0x9D, 0x79, 0xC6, 0xB6, 0x8F, 0x94, 0xEB, 0xD8,
-	0xBA, 0x5E, 0x01, 0x49, 0x7D, 0xB3, 0xC5, 0xFE,
-	0x18, 0xF4, 0xE3, 0x60, 0x8C, 0x84, 0x68, 0x13,
-	0x33, 0x06, 0x85, 0x60, 0xD3, 0xE7, 0x8A, 0xB5,
-	0x23, 0xA2, 0xDE, 0x52, 0x5C, 0xB6, 0x26, 0x37,
-	0xBB, 0x23, 0x8A, 0x38, 0x07, 0x85, 0xB6, 0x2E,
-	0xC3, 0x69, 0x57, 0x79, 0x6B, 0xE4, 0xD7, 0x86,
-	0x23, 0x72, 0x4C, 0x65, 0x49, 0x08, 0x1E, 0xF3,
-	0xCC, 0x71, 0x4C, 0x45, 0x97, 0x03, 0xBC, 0xA0,
-	0x9D, 0xF0, 0x4F, 0x5D, 0xEC, 0x40, 0x6C, 0xC6,
-	0x52, 0xC0, 0x9D, 0x1C, 0xDC, 0x8B, 0xC2, 0xFA,
-	0x35, 0xA7, 0x3A, 0x00, 0x04, 0x1C, 0xA6, 0x91,
-	0x5D, 0xEB, 0x07, 0xA1, 0xB9, 0x3E, 0xD1, 0xB6,
-	0xCA, 0x96, 0xEC, 0x71, 0xF7, 0x7D, 0xB6, 0x09,
-	0x3D, 0x19, 0x6E, 0x75, 0x03, 0xC3, 0x1A, 0x4E,
-	0x5B, 0x4D, 0xEA, 0xD9, 0x92, 0x96, 0x01, 0xFB,
-	0xA3, 0xC2, 0x6D, 0xC4, 0x17, 0x6B, 0xB4, 0x3B,
-	0x1E, 0x87, 0x54, 0x26, 0x95, 0x63, 0x07, 0x73,
-	0xB6, 0xBA, 0x52, 0xD7, 0xA7, 0xD0, 0x9C, 0x75,
-	0x8A, 0xCF, 0xC4, 0x3C, 0x4A, 0x55, 0x0E, 0x53,
-	0xEC, 0xE0, 0x31, 0x51, 0xB7, 0xB7, 0xD2, 0xB4,
-	0xF3, 0x2B, 0x70, 0x6D, 0x15, 0x9E, 0x57, 0x30,
-	0x72, 0xE5, 0xA4, 0x71, 0x5F, 0xA4, 0xE8, 0x7C,
-	0x46, 0x58, 0x36, 0x71, 0x91, 0x55, 0xAA, 0x99,
-	0x3B, 0x3F, 0xF6, 0xA2, 0x9D, 0x27, 0xBF, 0xC2,
-	0x62, 0x2C, 0x85, 0xB7, 0x51, 0xDD, 0xFD, 0x7B,
-	0x8B, 0xB5, 0xDD, 0x2A, 0x73, 0xF8, 0x93, 0x9A,
-	0x3F, 0xAD, 0x1D, 0xF0, 0x46, 0xD1, 0x76, 0x83,
-	0x71, 0x4E, 0xD3, 0x0D, 0x64, 0x8C, 0xC3, 0xE6,
-	0x03, 0xED, 0xE8, 0x53, 0x23, 0x1A, 0xC7, 0x86,
-	0xEB, 0x87, 0xD6, 0x78, 0xF9, 0xFB, 0x9C, 0x1D,
-	0xE7, 0x4E, 0xC0, 0x70, 0x27, 0x7A, 0x43, 0xE2,
-	0x5D, 0xA4, 0x10, 0x40, 0xBE, 0x61, 0x0D, 0x2B,
-	0x25, 0x08, 0x75, 0x91, 0xB5, 0x5A, 0x26, 0xC8,
-	0x32, 0xA7, 0xC6, 0x88, 0xBF, 0x75, 0x94, 0xCC,
-	0x58, 0xA4, 0xFE, 0x2F, 0xF7, 0x5C, 0xD2, 0x36,
-	0x66, 0x55, 0xF0, 0xEA, 0xF5, 0x64, 0x43, 0xE7,
-	0x6D, 0xE0, 0xED, 0xA1, 0x10, 0x0A, 0x84, 0x07,
-	0x11, 0x88, 0xFA, 0xA1, 0xD3, 0xA0, 0x00, 0x5D,
-	0xEB, 0xB5, 0x62, 0x01, 0x72, 0xC1, 0x9B, 0x39,
-	0x0B, 0xD3, 0xAF, 0x04, 0x19, 0x42, 0xEC, 0xFF,
-	0x4B, 0xB3, 0x5E, 0x87, 0x27, 0xE4, 0x26, 0x57,
-	0x76, 0xCD, 0x36, 0x31, 0x5B, 0x94, 0x74, 0xFF,
-	0x33, 0x91, 0xAA, 0xD1, 0x45, 0x34, 0xC2, 0x11,
-	0xF0, 0x35, 0x44, 0xC9, 0xD5, 0xA2, 0x5A, 0xC2,
-	0xE9, 0x9E, 0xCA, 0xE2, 0x6F, 0xD2, 0x40, 0xB4,
-	0x93, 0x42, 0x78, 0x20, 0x92, 0x88, 0xC7, 0x16,
-	0xCF, 0x15, 0x54, 0x7B, 0xE1, 0x46, 0x38, 0x69,
-	0xB8, 0xE4, 0xF1, 0x81, 0xF0, 0x08, 0x6F, 0x92,
-	0x6D, 0x1A, 0xD9, 0x93, 0xFA, 0xD7, 0x35, 0xFE,
-	0x7F, 0x59, 0x43, 0x1D, 0x3A, 0x3B, 0xFC, 0xD0,
-	0x14, 0x95, 0x1E, 0xB2, 0x04, 0x08, 0x4F, 0xC6,
-	0xEA, 0xE8, 0x22, 0xF3, 0xD7, 0x66, 0x93, 0xAA,
-	0xFD, 0xA0, 0xFE, 0x03, 0x96, 0x54, 0x78, 0x35,
-	0x18, 0xED, 0xB7, 0x2F, 0x40, 0xE3, 0x8E, 0x22,
-	0xC6, 0xDA, 0xB0, 0x8E, 0xA0, 0xA1, 0x62, 0x03,
-	0x63, 0x34, 0x11, 0xF5, 0x9E, 0xAA, 0x6B, 0xC4,
-	0x14, 0x75, 0x4C, 0xF4, 0xD8, 0xD9, 0xF1, 0x76,
-	0xE3, 0xD3, 0x55, 0xCE, 0x22, 0x7D, 0x4A, 0xB7,
-	0xBB, 0x7F, 0x4F, 0x09, 0x88, 0x70, 0x6E, 0x09,
-	0x84, 0x6B, 0x24, 0x19, 0x2C, 0x20, 0x73, 0x75
+	0x1D, 0x7C, 0x76, 0xED, 0xC2, 0x10, 0x3C, 0xB5,
+	0x14, 0x07, 0x3C, 0x33, 0x7B, 0xBE, 0x9E, 0xA9,
+	0x01, 0xC5, 0xAA, 0xA6, 0xB6, 0x7A, 0xE1, 0xDB,
+	0x39, 0xAA, 0xAA, 0xF4, 0xEE, 0xA7, 0x71, 0x71,
+	0x78, 0x0D, 0x5A, 0xD4, 0xF9, 0xCD, 0x75, 0xD1,
+	0x9C, 0x7F, 0xC8, 0x58, 0x46, 0x7A, 0xD1, 0x81,
+	0xEA, 0xCC, 0x08, 0xDC, 0x82, 0x73, 0x22, 0x08,
+	0x11, 0x73, 0x7C, 0xB1, 0x84, 0x6A, 0x8E, 0x67,
+	0x3F, 0x5D, 0xDB, 0x0E, 0xE2, 0xC2, 0xCB, 0x6D,
+	0x88, 0xEC, 0x3F, 0x50, 0x44, 0xD3, 0x47, 0x6E,
+	0xDD, 0x42, 0xDC, 0x2A, 0x5E, 0x5C, 0x50, 0x24,
+	0x57, 0x8A, 0xE7, 0xC5, 0x53, 0x6D, 0x89, 0x33,
+	0x21, 0x65, 0x82, 0xD6, 0xE9, 0xE7, 0x77, 0x10,
+	0xC2, 0x09, 0x91, 0xC1, 0x42, 0x62, 0x36, 0xF4,
+	0x43, 0x37, 0x95, 0xB3, 0x7E, 0x21, 0xC5, 0x3E,
+	0x65, 0xCB, 0xB6, 0xAA, 0xEC, 0xA5, 0xC6, 0x5C,
+	0x4D, 0xBE, 0x14, 0xF1, 0x98, 0xBF, 0x6C, 0x8A,
+	0x9E, 0x9F, 0xD4, 0xB4, 0xF2, 0x22, 0x96, 0x99,
+	0x37, 0x32, 0xB6, 0xC1, 0x04, 0x66, 0x52, 0x37,
+	0x5D, 0x5F, 0x58, 0x92, 0xC9, 0x97, 0xEA, 0x60,
+	0x60, 0x27, 0x57, 0xF9, 0x47, 0x4F, 0xBC, 0xDF,
+	0x05, 0xBD, 0x37, 0x87, 0xBB, 0x09, 0xA5, 0xBE,
+	0xC1, 0xFC, 0x32, 0x86, 0x6A, 0xB7, 0x8B, 0x1E,
+	0x6B, 0xCE, 0x8D, 0x81, 0x63, 0x4C, 0xF2, 0x7F,
+	0xD1, 0x45, 0x82, 0xE8, 0x0D, 0x1C, 0x4D, 0xA8,
+	0xBF, 0x2D, 0x2B, 0x52, 0xE5, 0xDB, 0xAB, 0xFD,
+	0x04, 0xA2, 0xA1, 0x1E, 0x21, 0x1D, 0x06, 0x9A,
+	0xC2, 0x7D, 0x99, 0xFC, 0xB4, 0x72, 0x89, 0x41,
+	0x55, 0x69, 0xFA, 0x1F, 0x78, 0x2F, 0x35, 0x59,
+	0xD7, 0x59, 0x6D, 0xA6, 0x45, 0xC9, 0x2B, 0x06,
+	0x6C, 0xEC, 0x83, 0x34, 0xA5, 0x08, 0xDB, 0x6F,
+	0xDE, 0x75, 0x21, 0x9B, 0xB0, 0xCB, 0x0A, 0xAE,
+	0x22, 0x99, 0x74, 0x1C, 0x9D, 0x37, 0x0E, 0xC6,
+	0x3A, 0x45, 0x49, 0xE5, 0xE3, 0x21, 0x11, 0xEA,
+	0x34, 0x25, 0xD5, 0x76, 0xB0, 0x30, 0x19, 0x87,
+	0x14, 0x3A, 0x10, 0x6F, 0x6D, 0xDD, 0xE9, 0x60,
+	0x6A, 0x00, 0x6A, 0x4C, 0x5B, 0x85, 0x3E, 0x1A,
+	0x41, 0xFA, 0xDE, 0x2D, 0x2F, 0x2E, 0x5B, 0x79,
+	0x09, 0x66, 0x65, 0xD0, 0xDB, 0x32, 0x05, 0xB5,
+	0xEA, 0xFB, 0x6A, 0xD5, 0x43, 0xF8, 0xBD, 0x98,
+	0x7B, 0x8E, 0x3B, 0x85, 0x89, 0x5D, 0xC5, 0x59,
+	0x54, 0x22, 0x75, 0xA8, 0x60, 0xDC, 0x0A, 0x37,
+	0x8C, 0xD8, 0x05, 0xEA, 0x62, 0x62, 0x71, 0x98,
+	0x0C, 0xCB, 0xCE, 0x0A, 0xD9, 0xE6, 0xE8, 0xA7,
+	0xB3, 0x2D, 0x89, 0xA7, 0x60, 0xF0, 0x42, 0xA7,
+	0x3D, 0x80, 0x44, 0xE7, 0xC1, 0xA6, 0x88, 0xB1,
+	0x4F, 0xC0, 0xB1, 0xAF, 0x40, 0xF3, 0x54, 0x72,
+	0x8F, 0xAF, 0x47, 0x96, 0x19, 0xEB, 0xA5, 0x5C,
+	0x00, 0x3B, 0x36, 0xC8, 0x3F, 0x1E, 0x63, 0x54,
+	0xF3, 0x3D, 0x85, 0x44, 0x9B, 0x9B, 0x20, 0xE3,
+	0x9D, 0xEF, 0x62, 0x21, 0xA1, 0x0B, 0x78, 0xF4,
+	0x2B, 0x89, 0x66, 0x5E, 0x97, 0xC6, 0xC4, 0x55,
+	0x35, 0x32, 0xD7, 0x44, 0x95, 0x9A, 0xE7, 0xF2,
+	0x57, 0x52, 0x5B, 0x92, 0x86, 0x8F, 0x8B, 0xCF,
+	0x41, 0x89, 0xF6, 0x2A, 0xD3, 0x42, 0x87, 0x43,
+	0x56, 0x1F, 0x0E, 0x49, 0xF1, 0x32, 0x6D, 0xA8,
+	0x62, 0xDF, 0x47, 0xBB, 0xB6, 0x53, 0xF8, 0x5C,
+	0x36, 0xDA, 0x34, 0x34, 0x2D, 0x2E, 0x1D, 0x33,
+	0xAF, 0x6A, 0x1E, 0xF1, 0xC9, 0x72, 0xB5, 0x3C,
+	0x64, 0x4C, 0x96, 0x12, 0x78, 0x67, 0x6A, 0xE5,
+	0x8B, 0x05, 0x80, 0xAE, 0x7D, 0xE5, 0x9B, 0x24,
+	0xDB, 0xFF, 0x1E, 0xB8, 0x36, 0x6D, 0x3D, 0x5D,
+	0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75
 };
 
 /* AES128-CTR-SHA1 test vector */
diff --git a/dpdk/app/test/test_cryptodev_asym.c b/dpdk/app/test/test_cryptodev_asym.c
index 69df293041..a0802994fa 100644
--- a/dpdk/app/test/test_cryptodev_asym.c
+++ b/dpdk/app/test/test_cryptodev_asym.c
@@ -933,8 +933,9 @@ testsuite_setup(void)
 	}
 
 	/* setup asym session pool */
-	unsigned int session_size =
-		rte_cryptodev_asym_get_private_session_size(dev_id);
+	unsigned int session_size = RTE_MAX(
+		rte_cryptodev_asym_get_private_session_size(dev_id),
+		rte_cryptodev_asym_get_header_session_size());
 	/*
 	 * Create mempool with TEST_NUM_SESSIONS * 2,
 	 * to include the session headers
diff --git a/dpdk/app/test/test_cryptodev_blockcipher.c b/dpdk/app/test/test_cryptodev_blockcipher.c
index 5bfe2d009f..2f91d000a2 100644
--- a/dpdk/app/test/test_cryptodev_blockcipher.c
+++ b/dpdk/app/test/test_cryptodev_blockcipher.c
@@ -93,7 +93,7 @@ test_blockcipher_one_case(const struct blockcipher_test_case *t,
 		uint64_t feat_flags = dev_info.feature_flags;
 		uint64_t oop_flag = RTE_CRYPTODEV_FF_OOP_SGL_IN_LB_OUT;
 
-		if (t->feature_mask && BLOCKCIPHER_TEST_FEATURE_OOP) {
+		if (t->feature_mask & BLOCKCIPHER_TEST_FEATURE_OOP) {
 			if (!(feat_flags & oop_flag)) {
 				printf("Device doesn't support out-of-place "
 					"scatter-gather in input mbuf. "
diff --git a/dpdk/app/test/test_cryptodev_hash_test_vectors.h b/dpdk/app/test/test_cryptodev_hash_test_vectors.h
index cff2831185..394bb6b60b 100644
--- a/dpdk/app/test/test_cryptodev_hash_test_vectors.h
+++ b/dpdk/app/test/test_cryptodev_hash_test_vectors.h
@@ -460,6 +460,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha1_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -473,6 +474,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha1_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -540,6 +542,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha224_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -553,6 +556,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha224_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -596,6 +600,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha256_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -609,6 +614,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha256_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -654,6 +660,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha384_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -667,6 +674,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha384_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -712,6 +720,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha512_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_GEN,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
@@ -724,6 +733,7 @@ static const struct blockcipher_test_case hash_test_cases[] = {
 		.test_data = &sha512_test_vector,
 		.op_mask = BLOCKCIPHER_TEST_OP_AUTH_VERIFY,
 		.pmd_mask = BLOCKCIPHER_TEST_TARGET_PMD_OPENSSL |
+			    BLOCKCIPHER_TEST_TARGET_PMD_QAT |
 			    BLOCKCIPHER_TEST_TARGET_PMD_CCP |
 			    BLOCKCIPHER_TEST_TARGET_PMD_MVSAM |
 #if IMB_VERSION_NUM >= IMB_VERSION(0, 52, 0)
diff --git a/dpdk/app/test/test_cryptodev_mixed_test_vectors.h b/dpdk/app/test/test_cryptodev_mixed_test_vectors.h
index bca47c05c8..f50dcb0457 100644
--- a/dpdk/app/test/test_cryptodev_mixed_test_vectors.h
+++ b/dpdk/app/test/test_cryptodev_mixed_test_vectors.h
@@ -126,9 +126,9 @@ struct mixed_cipher_auth_test_data auth_aes_cmac_cipher_aes_ctr_test_case_1 = {
 			0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A,
 			0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A,
 			0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A,
-			0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A, 0x5A,
+			0x5A, 0x5A, 0x5A, 0x5A
 		},
-		.len_bits = 128 << 3,
+		.len_bits = 124 << 3,
 	},
 	.ciphertext = {
 		.data = {
@@ -169,4 +169,1320 @@ struct mixed_cipher_auth_test_data auth_aes_cmac_cipher_aes_ctr_test_case_1 = {
 	}
 };
 
+struct mixed_cipher_auth_test_data auth_zuc_cipher_snow_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_ZUC_EIA3,
+	.auth_key = {
+		.data = {
+			0xc9, 0xe6, 0xce, 0xc4, 0x60, 0x7c, 0x72, 0xdb,
+			0x00, 0x0a, 0xef, 0xa8, 0x83, 0x85, 0xab, 0x0a
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0xa9, 0x40, 0x59, 0xda, 0x50, 0x00, 0x00, 0x00,
+			0x29, 0x40, 0x59, 0xda, 0x50, 0x00, 0x80, 0x00
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 73 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_SNOW3G_UEA2,
+	.cipher_key = {
+		.data = {
+			0xc9, 0xe6, 0xce, 0xc4, 0x60, 0x7c, 0x72, 0xdb,
+			0x00, 0x0a, 0xef, 0xa8, 0x83, 0x85, 0xab, 0x0a
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0xa9, 0x40, 0x59, 0xda, 0x50, 0x00, 0x00, 0x00,
+			0x29, 0x40, 0x59, 0xda, 0x50, 0x00, 0x80, 0x00
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 77 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0x98, 0x3b, 0x41, 0xd4, 0x7d, 0x78, 0x0c, 0x9e,
+			0x1a, 0xd1, 0x1d, 0x7e, 0xb7, 0x03, 0x91, 0xb1,
+			0xde, 0x0b, 0x35, 0xda, 0x2d, 0xc6, 0x2f, 0x83,
+			0xe7, 0xb7, 0x8d, 0x63, 0x06, 0xca, 0x0e, 0xa0,
+			0x7e, 0x94, 0x1b, 0x7b, 0xe9, 0x13, 0x48, 0xf9,
+			0xfc, 0xb1, 0x70, 0xe2, 0x21, 0x7f, 0xec, 0xd9,
+			0x7f, 0x9f, 0x68, 0xad, 0xb1, 0x6e, 0x5d, 0x7d,
+			0x21, 0xe5, 0x69, 0xd2, 0x80, 0xed, 0x77, 0x5c,
+			0xeb, 0xde, 0x3f, 0x40, 0x93, 0xc5, 0x38, 0x81,
+			0x00
+		},
+		.len_bits = 73 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x18, 0x46, 0xE1, 0xC5, 0x2C, 0x85, 0x93, 0x22,
+			0x84, 0x80, 0xD6, 0x84, 0x5C, 0x99, 0x55, 0xE0,
+			0xD5, 0x02, 0x41, 0x74, 0x4A, 0xD2, 0x8E, 0x7E,
+			0xB9, 0x79, 0xD3, 0xE5, 0x76, 0x75, 0xD5, 0x59,
+			0x26, 0xD7, 0x06, 0x2D, 0xF4, 0x71, 0x26, 0x40,
+			0xAC, 0x77, 0x62, 0xAC, 0x35, 0x0D, 0xC5, 0x35,
+			0xF8, 0x03, 0x54, 0x52, 0x2E, 0xCA, 0x14, 0xD8,
+			0x2E, 0x6C, 0x0E, 0x7A, 0x09, 0xE7, 0x20, 0xDD,
+			0x7C, 0xE3, 0x28, 0x77, 0x53, 0x65, 0xBA, 0x54,
+			0xE8, 0x25, 0x04, 0x52, 0xFD
+		},
+		.len_bits = 77 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x25, 0x04, 0x52, 0xFD
+		},
+		.len = 4,
+		.offset = 73,
+	},
+	.validDataLen = {
+		.len_bits = 77 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 77 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 73 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_aes_cmac_cipher_snow_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_AES_CMAC,
+	.auth_key = {
+		.data = {
+			0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6,
+			0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+		},
+		.len = 0,
+	},
+	.auth = {
+		.len_bits = 512 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_SNOW3G_UEA2,
+	.cipher_key = {
+		.data = {
+			0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6,
+			0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+		},
+		.len = 0,
+	},
+	.cipher = {
+		.len_bits = 516 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+			0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+			0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+			0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+			0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+			0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+			0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+			0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+			0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+			0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+			0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+			0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+			0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+			0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+			0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+			0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
+			0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+			0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+			0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+			0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+			0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+			0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+			0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+			0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+			0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+			0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+			0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+			0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+			0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+			0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+			0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+			0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+			0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+			0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+			0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+			0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+			0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+			0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+			0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+			0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+			0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+			0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+			0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+			0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+			0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+			0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+			0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+			0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+			0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+			0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+			0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+			0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+			0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+			0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x77, 0x69, 0x6E, 0x6E, 0x65, 0x72, 0x73,
+			0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x6C, 0x6F,
+			0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75
+		},
+		.len_bits = 512 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x8A, 0xA9, 0x74, 0x31, 0xB1, 0xF2, 0xAB, 0x00,
+			0xD6, 0x3D, 0xFA, 0xBD, 0xD9, 0x65, 0x52, 0x80,
+			0xB5, 0x98, 0x20, 0xFF, 0x8D, 0x1C, 0x0F, 0x53,
+			0xDD, 0x79, 0xCC, 0x9D, 0x7A, 0x6D, 0x76, 0x06,
+			0xB6, 0xF4, 0xAC, 0xDA, 0xF2, 0x24, 0x02, 0x58,
+			0x5F, 0xE3, 0xD4, 0xF7, 0x0B, 0x3B, 0x1C, 0x4C,
+			0x0B, 0x4C, 0xC7, 0x4D, 0x3D, 0xFA, 0x28, 0xD9,
+			0xA0, 0x90, 0x3E, 0x91, 0xDC, 0xC4, 0xE1, 0x2E,
+			0x7C, 0xB4, 0xBD, 0xE0, 0x9E, 0xC8, 0x33, 0x42,
+			0x0E, 0x84, 0xEF, 0x3C, 0xF1, 0x8B, 0x2C, 0xBD,
+			0x33, 0x70, 0x22, 0xBA, 0xD4, 0x0B, 0xB2, 0x83,
+			0x7F, 0x27, 0x51, 0x92, 0xD1, 0x40, 0x1E, 0xCD,
+			0x62, 0x0F, 0x61, 0x5F, 0xB4, 0xB1, 0x0D, 0x1A,
+			0x16, 0x1B, 0xE8, 0xA8, 0x2B, 0x45, 0xBA, 0x56,
+			0x30, 0xD0, 0xE3, 0xCA, 0x4D, 0x23, 0xA3, 0x38,
+			0xD6, 0x2C, 0xE4, 0x8D, 0xFF, 0x23, 0x97, 0x9E,
+			0xE9, 0xBD, 0x70, 0xAF, 0x6B, 0x68, 0xA7, 0x21,
+			0x3C, 0xFB, 0xB2, 0x99, 0x4D, 0xE9, 0x70, 0x56,
+			0x36, 0xB8, 0xD7, 0xE0, 0xEB, 0x62, 0xA1, 0x79,
+			0xF9, 0xD6, 0xAD, 0x83, 0x75, 0x54, 0xF5, 0x45,
+			0x82, 0xE8, 0xD6, 0xA9, 0x76, 0x11, 0xC7, 0x81,
+			0x2C, 0xBA, 0x67, 0xB5, 0xDB, 0xE5, 0xF2, 0x6B,
+			0x7D, 0x9F, 0x4E, 0xDC, 0xA1, 0x62, 0xF1, 0xF0,
+			0xAD, 0xD4, 0x7A, 0xA3, 0xF3, 0x76, 0x29, 0xA4,
+			0xB7, 0xF3, 0x31, 0x84, 0xE7, 0x1F, 0x0D, 0x01,
+			0xBD, 0x46, 0x07, 0x51, 0x05, 0x76, 0xE2, 0x95,
+			0xF8, 0x48, 0x18, 0x8A, 0x1E, 0x92, 0x8B, 0xBC,
+			0x30, 0x05, 0xF5, 0xD6, 0x96, 0xEF, 0x78, 0xB6,
+			0xF3, 0xEC, 0x4C, 0xB1, 0x88, 0x8B, 0x63, 0x40,
+			0x07, 0x37, 0xB4, 0x1A, 0xBD, 0xE9, 0x38, 0xB4,
+			0x31, 0x35, 0x9D, 0x0C, 0xF1, 0x24, 0x0E, 0xD2,
+			0xAE, 0x39, 0xA6, 0x41, 0x3C, 0x91, 0x6A, 0x4B,
+			0xEC, 0x46, 0x76, 0xB4, 0x15, 0xC3, 0x58, 0x96,
+			0x69, 0x02, 0x21, 0x37, 0x65, 0xDF, 0xA6, 0x43,
+			0x78, 0x81, 0x8B, 0x39, 0x37, 0xE3, 0xF3, 0xD9,
+			0xA2, 0xAA, 0x3F, 0xA9, 0x21, 0x24, 0x93, 0x4A,
+			0xB0, 0xDE, 0x22, 0x5F, 0xF8, 0xD3, 0xCC, 0x13,
+			0x5C, 0xC2, 0x5C, 0x98, 0x6D, 0xFB, 0x34, 0x26,
+			0xE2, 0xC9, 0x26, 0x23, 0x41, 0xAB, 0xC3, 0x8A,
+			0xEC, 0x62, 0xA9, 0x5B, 0x51, 0xB9, 0x10, 0x9D,
+			0xB1, 0xBB, 0xDE, 0x78, 0xDE, 0xE7, 0xF0, 0x9F,
+			0x91, 0x6C, 0x4D, 0xFC, 0xB3, 0x9C, 0xFF, 0xA4,
+			0x9D, 0xB8, 0xCD, 0xF6, 0xA8, 0x6A, 0xDB, 0x3B,
+			0x82, 0xFE, 0xCD, 0x6B, 0x08, 0x0A, 0x5E, 0x76,
+			0xE9, 0xB3, 0xA2, 0x78, 0x25, 0xDB, 0xB1, 0x76,
+			0x42, 0x2C, 0xFB, 0x20, 0x87, 0x81, 0x76, 0x17,
+			0x99, 0xFD, 0x56, 0x52, 0xE2, 0xB0, 0x8E, 0x1B,
+			0x99, 0xB3, 0x6B, 0x16, 0xC5, 0x4F, 0x0D, 0xBB,
+			0x0E, 0xB7, 0x54, 0x63, 0xD9, 0x67, 0xD9, 0x85,
+			0x1F, 0xA8, 0xF0, 0xF0, 0xB0, 0x41, 0xDC, 0xBC,
+			0x75, 0xEE, 0x23, 0x7D, 0x40, 0xCE, 0xB8, 0x0A,
+			0x6D, 0xC1, 0xD7, 0xCB, 0xAE, 0xCE, 0x91, 0x9E,
+			0x3E, 0x5A, 0x76, 0xF8, 0xC0, 0xF2, 0x7F, 0x0B,
+			0xD2, 0x5F, 0x63, 0xBE, 0xB2, 0x81, 0x8E, 0x6D,
+			0xB3, 0x6B, 0x67, 0x9D, 0xAC, 0xE2, 0xDB, 0x7C,
+			0x11, 0x19, 0x55, 0x55, 0x11, 0xED, 0x7F, 0x4E,
+			0x9E, 0x4B, 0x6E, 0x01, 0x74, 0x4A, 0xE8, 0x78,
+			0xEC, 0xCD, 0xF7, 0xA2, 0x6E, 0xDB, 0xB6, 0x3B,
+			0x4D, 0x2C, 0x09, 0x62, 0x57, 0x6E, 0x38, 0x8A,
+			0x61, 0x17, 0x00, 0xE9, 0x86, 0x7F, 0x3D, 0x93,
+			0xBC, 0xC3, 0x27, 0x90, 0x7E, 0x41, 0x81, 0xBA,
+			0x74, 0x70, 0x19, 0xE8, 0xD2, 0x88, 0x61, 0xDF,
+			0xB4, 0xED, 0xA4, 0x9D, 0x3D, 0xED, 0x95, 0x65,
+			0xCA, 0xFF, 0x8D, 0x58, 0x63, 0x10, 0x9D, 0xBE,
+			0x78, 0x81, 0x47, 0x38
+		},
+		.len_bits = 516 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x78, 0x81, 0x47, 0x38
+		},
+		.len = 4,
+		.offset = 512,
+	},
+	.validDataLen = {
+		.len_bits = 516 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 516 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 512 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_zuc_cipher_aes_ctr_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_ZUC_EIA3,
+	.auth_key = {
+		.data = {
+			0xc9, 0xe6, 0xce, 0xc4, 0x60, 0x7c, 0x72, 0xdb,
+			0x00, 0x0a, 0xef, 0xa8, 0x83, 0x85, 0xab, 0x0a
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0xa9, 0x40, 0x59, 0xda, 0x50, 0x00, 0x00, 0x00,
+			0x29, 0x40, 0x59, 0xda, 0x50, 0x00, 0x80, 0x00
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 73 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_AES_CTR,
+	.cipher_key = {
+		.data = {
+			0xc9, 0xe6, 0xce, 0xc4, 0x60, 0x7c, 0x72, 0xdb,
+			0x00, 0x0a, 0xef, 0xa8, 0x83, 0x85, 0xab, 0x0a
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0xa9, 0x40, 0x59, 0xda, 0x50, 0x00, 0x00, 0x00,
+			0x29, 0x40, 0x59, 0xda, 0x50, 0x00, 0x80, 0x00
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 77 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0x98, 0x3b, 0x41, 0xd4, 0x7d, 0x78, 0x0c, 0x9e,
+			0x1a, 0xd1, 0x1d, 0x7e, 0xb7, 0x03, 0x91, 0xb1,
+			0xde, 0x0b, 0x35, 0xda, 0x2d, 0xc6, 0x2f, 0x83,
+			0xe7, 0xb7, 0x8d, 0x63, 0x06, 0xca, 0x0e, 0xa0,
+			0x7e, 0x94, 0x1b, 0x7b, 0xe9, 0x13, 0x48, 0xf9,
+			0xfc, 0xb1, 0x70, 0xe2, 0x21, 0x7f, 0xec, 0xd9,
+			0x7f, 0x9f, 0x68, 0xad, 0xb1, 0x6e, 0x5d, 0x7d,
+			0x21, 0xe5, 0x69, 0xd2, 0x80, 0xed, 0x77, 0x5c,
+			0xeb, 0xde, 0x3f, 0x40, 0x93, 0xc5, 0x38, 0x81,
+			0x00
+		},
+		.len_bits = 73 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x53, 0x92, 0x9F, 0x88, 0x32, 0xA1, 0x6D, 0x66,
+			0x00, 0x32, 0x29, 0xF9, 0x14, 0x75, 0x6D, 0xB3,
+			0xEB, 0x64, 0x25, 0x09, 0xE1, 0x80, 0x31, 0x8C,
+			0xF8, 0x47, 0x64, 0xAA, 0x07, 0x8E, 0x06, 0xBF,
+			0x05, 0xD7, 0x43, 0xEE, 0xFF, 0x11, 0x33, 0x4A,
+			0x82, 0xCF, 0x88, 0x6F, 0x33, 0xB2, 0xB5, 0x67,
+			0x50, 0x0A, 0x74, 0x2D, 0xE4, 0x56, 0x40, 0x31,
+			0xEE, 0xB3, 0x6C, 0x6E, 0x6A, 0x7B, 0x20, 0xBA,
+			0x4E, 0x44, 0x34, 0xC8, 0x62, 0x21, 0x8C, 0x45,
+			0xD7, 0x85, 0x44, 0xF4, 0x7E
+		},
+		.len_bits = 77 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x85, 0x44, 0xF4, 0x7E
+		},
+		.len = 4,
+		.offset = 73,
+	},
+	.validDataLen = {
+		.len_bits = 77 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 77 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 73 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_snow_cipher_aes_ctr_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_SNOW3G_UIA2,
+	.auth_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 48 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_AES_CTR,
+	.cipher_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 52 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A, 0x50, 0x42, 0x70, 0x09
+		},
+		.len_bits = 48 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x91, 0x96, 0x28, 0xB4, 0x89, 0x74, 0xF6, 0x5E,
+			0x98, 0x58, 0xA1, 0xD3, 0x0E, 0xE3, 0xFC, 0x39,
+			0xDB, 0x36, 0xE4, 0x97, 0x74, 0x5B, 0x5E, 0xD4,
+			0x1B, 0x8A, 0xC5, 0x9D, 0xDF, 0x96, 0x97, 0x5F,
+			0x58, 0x4A, 0x75, 0x74, 0x27, 0x07, 0xF3, 0x7F,
+			0xCE, 0x2C, 0x4A, 0x6C, 0xE5, 0x19, 0xE7, 0x8B,
+			0xF3, 0x21, 0x84, 0x6C
+		},
+		.len_bits = 52 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0xF3, 0x21, 0x84, 0x6C
+		},
+		.len = 4,
+		.offset = 48,
+	},
+	.validDataLen = {
+		.len_bits = 52 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 52 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 48 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_snow_cipher_zuc_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_SNOW3G_UIA2,
+	.auth_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 48 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_ZUC_EEA3,
+	.cipher_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 52 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A, 0x50, 0x42, 0x70, 0x09
+		},
+		.len_bits = 48 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x52, 0x11, 0xCD, 0xFF, 0xF8, 0x88, 0x61, 0x1E,
+			0xF5, 0xD2, 0x8E, 0xEB, 0x2A, 0x49, 0x18, 0x1F,
+			0xF4, 0xDA, 0x8B, 0x19, 0x60, 0x0B, 0x92, 0x9E,
+			0x79, 0x2A, 0x5B, 0x0B, 0x7E, 0xC6, 0x22, 0x36,
+			0x74, 0xA4, 0x6C, 0xBC, 0xF5, 0x25, 0x69, 0xAE,
+			0xDA, 0x04, 0xB9, 0xAF, 0x16, 0x42, 0x0F, 0xCB,
+			0x3E, 0xC9, 0x49, 0xE9
+		},
+		.len_bits = 52 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x3E, 0xC9, 0x49, 0xE9
+		},
+		.len = 4,
+		.offset = 48,
+	},
+	.validDataLen = {
+		.len_bits = 52 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 52 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 48 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_aes_cmac_cipher_zuc_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_AES_CMAC,
+	.auth_key = {
+		.data = {
+			0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6,
+			0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+		},
+		.len = 0,
+	},
+	.auth = {
+		.len_bits = 512 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_ZUC_EEA3,
+	.cipher_key = {
+		.data = {
+			0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6,
+			0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+		},
+		.len = 0,
+	},
+	.cipher = {
+		.len_bits = 516 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+			0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+			0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+			0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+			0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+			0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+			0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+			0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+			0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+			0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+			0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+			0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+			0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+			0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+			0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+			0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
+			0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+			0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+			0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+			0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+			0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+			0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+			0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+			0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+			0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+			0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+			0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+			0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+			0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+			0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+			0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+			0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+			0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+			0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+			0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+			0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+			0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+			0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+			0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+			0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+			0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+			0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+			0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+			0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+			0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+			0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+			0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+			0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+			0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+			0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+			0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+			0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+			0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+			0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x77, 0x69, 0x6E, 0x6E, 0x65, 0x72, 0x73,
+			0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x6C, 0x6F,
+			0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75
+		},
+		.len_bits = 512 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x3C, 0x89, 0x1C, 0xE5, 0xB7, 0xDE, 0x61, 0x4D,
+			0x05, 0x37, 0x3F, 0x40, 0xC9, 0xCF, 0x10, 0x07,
+			0x7F, 0x18, 0xC5, 0x96, 0x21, 0xA9, 0xCF, 0xF5,
+			0xBB, 0x9C, 0x22, 0x72, 0x00, 0xBE, 0xAC, 0x4B,
+			0x55, 0x02, 0x19, 0x2B, 0x37, 0x64, 0x15, 0x6B,
+			0x54, 0x74, 0xAE, 0x0F, 0xE7, 0x68, 0xB3, 0x92,
+			0x17, 0x26, 0x75, 0xEE, 0x0B, 0xE9, 0x46, 0x3C,
+			0x6E, 0x76, 0x52, 0x14, 0x2B, 0xD0, 0xB6, 0xD0,
+			0x09, 0x07, 0x17, 0x12, 0x58, 0x61, 0xE8, 0x2A,
+			0x7C, 0x55, 0x67, 0x66, 0x49, 0xD1, 0x4E, 0x2F,
+			0x06, 0x96, 0x3A, 0xF7, 0x05, 0xE3, 0x65, 0x47,
+			0x7C, 0xBB, 0x66, 0x25, 0xC4, 0x73, 0xB3, 0x7B,
+			0x3D, 0x1D, 0x59, 0x54, 0x4E, 0x38, 0x9C, 0x4D,
+			0x10, 0x4B, 0x49, 0xA4, 0x92, 0xC7, 0xD7, 0x17,
+			0x6F, 0xC0, 0xEE, 0x8D, 0xBE, 0xA5, 0xE3, 0xB9,
+			0xBA, 0x5E, 0x88, 0x36, 0x06, 0x19, 0xB7, 0x86,
+			0x66, 0x19, 0x90, 0xC4, 0xAE, 0xB3, 0xFE, 0xA7,
+			0xCF, 0x2A, 0xD8, 0x6C, 0x0E, 0xD5, 0x24, 0x2A,
+			0x92, 0x93, 0xB9, 0x12, 0xCB, 0x50, 0x0A, 0x22,
+			0xB0, 0x09, 0x06, 0x17, 0x85, 0xC9, 0x03, 0x70,
+			0x18, 0xF2, 0xD5, 0x6A, 0x66, 0xC2, 0xB6, 0xC6,
+			0xA5, 0xA3, 0x24, 0xEC, 0xB9, 0x07, 0xD5, 0x8A,
+			0xA0, 0x44, 0x54, 0xD7, 0x21, 0x9F, 0x02, 0x83,
+			0x78, 0x7B, 0x78, 0x9C, 0x97, 0x2A, 0x36, 0x51,
+			0xAF, 0xE1, 0x79, 0x81, 0x07, 0x53, 0xE4, 0xA0,
+			0xC7, 0xCF, 0x10, 0x7C, 0xB2, 0xE6, 0xA1, 0xFD,
+			0x81, 0x0B, 0x96, 0x50, 0x5D, 0xFE, 0xB3, 0xC6,
+			0x75, 0x00, 0x0C, 0x56, 0x83, 0x9B, 0x7B, 0xF4,
+			0xE0, 0x3A, 0xC0, 0xE1, 0xA9, 0xEC, 0xAC, 0x47,
+			0x24, 0xF5, 0x12, 0x1B, 0xD0, 0x28, 0x32, 0xE2,
+			0x3B, 0x42, 0xC1, 0x5B, 0x98, 0x98, 0x78, 0x2D,
+			0xC1, 0x69, 0x05, 0x37, 0x24, 0xF0, 0x73, 0xBA,
+			0xBE, 0x57, 0xAC, 0x40, 0x9A, 0x91, 0x42, 0x49,
+			0x31, 0x0F, 0xED, 0x45, 0xA8, 0x25, 0xFF, 0x1B,
+			0xF4, 0x2F, 0x61, 0x7A, 0xB0, 0x60, 0xC6, 0x5E,
+			0x0E, 0xF6, 0x96, 0x35, 0x90, 0xAF, 0x3B, 0x9D,
+			0x4D, 0x6C, 0xE7, 0xF2, 0x4F, 0xC0, 0xBA, 0x57,
+			0x92, 0x18, 0xB7, 0xF5, 0x1D, 0x06, 0x81, 0xF6,
+			0xE3, 0xF4, 0x66, 0x8C, 0x33, 0x74, 0xBE, 0x64,
+			0x8C, 0x18, 0xED, 0x7F, 0x68, 0x2A, 0xE4, 0xAF,
+			0xF1, 0x02, 0x07, 0x51, 0x22, 0x96, 0xC8, 0x9E,
+			0x23, 0x7F, 0x6A, 0xD7, 0x80, 0x0F, 0x2D, 0xFC,
+			0xCC, 0xD0, 0x95, 0x86, 0x00, 0x2A, 0x77, 0xDD,
+			0xA2, 0x60, 0x1E, 0x0F, 0x8E, 0x42, 0x44, 0x37,
+			0x7E, 0x33, 0xC4, 0xE0, 0x04, 0x53, 0xF6, 0x3F,
+			0xDD, 0x1D, 0x5E, 0x24, 0xDA, 0xAE, 0xEF, 0x06,
+			0x06, 0x05, 0x13, 0x3A, 0x1E, 0xFF, 0xAD, 0xAD,
+			0xEE, 0x0F, 0x6F, 0x05, 0xA5, 0xFB, 0x3B, 0xC3,
+			0xDB, 0xA0, 0x20, 0xC1, 0x65, 0x8B, 0x39, 0xAB,
+			0xC9, 0xEC, 0xA8, 0x31, 0x85, 0x6C, 0xD2, 0xE4,
+			0x76, 0x77, 0x76, 0xD5, 0x81, 0x01, 0x73, 0x36,
+			0x08, 0x8C, 0xC3, 0xD4, 0x70, 0x7A, 0xA3, 0xDF,
+			0xAD, 0x3A, 0x00, 0x46, 0x88, 0x65, 0x10, 0xBE,
+			0xD8, 0x1C, 0x19, 0x98, 0xE9, 0x29, 0xDD, 0x58,
+			0x46, 0x31, 0xEB, 0x3D, 0xD0, 0x12, 0x02, 0x83,
+			0x15, 0xDD, 0x70, 0x27, 0x0D, 0xB5, 0xBB, 0x0C,
+			0xE3, 0xF1, 0x02, 0xF2, 0xD7, 0x1D, 0x17, 0x6D,
+			0xDF, 0x2A, 0x42, 0x1F, 0x01, 0x5C, 0x68, 0xB1,
+			0x64, 0x74, 0xCE, 0x74, 0xB1, 0x3C, 0x2F, 0x43,
+			0x5F, 0xB7, 0x7E, 0x3E, 0x6F, 0xE3, 0xDC, 0x03,
+			0xD9, 0x0C, 0xDD, 0x42, 0x65, 0x7F, 0xEA, 0x69,
+			0x6F, 0xDB, 0xD7, 0xFB, 0xFF, 0x4D, 0xB4, 0x48,
+			0xFE, 0x0F, 0x59, 0x24, 0x8F, 0x13, 0xA8, 0x60,
+			0xF7, 0x13, 0xE5, 0xB1, 0x8D, 0xB7, 0x70, 0xEE,
+			0x82, 0x8F, 0xCF, 0x7E
+		},
+		.len_bits = 516 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x82, 0x8F, 0xCF, 0x7E
+		},
+		.len = 4,
+		.offset = 512,
+	},
+	.validDataLen = {
+		.len_bits = 516 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 516 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 512 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_null_cipher_snow_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_NULL,
+	.auth_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 44 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_SNOW3G_UEA2,
+	.cipher_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 48 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A,
+		},
+		.len_bits = 44 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x95, 0x2E, 0x5A, 0xE1, 0x50, 0xB8, 0x59, 0x2A,
+			0x9B, 0xA0, 0x38, 0xA9, 0x8E, 0x2F, 0xED, 0xAB,
+			0xFD, 0xC8, 0x3B, 0x47, 0x46, 0x0B, 0x50, 0x16,
+			0xEC, 0x88, 0x45, 0xB6, 0x05, 0xC7, 0x54, 0xF8,
+			0xBD, 0x91, 0xAA, 0xB6, 0xA4, 0xDC, 0x64, 0xB4,
+			0xCB, 0xEB, 0x97, 0x06, 0x1C, 0xB5, 0x72, 0x34
+		},
+		.len_bits = 48 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x1C, 0xB5, 0x72, 0x34
+		},
+		.len = 4,
+		.offset = 44,
+	},
+	.validDataLen = {
+		.len_bits = 48 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 48 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 44 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_null_cipher_zuc_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_NULL,
+	.auth_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 48 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_ZUC_EEA3,
+	.cipher_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 52 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A, 0x50, 0x42, 0x70, 0x09
+		},
+		.len_bits = 48 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x52, 0x11, 0xCD, 0xFF, 0xF8, 0x88, 0x61, 0x1E,
+			0xF5, 0xD2, 0x8E, 0xEB, 0x2A, 0x49, 0x18, 0x1F,
+			0xF4, 0xDA, 0x8B, 0x19, 0x60, 0x0B, 0x92, 0x9E,
+			0x79, 0x2A, 0x5B, 0x0B, 0x7E, 0xC6, 0x22, 0x36,
+			0x74, 0xA4, 0x6C, 0xBC, 0xF5, 0x25, 0x69, 0xAE,
+			0xDA, 0x04, 0xB9, 0xAF, 0x16, 0x42, 0x0F, 0xCB,
+			0x06, 0x7C, 0x1D, 0x29
+		},
+		.len_bits = 52 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x06, 0x7C, 0x1D, 0x29
+		},
+		.len = 4,
+		.offset = 48,
+	},
+	.validDataLen = {
+		.len_bits = 52 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 52 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 48 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_snow_cipher_null_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_SNOW3G_UIA2,
+	.auth_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 48 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_NULL,
+	.cipher_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 52 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A, 0x50, 0x42, 0x70, 0x09
+		},
+		.len_bits = 48 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A, 0x50, 0x42, 0x70, 0x09,
+			0x38, 0xB5, 0x54, 0xC0
+		},
+		.len_bits = 52 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x38, 0xB5, 0x54, 0xC0
+		},
+		.len = 4,
+		.offset = 48,
+	},
+	.validDataLen = {
+		.len_bits = 52 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 52 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 48 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_zuc_cipher_null_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_ZUC_EIA3,
+	.auth_key = {
+		.data = {
+			0xc9, 0xe6, 0xce, 0xc4, 0x60, 0x7c, 0x72, 0xdb,
+			0x00, 0x0a, 0xef, 0xa8, 0x83, 0x85, 0xab, 0x0a
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0xa9, 0x40, 0x59, 0xda, 0x50, 0x00, 0x00, 0x00,
+			0x29, 0x40, 0x59, 0xda, 0x50, 0x00, 0x80, 0x00
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 73 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_NULL,
+	.cipher_key = {
+		.data = {
+			0xc9, 0xe6, 0xce, 0xc4, 0x60, 0x7c, 0x72, 0xdb,
+			0x00, 0x0a, 0xef, 0xa8, 0x83, 0x85, 0xab, 0x0a
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0xa9, 0x40, 0x59, 0xda, 0x50, 0x00, 0x00, 0x00,
+			0x29, 0x40, 0x59, 0xda, 0x50, 0x00, 0x80, 0x00
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 77 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0x98, 0x3b, 0x41, 0xd4, 0x7d, 0x78, 0x0c, 0x9e,
+			0x1a, 0xd1, 0x1d, 0x7e, 0xb7, 0x03, 0x91, 0xb1,
+			0xde, 0x0b, 0x35, 0xda, 0x2d, 0xc6, 0x2f, 0x83,
+			0xe7, 0xb7, 0x8d, 0x63, 0x06, 0xca, 0x0e, 0xa0,
+			0x7e, 0x94, 0x1b, 0x7b, 0xe9, 0x13, 0x48, 0xf9,
+			0xfc, 0xb1, 0x70, 0xe2, 0x21, 0x7f, 0xec, 0xd9,
+			0x7f, 0x9f, 0x68, 0xad, 0xb1, 0x6e, 0x5d, 0x7d,
+			0x21, 0xe5, 0x69, 0xd2, 0x80, 0xed, 0x77, 0x5c,
+			0xeb, 0xde, 0x3f, 0x40, 0x93, 0xc5, 0x38, 0x81,
+			0x00
+		},
+		.len_bits = 73 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x98, 0x3b, 0x41, 0xd4, 0x7d, 0x78, 0x0c, 0x9e,
+			0x1a, 0xd1, 0x1d, 0x7e, 0xb7, 0x03, 0x91, 0xb1,
+			0xde, 0x0b, 0x35, 0xda, 0x2d, 0xc6, 0x2f, 0x83,
+			0xe7, 0xb7, 0x8d, 0x63, 0x06, 0xca, 0x0e, 0xa0,
+			0x7e, 0x94, 0x1b, 0x7b, 0xe9, 0x13, 0x48, 0xf9,
+			0xfc, 0xb1, 0x70, 0xe2, 0x21, 0x7f, 0xec, 0xd9,
+			0x7f, 0x9f, 0x68, 0xad, 0xb1, 0x6e, 0x5d, 0x7d,
+			0x21, 0xe5, 0x69, 0xd2, 0x80, 0xed, 0x77, 0x5c,
+			0xeb, 0xde, 0x3f, 0x40, 0x93, 0xc5, 0x38, 0x81,
+			0x00, 0x24, 0xa8, 0x42, 0xb3
+		},
+		.len_bits = 77 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x24, 0xa8, 0x42, 0xb3
+		},
+		.len = 4,
+		.offset = 73,
+	},
+	.validDataLen = {
+		.len_bits = 77 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 77 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 73 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_null_cipher_aes_ctr_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_NULL,
+	.auth_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.auth = {
+		.len_bits = 48 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_AES_CTR,
+	.cipher_key = {
+		.data = {
+			0xC7, 0x36, 0xC6, 0xAA, 0xB2, 0x2B, 0xFF, 0xF9,
+			0x1E, 0x26, 0x98, 0xD2, 0xE2, 0x2A, 0xD5, 0x7E
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+			0x14, 0x79, 0x3E, 0x41, 0x03, 0x97, 0xE8, 0xFD,
+			0x94, 0x79, 0x3E, 0x41, 0x03, 0x97, 0x68, 0xFD
+		},
+		.len = 16,
+	},
+	.cipher = {
+		.len_bits = 52 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0xD0, 0xA7, 0xD4, 0x63, 0xDF, 0x9F, 0xB2, 0xB2,
+			0x78, 0x83, 0x3F, 0xA0, 0x2E, 0x23, 0x5A, 0xA1,
+			0x72, 0xBD, 0x97, 0x0C, 0x14, 0x73, 0xE1, 0x29,
+			0x07, 0xFB, 0x64, 0x8B, 0x65, 0x99, 0xAA, 0xA0,
+			0xB2, 0x4A, 0x03, 0x86, 0x65, 0x42, 0x2B, 0x20,
+			0xA4, 0x99, 0x27, 0x6A, 0x50, 0x42, 0x70, 0x09
+		},
+		.len_bits = 48 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x91, 0x96, 0x28, 0xB4, 0x89, 0x74, 0xF6, 0x5E,
+			0x98, 0x58, 0xA1, 0xD3, 0x0E, 0xE3, 0xFC, 0x39,
+			0xDB, 0x36, 0xE4, 0x97, 0x74, 0x5B, 0x5E, 0xD4,
+			0x1B, 0x8A, 0xC5, 0x9D, 0xDF, 0x96, 0x97, 0x5F,
+			0x58, 0x4A, 0x75, 0x74, 0x27, 0x07, 0xF3, 0x7F,
+			0xCE, 0x2C, 0x4A, 0x6C, 0xE5, 0x19, 0xE7, 0x8B,
+			0xCB, 0x94, 0xD0, 0xAC
+		},
+		.len_bits = 52 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0xCB, 0x94, 0xD0, 0xAC
+		},
+		.len = 4,
+		.offset = 48,
+	},
+	.validDataLen = {
+		.len_bits = 52 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 52 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 48 << 3,
+	}
+};
+
+struct mixed_cipher_auth_test_data auth_aes_cmac_cipher_null_test_case_1 = {
+	.auth_algo = RTE_CRYPTO_AUTH_AES_CMAC,
+	.auth_key = {
+		.data = {
+			0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6,
+			0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C
+		},
+		.len = 16,
+	},
+	.auth_iv = {
+		.data = {
+		},
+		.len = 0,
+	},
+	.auth = {
+		.len_bits = 512 << 3,
+		.offset_bits = 0,
+	},
+	.cipher_algo = RTE_CRYPTO_CIPHER_NULL,
+	.cipher_key = {
+		.data = {
+			0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6,
+			0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C
+		},
+		.len = 16,
+	},
+	.cipher_iv = {
+		.data = {
+		},
+		.len = 0,
+	},
+	.cipher = {
+		.len_bits = 516 << 3,
+		.offset_bits = 0,
+	},
+	.plaintext = {
+		.data = {
+			0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+			0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+			0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+			0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+			0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+			0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+			0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+			0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+			0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+			0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+			0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+			0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+			0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+			0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+			0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+			0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
+			0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+			0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+			0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+			0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+			0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+			0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+			0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+			0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+			0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+			0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+			0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+			0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+			0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+			0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+			0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+			0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+			0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+			0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+			0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+			0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+			0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+			0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+			0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+			0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+			0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+			0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+			0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+			0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+			0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+			0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+			0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+			0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+			0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+			0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+			0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+			0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+			0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+			0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x77, 0x69, 0x6E, 0x6E, 0x65, 0x72, 0x73,
+			0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x6C, 0x6F,
+			0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75
+		},
+		.len_bits = 512 << 3,
+	},
+	.ciphertext = {
+		.data = {
+			0x57, 0x68, 0x61, 0x74, 0x20, 0x61, 0x20, 0x6C,
+			0x6F, 0x75, 0x73, 0x79, 0x20, 0x65, 0x61, 0x72,
+			0x74, 0x68, 0x21, 0x20, 0x48, 0x65, 0x20, 0x77,
+			0x6F, 0x6E, 0x64, 0x65, 0x72, 0x65, 0x64, 0x20,
+			0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x70, 0x65, 0x6F, 0x70, 0x6C, 0x65, 0x20,
+			0x77, 0x65, 0x72, 0x65, 0x20, 0x64, 0x65, 0x73,
+			0x74, 0x69, 0x74, 0x75, 0x74, 0x65, 0x20, 0x74,
+			0x68, 0x61, 0x74, 0x20, 0x73, 0x61, 0x6D, 0x65,
+			0x20, 0x6E, 0x69, 0x67, 0x68, 0x74, 0x20, 0x65,
+			0x76, 0x65, 0x6E, 0x20, 0x69, 0x6E, 0x20, 0x68,
+			0x69, 0x73, 0x20, 0x6F, 0x77, 0x6E, 0x20, 0x70,
+			0x72, 0x6F, 0x73, 0x70, 0x65, 0x72, 0x6F, 0x75,
+			0x73, 0x20, 0x63, 0x6F, 0x75, 0x6E, 0x74, 0x72,
+			0x79, 0x2C, 0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D,
+			0x61, 0x6E, 0x79, 0x20, 0x68, 0x6F, 0x6D, 0x65,
+			0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x73,
Louis Abel's avatar
Louis Abel committed
8201 8202 8203 8204 8205 8206 8207 8208 8209 8210 8211 8212 8213 8214 8215 8216 8217 8218 8219 8220 8221 8222 8223 8224 8225 8226 8227 8228 8229 8230 8231 8232 8233 8234 8235 8236 8237 8238 8239 8240 8241 8242 8243 8244 8245 8246 8247 8248 8249 8250 8251 8252 8253 8254 8255 8256 8257 8258 8259 8260 8261 8262 8263 8264 8265 8266 8267 8268 8269 8270 8271 8272 8273 8274 8275 8276 8277 8278 8279 8280 8281 8282 8283 8284 8285 8286 8287 8288 8289 8290 8291 8292 8293 8294 8295 8296 8297 8298 8299 8300 8301 8302 8303 8304 8305 8306 8307 8308 8309 8310 8311 8312 8313 8314 8315 8316 8317 8318 8319 8320 8321 8322 8323 8324 8325 8326 8327 8328 8329 8330 8331 8332 8333 8334 8335 8336 8337 8338 8339 8340 8341 8342 8343 8344 8345 8346 8347 8348 8349 8350 8351 8352 8353 8354 8355 8356 8357 8358 8359 8360 8361 8362 8363 8364 8365 8366 8367 8368 8369 8370 8371 8372 8373 8374 8375 8376 8377 8378 8379 8380 8381 8382 8383 8384 8385 8386 8387 8388 8389 8390 8391 8392 8393 8394 8395 8396 8397 8398 8399 8400 8401 8402 8403 8404 8405 8406 8407 8408 8409 8410 8411 8412 8413 8414 8415 8416 8417 8418 8419 8420 8421 8422 8423 8424 8425 8426 8427 8428 8429 8430 8431 8432 8433 8434 8435 8436 8437 8438 8439 8440 8441 8442 8443 8444 8445 8446 8447 8448 8449 8450 8451 8452 8453 8454 8455 8456 8457 8458 8459 8460 8461 8462 8463 8464 8465 8466 8467 8468 8469 8470 8471 8472 8473 8474 8475 8476 8477 8478 8479 8480 8481 8482 8483 8484 8485 8486 8487 8488 8489 8490 8491 8492 8493 8494 8495 8496 8497 8498 8499 8500 8501 8502 8503 8504 8505 8506 8507 8508 8509 8510 8511 8512 8513 8514 8515 8516 8517 8518 8519 8520 8521 8522 8523 8524 8525 8526 8527 8528 8529 8530 8531 8532 8533 8534 8535 8536 8537 8538 8539 8540 8541 8542 8543 8544 8545 8546 8547 8548 8549 8550 8551 8552 8553 8554 8555 8556 8557 8558 8559 8560 8561 8562 8563 8564 8565 8566 8567 8568 8569 8570 8571 8572 8573 8574 8575 8576 8577 8578 8579 8580 8581 8582 8583 8584 8585 8586 8587 8588 8589 8590 8591 8592 8593 8594 8595 8596 8597 8598 8599 8600 8601 8602 8603 8604 8605 8606 8607 8608 8609 8610 8611 8612 8613 8614 8615 8616 8617 8618 8619 8620 8621 8622 8623 8624 8625 8626 8627 8628 8629 8630 8631 8632 8633 8634 8635 8636 8637 8638 8639 8640 8641 8642 8643 8644 8645 8646 8647 8648 8649 8650 8651 8652 8653 8654 8655 8656 8657 8658 8659 8660 8661 8662 8663 8664 8665 8666 8667 8668 8669 8670 8671 8672 8673 8674 8675 8676 8677 8678 8679 8680 8681 8682 8683 8684 8685 8686 8687 8688 8689 8690 8691 8692 8693 8694 8695 8696 8697 8698 8699 8700 8701 8702 8703 8704 8705 8706 8707 8708 8709 8710 8711 8712 8713 8714 8715 8716 8717 8718 8719 8720 8721 8722 8723 8724 8725 8726 8727 8728 8729 8730 8731 8732 8733 8734 8735 8736 8737 8738 8739 8740 8741 8742 8743 8744 8745 8746 8747 8748 8749 8750 8751 8752 8753 8754 8755 8756 8757 8758 8759 8760 8761 8762 8763 8764 8765 8766 8767 8768 8769 8770 8771 8772 8773 8774 8775 8776 8777 8778 8779 8780 8781 8782 8783 8784 8785 8786 8787 8788 8789 8790 8791 8792 8793 8794 8795 8796 8797 8798 8799 8800 8801 8802 8803 8804 8805 8806 8807 8808 8809 8810 8811 8812 8813 8814 8815 8816 8817 8818 8819 8820 8821 8822 8823 8824 8825 8826 8827 8828 8829 8830 8831 8832 8833 8834 8835 8836 8837 8838 8839 8840 8841 8842 8843 8844 8845 8846 8847 8848 8849 8850 8851 8852 8853 8854 8855 8856 8857 8858 8859 8860 8861 8862 8863 8864 8865 8866 8867 8868 8869 8870 8871 8872 8873 8874 8875 8876 8877 8878 8879 8880 8881 8882 8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934 8935 8936 8937 8938 8939 8940 8941 8942 8943 8944 8945 8946 8947 8948 8949 8950 8951 8952 8953 8954 8955 8956 8957 8958 8959 8960 8961 8962 8963 8964 8965 8966 8967 8968 8969 8970 8971 8972 8973 8974 8975 8976 8977 8978 8979 8980 8981 8982 8983 8984 8985 8986 8987 8988 8989 8990 8991 8992 8993 8994 8995 8996 8997 8998 8999 9000 9001 9002 9003 9004 9005 9006 9007 9008 9009 9010 9011 9012 9013 9014 9015 9016 9017 9018 9019 9020 9021 9022 9023 9024 9025 9026 9027 9028 9029 9030 9031 9032 9033 9034 9035 9036 9037 9038 9039 9040 9041 9042 9043 9044 9045 9046 9047 9048 9049 9050 9051 9052 9053 9054 9055 9056 9057 9058 9059 9060 9061 9062 9063 9064 9065 9066 9067 9068 9069 9070 9071 9072 9073 9074 9075 9076 9077 9078 9079 9080 9081 9082 9083 9084 9085 9086 9087 9088 9089 9090 9091 9092 9093 9094 9095 9096 9097 9098 9099 9100 9101 9102 9103 9104 9105 9106 9107 9108 9109 9110 9111 9112 9113 9114 9115 9116 9117 9118 9119 9120 9121 9122 9123 9124 9125 9126 9127 9128 9129 9130 9131 9132 9133 9134 9135 9136 9137 9138 9139 9140 9141 9142 9143 9144 9145 9146 9147 9148 9149 9150 9151 9152 9153 9154 9155 9156 9157 9158 9159 9160 9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 9174 9175 9176 9177 9178 9179 9180 9181 9182 9183 9184 9185 9186 9187 9188 9189 9190 9191 9192 9193 9194 9195 9196 9197 9198 9199 9200 9201 9202 9203 9204 9205 9206 9207 9208 9209 9210 9211 9212 9213 9214 9215 9216 9217 9218 9219 9220 9221 9222 9223 9224 9225 9226 9227 9228 9229 9230 9231 9232 9233 9234 9235 9236 9237 9238 9239 9240 9241 9242 9243 9244 9245 9246 9247 9248 9249 9250 9251 9252 9253 9254 9255 9256 9257 9258 9259 9260 9261 9262 9263 9264 9265 9266 9267 9268 9269 9270 9271 9272 9273 9274 9275 9276 9277 9278 9279 9280 9281 9282 9283 9284 9285 9286 9287 9288 9289 9290 9291 9292 9293 9294 9295 9296 9297 9298 9299 9300 9301 9302 9303 9304 9305 9306 9307 9308 9309 9310 9311 9312 9313 9314 9315 9316 9317 9318 9319 9320 9321 9322 9323 9324 9325 9326 9327 9328 9329 9330 9331 9332 9333 9334 9335 9336 9337 9338 9339 9340 9341 9342 9343 9344 9345 9346 9347 9348 9349 9350 9351 9352 9353 9354 9355 9356 9357 9358 9359 9360 9361 9362 9363 9364 9365 9366 9367 9368 9369 9370 9371 9372 9373 9374 9375 9376 9377 9378 9379 9380 9381 9382 9383 9384 9385 9386 9387 9388 9389 9390 9391 9392 9393 9394 9395 9396 9397 9398 9399 9400 9401 9402 9403 9404 9405 9406 9407 9408 9409 9410 9411 9412 9413 9414 9415 9416 9417 9418 9419 9420 9421 9422 9423 9424 9425 9426 9427 9428 9429 9430 9431 9432 9433 9434 9435 9436 9437 9438 9439 9440 9441 9442 9443 9444 9445 9446 9447 9448 9449 9450 9451 9452 9453 9454 9455 9456 9457 9458 9459 9460 9461 9462 9463 9464 9465 9466 9467 9468 9469 9470 9471 9472 9473 9474 9475 9476 9477 9478 9479 9480 9481 9482 9483 9484 9485 9486 9487 9488 9489 9490 9491 9492 9493 9494 9495 9496 9497 9498 9499 9500 9501 9502 9503 9504 9505 9506 9507 9508 9509 9510 9511 9512 9513 9514 9515 9516 9517 9518 9519 9520 9521 9522 9523 9524 9525 9526 9527 9528 9529 9530 9531 9532 9533 9534 9535 9536 9537 9538 9539 9540 9541 9542 9543 9544 9545 9546 9547 9548 9549 9550 9551 9552 9553 9554 9555 9556 9557 9558 9559 9560 9561 9562 9563 9564 9565 9566 9567 9568 9569 9570 9571 9572 9573 9574 9575 9576 9577 9578 9579 9580 9581 9582 9583 9584 9585 9586 9587 9588 9589 9590 9591 9592 9593 9594 9595 9596 9597 9598 9599 9600 9601 9602 9603 9604 9605 9606 9607 9608 9609 9610 9611 9612 9613 9614 9615 9616 9617 9618 9619 9620 9621 9622 9623 9624 9625 9626 9627 9628 9629 9630 9631 9632 9633 9634 9635 9636 9637 9638 9639 9640 9641 9642 9643 9644 9645 9646 9647 9648 9649 9650 9651 9652 9653 9654 9655 9656 9657 9658 9659 9660 9661 9662 9663 9664 9665 9666 9667 9668 9669 9670 9671 9672 9673 9674 9675 9676 9677 9678 9679 9680 9681 9682 9683 9684 9685 9686 9687 9688 9689 9690 9691 9692 9693 9694 9695 9696 9697 9698 9699 9700 9701 9702 9703 9704 9705 9706 9707 9708 9709 9710 9711 9712 9713 9714 9715 9716 9717 9718 9719 9720 9721 9722 9723 9724 9725 9726 9727 9728 9729 9730 9731 9732 9733 9734 9735 9736 9737 9738 9739 9740 9741 9742 9743 9744 9745 9746 9747 9748 9749 9750 9751 9752 9753 9754 9755 9756 9757 9758 9759 9760 9761 9762 9763 9764 9765 9766 9767 9768 9769 9770 9771 9772 9773 9774 9775 9776 9777 9778 9779 9780 9781 9782 9783 9784 9785 9786 9787 9788 9789 9790 9791 9792 9793 9794 9795 9796 9797 9798 9799 9800 9801 9802 9803 9804 9805 9806 9807 9808 9809 9810 9811 9812 9813 9814 9815 9816 9817 9818 9819 9820 9821 9822 9823 9824 9825 9826 9827 9828 9829 9830 9831 9832 9833 9834 9835 9836 9837 9838 9839 9840 9841 9842 9843 9844 9845 9846 9847 9848 9849 9850 9851 9852 9853 9854 9855 9856 9857 9858 9859 9860 9861 9862 9863 9864 9865 9866 9867 9868 9869 9870 9871 9872 9873 9874 9875 9876 9877 9878 9879 9880 9881 9882 9883 9884 9885 9886 9887 9888 9889 9890 9891 9892 9893 9894 9895 9896 9897 9898 9899 9900 9901 9902 9903 9904 9905 9906 9907 9908 9909 9910 9911 9912 9913 9914 9915 9916 9917 9918 9919 9920 9921 9922 9923 9924 9925 9926 9927 9928 9929 9930 9931 9932 9933 9934 9935 9936 9937 9938 9939 9940 9941 9942 9943 9944 9945 9946 9947 9948 9949 9950 9951 9952 9953 9954 9955 9956 9957 9958 9959 9960 9961 9962 9963 9964 9965 9966 9967 9968 9969 9970 9971 9972 9973 9974 9975 9976 9977 9978 9979 9980 9981 9982 9983 9984 9985 9986 9987 9988 9989 9990 9991 9992 9993 9994 9995 9996 9997 9998 9999 10000 10001 10002 10003 10004 10005 10006 10007 10008 10009 10010 10011 10012 10013 10014 10015 10016 10017 10018 10019 10020 10021 10022 10023 10024 10025 10026 10027 10028 10029 10030 10031 10032 10033 10034 10035 10036 10037 10038 10039 10040 10041 10042 10043 10044 10045 10046 10047 10048 10049 10050 10051 10052 10053 10054 10055 10056 10057 10058 10059 10060 10061 10062 10063 10064 10065 10066 10067 10068 10069 10070 10071 10072 10073 10074 10075 10076 10077 10078 10079 10080 10081 10082 10083 10084 10085 10086 10087 10088 10089 10090 10091 10092 10093 10094 10095 10096 10097 10098 10099 10100 10101 10102 10103 10104 10105 10106 10107 10108 10109 10110 10111 10112 10113 10114 10115 10116 10117 10118 10119 10120 10121 10122 10123 10124 10125 10126 10127 10128 10129 10130 10131 10132 10133 10134 10135 10136 10137 10138 10139 10140 10141 10142 10143 10144 10145 10146 10147 10148 10149 10150 10151 10152 10153 10154 10155 10156 10157 10158 10159 10160 10161 10162 10163 10164 10165 10166 10167 10168 10169 10170 10171 10172 10173 10174 10175 10176 10177 10178 10179 10180 10181 10182 10183 10184 10185 10186 10187 10188 10189 10190 10191 10192 10193 10194 10195 10196 10197 10198 10199 10200
+			0x68, 0x61, 0x6E, 0x74, 0x69, 0x65, 0x73, 0x2C,
+			0x20, 0x68, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x68, 0x75, 0x73, 0x62, 0x61, 0x6E,
+			0x64, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65, 0x20,
+			0x64, 0x72, 0x75, 0x6E, 0x6B, 0x20, 0x61, 0x6E,
+			0x64, 0x20, 0x77, 0x69, 0x76, 0x65, 0x73, 0x20,
+			0x73, 0x6F, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20,
+			0x61, 0x6E, 0x64, 0x20, 0x68, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63, 0x68, 0x69,
+			0x6C, 0x64, 0x72, 0x65, 0x6E, 0x20, 0x77, 0x65,
+			0x72, 0x65, 0x20, 0x62, 0x75, 0x6C, 0x6C, 0x69,
+			0x65, 0x64, 0x2C, 0x20, 0x61, 0x62, 0x75, 0x73,
+			0x65, 0x64, 0x2C, 0x20, 0x6F, 0x72, 0x20, 0x61,
+			0x62, 0x61, 0x6E, 0x64, 0x6F, 0x6E, 0x65, 0x64,
+			0x2E, 0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61,
+			0x6E, 0x79, 0x20, 0x66, 0x61, 0x6D, 0x69, 0x6C,
+			0x69, 0x65, 0x73, 0x20, 0x68, 0x75, 0x6E, 0x67,
+			0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x6F, 0x72,
+			0x20, 0x66, 0x6F, 0x6F, 0x64, 0x20, 0x74, 0x68,
+			0x65, 0x79, 0x20, 0x63, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x6E, 0x6F, 0x74, 0x20, 0x61, 0x66, 0x66,
+			0x6F, 0x72, 0x64, 0x20, 0x74, 0x6F, 0x20, 0x62,
+			0x75, 0x79, 0x3F, 0x20, 0x48, 0x6F, 0x77, 0x20,
+			0x6D, 0x61, 0x6E, 0x79, 0x20, 0x68, 0x65, 0x61,
+			0x72, 0x74, 0x73, 0x20, 0x77, 0x65, 0x72, 0x65,
+			0x20, 0x62, 0x72, 0x6F, 0x6B, 0x65, 0x6E, 0x3F,
+			0x20, 0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E,
+			0x79, 0x20, 0x73, 0x75, 0x69, 0x63, 0x69, 0x64,
+			0x65, 0x73, 0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64,
+			0x20, 0x74, 0x61, 0x6B, 0x65, 0x20, 0x70, 0x6C,
+			0x61, 0x63, 0x65, 0x20, 0x74, 0x68, 0x61, 0x74,
+			0x20, 0x73, 0x61, 0x6D, 0x65, 0x20, 0x6E, 0x69,
+			0x67, 0x68, 0x74, 0x2C, 0x20, 0x68, 0x6F, 0x77,
+			0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x70, 0x65,
+			0x6F, 0x70, 0x6C, 0x65, 0x20, 0x77, 0x6F, 0x75,
+			0x6C, 0x64, 0x20, 0x67, 0x6F, 0x20, 0x69, 0x6E,
+			0x73, 0x61, 0x6E, 0x65, 0x3F, 0x20, 0x48, 0x6F,
+			0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79, 0x20, 0x63,
+			0x6F, 0x63, 0x6B, 0x72, 0x6F, 0x61, 0x63, 0x68,
+			0x65, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x6C,
+			0x61, 0x6E, 0x64, 0x6C, 0x6F, 0x72, 0x64, 0x73,
+			0x20, 0x77, 0x6F, 0x75, 0x6C, 0x64, 0x20, 0x74,
+			0x72, 0x69, 0x75, 0x6D, 0x70, 0x68, 0x3F, 0x20,
+			0x48, 0x6F, 0x77, 0x20, 0x6D, 0x61, 0x6E, 0x79,
+			0x20, 0x77, 0x69, 0x6E, 0x6E, 0x65, 0x72, 0x73,
+			0x20, 0x77, 0x65, 0x72, 0x65, 0x20, 0x6C, 0x6F,
+			0x73, 0x65, 0x72, 0x73, 0x2C, 0x20, 0x73, 0x75,
+			0x4C, 0x77, 0x87, 0xA0
+		},
+		.len_bits = 516 << 3,
+	},
+	.digest_enc = {
+		.data = {
+			0x4C, 0x77, 0x87, 0xA0
+		},
+		.len = 4,
+		.offset = 512,
+	},
+	.validDataLen = {
+		.len_bits = 516 << 3,
+	},
+	.validCipherLen = {
+		.len_bits = 516 << 3,
+	},
+	.validAuthLen = {
+		.len_bits = 512 << 3,
+	}
+};
+
 #endif /* TEST_CRYPTODEV_MIXED_TEST_VECTORS_H_ */
diff --git a/dpdk/app/test/test_cycles.c b/dpdk/app/test/test_cycles.c
index c78e6a5b12..97d42f3032 100644
--- a/dpdk/app/test/test_cycles.c
+++ b/dpdk/app/test/test_cycles.c
@@ -79,8 +79,14 @@ REGISTER_TEST_COMMAND(cycles_autotest, test_cycles);
 static int
 test_delay_us_sleep(void)
 {
+	int rv;
+
 	rte_delay_us_callback_register(rte_delay_us_sleep);
-	return check_wait_one_second();
+	rv = check_wait_one_second();
+	/* restore original delay function */
+	rte_delay_us_callback_register(rte_delay_us_block);
+
+	return rv;
 }
 
 REGISTER_TEST_COMMAND(delay_us_sleep_autotest, test_delay_us_sleep);
diff --git a/dpdk/app/test/test_distributor.c b/dpdk/app/test/test_distributor.c
index ba1f81cf8d..acfe728f0c 100644
--- a/dpdk/app/test/test_distributor.c
+++ b/dpdk/app/test/test_distributor.c
@@ -27,7 +27,9 @@ struct worker_params worker_params;
 /* statics - all zero-initialized by default */
 static volatile int quit;      /**< general quit variable for all threads */
 static volatile int zero_quit; /**< var for when we just want thr0 to quit*/
+static volatile int zero_sleep; /**< thr0 has quit basic loop and is sleeping*/
 static volatile unsigned worker_idx;
+static volatile unsigned zero_idx;
 
 struct worker_stats {
 	volatile unsigned handled_packets;
@@ -42,7 +44,8 @@ total_packet_count(void)
 {
 	unsigned i, count = 0;
 	for (i = 0; i < worker_idx; i++)
-		count += worker_stats[i].handled_packets;
+		count += __atomic_load_n(&worker_stats[i].handled_packets,
+				__ATOMIC_RELAXED);
 	return count;
 }
 
@@ -50,7 +53,10 @@ total_packet_count(void)
 static inline void
 clear_packet_count(void)
 {
-	memset(&worker_stats, 0, sizeof(worker_stats));
+	unsigned int i;
+	for (i = 0; i < RTE_MAX_LCORE; i++)
+		__atomic_store_n(&worker_stats[i].handled_packets, 0,
+			__ATOMIC_RELAXED);
 }
 
 /* this is the basic worker function for sanity test
@@ -62,23 +68,18 @@ handle_work(void *arg)
 	struct rte_mbuf *buf[8] __rte_cache_aligned;
 	struct worker_params *wp = arg;
 	struct rte_distributor *db = wp->dist;
-	unsigned int count = 0, num = 0;
+	unsigned int num;
 	unsigned int id = __atomic_fetch_add(&worker_idx, 1, __ATOMIC_RELAXED);
-	int i;
 
-	for (i = 0; i < 8; i++)
-		buf[i] = NULL;
-	num = rte_distributor_get_pkt(db, id, buf, buf, num);
+	num = rte_distributor_get_pkt(db, id, buf, NULL, 0);
 	while (!quit) {
 		__atomic_fetch_add(&worker_stats[id].handled_packets, num,
 				__ATOMIC_RELAXED);
-		count += num;
 		num = rte_distributor_get_pkt(db, id,
 				buf, buf, num);
 	}
 	__atomic_fetch_add(&worker_stats[id].handled_packets, num,
 			__ATOMIC_RELAXED);
-	count += num;
 	rte_distributor_return_pkt(db, id, buf, num);
 	return 0;
 }
@@ -102,6 +103,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 	struct rte_mbuf *returns[BURST*2];
 	unsigned int i, count;
 	unsigned int retries;
+	unsigned int processed;
 
 	printf("=== Basic distributor sanity tests ===\n");
 	clear_packet_count();
@@ -115,7 +117,11 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 	for (i = 0; i < BURST; i++)
 		bufs[i]->hash.usr = 0;
 
-	rte_distributor_process(db, bufs, BURST);
+	processed = 0;
+	while (processed < BURST)
+		processed += rte_distributor_process(db, &bufs[processed],
+			BURST - processed);
+
 	count = 0;
 	do {
 
@@ -128,12 +134,14 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 		printf("Line %d: Error, not all packets flushed. "
 				"Expected %u, got %u\n",
 				__LINE__, BURST, total_packet_count());
+		rte_mempool_put_bulk(p, (void *)bufs, BURST);
 		return -1;
 	}
 
 	for (i = 0; i < rte_lcore_count() - 1; i++)
 		printf("Worker %u handled %u packets\n", i,
-				worker_stats[i].handled_packets);
+			__atomic_load_n(&worker_stats[i].handled_packets,
+					__ATOMIC_RELAXED));
 	printf("Sanity test with all zero hashes done.\n");
 
 	/* pick two flows and check they go correctly */
@@ -153,12 +161,15 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 			printf("Line %d: Error, not all packets flushed. "
 					"Expected %u, got %u\n",
 					__LINE__, BURST, total_packet_count());
+			rte_mempool_put_bulk(p, (void *)bufs, BURST);
 			return -1;
 		}
 
 		for (i = 0; i < rte_lcore_count() - 1; i++)
 			printf("Worker %u handled %u packets\n", i,
-					worker_stats[i].handled_packets);
+				__atomic_load_n(
+					&worker_stats[i].handled_packets,
+					__ATOMIC_RELAXED));
 		printf("Sanity test with two hash values done\n");
 	}
 
@@ -179,12 +190,14 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 		printf("Line %d: Error, not all packets flushed. "
 				"Expected %u, got %u\n",
 				__LINE__, BURST, total_packet_count());
+		rte_mempool_put_bulk(p, (void *)bufs, BURST);
 		return -1;
 	}
 
 	for (i = 0; i < rte_lcore_count() - 1; i++)
 		printf("Worker %u handled %u packets\n", i,
-				worker_stats[i].handled_packets);
+			__atomic_load_n(&worker_stats[i].handled_packets,
+					__ATOMIC_RELAXED));
 	printf("Sanity test with non-zero hashes done\n");
 
 	rte_mempool_put_bulk(p, (void *)bufs, BURST);
@@ -194,6 +207,8 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 	clear_packet_count();
 	struct rte_mbuf *many_bufs[BIG_BATCH], *return_bufs[BIG_BATCH];
 	unsigned num_returned = 0;
+	unsigned int num_being_processed = 0;
+	unsigned int return_buffer_capacity = 127;/* RTE_DISTRIB_RETURNS_MASK */
 
 	/* flush out any remaining packets */
 	rte_distributor_flush(db);
@@ -210,16 +225,16 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 	for (i = 0; i < BIG_BATCH/BURST; i++) {
 		rte_distributor_process(db,
 				&many_bufs[i*BURST], BURST);
-		count = rte_distributor_returned_pkts(db,
-				&return_bufs[num_returned],
-				BIG_BATCH - num_returned);
-		num_returned += count;
+		num_being_processed += BURST;
+		do {
+			count = rte_distributor_returned_pkts(db,
+					&return_bufs[num_returned],
+					BIG_BATCH - num_returned);
+			num_being_processed -= count;
+			num_returned += count;
+			rte_distributor_flush(db);
+		} while (num_being_processed + BURST > return_buffer_capacity);
 	}
-	rte_distributor_flush(db);
-	count = rte_distributor_returned_pkts(db,
-		&return_bufs[num_returned],
-			BIG_BATCH - num_returned);
-	num_returned += count;
 	retries = 0;
 	do {
 		rte_distributor_flush(db);
@@ -233,6 +248,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 	if (num_returned != BIG_BATCH) {
 		printf("line %d: Missing packets, expected %d\n",
 				__LINE__, num_returned);
+		rte_mempool_put_bulk(p, (void *)many_bufs, BIG_BATCH);
 		return -1;
 	}
 
@@ -247,6 +263,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p)
 
 		if (j == BIG_BATCH) {
 			printf("Error: could not find source packet #%u\n", i);
+			rte_mempool_put_bulk(p, (void *)many_bufs, BIG_BATCH);
 			return -1;
 		}
 	}
@@ -270,24 +287,20 @@ handle_work_with_free_mbufs(void *arg)
 	struct rte_mbuf *buf[8] __rte_cache_aligned;
 	struct worker_params *wp = arg;
 	struct rte_distributor *d = wp->dist;
-	unsigned int count = 0;
 	unsigned int i;
-	unsigned int num = 0;
+	unsigned int num;
 	unsigned int id = __atomic_fetch_add(&worker_idx, 1, __ATOMIC_RELAXED);
 
-	for (i = 0; i < 8; i++)
-		buf[i] = NULL;
-	num = rte_distributor_get_pkt(d, id, buf, buf, num);
+	num = rte_distributor_get_pkt(d, id, buf, NULL, 0);
 	while (!quit) {
-		worker_stats[id].handled_packets += num;
-		count += num;
+		__atomic_fetch_add(&worker_stats[id].handled_packets, num,
+				__ATOMIC_RELAXED);
 		for (i = 0; i < num; i++)
 			rte_pktmbuf_free(buf[i]);
-		num = rte_distributor_get_pkt(d,
-				id, buf, buf, num);
+		num = rte_distributor_get_pkt(d, id, buf, NULL, 0);
 	}
-	worker_stats[id].handled_packets += num;
-	count += num;
+	__atomic_fetch_add(&worker_stats[id].handled_packets, num,
+			__ATOMIC_RELAXED);
 	rte_distributor_return_pkt(d, id, buf, num);
 	return 0;
 }
@@ -303,6 +316,7 @@ sanity_test_with_mbuf_alloc(struct worker_params *wp, struct rte_mempool *p)
 	struct rte_distributor *d = wp->dist;
 	unsigned i;
 	struct rte_mbuf *bufs[BURST];
+	unsigned int processed;
 
 	printf("=== Sanity test with mbuf alloc/free (%s) ===\n", wp->name);
 
@@ -313,10 +327,12 @@ sanity_test_with_mbuf_alloc(struct worker_params *wp, struct rte_mempool *p)
 			rte_distributor_process(d, NULL, 0);
 		for (j = 0; j < BURST; j++) {
 			bufs[j]->hash.usr = (i+j) << 1;
-			rte_mbuf_refcnt_set(bufs[j], 1);
 		}
 
-		rte_distributor_process(d, bufs, BURST);
+		processed = 0;
+		while (processed < BURST)
+			processed += rte_distributor_process(d,
+				&bufs[processed], BURST - processed);
 	}
 
 	rte_distributor_flush(d);
@@ -337,55 +353,61 @@ sanity_test_with_mbuf_alloc(struct worker_params *wp, struct rte_mempool *p)
 static int
 handle_work_for_shutdown_test(void *arg)
 {
-	struct rte_mbuf *pkt = NULL;
 	struct rte_mbuf *buf[8] __rte_cache_aligned;
 	struct worker_params *wp = arg;
 	struct rte_distributor *d = wp->dist;
-	unsigned int count = 0;
-	unsigned int num = 0;
-	unsigned int total = 0;
-	unsigned int i;
-	unsigned int returned = 0;
+	unsigned int num;
+	unsigned int zero_id = 0;
+	unsigned int zero_unset;
 	const unsigned int id = __atomic_fetch_add(&worker_idx, 1,
 			__ATOMIC_RELAXED);
 
-	num = rte_distributor_get_pkt(d, id, buf, buf, num);
+	num = rte_distributor_get_pkt(d, id, buf, NULL, 0);
+
+	if (num > 0) {
+		zero_unset = RTE_MAX_LCORE;
+		__atomic_compare_exchange_n(&zero_idx, &zero_unset, id,
+			0, __ATOMIC_ACQ_REL, __ATOMIC_ACQUIRE);
+	}
+	zero_id = __atomic_load_n(&zero_idx, __ATOMIC_ACQUIRE);
 
 	/* wait for quit single globally, or for worker zero, wait
 	 * for zero_quit */
-	while (!quit && !(id == 0 && zero_quit)) {
-		worker_stats[id].handled_packets += num;
-		count += num;
-		for (i = 0; i < num; i++)
-			rte_pktmbuf_free(buf[i]);
-		num = rte_distributor_get_pkt(d,
-				id, buf, buf, num);
-		total += num;
+	while (!quit && !(id == zero_id && zero_quit)) {
+		__atomic_fetch_add(&worker_stats[id].handled_packets, num,
+				__ATOMIC_RELAXED);
+		num = rte_distributor_get_pkt(d, id, buf, NULL, 0);
+
+		if (num > 0) {
+			zero_unset = RTE_MAX_LCORE;
+			__atomic_compare_exchange_n(&zero_idx, &zero_unset, id,
+				0, __ATOMIC_ACQ_REL, __ATOMIC_ACQUIRE);
+		}
+		zero_id = __atomic_load_n(&zero_idx, __ATOMIC_ACQUIRE);
 	}
-	worker_stats[id].handled_packets += num;
-	count += num;
-	returned = rte_distributor_return_pkt(d, id, buf, num);
 
-	if (id == 0) {
+	__atomic_fetch_add(&worker_stats[id].handled_packets, num,
+			__ATOMIC_RELAXED);
+	if (id == zero_id) {
+		rte_distributor_return_pkt(d, id, NULL, 0);
+
 		/* for worker zero, allow it to restart to pick up last packet
 		 * when all workers are shutting down.
 		 */
+		__atomic_store_n(&zero_sleep, 1, __ATOMIC_RELEASE);
 		while (zero_quit)
 			usleep(100);
+		__atomic_store_n(&zero_sleep, 0, __ATOMIC_RELEASE);
 
-		num = rte_distributor_get_pkt(d,
-				id, buf, buf, num);
+		num = rte_distributor_get_pkt(d, id, buf, NULL, 0);
 
 		while (!quit) {
-			worker_stats[id].handled_packets += num;
-			count += num;
-			rte_pktmbuf_free(pkt);
-			num = rte_distributor_get_pkt(d, id, buf, buf, num);
+			__atomic_fetch_add(&worker_stats[id].handled_packets,
+					num, __ATOMIC_RELAXED);
+			num = rte_distributor_get_pkt(d, id, buf, NULL, 0);
 		}
-		returned = rte_distributor_return_pkt(d,
-				id, buf, num);
-		printf("Num returned = %d\n", returned);
 	}
+	rte_distributor_return_pkt(d, id, buf, num);
 	return 0;
 }
 
@@ -401,7 +423,10 @@ sanity_test_with_worker_shutdown(struct worker_params *wp,
 {
 	struct rte_distributor *d = wp->dist;
 	struct rte_mbuf *bufs[BURST];
-	unsigned i;
+	struct rte_mbuf *bufs2[BURST];
+	unsigned int i;
+	unsigned int failed = 0;
+	unsigned int processed = 0;
 
 	printf("=== Sanity test of worker shutdown ===\n");
 
@@ -419,7 +444,10 @@ sanity_test_with_worker_shutdown(struct worker_params *wp,
 	for (i = 0; i < BURST; i++)
 		bufs[i]->hash.usr = 1;
 
-	rte_distributor_process(d, bufs, BURST);
+	processed = 0;
+	while (processed < BURST)
+		processed += rte_distributor_process(d, &bufs[processed],
+			BURST - processed);
 	rte_distributor_flush(d);
 
 	/* at this point, we will have processed some packets and have a full
@@ -427,32 +455,45 @@ sanity_test_with_worker_shutdown(struct worker_params *wp,
 	 */
 
 	/* get more buffers to queue up, again setting them to the same flow */
-	if (rte_mempool_get_bulk(p, (void *)bufs, BURST) != 0) {
+	if (rte_mempool_get_bulk(p, (void *)bufs2, BURST) != 0) {
 		printf("line %d: Error getting mbufs from pool\n", __LINE__);
+		rte_mempool_put_bulk(p, (void *)bufs, BURST);
 		return -1;
 	}
 	for (i = 0; i < BURST; i++)
-		bufs[i]->hash.usr = 1;
+		bufs2[i]->hash.usr = 1;
 
 	/* get worker zero to quit */
 	zero_quit = 1;
-	rte_distributor_process(d, bufs, BURST);
+	rte_distributor_process(d, bufs2, BURST);
 
 	/* flush the distributor */
 	rte_distributor_flush(d);
-	rte_delay_us(10000);
+	while (!__atomic_load_n(&zero_sleep, __ATOMIC_ACQUIRE))
+		rte_distributor_flush(d);
+
+	zero_quit = 0;
+	while (__atomic_load_n(&zero_sleep, __ATOMIC_ACQUIRE))
+		rte_delay_us(100);
 
 	for (i = 0; i < rte_lcore_count() - 1; i++)
 		printf("Worker %u handled %u packets\n", i,
-				worker_stats[i].handled_packets);
+			__atomic_load_n(&worker_stats[i].handled_packets,
+					__ATOMIC_RELAXED));
 
 	if (total_packet_count() != BURST * 2) {
 		printf("Line %d: Error, not all packets flushed. "
 				"Expected %u, got %u\n",
 				__LINE__, BURST * 2, total_packet_count());
-		return -1;
+		failed = 1;
 	}
 
+	rte_mempool_put_bulk(p, (void *)bufs, BURST);
+	rte_mempool_put_bulk(p, (void *)bufs2, BURST);
+
+	if (failed)
+		return -1;
+
 	printf("Sanity test with worker shutdown passed\n\n");
 	return 0;
 }
@@ -466,7 +507,9 @@ test_flush_with_worker_shutdown(struct worker_params *wp,
 {
 	struct rte_distributor *d = wp->dist;
 	struct rte_mbuf *bufs[BURST];
-	unsigned i;
+	unsigned int i;
+	unsigned int failed = 0;
+	unsigned int processed;
 
 	printf("=== Test flush fn with worker shutdown (%s) ===\n", wp->name);
 
@@ -481,7 +524,10 @@ test_flush_with_worker_shutdown(struct worker_params *wp,
 	for (i = 0; i < BURST; i++)
 		bufs[i]->hash.usr = 0;
 
-	rte_distributor_process(d, bufs, BURST);
+	processed = 0;
+	while (processed < BURST)
+		processed += rte_distributor_process(d, &bufs[processed],
+			BURST - processed);
 	/* at this point, we will have processed some packets and have a full
 	 * backlog for the other ones at worker 0.
 	 */
@@ -492,20 +538,31 @@ test_flush_with_worker_shutdown(struct worker_params *wp,
 	/* flush the distributor */
 	rte_distributor_flush(d);
 
-	rte_delay_us(10000);
+	while (!__atomic_load_n(&zero_sleep, __ATOMIC_ACQUIRE))
+		rte_distributor_flush(d);
 
 	zero_quit = 0;
+
+	while (__atomic_load_n(&zero_sleep, __ATOMIC_ACQUIRE))
+		rte_delay_us(100);
+
 	for (i = 0; i < rte_lcore_count() - 1; i++)
 		printf("Worker %u handled %u packets\n", i,
-				worker_stats[i].handled_packets);
+			__atomic_load_n(&worker_stats[i].handled_packets,
+					__ATOMIC_RELAXED));
 
 	if (total_packet_count() != BURST) {
 		printf("Line %d: Error, not all packets flushed. "
 				"Expected %u, got %u\n",
 				__LINE__, BURST, total_packet_count());
-		return -1;
+		failed = 1;
 	}
 
+	rte_mempool_put_bulk(p, (void *)bufs, BURST);
+
+	if (failed)
+		return -1;
+
 	printf("Flush test with worker shutdown passed\n\n");
 	return 0;
 }
@@ -571,21 +628,34 @@ quit_workers(struct worker_params *wp, struct rte_mempool *p)
 	const unsigned num_workers = rte_lcore_count() - 1;
 	unsigned i;
 	struct rte_mbuf *bufs[RTE_MAX_LCORE];
-	rte_mempool_get_bulk(p, (void *)bufs, num_workers);
+	struct rte_mbuf *returns[RTE_MAX_LCORE];
+	if (rte_mempool_get_bulk(p, (void *)bufs, num_workers) != 0) {
+		printf("line %d: Error getting mbufs from pool\n", __LINE__);
+		return;
+	}
 
 	zero_quit = 0;
 	quit = 1;
-	for (i = 0; i < num_workers; i++)
+	for (i = 0; i < num_workers; i++) {
 		bufs[i]->hash.usr = i << 1;
-	rte_distributor_process(d, bufs, num_workers);
-
-	rte_mempool_put_bulk(p, (void *)bufs, num_workers);
+		rte_distributor_process(d, &bufs[i], 1);
+	}
 
 	rte_distributor_process(d, NULL, 0);
 	rte_distributor_flush(d);
 	rte_eal_mp_wait_lcore();
+
+	while (rte_distributor_returned_pkts(d, returns, RTE_MAX_LCORE))
+		;
+
+	rte_distributor_clear_returns(d);
+	rte_mempool_put_bulk(p, (void *)bufs, num_workers);
+
 	quit = 0;
 	worker_idx = 0;
+	zero_idx = RTE_MAX_LCORE;
+	zero_quit = 0;
+	zero_sleep = 0;
 }
 
 static int
diff --git a/dpdk/app/test/test_event_crypto_adapter.c b/dpdk/app/test/test_event_crypto_adapter.c
index 8d42462d87..1c0a0fa5e3 100644
--- a/dpdk/app/test/test_event_crypto_adapter.c
+++ b/dpdk/app/test/test_event_crypto_adapter.c
@@ -171,7 +171,6 @@ test_op_forward_mode(uint8_t session_less)
 	struct rte_event ev;
 	uint32_t cap;
 	int ret;
-	uint8_t cipher_key[17];
 
 	memset(&m_data, 0, sizeof(m_data));
 
@@ -183,15 +182,9 @@ test_op_forward_mode(uint8_t session_less)
 	/* Setup Cipher Parameters */
 	cipher_xform.type = RTE_CRYPTO_SYM_XFORM_CIPHER;
 	cipher_xform.next = NULL;
-
-	cipher_xform.cipher.algo = RTE_CRYPTO_CIPHER_AES_CBC;
+	cipher_xform.cipher.algo = RTE_CRYPTO_CIPHER_NULL;
 	cipher_xform.cipher.op = RTE_CRYPTO_CIPHER_OP_ENCRYPT;
 
-	cipher_xform.cipher.key.data = cipher_key;
-	cipher_xform.cipher.key.length = 16;
-	cipher_xform.cipher.iv.offset = IV_OFFSET;
-	cipher_xform.cipher.iv.length = 16;
-
 	op = rte_crypto_op_alloc(params.op_mpool,
 			RTE_CRYPTO_OP_TYPE_SYMMETRIC);
 	TEST_ASSERT_NOT_NULL(op,
@@ -209,8 +202,8 @@ test_op_forward_mode(uint8_t session_less)
 				&cipher_xform, params.session_priv_mpool);
 		TEST_ASSERT_SUCCESS(ret, "Failed to init session\n");
 
-		ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID,
-							evdev, &cap);
+		ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID,
+							&cap);
 		TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 		if (cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_SESSION_PRIVATE_DATA) {
@@ -296,7 +289,7 @@ test_sessionless_with_op_forward_mode(void)
 	uint32_t cap;
 	int ret;
 
-	ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID, evdev, &cap);
+	ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID, &cap);
 	TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 	if (!(cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD) &&
@@ -321,7 +314,7 @@ test_session_with_op_forward_mode(void)
 	uint32_t cap;
 	int ret;
 
-	ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID, evdev, &cap);
+	ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID, &cap);
 	TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 	if (!(cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD) &&
@@ -378,7 +371,6 @@ test_op_new_mode(uint8_t session_less)
 	struct rte_mbuf *m;
 	uint32_t cap;
 	int ret;
-	uint8_t cipher_key[17];
 
 	memset(&m_data, 0, sizeof(m_data));
 
@@ -390,15 +382,9 @@ test_op_new_mode(uint8_t session_less)
 	/* Setup Cipher Parameters */
 	cipher_xform.type = RTE_CRYPTO_SYM_XFORM_CIPHER;
 	cipher_xform.next = NULL;
-
-	cipher_xform.cipher.algo = RTE_CRYPTO_CIPHER_AES_CBC;
+	cipher_xform.cipher.algo = RTE_CRYPTO_CIPHER_NULL;
 	cipher_xform.cipher.op = RTE_CRYPTO_CIPHER_OP_ENCRYPT;
 
-	cipher_xform.cipher.key.data = cipher_key;
-	cipher_xform.cipher.key.length = 16;
-	cipher_xform.cipher.iv.offset = IV_OFFSET;
-	cipher_xform.cipher.iv.length = 16;
-
 	op = rte_crypto_op_alloc(params.op_mpool,
 			RTE_CRYPTO_OP_TYPE_SYMMETRIC);
 	TEST_ASSERT_NOT_NULL(op, "Failed to allocate crypto_op!\n");
@@ -410,8 +396,8 @@ test_op_new_mode(uint8_t session_less)
 				params.session_mpool);
 		TEST_ASSERT_NOT_NULL(sess, "Session creation failed\n");
 
-		ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID,
-							evdev, &cap);
+		ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID,
+							&cap);
 		TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 		if (cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_SESSION_PRIVATE_DATA) {
@@ -460,7 +446,7 @@ test_sessionless_with_op_new_mode(void)
 	uint32_t cap;
 	int ret;
 
-	ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID, evdev, &cap);
+	ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID, &cap);
 	TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 	if (!(cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD) &&
@@ -486,7 +472,7 @@ test_session_with_op_new_mode(void)
 	uint32_t cap;
 	int ret;
 
-	ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID, evdev, &cap);
+	ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID, &cap);
 	TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 	if (!(cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_OP_FWD) &&
@@ -564,7 +550,9 @@ configure_cryptodev(void)
 
 	params.session_mpool = rte_cryptodev_sym_session_pool_create(
 			"CRYPTO_ADAPTER_SESSION_MP",
-			MAX_NB_SESSIONS, 0, 0, 0, SOCKET_ID_ANY);
+			MAX_NB_SESSIONS, 0, 0,
+			sizeof(union rte_event_crypto_metadata),
+			SOCKET_ID_ANY);
 	TEST_ASSERT_NOT_NULL(params.session_mpool,
 			"session mempool allocation failed\n");
 
@@ -706,7 +694,7 @@ test_crypto_adapter_create(void)
 
 	/* Create adapter with default port creation callback */
 	ret = rte_event_crypto_adapter_create(TEST_ADAPTER_ID,
-					      TEST_CDEV_ID,
+					      evdev,
 					      &conf, 0);
 	TEST_ASSERT_SUCCESS(ret, "Failed to create event crypto adapter\n");
 
@@ -719,7 +707,7 @@ test_crypto_adapter_qp_add_del(void)
 	uint32_t cap;
 	int ret;
 
-	ret = rte_event_crypto_adapter_caps_get(TEST_ADAPTER_ID, evdev, &cap);
+	ret = rte_event_crypto_adapter_caps_get(evdev, TEST_CDEV_ID, &cap);
 	TEST_ASSERT_SUCCESS(ret, "Failed to get adapter capabilities\n");
 
 	if (cap & RTE_EVENT_CRYPTO_ADAPTER_CAP_INTERNAL_PORT_QP_EV_BIND) {
diff --git a/dpdk/app/test/test_event_eth_tx_adapter.c b/dpdk/app/test/test_event_eth_tx_adapter.c
index 3af749280a..7073030902 100644
--- a/dpdk/app/test/test_event_eth_tx_adapter.c
+++ b/dpdk/app/test/test_event_eth_tx_adapter.c
@@ -45,7 +45,7 @@ static uint64_t eid = ~0ULL;
 static uint32_t tid;
 
 static inline int
-port_init_common(uint8_t port, const struct rte_eth_conf *port_conf,
+port_init_common(uint16_t port, const struct rte_eth_conf *port_conf,
 		struct rte_mempool *mp)
 {
 	const uint16_t rx_ring_size = RING_SIZE, tx_ring_size = RING_SIZE;
@@ -104,7 +104,7 @@ port_init_common(uint8_t port, const struct rte_eth_conf *port_conf,
 }
 
 static inline int
-port_init(uint8_t port, struct rte_mempool *mp)
+port_init(uint16_t port, struct rte_mempool *mp)
 {
 	struct rte_eth_conf conf = { 0 };
 	return port_init_common(port, &conf, mp);
diff --git a/dpdk/app/test/test_eventdev.c b/dpdk/app/test/test_eventdev.c
index 427dbbf77f..43ccb1ce97 100644
--- a/dpdk/app/test/test_eventdev.c
+++ b/dpdk/app/test/test_eventdev.c
@@ -996,9 +996,13 @@ test_eventdev_common(void)
 static int
 test_eventdev_selftest_impl(const char *pmd, const char *opts)
 {
-	rte_vdev_init(pmd, opts);
+	int ret = 0;
+
 	if (rte_event_dev_get_dev_id(pmd) == -ENODEV)
+		ret = rte_vdev_init(pmd, opts);
+	if (ret)
 		return TEST_SKIPPED;
+
 	return rte_event_dev_selftest(rte_event_dev_get_dev_id(pmd));
 }
 
@@ -1017,7 +1021,7 @@ test_eventdev_selftest_octeontx(void)
 static int
 test_eventdev_selftest_octeontx2(void)
 {
-	return test_eventdev_selftest_impl("otx2_eventdev", "");
+	return test_eventdev_selftest_impl("event_octeontx2", "");
 }
 
 static int
diff --git a/dpdk/app/test/test_fib_perf.c b/dpdk/app/test/test_fib_perf.c
index 573087c3c0..dd2e54db8b 100644
--- a/dpdk/app/test/test_fib_perf.c
+++ b/dpdk/app/test/test_fib_perf.c
@@ -35,7 +35,7 @@ struct route_rule {
 	uint8_t depth;
 };
 
-struct route_rule large_route_table[MAX_RULE_NUM];
+static struct route_rule large_route_table[MAX_RULE_NUM];
 
 static uint32_t num_route_entries;
 #define NUM_ROUTE_ENTRIES num_route_entries
diff --git a/dpdk/app/test/test_flow_classify.c b/dpdk/app/test/test_flow_classify.c
index ff5265c6af..ef0b6fdd5c 100644
--- a/dpdk/app/test/test_flow_classify.c
+++ b/dpdk/app/test/test_flow_classify.c
@@ -23,7 +23,7 @@
 
 #define FLOW_CLASSIFY_MAX_RULE_NUM 100
 #define MAX_PKT_BURST              32
-#define NB_SOCKETS                 1
+#define NB_SOCKETS                 4
 #define MEMPOOL_CACHE_SIZE         256
 #define MBUF_SIZE                  512
 #define NB_MBUF                    512
diff --git a/dpdk/app/test/test_hash.c b/dpdk/app/test/test_hash.c
index 0052dce2de..2ac298e21e 100644
--- a/dpdk/app/test/test_hash.c
+++ b/dpdk/app/test/test_hash.c
@@ -1142,8 +1142,11 @@ fbk_hash_unit_test(void)
 	handle = rte_fbk_hash_create(&invalid_params_7);
 	RETURN_IF_ERROR_FBK(handle != NULL, "fbk hash creation should have failed");
 
-	handle = rte_fbk_hash_create(&invalid_params_8);
-	RETURN_IF_ERROR_FBK(handle != NULL, "fbk hash creation should have failed");
+	if (rte_eal_has_hugepages()) {
+		handle = rte_fbk_hash_create(&invalid_params_8);
+		RETURN_IF_ERROR_FBK(handle != NULL,
+					"fbk hash creation should have failed");
+	}
 
 	handle = rte_fbk_hash_create(&invalid_params_same_name_1);
 	RETURN_IF_ERROR_FBK(handle == NULL, "fbk hash creation should have succeeded");
diff --git a/dpdk/app/test/test_hash_readwrite_lf.c b/dpdk/app/test/test_hash_readwrite_lf_perf.c
similarity index 99%
rename from dpdk/app/test/test_hash_readwrite_lf.c
rename to dpdk/app/test/test_hash_readwrite_lf_perf.c
index 97c304054c..7bfc067f4e 100644
--- a/dpdk/app/test/test_hash_readwrite_lf.c
+++ b/dpdk/app/test/test_hash_readwrite_lf_perf.c
@@ -1241,7 +1241,7 @@ test_hash_add_ks_lookup_hit_extbkt(struct rwc_perf *rwc_perf_results,
 }
 
 static int
-test_hash_readwrite_lf_main(void)
+test_hash_readwrite_lf_perf_main(void)
 {
 	/*
 	 * Variables used to choose different tests.
@@ -1254,7 +1254,7 @@ test_hash_readwrite_lf_main(void)
 	int ext_bkt = 0;
 
 	if (rte_lcore_count() < 2) {
-		printf("Not enough cores for hash_readwrite_lf_autotest, expecting at least 2\n");
+		printf("Not enough cores for hash_readwrite_lf_perf_autotest, expecting at least 2\n");
 		return TEST_SKIPPED;
 	}
 
@@ -1431,4 +1431,5 @@ test_hash_readwrite_lf_main(void)
 	return 0;
 }
 
-REGISTER_TEST_COMMAND(hash_readwrite_lf_autotest, test_hash_readwrite_lf_main);
+REGISTER_TEST_COMMAND(hash_readwrite_lf_perf_autotest,
+	test_hash_readwrite_lf_perf_main);
diff --git a/dpdk/app/test/test_ipsec.c b/dpdk/app/test/test_ipsec.c
index 7dc83fee7e..6a4bd12f7f 100644
--- a/dpdk/app/test/test_ipsec.c
+++ b/dpdk/app/test/test_ipsec.c
@@ -237,7 +237,7 @@ fill_crypto_xform(struct ipsec_unitest_params *ut_params,
 }
 
 static int
-check_cryptodev_capablity(const struct ipsec_unitest_params *ut,
+check_cryptodev_capability(const struct ipsec_unitest_params *ut,
 		uint8_t dev_id)
 {
 	struct rte_cryptodev_sym_capability_idx cap_idx;
@@ -302,7 +302,7 @@ testsuite_setup(void)
 
 	/* Find first valid crypto device */
 	for (i = 0; i < nb_devs; i++) {
-		rc = check_cryptodev_capablity(ut_params, i);
+		rc = check_cryptodev_capability(ut_params, i);
 		if (rc == 0) {
 			ts_params->valid_dev = i;
 			ts_params->valid_dev_found = 1;
@@ -743,7 +743,7 @@ create_sa(enum rte_security_session_action_type action_type,
 	ut->ss[j].type = action_type;
 	rc = create_session(ut, &ts->qp_conf, ts->valid_dev, j);
 	if (rc != 0)
-		return TEST_FAILED;
+		return rc;
 
 	rc = rte_ipsec_sa_init(ut->ss[j].sa, &ut->sa_prm, sz);
 	rc = (rc > 0 && (uint32_t)rc <= sz) ? 0 : -EINVAL;
@@ -1167,6 +1167,34 @@ test_ipsec_dump_buffers(struct ipsec_unitest_params *ut_params, int i)
 	}
 }
 
+static void
+destroy_dummy_sec_session(struct ipsec_unitest_params *ut,
+	uint32_t j)
+{
+	rte_security_session_destroy(&dummy_sec_ctx,
+					ut->ss[j].security.ses);
+	ut->ss[j].security.ctx = NULL;
+}
+
+static void
+destroy_crypto_session(struct ipsec_unitest_params *ut,
+	uint8_t crypto_dev, uint32_t j)
+{
+	rte_cryptodev_sym_session_clear(crypto_dev, ut->ss[j].crypto.ses);
+	rte_cryptodev_sym_session_free(ut->ss[j].crypto.ses);
+	memset(&ut->ss[j], 0, sizeof(ut->ss[j]));
+}
+
+static void
+destroy_session(struct ipsec_unitest_params *ut,
+	uint8_t crypto_dev, uint32_t j)
+{
+	if (ut->ss[j].type == RTE_SECURITY_ACTION_TYPE_NONE)
+		return destroy_crypto_session(ut, crypto_dev, j);
+	else
+		return destroy_dummy_sec_session(ut, j);
+}
+
 static void
 destroy_sa(uint32_t j)
 {
@@ -1175,9 +1203,8 @@ destroy_sa(uint32_t j)
 
 	rte_ipsec_sa_fini(ut->ss[j].sa);
 	rte_free(ut->ss[j].sa);
-	rte_cryptodev_sym_session_clear(ts->valid_dev, ut->ss[j].crypto.ses);
-	rte_cryptodev_sym_session_free(ut->ss[j].crypto.ses);
-	memset(&ut->ss[j], 0, sizeof(ut->ss[j]));
+
+	destroy_session(ut, ts->valid_dev, j);
 }
 
 static int
@@ -1219,7 +1246,7 @@ test_ipsec_crypto_inb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -1321,7 +1348,7 @@ test_ipsec_crypto_outb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate input mbuf data */
@@ -1430,7 +1457,7 @@ test_ipsec_inline_crypto_inb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate inbound mbuf data */
@@ -1508,7 +1535,7 @@ test_ipsec_inline_proto_inb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate inbound mbuf data */
@@ -1616,7 +1643,7 @@ test_ipsec_inline_crypto_outb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -1694,7 +1721,7 @@ test_ipsec_inline_proto_outb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -1770,7 +1797,7 @@ test_ipsec_lksd_proto_inb_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -1883,7 +1910,7 @@ test_ipsec_replay_inb_inside_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate inbound mbuf data */
@@ -1976,7 +2003,7 @@ test_ipsec_replay_inb_outside_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -2076,7 +2103,7 @@ test_ipsec_replay_inb_repeat_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -2177,7 +2204,7 @@ test_ipsec_replay_inb_inside_burst_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate inbound mbuf data */
@@ -2310,7 +2337,7 @@ test_ipsec_crypto_inb_burst_2sa_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa 0 failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* create second rte_ipsec_sa */
@@ -2320,7 +2347,7 @@ test_ipsec_crypto_inb_burst_2sa_null_null(int i)
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa 1 failed, cfg %d\n", i);
 		destroy_sa(0);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
@@ -2396,7 +2423,7 @@ test_ipsec_crypto_inb_burst_2sa_4grp_null_null(int i)
 			test_cfg[i].replay_win_sz, test_cfg[i].flags, 0);
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa 0 failed, cfg %d\n", i);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* create second rte_ipsec_sa */
@@ -2406,7 +2433,7 @@ test_ipsec_crypto_inb_burst_2sa_4grp_null_null(int i)
 	if (rc != 0) {
 		RTE_LOG(ERR, USER1, "create_sa 1 failed, cfg %d\n", i);
 		destroy_sa(0);
-		return TEST_FAILED;
+		return rc;
 	}
 
 	/* Generate test mbuf data */
diff --git a/dpdk/app/test/test_kvargs.c b/dpdk/app/test/test_kvargs.c
index a42056f361..2a2dae43a0 100644
--- a/dpdk/app/test/test_kvargs.c
+++ b/dpdk/app/test/test_kvargs.c
@@ -142,7 +142,7 @@ static int test_valid_kvargs(void)
 	valid_keys = valid_keys_list;
 	kvlist = rte_kvargs_parse(args, valid_keys);
 	if (kvlist == NULL) {
-		printf("rte_kvargs_parse() error");
+		printf("rte_kvargs_parse() error\n");
 		goto fail;
 	}
 	if (strcmp(kvlist->pairs[0].value, "[0,1]") != 0) {
@@ -157,6 +157,40 @@ static int test_valid_kvargs(void)
 	}
 	rte_kvargs_free(kvlist);
 
+	/* test using empty string (it is valid) */
+	args = "";
+	kvlist = rte_kvargs_parse(args, NULL);
+	if (kvlist == NULL) {
+		printf("rte_kvargs_parse() error\n");
+		goto fail;
+	}
+	if (rte_kvargs_count(kvlist, NULL) != 0) {
+		printf("invalid count value\n");
+		goto fail;
+	}
+	rte_kvargs_free(kvlist);
+
+	/* test using empty elements (it is valid) */
+	args = "foo=1,,check=value2,,";
+	kvlist = rte_kvargs_parse(args, NULL);
+	if (kvlist == NULL) {
+		printf("rte_kvargs_parse() error\n");
+		goto fail;
+	}
+	if (rte_kvargs_count(kvlist, NULL) != 2) {
+		printf("invalid count value\n");
+		goto fail;
+	}
+	if (rte_kvargs_count(kvlist, "foo") != 1) {
+		printf("invalid count value for 'foo'\n");
+		goto fail;
+	}
+	if (rte_kvargs_count(kvlist, "check") != 1) {
+		printf("invalid count value for 'check'\n");
+		goto fail;
+	}
+	rte_kvargs_free(kvlist);
+
 	return 0;
 
  fail:
@@ -179,11 +213,11 @@ static int test_invalid_kvargs(void)
 	const char *args_list[] = {
 		"wrong-key=x",     /* key not in valid_keys_list */
 		"foo=1,foo=",      /* empty value */
-		"foo=1,,foo=2",    /* empty key/value */
 		"foo=1,foo",       /* no value */
 		"foo=1,=2",        /* no key */
 		"foo=[1,2",        /* no closing bracket in value */
 		",=",              /* also test with a smiley */
+		"foo=[",           /* no value in list and no closing bracket */
 		NULL };
 	const char **args;
 	const char *valid_keys_list[] = { "foo", "check", NULL };
@@ -197,8 +231,8 @@ static int test_invalid_kvargs(void)
 			rte_kvargs_free(kvlist);
 			goto fail;
 		}
-		return 0;
 	}
+	return 0;
 
  fail:
 	printf("while processing <%s>", *args);
diff --git a/dpdk/app/test/test_lpm_perf.c b/dpdk/app/test/test_lpm_perf.c
index a2578fe90e..489719c40b 100644
--- a/dpdk/app/test/test_lpm_perf.c
+++ b/dpdk/app/test/test_lpm_perf.c
@@ -34,7 +34,7 @@ struct route_rule {
 	uint8_t depth;
 };
 
-struct route_rule large_route_table[MAX_RULE_NUM];
+static struct route_rule large_route_table[MAX_RULE_NUM];
 
 static uint32_t num_route_entries;
 #define NUM_ROUTE_ENTRIES num_route_entries
diff --git a/dpdk/app/test/test_malloc.c b/dpdk/app/test/test_malloc.c
index a16e28cc32..57f796f9e5 100644
--- a/dpdk/app/test/test_malloc.c
+++ b/dpdk/app/test/test_malloc.c
@@ -746,6 +746,18 @@ test_malloc_bad_params(void)
 	if (bad_ptr != NULL)
 		goto err_return;
 
+	/* rte_malloc expected to return null with size will cause overflow */
+	align = RTE_CACHE_LINE_SIZE;
+	size = (size_t)-8;
+
+	bad_ptr = rte_malloc(type, size, align);
+	if (bad_ptr != NULL)
+		goto err_return;
+
+	bad_ptr = rte_realloc(NULL, size, align);
+	if (bad_ptr != NULL)
+		goto err_return;
+
 	return 0;
 
 err_return:
diff --git a/dpdk/app/test/test_mbuf.c b/dpdk/app/test/test_mbuf.c
index 61ecffc184..a5bd1693b2 100644
--- a/dpdk/app/test/test_mbuf.c
+++ b/dpdk/app/test/test_mbuf.c
@@ -1144,7 +1144,7 @@ test_refcnt_mbuf(void)
 		tref += refcnt_lcore[slave];
 
 	if (tref != refcnt_lcore[master])
-		rte_panic("refernced mbufs: %u, freed mbufs: %u\n",
+		rte_panic("referenced mbufs: %u, freed mbufs: %u\n",
 		          tref, refcnt_lcore[master]);
 
 	rte_mempool_dump(stdout, refcnt_pool);
@@ -2481,9 +2481,13 @@ test_mbuf_dyn(struct rte_mempool *pktmbuf_pool)
 
 	offset3 = rte_mbuf_dynfield_register_offset(&dynfield3,
 				offsetof(struct rte_mbuf, dynfield1[1]));
-	if (offset3 != offsetof(struct rte_mbuf, dynfield1[1]))
-		GOTO_FAIL("failed to register dynamic field 3, offset=%d: %s",
-			offset3, strerror(errno));
+	if (offset3 != offsetof(struct rte_mbuf, dynfield1[1])) {
+		if (rte_errno == EBUSY)
+			printf("mbuf test error skipped: dynfield is busy\n");
+		else
+			GOTO_FAIL("failed to register dynamic field 3, offset="
+				"%d: %s", offset3, strerror(errno));
+	}
 
 	printf("dynfield: offset=%d, offset2=%d, offset3=%d\n",
 		offset, offset2, offset3);
@@ -2519,7 +2523,7 @@ test_mbuf_dyn(struct rte_mempool *pktmbuf_pool)
 	flag3 = rte_mbuf_dynflag_register_bitnum(&dynflag3,
 						rte_bsf64(PKT_LAST_FREE));
 	if (flag3 != rte_bsf64(PKT_LAST_FREE))
-		GOTO_FAIL("failed to register dynamic flag 3, flag2=%d: %s",
+		GOTO_FAIL("failed to register dynamic flag 3, flag3=%d: %s",
 			flag3, strerror(errno));
 
 	printf("dynflag: flag=%d, flag2=%d, flag3=%d\n", flag, flag2, flag3);
diff --git a/dpdk/app/test/test_mcslock.c b/dpdk/app/test/test_mcslock.c
index e9359df2ee..b70dd4775b 100644
--- a/dpdk/app/test/test_mcslock.c
+++ b/dpdk/app/test/test_mcslock.c
@@ -37,10 +37,6 @@
  *   lock multiple times.
  */
 
-RTE_DEFINE_PER_LCORE(rte_mcslock_t, _ml_me);
-RTE_DEFINE_PER_LCORE(rte_mcslock_t, _ml_try_me);
-RTE_DEFINE_PER_LCORE(rte_mcslock_t, _ml_perf_me);
-
 rte_mcslock_t *p_ml;
 rte_mcslock_t *p_ml_try;
 rte_mcslock_t *p_ml_perf;
@@ -53,7 +49,7 @@ static int
 test_mcslock_per_core(__attribute__((unused)) void *arg)
 {
 	/* Per core me node. */
-	rte_mcslock_t ml_me = RTE_PER_LCORE(_ml_me);
+	rte_mcslock_t ml_me;
 
 	rte_mcslock_lock(&p_ml, &ml_me);
 	printf("MCS lock taken on core %u\n", rte_lcore_id());
@@ -77,7 +73,7 @@ load_loop_fn(void *func_param)
 	const unsigned int lcore = rte_lcore_id();
 
 	/**< Per core me node. */
-	rte_mcslock_t ml_perf_me = RTE_PER_LCORE(_ml_perf_me);
+	rte_mcslock_t ml_perf_me;
 
 	/* wait synchro */
 	while (rte_atomic32_read(&synchro) == 0)
@@ -151,8 +147,8 @@ static int
 test_mcslock_try(__attribute__((unused)) void *arg)
 {
 	/**< Per core me node. */
-	rte_mcslock_t ml_me     = RTE_PER_LCORE(_ml_me);
-	rte_mcslock_t ml_try_me = RTE_PER_LCORE(_ml_try_me);
+	rte_mcslock_t ml_me;
+	rte_mcslock_t ml_try_me;
 
 	/* Locked ml_try in the master lcore, so it should fail
 	 * when trying to lock it in the slave lcore.
@@ -178,8 +174,8 @@ test_mcslock(void)
 	int i;
 
 	/* Define per core me node. */
-	rte_mcslock_t ml_me     = RTE_PER_LCORE(_ml_me);
-	rte_mcslock_t ml_try_me = RTE_PER_LCORE(_ml_try_me);
+	rte_mcslock_t ml_me;
+	rte_mcslock_t ml_try_me;
 
 	/*
 	 * Test mcs lock & unlock on each core
diff --git a/dpdk/app/test/test_pmd_perf.c b/dpdk/app/test/test_pmd_perf.c
index d61be58bb3..de7e726429 100644
--- a/dpdk/app/test/test_pmd_perf.c
+++ b/dpdk/app/test/test_pmd_perf.c
@@ -151,7 +151,7 @@ check_all_ports_link_status(uint16_t port_num, uint32_t port_mask)
 					"Port%d Link Up. Speed %u Mbps - %s\n",
 						portid, link.link_speed,
 				(link.link_duplex == ETH_LINK_FULL_DUPLEX) ?
-					("full-duplex") : ("half-duplex\n"));
+					("full-duplex") : ("half-duplex"));
 					if (link_mbps == 0)
 						link_mbps = link.link_speed;
 				} else
@@ -609,10 +609,10 @@ poll_burst(void *args)
 static int
 exec_burst(uint32_t flags, int lcore)
 {
-	unsigned i, portid, nb_tx = 0;
+	unsigned int portid, nb_tx = 0;
 	struct lcore_conf *conf;
 	uint32_t pkt_per_port;
-	int num, idx = 0;
+	int num, i, idx = 0;
 	int diff_tsc;
 
 	conf = &lcore_conf[lcore];
@@ -631,16 +631,14 @@ exec_burst(uint32_t flags, int lcore)
 		rte_atomic64_set(&start, 1);
 
 	/* start xmit */
+	i = 0;
 	while (num) {
 		nb_tx = RTE_MIN(MAX_PKT_BURST, num);
-		for (i = 0; i < conf->nb_ports; i++) {
-			portid = conf->portlist[i];
-			nb_tx = rte_eth_tx_burst(portid, 0,
-					 &tx_burst[idx], nb_tx);
-			idx += nb_tx;
-			num -= nb_tx;
-		}
-
+		portid = conf->portlist[i];
+		nb_tx = rte_eth_tx_burst(portid, 0, &tx_burst[idx], nb_tx);
+		idx += nb_tx;
+		num -= nb_tx;
+		i = (i >= conf->nb_ports - 1) ? 0 : (i + 1);
 	}
 
 	sleep(5);
diff --git a/dpdk/app/test/test_rcu_qsbr.c b/dpdk/app/test/test_rcu_qsbr.c
index b60dc5099c..5542b3c175 100644
--- a/dpdk/app/test/test_rcu_qsbr.c
+++ b/dpdk/app/test/test_rcu_qsbr.c
@@ -273,13 +273,13 @@ static int
 test_rcu_qsbr_start(void)
 {
 	uint64_t token;
-	int i;
+	unsigned int i;
 
 	printf("\nTest rte_rcu_qsbr_start()\n");
 
 	rte_rcu_qsbr_init(t[0], RTE_MAX_LCORE);
 
-	for (i = 0; i < 3; i++)
+	for (i = 0; i < num_cores; i++)
 		rte_rcu_qsbr_thread_register(t[0], enabled_core_ids[i]);
 
 	token = rte_rcu_qsbr_start(t[0]);
@@ -293,14 +293,18 @@ test_rcu_qsbr_check_reader(void *arg)
 {
 	struct rte_rcu_qsbr *temp;
 	uint8_t read_type = (uint8_t)((uintptr_t)arg);
+	unsigned int i;
 
 	temp = t[read_type];
 
 	/* Update quiescent state counter */
-	rte_rcu_qsbr_quiescent(temp, enabled_core_ids[0]);
-	rte_rcu_qsbr_quiescent(temp, enabled_core_ids[1]);
-	rte_rcu_qsbr_thread_unregister(temp, enabled_core_ids[2]);
-	rte_rcu_qsbr_quiescent(temp, enabled_core_ids[3]);
+	for (i = 0; i < num_cores; i++) {
+		if (i % 2 == 0)
+			rte_rcu_qsbr_quiescent(temp, enabled_core_ids[i]);
+		else
+			rte_rcu_qsbr_thread_unregister(temp,
+							enabled_core_ids[i]);
+	}
 	return 0;
 }
 
@@ -311,7 +315,8 @@ test_rcu_qsbr_check_reader(void *arg)
 static int
 test_rcu_qsbr_check(void)
 {
-	int i, ret;
+	int ret;
+	unsigned int i;
 	uint64_t token;
 
 	printf("\nTest rte_rcu_qsbr_check()\n");
@@ -329,7 +334,7 @@ test_rcu_qsbr_check(void)
 	ret = rte_rcu_qsbr_check(t[0], token, true);
 	TEST_RCU_QSBR_RETURN_IF_ERROR((ret == 0), "Blocking QSBR check");
 
-	for (i = 0; i < 3; i++)
+	for (i = 0; i < num_cores; i++)
 		rte_rcu_qsbr_thread_register(t[0], enabled_core_ids[i]);
 
 	ret = rte_rcu_qsbr_check(t[0], token, false);
@@ -344,7 +349,7 @@ test_rcu_qsbr_check(void)
 	/* Threads are offline, hence this should pass */
 	TEST_RCU_QSBR_RETURN_IF_ERROR((ret == 0), "Non-blocking QSBR check");
 
-	for (i = 0; i < 3; i++)
+	for (i = 0; i < num_cores; i++)
 		rte_rcu_qsbr_thread_unregister(t[0], enabled_core_ids[i]);
 
 	ret = rte_rcu_qsbr_check(t[0], token, true);
@@ -352,7 +357,7 @@ test_rcu_qsbr_check(void)
 
 	rte_rcu_qsbr_init(t[0], RTE_MAX_LCORE);
 
-	for (i = 0; i < 4; i++)
+	for (i = 0; i < num_cores; i++)
 		rte_rcu_qsbr_thread_register(t[0], enabled_core_ids[i]);
 
 	token = rte_rcu_qsbr_start(t[0]);
@@ -591,7 +596,7 @@ test_rcu_qsbr_thread_offline(void)
 static int
 test_rcu_qsbr_dump(void)
 {
-	int i;
+	unsigned int i;
 
 	printf("\nTest rte_rcu_qsbr_dump()\n");
 
@@ -608,7 +613,7 @@ test_rcu_qsbr_dump(void)
 
 	rte_rcu_qsbr_thread_register(t[0], enabled_core_ids[0]);
 
-	for (i = 1; i < 3; i++)
+	for (i = 1; i < num_cores; i++)
 		rte_rcu_qsbr_thread_register(t[1], enabled_core_ids[i]);
 
 	rte_rcu_qsbr_dump(stdout, t[0]);
@@ -758,7 +763,7 @@ test_rcu_qsbr_sw_sv_3qs(void)
 {
 	uint64_t token[3];
 	uint32_t c;
-	int i;
+	int i, num_readers;
 	int32_t pos[3];
 
 	writer_done = 0;
@@ -781,7 +786,11 @@ test_rcu_qsbr_sw_sv_3qs(void)
 	thread_info[0].ih = 0;
 
 	/* Reader threads are launched */
-	for (i = 0; i < 4; i++)
+	/* Keep the number of reader threads low to reduce
+	 * the execution time.
+	 */
+	num_readers = num_cores < 4 ? num_cores : 4;
+	for (i = 0; i < num_readers; i++)
 		rte_eal_remote_launch(test_rcu_qsbr_reader, &thread_info[0],
 					enabled_core_ids[i]);
 
@@ -814,7 +823,7 @@ test_rcu_qsbr_sw_sv_3qs(void)
 
 	/* Check the quiescent state status */
 	rte_rcu_qsbr_check(t[0], token[0], true);
-	for (i = 0; i < 4; i++) {
+	for (i = 0; i < num_readers; i++) {
 		c = hash_data[0][0][enabled_core_ids[i]];
 		if (c != COUNTER_VALUE && c != 0) {
 			printf("Reader lcore %d did not complete #0 = %d\n",
@@ -832,7 +841,7 @@ test_rcu_qsbr_sw_sv_3qs(void)
 
 	/* Check the quiescent state status */
 	rte_rcu_qsbr_check(t[0], token[1], true);
-	for (i = 0; i < 4; i++) {
+	for (i = 0; i < num_readers; i++) {
 		c = hash_data[0][3][enabled_core_ids[i]];
 		if (c != COUNTER_VALUE && c != 0) {
 			printf("Reader lcore %d did not complete #3 = %d\n",
@@ -850,7 +859,7 @@ test_rcu_qsbr_sw_sv_3qs(void)
 
 	/* Check the quiescent state status */
 	rte_rcu_qsbr_check(t[0], token[2], true);
-	for (i = 0; i < 4; i++) {
+	for (i = 0; i < num_readers; i++) {
 		c = hash_data[0][6][enabled_core_ids[i]];
 		if (c != COUNTER_VALUE && c != 0) {
 			printf("Reader lcore %d did not complete #6 = %d\n",
@@ -869,7 +878,7 @@ test_rcu_qsbr_sw_sv_3qs(void)
 	writer_done = 1;
 
 	/* Wait and check return value from reader threads */
-	for (i = 0; i < 4; i++)
+	for (i = 0; i < num_readers; i++)
 		if (rte_eal_wait_lcore(enabled_core_ids[i]) < 0)
 			goto error;
 	rte_hash_free(h[0]);
@@ -899,6 +908,12 @@ test_rcu_qsbr_mw_mv_mqs(void)
 	unsigned int i, j;
 	unsigned int test_cores;
 
+	if (RTE_MAX_LCORE < 5 || num_cores < 4) {
+		printf("Not enough cores for %s, expecting at least 5\n",
+			__func__);
+		return TEST_SKIPPED;
+	}
+
 	writer_done = 0;
 	test_cores = num_cores / 4;
 	test_cores = test_cores * 4;
@@ -984,11 +999,6 @@ test_rcu_qsbr_main(void)
 {
 	uint16_t core_id;
 
-	if (rte_lcore_count() < 5) {
-		printf("Not enough cores for rcu_qsbr_autotest, expecting at least 5\n");
-		return TEST_SKIPPED;
-	}
-
 	num_cores = 0;
 	RTE_LCORE_FOREACH_SLAVE(core_id) {
 		enabled_core_ids[num_cores] = core_id;
diff --git a/dpdk/app/test/test_ring.c b/dpdk/app/test/test_ring.c
index aaf1e70ad8..4825c9e2e9 100644
--- a/dpdk/app/test/test_ring.c
+++ b/dpdk/app/test/test_ring.c
@@ -696,7 +696,7 @@ test_ring_basic_ex(void)
 
 	printf("%u ring entries are now free\n", rte_ring_free_count(rp));
 
-	for (i = 0; i < RING_SIZE; i ++) {
+	for (i = 0; i < RING_SIZE - 1; i ++) {
 		rte_ring_enqueue(rp, obj[i]);
 	}
 
@@ -705,7 +705,7 @@ test_ring_basic_ex(void)
 		goto fail_test;
 	}
 
-	for (i = 0; i < RING_SIZE; i ++) {
+	for (i = 0; i < RING_SIZE - 1; i ++) {
 		rte_ring_dequeue(rp, &obj[i]);
 	}
 
diff --git a/dpdk/app/test/test_ring_perf.c b/dpdk/app/test/test_ring_perf.c
index 70ee46ffe6..3cf27965de 100644
--- a/dpdk/app/test/test_ring_perf.c
+++ b/dpdk/app/test/test_ring_perf.c
@@ -296,12 +296,13 @@ load_loop_fn(void *p)
 static int
 run_on_all_cores(struct rte_ring *r)
 {
-	uint64_t total = 0;
+	uint64_t total;
 	struct thread_params param;
 	unsigned int i, c;
 
 	memset(&param, 0, sizeof(struct thread_params));
 	for (i = 0; i < RTE_DIM(bulk_sizes); i++) {
+		total = 0;
 		printf("\nBulk enq/dequeue count on size %u\n", bulk_sizes[i]);
 		param.size = bulk_sizes[i];
 		param.r = r;
diff --git a/dpdk/app/test/test_service_cores.c b/dpdk/app/test/test_service_cores.c
index a922c7ddcc..2a4978e29a 100644
--- a/dpdk/app/test/test_service_cores.c
+++ b/dpdk/app/test/test_service_cores.c
@@ -114,6 +114,7 @@ unregister_all(void)
 	}
 
 	rte_service_lcore_reset_all();
+	rte_eal_mp_wait_lcore();
 
 	return TEST_SUCCESS;
 }
diff --git a/dpdk/app/test/test_table_pipeline.c b/dpdk/app/test/test_table_pipeline.c
index 441338ac01..bc412c3081 100644
--- a/dpdk/app/test/test_table_pipeline.c
+++ b/dpdk/app/test/test_table_pipeline.c
@@ -190,11 +190,13 @@ check_pipeline_invalid_params(void)
 		goto fail;
 	}
 
-	p = rte_pipeline_create(&pipeline_params_3);
-	if (p != NULL) {
-		RTE_LOG(INFO, PIPELINE, "%s: Configure pipeline with invalid "
-			"socket\n", __func__);
-		goto fail;
+	if (rte_eal_has_hugepages()) {
+		p = rte_pipeline_create(&pipeline_params_3);
+		if (p != NULL) {
+			RTE_LOG(INFO, PIPELINE, "%s: Configure pipeline with "
+				"invalid socket\n", __func__);
+			goto fail;
+		}
 	}
 
 	/* Check pipeline consistency */
diff --git a/dpdk/buildtools/call-sphinx-build.py b/dpdk/buildtools/call-sphinx-build.py
new file mode 100755
index 0000000000..b9a3994e17
--- /dev/null
+++ b/dpdk/buildtools/call-sphinx-build.py
@@ -0,0 +1,31 @@
+#! /usr/bin/env python3
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2019 Intel Corporation
+#
+
+import sys
+import os
+from os.path import join
+from subprocess import run, PIPE
+from distutils.version import StrictVersion
+
+(sphinx, src, dst) = sys.argv[1:]  # assign parameters to variables
+
+# for sphinx version >= 1.7 add parallelism using "-j auto"
+ver = run([sphinx, '--version'], stdout=PIPE).stdout.decode().split()[-1]
+sphinx_cmd = [sphinx]
+if StrictVersion(ver) >= StrictVersion('1.7'):
+    sphinx_cmd += ['-j', 'auto']
+
+# find all the files sphinx will process so we can write them as dependencies
+srcfiles = []
+for root, dirs, files in os.walk(src):
+    srcfiles.extend([join(root, f) for f in files])
+
+# run sphinx, putting the html output in a "html" directory
+process = run(sphinx_cmd + ['-b', 'html', src, join(dst, 'html')], check=True)
+print(str(process.args) + ' Done OK')
+
+# create a gcc format .d file giving all the dependencies of this doc build
+with open(join(dst, '.html.d'), 'w') as d:
+    d.write('html: ' + ' '.join(srcfiles) + '\n')
diff --git a/dpdk/buildtools/meson.build b/dpdk/buildtools/meson.build
index 6ef2c5721c..ea13d9fc3f 100644
--- a/dpdk/buildtools/meson.build
+++ b/dpdk/buildtools/meson.build
@@ -3,17 +3,21 @@
 
 subdir('pmdinfogen')
 
+pkgconf = find_program('pkg-config', 'pkgconf', required: false)
 pmdinfo = find_program('gen-pmdinfo-cfile.sh')
 
 check_experimental_syms = find_program('check-experimental-syms.sh')
+ldflags_ibverbs_static = find_program('options-ibverbs-static.sh')
 
 # set up map-to-def script using python, either built-in or external
 python3 = import('python').find_installation(required: false)
 if python3.found()
-	map_to_def_cmd = [python3, files('map_to_def.py')]
+	py3 = [python3]
 else
-	map_to_def_cmd = ['meson', 'runpython', files('map_to_def.py')]
+	py3 = ['meson', 'runpython']
 endif
+map_to_def_cmd = py3 + files('map_to_def.py')
+sphinx_wrapper = py3 + files('call-sphinx-build.py')
 
 # stable ABI always starts with "DPDK_"
 is_experimental_cmd = [find_program('grep', 'findstr'), '^DPDK_']
diff --git a/dpdk/buildtools/options-ibverbs-static.sh b/dpdk/buildtools/options-ibverbs-static.sh
index 0f285a343b..0740a711ff 100755
--- a/dpdk/buildtools/options-ibverbs-static.sh
+++ b/dpdk/buildtools/options-ibverbs-static.sh
@@ -9,6 +9,13 @@
 #
 # PKG_CONFIG_PATH may be required to be set if libibverbs.pc is not installed.
 
-pkg-config --libs-only-l --static libibverbs |
+lib='libibverbs'
+deps='pthread|nl'
+
+pkg-config --libs --static $lib |
 	tr '[:space:]' '\n' |
-	sed -r '/^-l(pthread|nl)/! s,(^-l)(.*),\1:lib\2.a,'
+	sed -r "/^-l($deps)/! s,(^-l)(.*),\1:lib\2.a," |   # explicit .a
+	sed -n '/^-[Ll]/p' |   # extra link options may break with make
+	tac |
+	awk "/^-l:$lib.a/&&c++ {next} 1" | # drop first duplicates of main lib
+	tac
diff --git a/dpdk/buildtools/pkg-config/meson.build b/dpdk/buildtools/pkg-config/meson.build
new file mode 100644
index 0000000000..39a8fd1c8e
--- /dev/null
+++ b/dpdk/buildtools/pkg-config/meson.build
@@ -0,0 +1,59 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2020 Intel Corporation
+
+pkg = import('pkgconfig')
+pkg_extra_cflags = ['-include', 'rte_config.h'] + machine_args
+if is_freebsd
+	pkg_extra_cflags += ['-D__BSD_VISIBLE']
+endif
+
+# When calling pkg-config --static --libs, pkg-config will always output the
+# regular libs first, and then the extra libs from Libs.private field,
+# since the assumption is that those are additional dependencies for building
+# statically that the .a files depend upon. The output order of .pc fields is:
+#   Libs   Libs.private   Requires   Requires.private
+# The fields Requires* are for package names.
+# The flags of the DPDK libraries must be defined in Libs* fields.
+# However, the DPDK drivers are linked only in static builds (Libs.private),
+# and those need to come *before* the regular libraries (Libs field).
+# This requirement is satisfied by moving the regular libs in a separate file
+# included in the field Requires (after Libs.private).
+# Another requirement is to allow linking dependencies as shared libraries,
+# while linking static DPDK libraries and drivers. It is satisfied by
+# listing the static files in Libs.private with the explicit syntax -l:libfoo.a.
+# As a consequence, the regular DPDK libraries are already listed as static
+# in the field Libs.private. The second occurences of DPDK libraries,
+# included from Requires and used for shared library linkage case,
+# are skipped in the case of static linkage thanks to the flag --as-needed.
+
+
+pkg.generate(name: 'dpdk-libs',
+	filebase: 'libdpdk-libs',
+	description: '''Internal-only DPDK pkgconfig file. Not for direct use.
+Use libdpdk.pc instead of this file to query DPDK compile/link arguments''',
+	version: meson.project_version(),
+	subdirs: [get_option('include_subdir_arch'), '.'],
+	extra_cflags: pkg_extra_cflags,
+	libraries: ['-Wl,--as-needed'] + dpdk_libraries,
+	libraries_private: dpdk_extra_ldflags)
+
+platform_flags = []
+if not is_windows
+	platform_flags += ['-Wl,--export-dynamic'] # ELF only
+endif
+pkg.generate(name: 'DPDK', # main DPDK pkgconfig file
+	filebase: 'libdpdk',
+	version: meson.project_version(),
+	description: '''The Data Plane Development Kit (DPDK).
+Note that CFLAGS might contain an -march flag higher than typical baseline.
+This is required for a number of static inline functions in the public headers.''',
+	requires: ['libdpdk-libs', libbsd], # may need libbsd for string funcs
+	                  # if libbsd is not enabled, then this is blank
+	libraries_private: ['-Wl,--whole-archive'] +
+			dpdk_drivers + dpdk_static_libraries +
+			['-Wl,--no-whole-archive'] + platform_flags
+)
+
+# For static linking with dependencies as shared libraries,
+# the internal static libraries must be flagged explicitly.
+run_command(py3, 'set-static-linker-flags.py', check: true)
diff --git a/dpdk/buildtools/pkg-config/set-static-linker-flags.py b/dpdk/buildtools/pkg-config/set-static-linker-flags.py
new file mode 100644
index 0000000000..2745db34c2
--- /dev/null
+++ b/dpdk/buildtools/pkg-config/set-static-linker-flags.py
@@ -0,0 +1,38 @@
+#!/usr/bin/env python3
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2020 Intel Corporation
+
+# Script to fix flags for static linking in pkgconfig files from meson
+# Should be called from meson build itself
+import os
+import sys
+
+
+def fix_ldflag(f):
+    if not f.startswith('-lrte_'):
+        return f
+    return '-l:lib' + f[2:] + '.a'
+
+
+def fix_libs_private(line):
+    if not line.startswith('Libs.private'):
+        return line
+    ldflags = [fix_ldflag(flag) for flag in line.split()]
+    return ' '.join(ldflags) + '\n'
+
+
+def process_pc_file(filepath):
+    print('Processing', filepath)
+    with open(filepath) as src:
+        lines = src.readlines()
+    with open(filepath, 'w') as dst:
+        dst.writelines([fix_libs_private(line) for line in lines])
+
+
+if 'MESON_BUILD_ROOT' not in os.environ:
+    print('This script must be called from a meson build environment')
+    sys.exit(1)
+for root, dirs, files in os.walk(os.environ['MESON_BUILD_ROOT']):
+    pc_files = [f for f in files if f.endswith('.pc')]
+    for f in pc_files:
+        process_pc_file(os.path.join(root, f))
diff --git a/dpdk/buildtools/pmdinfogen/pmdinfogen.h b/dpdk/buildtools/pmdinfogen/pmdinfogen.h
index c8a9e2136a..467216d12b 100644
--- a/dpdk/buildtools/pmdinfogen/pmdinfogen.h
+++ b/dpdk/buildtools/pmdinfogen/pmdinfogen.h
@@ -82,7 +82,7 @@ if ((fend) == ELFDATA2LSB) \
 	___x = le##width##toh(x); \
 else \
 	___x = be##width##toh(x); \
-	___x; \
+___x; \
 })
 
 #define TO_NATIVE(fend, width, x) CONVERT_NATIVE(fend, width, x)
diff --git a/dpdk/config/common_base b/dpdk/config/common_base
index 7dec7ed457..3406146372 100644
--- a/dpdk/config/common_base
+++ b/dpdk/config/common_base
@@ -328,7 +328,6 @@ CONFIG_RTE_LIBRTE_ICE_PMD=y
 CONFIG_RTE_LIBRTE_ICE_DEBUG_RX=n
 CONFIG_RTE_LIBRTE_ICE_DEBUG_TX=n
 CONFIG_RTE_LIBRTE_ICE_DEBUG_TX_FREE=n
-CONFIG_RTE_LIBRTE_ICE_RX_ALLOW_BULK_ALLOC=y
 CONFIG_RTE_LIBRTE_ICE_16BYTE_RX_DESC=n
 
 # Compile burst-oriented IAVF PMD driver
@@ -352,7 +351,7 @@ CONFIG_RTE_LIBRTE_MLX4_DEBUG=n
 
 #
 # Compile burst-oriented Mellanox ConnectX-4, ConnectX-5,
-# ConnectX-6 & Bluefield (MLX5) PMD
+# ConnectX-6 & BlueField (MLX5) PMD
 #
 CONFIG_RTE_LIBRTE_MLX5_PMD=n
 CONFIG_RTE_LIBRTE_MLX5_DEBUG=n
@@ -573,7 +572,6 @@ CONFIG_RTE_CRYPTO_MAX_DEVS=64
 # Compile PMD for ARMv8 Crypto device
 #
 CONFIG_RTE_LIBRTE_PMD_ARMV8_CRYPTO=n
-CONFIG_RTE_LIBRTE_PMD_ARMV8_CRYPTO_DEBUG=n
 
 #
 # Compile NXP CAAM JR crypto Driver
diff --git a/dpdk/config/defconfig_arm-armv7a-linuxapp-gcc b/dpdk/config/defconfig_arm-armv7a-linuxapp-gcc
index c91423f0e6..749f9924d5 100644
--- a/dpdk/config/defconfig_arm-armv7a-linuxapp-gcc
+++ b/dpdk/config/defconfig_arm-armv7a-linuxapp-gcc
@@ -45,7 +45,6 @@ CONFIG_RTE_LIBRTE_CXGBE_PMD=n
 CONFIG_RTE_LIBRTE_E1000_PMD=n
 CONFIG_RTE_LIBRTE_ENIC_PMD=n
 CONFIG_RTE_LIBRTE_FM10K_PMD=n
-CONFIG_RTE_LIBRTE_I40E_PMD=n
 CONFIG_RTE_LIBRTE_IXGBE_PMD=n
 CONFIG_RTE_LIBRTE_MLX4_PMD=n
 CONFIG_RTE_LIBRTE_VMXNET3_PMD=n
diff --git a/dpdk/config/defconfig_arm64-graviton2-linux-gcc b/dpdk/config/defconfig_arm64-graviton2-linux-gcc
new file mode 120000
index 0000000000..80ac94d54d
--- /dev/null
+++ b/dpdk/config/defconfig_arm64-graviton2-linux-gcc
@@ -0,0 +1 @@
+defconfig_arm64-graviton2-linuxapp-gcc
\ No newline at end of file
diff --git a/dpdk/config/defconfig_arm64-graviton2-linuxapp-gcc b/dpdk/config/defconfig_arm64-graviton2-linuxapp-gcc
new file mode 100644
index 0000000000..e99fef3073
--- /dev/null
+++ b/dpdk/config/defconfig_arm64-graviton2-linuxapp-gcc
@@ -0,0 +1,13 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) Amazon.com, Inc or its affiliates
+#
+
+#include "defconfig_arm64-armv8a-linux-gcc"
+
+CONFIG_RTE_MACHINE="graviton2"
+CONFIG_RTE_MAX_LCORE=64
+CONFIG_RTE_CACHE_LINE_SIZE=64
+CONFIG_RTE_MAX_MEM_MB=1048576
+CONFIG_RTE_MAX_NUMA_NODES=1
+CONFIG_RTE_EAL_NUMA_AWARE_HUGEPAGES=n
+CONFIG_RTE_LIBRTE_VHOST_NUMA=n
diff --git a/dpdk/config/defconfig_graviton2 b/dpdk/config/defconfig_graviton2
new file mode 120000
index 0000000000..80ac94d54d
--- /dev/null
+++ b/dpdk/config/defconfig_graviton2
@@ -0,0 +1 @@
+defconfig_arm64-graviton2-linuxapp-gcc
\ No newline at end of file
diff --git a/dpdk/config/meson.build b/dpdk/config/meson.build
index 364a8d7394..b1f728ee86 100644
--- a/dpdk/config/meson.build
+++ b/dpdk/config/meson.build
@@ -14,6 +14,10 @@ foreach env:supported_exec_envs
 	set_variable('is_' + env, exec_env == env)
 endforeach
 
+# MS linker requires special treatment.
+# TODO: use cc.get_linker_id() with Meson >= 0.54
+is_ms_linker = is_windows and (cc.get_id() == 'clang')
+
 # set the major version, which might be used by drivers and libraries
 # depending on the configuration options
 pver = meson.project_version().split('.')
@@ -50,9 +54,11 @@ eal_pmd_path = join_paths(get_option('prefix'), driver_install_path)
 # driver .so files often depend upon the bus drivers for their connect bus,
 # e.g. ixgbe depends on librte_bus_pci. This means that the bus drivers need
 # to be in the library path, so symlink the drivers from the main lib directory.
-meson.add_install_script('../buildtools/symlink-drivers-solibs.sh',
-		get_option('libdir'),
-		pmd_subdir_opt)
+if not is_windows
+	meson.add_install_script('../buildtools/symlink-drivers-solibs.sh',
+			get_option('libdir'),
+			pmd_subdir_opt)
+endif
 
 # set the machine type and cflags for it
 if meson.is_cross_build()
@@ -98,14 +104,18 @@ dpdk_conf.set('RTE_TOOLCHAIN_' + toolchain.to_upper(), 1)
 
 dpdk_conf.set('RTE_ARCH_64', cc.sizeof('void *') == 8)
 
-add_project_link_arguments('-Wl,--no-as-needed', language: 'c')
+if not is_windows
+	add_project_link_arguments('-Wl,--no-as-needed', language: 'c')
+endif
 
-# use pthreads
-add_project_link_arguments('-pthread', language: 'c')
-dpdk_extra_ldflags += '-pthread'
+# use pthreads if available for the platform
+if not is_ms_linker
+	add_project_link_arguments('-pthread', language: 'c')
+	dpdk_extra_ldflags += '-pthread'
+endif
 
 # on some OS, maths functions are in a separate library
-if cc.find_library('libm', required : false).found()
+if cc.find_library('m', required : false).found()
 	# some libs depend on maths lib
 	add_project_link_arguments('-lm', language: 'c')
 	dpdk_extra_ldflags += '-lm'
@@ -136,18 +146,25 @@ if numa_dep.found() and cc.has_header('numaif.h')
 	dpdk_extra_ldflags += '-lnuma'
 endif
 
+has_libfdt = 0
+fdt_dep = cc.find_library('libfdt', required: false)
+if fdt_dep.found() and cc.has_header('fdt.h')
+	dpdk_conf.set10('RTE_HAS_LIBFDT', true)
+	has_libfdt = 1
+	add_project_link_arguments('-lfdt', language: 'c')
+	dpdk_extra_ldflags += '-lfdt'
+endif
+
 # check for libbsd
-libbsd = dependency('libbsd', required: false)
+libbsd = dependency('libbsd', required: false, method: 'pkg-config')
 if libbsd.found()
 	dpdk_conf.set('RTE_USE_LIBBSD', 1)
 endif
 
 # check for pcap
-pcap_dep = dependency('pcap', required: false)
-if pcap_dep.found()
-	# pcap got a pkg-config file only in 1.9.0 and before that meson uses
-	# an internal pcap-config finder, which is not compatible with
-	# cross-compilation, so try to fallback to find_library
+pcap_dep = dependency('libpcap', required: false, method: 'pkg-config')
+if not pcap_dep.found()
+	# pcap got a pkg-config file only in 1.9.0
 	pcap_dep = cc.find_library('pcap', required: false)
 endif
 if pcap_dep.found() and cc.has_header('pcap.h', dependencies: pcap_dep)
@@ -166,6 +183,7 @@ warning_flags = [
 	# additional warnings in alphabetical order
 	'-Wcast-qual',
 	'-Wdeprecated',
+	'-Wformat',
 	'-Wformat-nonliteral',
 	'-Wformat-security',
 	'-Wmissing-declarations',
@@ -183,6 +201,10 @@ warning_flags = [
 	'-Wno-packed-not-aligned',
 	'-Wno-missing-field-initializers'
 ]
+if cc.get_id() == 'gcc' and cc.version().version_compare('>=10.0')
+# FIXME: Bugzilla 396
+	warning_flags += '-Wno-zero-length-bounds'
+endif
 if not dpdk_conf.get('RTE_ARCH_64')
 # for 32-bit, don't warn about casting a 32-bit pointer to 64-bit int - it's fine!!
 	warning_flags += '-Wno-pointer-to-int-cast'
@@ -202,6 +224,11 @@ dpdk_conf.set('RTE_LIBEAL_USE_HPET', get_option('use_hpet'))
 dpdk_conf.set('RTE_MAX_VFIO_GROUPS', 64)
 dpdk_conf.set('RTE_DRIVER_MEMPOOL_BUCKET_SIZE_KB', 64)
 dpdk_conf.set('RTE_LIBRTE_DPAA2_USE_PHYS_IOVA', true)
+if dpdk_conf.get('RTE_ARCH_64')
+	dpdk_conf.set('RTE_MAX_MEM_MB', 524288)
+else # for 32-bit we need smaller reserved memory areas
+	dpdk_conf.set('RTE_MAX_MEM_MB', 2048)
+endif
 
 
 compile_time_cpuflags = []
@@ -231,6 +258,16 @@ if is_freebsd
 	add_project_arguments('-D__BSD_VISIBLE', language: 'c')
 endif
 
+if is_windows
+	# Minimum supported API is Windows 7.
+	add_project_arguments('-D_WIN32_WINNT=0x0601', language: 'c')
+
+	# Use MinGW-w64 stdio, because DPDK assumes ANSI-compliant formatting.
+	if cc.get_id() == 'gcc'
+		add_project_arguments('-D__USE_MINGW_ANSI_STDIO', language: 'c')
+	endif
+endif
+
 if get_option('b_lto')
Louis Abel's avatar
Louis Abel committed
10201 10202 10203 10204 10205 10206 10207 10208 10209 10210 10211 10212 10213 10214 10215 10216 10217 10218 10219 10220 10221 10222 10223 10224 10225 10226 10227 10228 10229 10230 10231 10232 10233 10234 10235 10236 10237 10238 10239 10240 10241 10242 10243 10244 10245 10246 10247 10248 10249 10250 10251 10252 10253 10254 10255 10256 10257 10258 10259 10260 10261 10262 10263 10264 10265 10266 10267 10268 10269 10270 10271 10272 10273 10274 10275 10276 10277 10278 10279 10280 10281 10282 10283 10284 10285 10286 10287 10288 10289 10290 10291 10292 10293 10294 10295 10296 10297 10298 10299 10300 10301 10302 10303 10304 10305 10306 10307 10308 10309 10310 10311 10312 10313 10314 10315 10316 10317 10318 10319 10320 10321 10322 10323 10324 10325 10326 10327 10328 10329 10330 10331 10332 10333 10334 10335 10336 10337 10338 10339 10340 10341 10342 10343 10344 10345 10346 10347 10348 10349 10350 10351 10352 10353 10354 10355 10356 10357 10358 10359 10360 10361 10362 10363 10364 10365 10366 10367 10368 10369 10370 10371 10372 10373 10374 10375 10376 10377 10378 10379 10380 10381 10382 10383 10384 10385 10386 10387 10388 10389 10390 10391 10392 10393 10394 10395 10396 10397 10398 10399 10400 10401 10402 10403 10404 10405 10406 10407 10408 10409 10410 10411 10412 10413 10414 10415 10416 10417 10418 10419 10420 10421 10422 10423 10424 10425 10426 10427 10428 10429 10430 10431 10432 10433 10434 10435 10436 10437 10438 10439 10440 10441 10442 10443 10444 10445 10446 10447 10448 10449 10450 10451 10452 10453 10454 10455 10456 10457 10458 10459 10460 10461 10462 10463 10464 10465 10466 10467 10468 10469 10470 10471 10472 10473 10474 10475 10476 10477 10478 10479 10480 10481 10482 10483 10484 10485 10486 10487 10488 10489 10490 10491 10492 10493 10494 10495 10496 10497 10498 10499 10500 10501 10502 10503 10504 10505 10506 10507 10508 10509 10510 10511 10512 10513 10514 10515 10516 10517 10518 10519 10520 10521 10522 10523 10524 10525 10526 10527 10528 10529 10530 10531 10532 10533 10534 10535 10536 10537 10538 10539 10540 10541 10542 10543 10544 10545 10546 10547 10548 10549 10550 10551 10552 10553 10554 10555 10556 10557 10558 10559 10560 10561 10562 10563 10564 10565 10566 10567 10568 10569 10570 10571 10572 10573 10574 10575 10576 10577 10578 10579 10580 10581 10582 10583 10584 10585 10586 10587 10588 10589 10590 10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671 10672 10673 10674 10675 10676 10677 10678 10679 10680 10681 10682 10683 10684 10685 10686 10687 10688 10689 10690 10691 10692 10693 10694 10695 10696 10697 10698 10699 10700 10701 10702 10703 10704 10705 10706 10707 10708 10709 10710 10711 10712 10713 10714 10715 10716 10717 10718 10719 10720 10721 10722 10723 10724 10725 10726 10727 10728 10729 10730 10731 10732 10733 10734 10735 10736 10737 10738 10739 10740 10741 10742 10743 10744 10745 10746 10747 10748 10749 10750 10751 10752 10753 10754 10755 10756 10757 10758 10759 10760 10761 10762 10763 10764 10765 10766 10767 10768 10769 10770 10771 10772 10773 10774 10775 10776 10777 10778 10779 10780 10781 10782 10783 10784 10785 10786 10787 10788 10789 10790 10791 10792 10793 10794 10795 10796 10797 10798 10799 10800 10801 10802 10803 10804 10805 10806 10807 10808 10809 10810 10811 10812 10813 10814 10815 10816 10817 10818 10819 10820 10821 10822 10823 10824 10825 10826 10827 10828 10829 10830 10831 10832 10833 10834 10835 10836 10837 10838 10839 10840 10841 10842 10843 10844 10845 10846 10847 10848 10849 10850 10851 10852 10853 10854 10855 10856 10857 10858 10859 10860 10861 10862 10863 10864 10865 10866 10867 10868 10869 10870 10871 10872 10873 10874 10875 10876 10877 10878 10879 10880 10881 10882 10883 10884 10885 10886 10887 10888 10889 10890 10891 10892 10893 10894 10895 10896 10897 10898 10899 10900 10901 10902 10903 10904 10905 10906 10907 10908 10909 10910 10911 10912 10913 10914 10915 10916 10917 10918 10919 10920 10921 10922 10923 10924 10925 10926 10927 10928 10929 10930 10931 10932 10933 10934 10935 10936 10937 10938 10939 10940 10941 10942 10943 10944 10945 10946 10947 10948 10949 10950 10951 10952 10953 10954 10955 10956 10957 10958 10959 10960 10961 10962 10963 10964 10965 10966 10967 10968 10969 10970 10971 10972 10973 10974 10975 10976 10977 10978 10979 10980 10981 10982 10983 10984 10985 10986 10987 10988 10989 10990 10991 10992 10993 10994 10995 10996 10997 10998 10999 11000 11001 11002 11003 11004 11005 11006 11007 11008 11009 11010 11011 11012 11013 11014 11015 11016 11017 11018 11019 11020 11021 11022 11023 11024 11025 11026 11027 11028 11029 11030 11031 11032 11033 11034 11035 11036 11037 11038 11039 11040 11041 11042 11043 11044 11045 11046 11047 11048 11049 11050 11051 11052 11053 11054 11055 11056 11057 11058 11059 11060 11061 11062 11063 11064 11065 11066 11067 11068 11069 11070 11071 11072 11073 11074 11075 11076 11077 11078 11079 11080 11081 11082 11083 11084 11085 11086 11087 11088 11089 11090 11091 11092 11093 11094 11095 11096 11097 11098 11099 11100 11101 11102 11103 11104 11105 11106 11107 11108 11109 11110 11111 11112 11113 11114 11115 11116 11117 11118 11119 11120 11121 11122 11123 11124 11125 11126 11127 11128 11129 11130 11131 11132 11133 11134 11135 11136 11137 11138 11139 11140 11141 11142 11143 11144 11145 11146 11147 11148 11149 11150 11151 11152 11153 11154 11155 11156 11157 11158 11159 11160 11161 11162 11163 11164 11165 11166 11167 11168 11169 11170 11171 11172 11173 11174 11175 11176 11177 11178 11179 11180 11181 11182 11183 11184 11185 11186 11187 11188 11189 11190 11191 11192 11193 11194 11195 11196 11197 11198 11199 11200 11201 11202 11203 11204 11205 11206 11207 11208 11209 11210 11211 11212 11213 11214 11215 11216 11217 11218 11219 11220 11221 11222 11223 11224 11225 11226 11227 11228 11229 11230 11231 11232 11233 11234 11235 11236 11237 11238 11239 11240 11241 11242 11243 11244 11245 11246 11247 11248 11249 11250 11251 11252 11253 11254 11255 11256 11257 11258 11259 11260 11261 11262 11263 11264 11265 11266 11267 11268 11269 11270 11271 11272 11273 11274 11275 11276 11277 11278 11279 11280 11281 11282 11283 11284 11285 11286 11287 11288 11289 11290 11291 11292 11293 11294 11295 11296 11297 11298 11299 11300 11301 11302 11303 11304 11305 11306 11307 11308 11309 11310 11311 11312 11313 11314 11315 11316 11317 11318 11319 11320 11321 11322 11323 11324 11325 11326 11327 11328 11329 11330 11331 11332 11333 11334 11335 11336 11337 11338 11339 11340 11341 11342 11343 11344 11345 11346 11347 11348 11349 11350 11351 11352 11353 11354 11355 11356 11357 11358 11359 11360 11361 11362 11363 11364 11365 11366 11367 11368 11369 11370 11371 11372 11373 11374 11375 11376 11377 11378 11379 11380 11381 11382 11383 11384 11385 11386 11387 11388 11389 11390 11391 11392 11393 11394 11395 11396 11397 11398 11399 11400 11401 11402 11403 11404 11405 11406 11407 11408 11409 11410 11411 11412 11413 11414 11415 11416 11417 11418 11419 11420 11421 11422 11423 11424 11425 11426 11427 11428 11429 11430 11431 11432 11433 11434 11435 11436 11437 11438 11439 11440 11441 11442 11443 11444 11445 11446 11447 11448 11449 11450 11451 11452 11453 11454 11455 11456 11457 11458 11459 11460 11461 11462 11463 11464 11465 11466 11467 11468 11469 11470 11471 11472 11473 11474 11475 11476 11477 11478 11479 11480 11481 11482 11483 11484 11485 11486 11487 11488 11489 11490 11491 11492 11493 11494 11495 11496 11497 11498 11499 11500 11501 11502 11503 11504 11505 11506 11507 11508 11509 11510 11511 11512 11513 11514 11515 11516 11517 11518 11519 11520 11521 11522 11523 11524 11525 11526 11527 11528 11529 11530 11531 11532 11533 11534 11535 11536 11537 11538 11539 11540 11541 11542 11543 11544 11545 11546 11547 11548 11549 11550 11551 11552 11553 11554 11555 11556 11557 11558 11559 11560 11561 11562 11563 11564 11565 11566 11567 11568 11569 11570 11571 11572 11573 11574 11575 11576 11577 11578 11579 11580 11581 11582 11583 11584 11585 11586 11587 11588 11589 11590 11591 11592 11593 11594 11595 11596 11597 11598 11599 11600 11601 11602 11603 11604 11605 11606 11607 11608 11609 11610 11611 11612 11613 11614 11615 11616 11617 11618 11619 11620 11621 11622 11623 11624 11625 11626 11627 11628 11629 11630 11631 11632 11633 11634 11635 11636 11637 11638 11639 11640 11641 11642 11643 11644 11645 11646 11647 11648 11649 11650 11651 11652 11653 11654 11655 11656 11657 11658 11659 11660 11661 11662 11663 11664 11665 11666 11667 11668 11669 11670 11671 11672 11673 11674 11675 11676 11677 11678 11679 11680 11681 11682 11683 11684 11685 11686 11687 11688 11689 11690 11691 11692 11693 11694 11695 11696 11697 11698 11699 11700 11701 11702 11703 11704 11705 11706 11707 11708 11709 11710 11711 11712 11713 11714 11715 11716 11717 11718 11719 11720 11721 11722 11723 11724 11725 11726 11727 11728 11729 11730 11731 11732 11733 11734 11735 11736 11737 11738 11739 11740 11741 11742 11743 11744 11745 11746 11747 11748 11749 11750 11751 11752 11753 11754 11755 11756 11757 11758 11759 11760 11761 11762 11763 11764 11765 11766 11767 11768 11769 11770 11771 11772 11773 11774 11775 11776 11777 11778 11779 11780 11781 11782 11783 11784 11785 11786 11787 11788 11789 11790 11791 11792 11793 11794 11795 11796 11797 11798 11799 11800 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 11816 11817 11818 11819 11820 11821 11822 11823 11824 11825 11826 11827 11828 11829 11830 11831 11832 11833 11834 11835 11836 11837 11838 11839 11840 11841 11842 11843 11844 11845 11846 11847 11848 11849 11850 11851 11852 11853 11854 11855 11856 11857 11858 11859 11860 11861 11862 11863 11864 11865 11866 11867 11868 11869 11870 11871 11872 11873 11874 11875 11876 11877 11878 11879 11880 11881 11882 11883 11884 11885 11886 11887 11888 11889 11890 11891 11892 11893 11894 11895 11896 11897 11898 11899 11900 11901 11902 11903 11904 11905 11906 11907 11908 11909 11910 11911 11912 11913 11914 11915 11916 11917 11918 11919 11920 11921 11922 11923 11924 11925 11926 11927 11928 11929 11930 11931 11932 11933 11934 11935 11936 11937 11938 11939 11940 11941 11942 11943 11944 11945 11946 11947 11948 11949 11950 11951 11952 11953 11954 11955 11956 11957 11958 11959 11960 11961 11962 11963 11964 11965 11966 11967 11968 11969 11970 11971 11972 11973 11974 11975 11976 11977 11978 11979 11980 11981 11982 11983 11984 11985 11986 11987 11988 11989 11990 11991 11992 11993 11994 11995 11996 11997 11998 11999 12000 12001 12002 12003 12004 12005 12006 12007 12008 12009 12010 12011 12012 12013 12014 12015 12016 12017 12018 12019 12020 12021 12022 12023 12024 12025 12026 12027 12028 12029 12030 12031 12032 12033 12034 12035 12036 12037 12038 12039 12040 12041 12042 12043 12044 12045 12046 12047 12048 12049 12050 12051 12052 12053 12054 12055 12056 12057 12058 12059 12060 12061 12062 12063 12064 12065 12066 12067 12068 12069 12070 12071 12072 12073 12074 12075 12076 12077 12078 12079 12080 12081 12082 12083 12084 12085 12086 12087 12088 12089 12090 12091 12092 12093 12094 12095 12096 12097 12098 12099 12100 12101 12102 12103 12104 12105 12106 12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185 12186 12187 12188 12189 12190 12191 12192 12193 12194 12195 12196 12197 12198 12199 12200
 	if cc.has_argument('-ffat-lto-objects')
 		add_project_arguments('-ffat-lto-objects', language: 'c')
@@ -243,3 +280,12 @@ if get_option('b_lto')
 		add_project_link_arguments('-Wno-lto-type-mismatch', language: 'c')
 	endif
 endif
+
+if get_option('default_library') == 'both'
+	error( '''
+    Unsupported value "both" for "default_library" option.
+
+    NOTE: DPDK always builds both shared and static libraries.  Please set
+    "default_library" to either "static" or "shared" to select default linkage
+    for apps and any examples.''')
+endif
diff --git a/dpdk/config/rte_config.h b/dpdk/config/rte_config.h
index d30786bc08..8ec0a58f19 100644
--- a/dpdk/config/rte_config.h
+++ b/dpdk/config/rte_config.h
@@ -38,7 +38,6 @@
 #define RTE_MAX_MEM_MB_PER_LIST 32768
 #define RTE_MAX_MEMSEG_PER_TYPE 32768
 #define RTE_MAX_MEM_MB_PER_TYPE 65536
-#define RTE_MAX_MEM_MB 524288
 #define RTE_MAX_MEMZONE 2560
 #define RTE_MAX_TAILQ 32
 #define RTE_LOG_DP_LEVEL RTE_LOG_INFO
@@ -95,11 +94,18 @@
 #define RTE_SCHED_PORT_N_GRINDERS 8
 #undef RTE_SCHED_VECTOR
 
+#ifdef RTE_LIBRTE_CRYPTO_SCHEDULER_PMD
+#define RTE_LIBRTE_PMD_CRYPTO_SCHEDULER 1
+#endif
+
 /* KNI defines */
 #define RTE_KNI_PREEMPT_DEFAULT 1
 
 /****** driver defines ********/
 
+/* Packet prefetching in PMDs */
+#define RTE_PMD_PACKET_PREFETCH 1
+
 /* QuickAssist device */
 /* Max. number of QuickAssist devices which can be attached */
 #define RTE_PMD_QAT_MAX_PCI_DEVICES 48
diff --git a/dpdk/config/x86/meson.build b/dpdk/config/x86/meson.build
index 8b0fa3e6f1..adc857ba28 100644
--- a/dpdk/config/x86/meson.build
+++ b/dpdk/config/x86/meson.build
@@ -15,11 +15,9 @@ if not is_windows
 endif
 
 # we require SSE4.2 for DPDK
-sse_errormsg = '''SSE4.2 instruction set is required for DPDK.
-Please set the machine type to "nehalem" or "corei7" or higher value'''
-
 if cc.get_define('__SSE4_2__', args: machine_args) == ''
-	error(sse_errormsg)
+	message('SSE 4.2 not enabled by default, explicitly enabling')
+	machine_args += '-msse4'
 endif
 
 base_flags = ['SSE', 'SSE2', 'SSE3','SSSE3', 'SSE4_1', 'SSE4_2']
diff --git a/dpdk/devtools/check-forbidden-tokens.awk b/dpdk/devtools/check-forbidden-tokens.awk
index 8c89de3d4e..61ba707c9b 100755
--- a/dpdk/devtools/check-forbidden-tokens.awk
+++ b/dpdk/devtools/check-forbidden-tokens.awk
@@ -54,7 +54,7 @@ BEGIN {
 	}
 	for (i in deny_folders) {
 		re = "^\\+\\+\\+ b/" deny_folders[i];
-		if ($0 ~ deny_folders[i]) {
+		if ($0 ~ re) {
 			in_file = 1
 			last_file = $0
 		}
@@ -62,7 +62,7 @@ BEGIN {
 }
 END {
 	if (count > 0) {
-		print "Warning in " substr(last_file,6) ":"
+		print "Warning in " substr(last_file,7) ":"
 		print MESSAGE
 		exit RET_ON_FAIL
 	}
diff --git a/dpdk/devtools/check-symbol-change.sh b/dpdk/devtools/check-symbol-change.sh
index c5434f3bb0..ed2178e36e 100755
--- a/dpdk/devtools/check-symbol-change.sh
+++ b/dpdk/devtools/check-symbol-change.sh
@@ -17,13 +17,11 @@ build_map_changes()
 		# map files are altered, and all section/symbol names
 		# appearing between a triggering of this rule and the
 		# next trigger of this rule are associated with this file
-		/[-+] a\/.*\.map/ {map=$2; in_map=1}
+		/[-+] [ab]\/.*\.map/ {map=$2; in_map=1; next}
 
-		# Same pattern as above, only it matches on anything that
-		# does not end in 'map', indicating we have left the map chunk.
-		# When we hit this, turn off the in_map variable, which
-		# supresses the subordonate rules below
-		/[-+] a\/.*\.[^map]/ {in_map=0}
+		# The previous rule catches all .map files, anything else
+		# indicates we left the map chunk.
+		/[-+] [ab]\// {in_map=0}
 
 		# Triggering this rule, which starts a line and ends it
 		# with a { identifies a versioned section.  The section name is
diff --git a/dpdk/devtools/checkpatches.sh b/dpdk/devtools/checkpatches.sh
index b16bace927..9902e2a9bc 100755
--- a/dpdk/devtools/checkpatches.sh
+++ b/dpdk/devtools/checkpatches.sh
@@ -70,6 +70,14 @@ check_forbidden_additions() { # <patch>
 		-f $(dirname $(readlink -f $0))/check-forbidden-tokens.awk \
 		"$1" || res=1
 
+	# links must prefer https over http
+	awk -v FOLDERS='doc' \
+		-v EXPRESSIONS='http://.*dpdk.org' \
+		-v RET_ON_FAIL=1 \
+		-v MESSAGE='Using non https link to dpdk.org' \
+		-f $(dirname $(readlink -f $0))/check-forbidden-tokens.awk \
+		"$1" || res=1
+
 	return $res
 }
 
diff --git a/dpdk/devtools/cocci.sh b/dpdk/devtools/cocci.sh
index 8b17a8ceba..ab9a6efe9a 100755
--- a/dpdk/devtools/cocci.sh
+++ b/dpdk/devtools/cocci.sh
@@ -1,34 +1,6 @@
 #! /bin/sh
-
-# BSD LICENSE
-#
-# Copyright 2015 EZchip Semiconductor Ltd.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-#
-#   * Redistributions of source code must retain the above copyright
-#     notice, this list of conditions and the following disclaimer.
-#   * Redistributions in binary form must reproduce the above copyright
-#     notice, this list of conditions and the following disclaimer in
-#     the documentation and/or other materials provided with the
-#     distribution.
-#   * Neither the name of EZchip Semiconductor nor the names of its
-#     contributors may be used to endorse or promote products derived
-#     from this software without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2015-2020 Mellanox Technologies, Ltd
 
 # Apply coccinelle transforms.
 
diff --git a/dpdk/devtools/git-log-fixes.sh b/dpdk/devtools/git-log-fixes.sh
index e37ee22600..6d468d6731 100755
--- a/dpdk/devtools/git-log-fixes.sh
+++ b/dpdk/devtools/git-log-fixes.sh
@@ -94,11 +94,23 @@ stable_tag () # <hash>
 	fi
 }
 
+# print a marker for fixes tag presence
+fixes_tag () # <hash>
+{
+        if git log --format='%b' -1 $1 | grep -qi '^Fixes: *' ; then
+                echo 'F'
+        else
+                echo '-'
+        fi
+}
+
 git log --oneline --reverse $range |
 while read id headline ; do
 	origins=$(origin_filter $id)
 	stable=$(stable_tag $id)
-	[ "$stable" = "S" ] || [ -n "$origins" ] || echo "$headline" | grep -q fix || continue
+	fixes=$(fixes_tag $id)
+	[ "$stable" = "S" ] || [ "$fixes" = "F" ] || [ -n "$origins" ] || \
+		echo "$headline" | grep -q fix || continue
 	version=$(commit_version $id)
 	if [ -n "$origins" ] ; then
 		origver="$(origin_version $origins)"
@@ -108,5 +120,5 @@ while read id headline ; do
 	else
 		origver='N/A'
 	fi
-	printf '%s %7s %s %s (%s)\n' $version $id $stable "$headline" "$origver"
+	printf '%s %7s %s %s %s (%s)\n' $version $id $stable $fixes "$headline" "$origver"
 done
diff --git a/dpdk/devtools/test-build.sh b/dpdk/devtools/test-build.sh
index be565a1bea..52305fbb8c 100755
--- a/dpdk/devtools/test-build.sh
+++ b/dpdk/devtools/test-build.sh
@@ -149,7 +149,7 @@ config () # <directory> <target> <options>
 		! echo $3 | grep -q '+debug' || ( \
 		sed -ri=""  's,(RTE_LOG_DP_LEVEL=).*,\1RTE_LOG_DEBUG,' $1/.config
 		sed -ri=""           's,(_DEBUG.*=)n,\1y,' $1/.config
-		sed -ri=""            's,(_STAT.*=)n,\1y,' $1/.config
+		sed -ri=""  's,(_STAT)([S_].*=|=)n,\1\2y,' $1/.config
 		sed -ri="" 's,(TEST_PMD_RECORD_.*=)n,\1y,' $1/.config )
 
 		# Automatic configuration
diff --git a/dpdk/devtools/test-meson-builds.sh b/dpdk/devtools/test-meson-builds.sh
index 688567714b..8678a3d824 100755
--- a/dpdk/devtools/test-meson-builds.sh
+++ b/dpdk/devtools/test-meson-builds.sh
@@ -38,20 +38,21 @@ else
 fi
 
 default_path=$PATH
-default_pkgpath=$PKG_CONFIG_PATH
 default_cppflags=$CPPFLAGS
 default_cflags=$CFLAGS
 default_ldflags=$LDFLAGS
+default_meson_options=$DPDK_MESON_OPTIONS
 
 load_env () # <target compiler>
 {
 	targetcc=$1
+	# reset variables before target-specific config
 	export PATH=$default_path
-	export PKG_CONFIG_PATH=$default_pkgpath
+	unset PKG_CONFIG_PATH # global default makes no sense
 	export CPPFLAGS=$default_cppflags
 	export CFLAGS=$default_cflags
 	export LDFLAGS=$default_ldflags
-	unset DPDK_MESON_OPTIONS
+	export DPDK_MESON_OPTIONS=$default_meson_options
 	command -v $targetcc >/dev/null 2>&1 || return 1
 	DPDK_TARGET=$($targetcc -v 2>&1 | sed -n 's,^Target: ,,p')
 	. $srcdir/devtools/load-devel-config
@@ -134,19 +135,17 @@ done
 
 # Test installation of the x86-default target, to be used for checking
 # the sample apps build using the pkg-config file for cflags and libs
+load_env cc
 build_path=$(readlink -f $builds_dir/build-x86-default)
 export DESTDIR=$build_path/install-root
 $ninja_cmd -C $build_path install
-
-load_env cc
 pc_file=$(find $DESTDIR -name libdpdk.pc)
 export PKG_CONFIG_PATH=$(dirname $pc_file):$PKG_CONFIG_PATH
-
 # if pkg-config defines the necessary flags, test building some examples
 if pkg-config --define-prefix libdpdk >/dev/null 2>&1; then
 	export PKGCONF="pkg-config --define-prefix"
 	for example in cmdline helloworld l2fwd l3fwd skeleton timer; do
 		echo "## Building $example"
-		$MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean all
+		$MAKE -C $DESTDIR/usr/local/share/dpdk/examples/$example clean shared static
 	done
 fi
diff --git a/dpdk/doc/api/doxy-api-index.md b/dpdk/doc/api/doxy-api-index.md
index dff496be09..5568dbc616 100644
--- a/dpdk/doc/api/doxy-api-index.md
+++ b/dpdk/doc/api/doxy-api-index.md
@@ -1,4 +1,4 @@
-API {#index}
+API
 ===
 
 <!--
@@ -107,8 +107,6 @@ The public API headers are grouped by topics:
   [GRO]                (@ref rte_gro.h),
   [GSO]                (@ref rte_gso.h),
   [frag/reass]         (@ref rte_ip_frag.h),
-  [LPM IPv4 route]     (@ref rte_lpm.h),
-  [LPM IPv6 route]     (@ref rte_lpm6.h),
   [VXLAN]              (@ref rte_vxlan.h)
 
 - **QoS**:
@@ -116,6 +114,14 @@ The public API headers are grouped by topics:
   [scheduler]          (@ref rte_sched.h),
   [RED congestion]     (@ref rte_red.h)
 
+- **routing**:
+  [LPM IPv4 route]     (@ref rte_lpm.h),
+  [LPM IPv6 route]     (@ref rte_lpm6.h),
+  [RIB IPv4]           (@ref rte_rib.h),
+  [RIB IPv6]           (@ref rte_rib6.h),
+  [FIB IPv4]           (@ref rte_fib.h),
+  [FIB IPv6]           (@ref rte_fib6.h)
+
 - **hashes**:
   [hash]               (@ref rte_hash.h),
   [jhash]              (@ref rte_jhash.h),
diff --git a/dpdk/doc/api/doxy-api.conf.in b/dpdk/doc/api/doxy-api.conf.in
index 1c4392eecc..12f0a26a90 100644
--- a/dpdk/doc/api/doxy-api.conf.in
+++ b/dpdk/doc/api/doxy-api.conf.in
@@ -3,6 +3,7 @@
 
 PROJECT_NAME            = DPDK
 PROJECT_NUMBER          = @VERSION@
+USE_MDFILE_AS_MAINPAGE  = @TOPDIR@/doc/api/doxy-api-index.md
 INPUT                   = @TOPDIR@/doc/api/doxy-api-index.md \
                           @TOPDIR@/drivers/bus/vdev \
                           @TOPDIR@/drivers/crypto/scheduler \
diff --git a/dpdk/doc/api/meson.build b/dpdk/doc/api/meson.build
index 1c48b7672e..c72b880e10 100644
--- a/dpdk/doc/api/meson.build
+++ b/dpdk/doc/api/meson.build
@@ -3,53 +3,54 @@
 
 doxygen = find_program('doxygen', required: get_option('enable_docs'))
 
-if doxygen.found()
-	# due to the CSS customisation script, which needs to run on a file that
-	# is in a subdirectory that is created at build time and thus it cannot
-	# be an individual custom_target, we need to wrap the doxygen call in a
-	# script to run the CSS modification afterwards
-	generate_doxygen = find_program('generate_doxygen.sh')
-	generate_examples = find_program('generate_examples.sh')
-	generate_css = find_program('doxy-html-custom.sh')
-
-	inputdir = join_paths(meson.source_root(), 'examples')
-	htmldir = join_paths('share', 'doc', 'dpdk')
-
-	# due to the following bug: https://github.com/mesonbuild/meson/issues/4107
-	# if install is set to true it will override build_by_default and it will
-	# cause the target to always be built. If install were to be always set to
-	# false it would be impossible to install the docs.
-	# So use a configure option for now.
-	example = custom_target('examples.dox',
-		input: inputdir,
-		output: 'examples.dox',
-		command: [generate_examples, '@INPUT@', '@OUTPUT@'],
-		install: get_option('enable_docs'),
-		install_dir: htmldir,
-		build_by_default: get_option('enable_docs'))
-
-	cdata = configuration_data()
-	cdata.set('VERSION', meson.project_version())
-	cdata.set('API_EXAMPLES', join_paths(meson.build_root(), 'doc', 'api', 'examples.dox'))
-	cdata.set('OUTPUT', join_paths(meson.build_root(), 'doc', 'api'))
-	cdata.set('HTML_OUTPUT', 'api')
-	cdata.set('TOPDIR', meson.source_root())
-	cdata.set('STRIP_FROM_PATH', meson.source_root())
-
-	doxy_conf = configure_file(input: 'doxy-api.conf.in',
-		output: 'doxy-api.conf',
-		configuration: cdata,
-		install: false)
-
-	doxy_build = custom_target('doxygen',
-		depends: example,
-		input: doxy_conf,
-		output: 'api',
-		command: [generate_doxygen, '@INPUT@', '@OUTPUT@', generate_css],
-		install: get_option('enable_docs'),
-		install_dir: htmldir,
-		build_by_default: get_option('enable_docs'))
-
-	doc_targets += doxy_build
-	doc_target_names += 'Doxygen_API'
+if not doxygen.found()
+  subdir_done()
 endif
+
+# due to the CSS customisation script, which needs to run on a file that
+# is in a subdirectory that is created at build time and thus it cannot
+# be an individual custom_target, we need to wrap the doxygen call in a
+# script to run the CSS modification afterwards
+generate_doxygen = find_program('generate_doxygen.sh')
+generate_examples = find_program('generate_examples.sh')
+generate_css = find_program('doxy-html-custom.sh')
+
+inputdir = join_paths(meson.source_root(), 'examples')
+htmldir = join_paths('share', 'doc', 'dpdk')
+
+# due to the following bug: https://github.com/mesonbuild/meson/issues/4107
+# if install is set to true it will override build_by_default and it will
+# cause the target to always be built. If install were to be always set to
+# false it would be impossible to install the docs.
+# So use a configure option for now.
+example = custom_target('examples.dox',
+	input: inputdir,
+	output: 'examples.dox',
+	command: [generate_examples, '@INPUT@', '@OUTPUT@'],
+	install: get_option('enable_docs'),
+	install_dir: htmldir,
+	build_by_default: get_option('enable_docs'))
+
+cdata = configuration_data()
+cdata.set('VERSION', meson.project_version())
+cdata.set('API_EXAMPLES', join_paths(meson.build_root(), 'doc', 'api', 'examples.dox'))
+cdata.set('OUTPUT', join_paths(meson.build_root(), 'doc', 'api'))
+cdata.set('HTML_OUTPUT', 'api')
+cdata.set('TOPDIR', meson.source_root())
+cdata.set('STRIP_FROM_PATH', meson.source_root())
+
+doxy_conf = configure_file(input: 'doxy-api.conf.in',
+	output: 'doxy-api.conf',
+	configuration: cdata)
+
+doxy_build = custom_target('doxygen',
+	depends: example,
+	input: doxy_conf,
+	output: 'api',
+	command: [generate_doxygen, '@INPUT@', '@OUTPUT@', generate_css],
+	install: get_option('enable_docs'),
+	install_dir: htmldir,
+	build_by_default: get_option('enable_docs'))
+
+doc_targets += doxy_build
+doc_target_names += 'Doxygen_API'
diff --git a/dpdk/doc/build-sdk-meson.txt b/dpdk/doc/build-sdk-meson.txt
index fc7fe37b54..8fb60a7c11 100644
--- a/dpdk/doc/build-sdk-meson.txt
+++ b/dpdk/doc/build-sdk-meson.txt
@@ -1,3 +1,6 @@
+..  SPDX-License-Identifier: BSD-3-Clause
+    Copyright(c) 2018 Intel Corporation.
+
 INSTALLING DPDK USING THE MESON BUILD SYSTEM
 ---------------------------------------------
 
@@ -94,14 +97,17 @@ Examples of setting the same options using meson configure::
 
 	meson configure -Dmax_lcores=8
 
-NOTE: once meson has been run to configure a build in a directory, it
-cannot be run again on the same directory. Instead ``meson configure``
-should be used to change the build settings within the directory, and when
-``ninja`` is called to do the build itself, it will trigger the necessary
-re-scan from meson.
+.. note::
+
+        once meson has been run to configure a build in a directory, it
+        cannot be run again on the same directory. Instead ``meson configure``
+        should be used to change the build settings within the directory, and when
+        ``ninja`` is called to do the build itself, it will trigger the necessary
+        re-scan from meson.
 
-NOTE: machine=default uses a config that works on all supported architectures
-regardless of the capabilities of the machine where the build is happening.
+.. note::
+        machine=default uses a config that works on all supported architectures
+        regardless of the capabilities of the machine where the build is happening.
 
 As well as those settings taken from ``meson configure``, other options
 such as the compiler to use can be passed via environment variables. For
@@ -109,9 +115,11 @@ example::
 
 	CC=clang meson clang-build
 
-NOTE: for more comprehensive overriding of compilers or other environment
-settings, the tools for cross-compilation may be considered. However, for
-basic overriding of the compiler etc., the above form works as expected.
+.. note::
+
+        for more comprehensive overriding of compilers or other environment
+        settings, the tools for cross-compilation may be considered. However, for
+        basic overriding of the compiler etc., the above form works as expected.
 
 
 Performing the Build
@@ -182,7 +190,7 @@ From examples/helloworld/Makefile::
 	PC_FILE := $(shell pkg-config --path libdpdk)
 	CFLAGS += -O3 $(shell pkg-config --cflags libdpdk)
 	LDFLAGS_SHARED = $(shell pkg-config --libs libdpdk)
-	LDFLAGS_STATIC = -Wl,-Bstatic $(shell pkg-config --static --libs libdpdk)
+	LDFLAGS_STATIC = $(shell pkg-config --static --libs libdpdk)
 
 	build/$(APP)-shared: $(SRCS-y) Makefile $(PC_FILE) | build
 		$(CC) $(CFLAGS) $(SRCS-y) -o $@ $(LDFLAGS) $(LDFLAGS_SHARED)
diff --git a/dpdk/doc/guides/compressdevs/qat_comp.rst b/dpdk/doc/guides/compressdevs/qat_comp.rst
index 6421f767c4..757611a30c 100644
--- a/dpdk/doc/guides/compressdevs/qat_comp.rst
+++ b/dpdk/doc/guides/compressdevs/qat_comp.rst
@@ -37,7 +37,10 @@ Limitations
 -----------
 
 * Compressdev level 0, no compression, is not supported.
-* Queue pairs are not thread-safe (that is, within a single queue pair, RX and TX from different lcores is not supported).
+* Queue-pairs are thread-safe on Intel CPUs but Queues are not (that is, within a single
+  queue-pair all enqueues to the TX queue must be done from one thread and all dequeues
+  from the RX queue must be done from one thread, but enqueues and dequeues may be done
+  in different threads.)
 * No BSD support as BSD QAT kernel driver not available.
 * When using Deflate dynamic huffman encoding for compression, the input size (op.src.length)
   must be < CONFIG_RTE_PMD_QAT_COMP_IM_BUFFER_SIZE from the config file,
diff --git a/dpdk/doc/guides/conf.py b/dpdk/doc/guides/conf.py
index e2b52e2df9..c1a82be95b 100644
--- a/dpdk/doc/guides/conf.py
+++ b/dpdk/doc/guides/conf.py
@@ -237,7 +237,7 @@ def generate_overview_table(output_filename, table_id, section, table_name, titl
                                                                 ini_filename))
                 continue
 
-            if value is not '':
+            if value:
                 # Get the first letter only.
                 ini_data[ini_filename][name] = value[0]
 
@@ -314,16 +314,22 @@ def print_table_css(outfile, table_id):
          cursor: default;
          overflow: hidden;
       }
+      table#idx p {
+         margin: 0;
+         line-height: inherit;
+      }
       table#idx th, table#idx td {
          text-align: center;
+         border: solid 1px #ddd;
       }
       table#idx th {
-         font-size: 72%;
+         padding: 0.5em 0;
+      }
+      table#idx th, table#idx th p {
+         font-size: 11px;
          white-space: pre-wrap;
          vertical-align: top;
-         padding: 0.5em 0;
          min-width: 0.9em;
-         width: 2em;
       }
       table#idx col:first-child {
          width: 0;
@@ -332,9 +338,11 @@ def print_table_css(outfile, table_id):
          vertical-align: bottom;
       }
       table#idx td {
-         font-size: 70%;
          padding: 1px;
       }
+      table#idx td, table#idx td p {
+         font-size: 11px;
+      }
       table#idx td:first-child {
          padding-left: 1em;
          text-align: left;
@@ -410,4 +418,8 @@ def setup(app):
         # Process the numref references once the doctree has been created.
         app.connect('doctree-resolved', process_numref)
 
-    app.add_stylesheet('css/custom.css')
+    try:
+        # New function in sphinx 1.8
+        app.add_css_file('css/custom.css')
+    except:
+        app.add_stylesheet('css/custom.css')
diff --git a/dpdk/doc/guides/contributing/abi_policy.rst b/dpdk/doc/guides/contributing/abi_policy.rst
index 05ca95980b..87942c8ac3 100644
--- a/dpdk/doc/guides/contributing/abi_policy.rst
+++ b/dpdk/doc/guides/contributing/abi_policy.rst
@@ -27,8 +27,8 @@ General Guidelines
 #. The removal of symbols is considered an :ref:`ABI breakage <abi_breakages>`,
    once approved these will form part of the next ABI version.
 #. Libraries or APIs marked as :ref:`experimental <experimental_apis>` may
-   change without constraint, as they are not considered part of an ABI version.
-   Experimental libraries have the major ABI version ``0``.
+   be changed or removed without prior notice, as they are not considered part
+   of an ABI version.
 #. Updates to the :ref:`minimum hardware requirements <hw_rqmts>`, which drop
    support for hardware which was previously supported, should be treated as an
    ABI change.
@@ -220,19 +220,18 @@ Examples of ABI Changes
 The following are examples of allowable ABI changes occurring between
 declarations of major ABI versions.
 
-* DPDK 19.11 release, defines the function ``rte_foo()``, and ``rte_foo()``
-  as part of the major ABI version ``20``.
+* DPDK 19.11 release defines the function ``rte_foo()`` ; ``rte_foo()``
+  is part of the major ABI version ``20``.
 
-* DPDK 20.02 release defines a new function ``rte_foo(uint8_t bar)``, and
-  this is not a problem as long as the symbol ``rte_foo@DPDK20`` is
+* DPDK 20.02 release defines a new function ``rte_foo(uint8_t bar)``.
+  This is not a problem as long as the symbol ``rte_foo@DPDK20`` is
   preserved through :ref:`abi_versioning`.
 
   - The new function may be marked with the ``__rte_experimental`` tag for a
     number of releases, as described in the section :ref:`experimental_apis`.
 
-  - Once ``rte_foo(uint8_t bar)`` becomes non-experimental ``rte_foo()`` is then
-    declared as ``__rte_depreciated``, with an associated deprecation notice
-    provided.
+  - Once ``rte_foo(uint8_t bar)`` becomes non-experimental, ``rte_foo()`` is
+    declared as ``__rte_deprecated`` and an deprecation notice is provided.
 
 * DPDK 19.11 is not re-released to include ``rte_foo(uint8_t bar)``, the new
   version of ``rte_foo`` only exists from DPDK 20.02 onwards as described in the
@@ -242,13 +241,13 @@ declarations of major ABI versions.
   rte_baz()``. This function may or may not exist in the DPDK 20.05 release.
 
 * An application ``dPacket`` wishes to use ``rte_foo(uint8_t bar)``, before the
-  declaration of the DPDK ``21`` major API version. The application can only
+  declaration of the DPDK ``21`` major ABI version. The application can only
   ensure its runtime dependencies are met by specifying ``DPDK (>= 20.2)`` as
-  an explicit package dependency, as the soname only may only indicate the
+  an explicit package dependency, as the soname can only indicate the
   supported major ABI version.
 
 * At the release of DPDK 20.11, the function ``rte_foo(uint8_t bar)`` becomes
-  formally part of then new major ABI version DPDK 21.0 and ``rte_foo()`` may be
+  formally part of then new major ABI version DPDK ``21`` and ``rte_foo()`` may be
   removed.
 
 .. _deprecation_notices:
@@ -290,7 +289,7 @@ APIs
 ~~~~
 
 APIs marked as ``experimental`` are not considered part of an ABI version and
-may change without warning at any time. Since changes to APIs are most likely
+may be changed or removed without prior notice. Since changes to APIs are most likely
 immediately after their introduction, as users begin to take advantage of those
 new APIs and start finding issues with them, new DPDK APIs will be automatically
 marked as ``experimental`` to allow for a period of stabilization before they
@@ -321,7 +320,5 @@ Libraries
 ~~~~~~~~~
 
 Libraries marked as ``experimental`` are entirely not considered part of an ABI
-version, and may change without warning at any time. Experimental libraries
-always have a major version of ``0`` to indicate they exist outside of
-:ref:`abi_versioning` , with the minor version incremented with each ABI change
-to library.
+version.
+All functions in such libraries may be changed or removed without prior notice.
diff --git a/dpdk/doc/guides/contributing/abi_versioning.rst b/dpdk/doc/guides/contributing/abi_versioning.rst
index a21f4e7a41..ea9d99606b 100644
--- a/dpdk/doc/guides/contributing/abi_versioning.rst
+++ b/dpdk/doc/guides/contributing/abi_versioning.rst
@@ -200,7 +200,7 @@ private, is safe), but it also requires modifying the code as follows
 Note also that, being a public function, the header file prototype must also be
 changed, as must all the call sites, to reflect the new ABI footprint.  We will
 maintain previous ABI versions that are accessible only to previously compiled
-binaries
+binaries.
 
 The addition of a parameter to the function is ABI breaking as the function is
 public, and existing application may use it in its current form. However, the
@@ -266,12 +266,12 @@ This file needs to be modified as follows
 
    } DPDK_20;
 
-The addition of the new block tells the linker that a new version node is
-available (DPDK_21), which contains the symbol rte_acl_create, and inherits
+The addition of the new block tells the linker that a new version node
+``DPDK_21`` is available, which contains the symbol rte_acl_create, and inherits
 the symbols from the DPDK_20 node. This list is directly translated into a
-list of exported symbols when DPDK is compiled as a shared library
+list of exported symbols when DPDK is compiled as a shared library.
 
-Next, we need to specify in the code which function map to the rte_acl_create
+Next, we need to specify in the code which function maps to the rte_acl_create
 symbol at which versions.  First, at the site of the initial symbol definition,
 we need to update the function so that it is uniquely named, and not in conflict
 with the public symbol name
@@ -288,24 +288,29 @@ with the public symbol name
         ...
 
 Note that the base name of the symbol was kept intact, as this is conducive to
-the macros used for versioning symbols and we have annotated the function as an
-implementation of versioned symbol.  That is our next step, mapping this new
-symbol name to the initial symbol name at version node 20.  Immediately after
-the function, we add this line of code
+the macros used for versioning symbols and we have annotated the function as
+``__vsym``, an implementation of a versioned symbol . That is our next step,
+mapping this new symbol name to the initial symbol name at version node 20.
+Immediately after the function, we add the VERSION_SYMBOL macro.
 
 .. code-block:: c
 
+   #include <rte_function_versioning.h>
+
+   ...
    VERSION_SYMBOL(rte_acl_create, _v20, 20);
 
 Remembering to also add the rte_function_versioning.h header to the requisite c
-file where these changes are being made. The above macro instructs the linker to
+file where these changes are being made. The macro instructs the linker to
 create a new symbol ``rte_acl_create@DPDK_20``, which matches the symbol created
 in older builds, but now points to the above newly named function. We have now
 mapped the original rte_acl_create symbol to the original function (but with a
 new name).
 
-Next, we need to create the 21 version of the symbol. We create a new function
-name, with a different suffix, and implement it appropriately
+Please see the section :ref:`Enabling versioning macros
+<enabling_versioning_macros>` to enable this macro in the meson/ninja build.
+Next, we need to create the new ``v21`` version of the symbol. We create a new
+function name, with the ``v21`` suffix, and implement it appropriately.
 
 .. code-block:: c
 
@@ -320,35 +325,58 @@ name, with a different suffix, and implement it appropriately
    }
 
 This code serves as our new API call. Its the same as our old call, but adds the
-new parameter in place. Next we need to map this function to the symbol
-``rte_acl_create@DPDK_21``. To do this, we modify the public prototype of the
-call in the header file, adding the macro there to inform all including
-applications, that on re-link, the default rte_acl_create symbol should point to
-this function. Note that we could do this by simply naming the function above
-rte_acl_create, and the linker would chose the most recent version tag to apply
-in the version script, but we can also do this in the header file
+new parameter in place. Next we need to map this function to the new default
+symbol ``rte_acl_create@DPDK_21``. To do this, immediately after the function,
+we add the BIND_DEFAULT_SYMBOL macro.
+
+.. code-block:: c
+
+   #include <rte_function_versioning.h>
+
+   ...
+   BIND_DEFAULT_SYMBOL(rte_acl_create, _v21, 21);
+
+The macro instructs the linker to create the new default symbol
+``rte_acl_create@DPDK_21``, which points to the above newly named function.
+
+We finally modify the prototype of the call in the public header file,
+such that it contains both versions of the symbol and the public API.
 
 .. code-block:: c
 
    struct rte_acl_ctx *
-   -rte_acl_create(const struct rte_acl_param *param);
-   +rte_acl_create_v21(const struct rte_acl_param *param, int debug);
-   +BIND_DEFAULT_SYMBOL(rte_acl_create, _v21, 21);
-
-The BIND_DEFAULT_SYMBOL macro explicitly tells applications that include this
-header, to link to the rte_acl_create_v21 function and apply the DPDK_21
-version node to it.  This method is more explicit and flexible than just
-re-implementing the exact symbol name, and allows for other features (such as
-linking to the old symbol version by default, when the new ABI is to be opt-in
-for a period.
-
-One last thing we need to do.  Note that we've taken what was a public symbol,
-and duplicated it into two uniquely and differently named symbols.  We've then
-mapped each of those back to the public symbol ``rte_acl_create`` with different
-version tags.  This only applies to dynamic linking, as static linking has no
-notion of versioning.  That leaves this code in a position of no longer having a
-symbol simply named ``rte_acl_create`` and a static build will fail on that
-missing symbol.
+   rte_acl_create(const struct rte_acl_param *param);
+
+   struct rte_acl_ctx * __vsym
+   rte_acl_create_v20(const struct rte_acl_param *param);
+
+   struct rte_acl_ctx * __vsym
+   rte_acl_create_v21(const struct rte_acl_param *param, int debug);
+
+
+And that's it, on the next shared library rebuild, there will be two versions of
+rte_acl_create, an old DPDK_20 version, used by previously built applications,
+and a new DPDK_21 version, used by future built applications.
+
+.. note::
+
+   **Before you leave**, please take care reviewing the sections on
+   :ref:`mapping static symbols <mapping_static_symbols>`,
+   :ref:`enabling versioning macros <enabling_versioning_macros>`,
+   and :ref:`ABI deprecation <abi_deprecation>`.
+
+
+.. _mapping_static_symbols:
+
+Mapping static symbols
+______________________
+
+Now we've taken what was a public symbol, and duplicated it into two uniquely
+and differently named symbols. We've then mapped each of those back to the
+public symbol ``rte_acl_create`` with different version tags. This only applies
+to dynamic linking, as static linking has no notion of versioning. That leaves
+this code in a position of no longer having a symbol simply named
+``rte_acl_create`` and a static build will fail on that missing symbol.
 
 To correct this, we can simply map a function of our choosing back to the public
 symbol in the static build with the ``MAP_STATIC_SYMBOL`` macro.  Generally the
@@ -369,15 +397,31 @@ defined, we add this
 That tells the compiler that, when building a static library, any calls to the
 symbol ``rte_acl_create`` should be linked to ``rte_acl_create_v21``
 
-That's it, on the next shared library rebuild, there will be two versions of
-rte_acl_create, an old DPDK_20 version, used by previously built applications,
-and a new DPDK_21 version, used by future built applications.
 
+.. _enabling_versioning_macros:
+
+Enabling versioning macros
+__________________________
+
+Finally, we need to indicate to the meson/ninja build system
+to enable versioning macros when building the
+library or driver. In the libraries or driver where we have added symbol
+versioning, in the ``meson.build`` file we add the following
+
+.. code-block:: none
+
+   use_function_versioning = true
+
+at the start of the head of the file. This will indicate to the tool-chain to
+enable the function version macros when building. There is no corresponding
+directive required for the ``make`` build system.
+
+.. _abi_deprecation:
 
 Deprecating part of a public API
 ________________________________
 
-Lets assume that you've done the above update, and in preparation for the next
+Lets assume that you've done the above updates, and in preparation for the next
 major ABI version you decide you would like to retire the old version of the
 function. After having gone through the ABI deprecation announcement process,
 removal is easy. Start by removing the symbol from the requisite version map
@@ -421,8 +465,8 @@ Next remove the corresponding versioned export.
 
 
 Note that the internal function definition could also be removed, but its used
-in our example by the newer version v21, so we leave it in place and declare it
-as static. This is a coding style choice.
+in our example by the newer version ``v21``, so we leave it in place and declare
+it as static. This is a coding style choice.
 
 .. _deprecating_entire_abi:
 
diff --git a/dpdk/doc/guides/contributing/documentation.rst b/dpdk/doc/guides/contributing/documentation.rst
index 27e4b13be1..3924771cf0 100644
--- a/dpdk/doc/guides/contributing/documentation.rst
+++ b/dpdk/doc/guides/contributing/documentation.rst
@@ -82,7 +82,7 @@ added to by the developer.
 * **API documentation**
 
   The API documentation explains how to use the public DPDK functions.
-  The `API index page <http://doc.dpdk.org/api/>`_ shows the generated API documentation with related groups of functions.
+  The `API index page <https://doc.dpdk.org/api/>`_ shows the generated API documentation with related groups of functions.
 
   The API documentation should be updated via Doxygen comments when new functions are added.
 
@@ -561,14 +561,14 @@ Hyperlinks
 ~~~~~~~~~~
 
 * Links to external websites can be plain URLs.
-  The following is rendered as http://dpdk.org::
+  The following is rendered as https://dpdk.org::
 
-     http://dpdk.org
+     https://dpdk.org
 
 * They can contain alternative text.
-  The following is rendered as `Check out DPDK <http://dpdk.org>`_::
+  The following is rendered as `Check out DPDK <https://dpdk.org>`_::
 
-     `Check out DPDK <http://dpdk.org>`_
+     `Check out DPDK <https://dpdk.org>`_
 
 * An internal link can be generated by placing labels in the document with the format ``.. _label_name``.
 
@@ -666,7 +666,7 @@ The following are some guidelines for use of Doxygen in the DPDK API documentati
        */
 
   In the API documentation the functions will be rendered as links, see the
-  `online section of the rte_ethdev.h docs <http://doc.dpdk.org/api/rte__ethdev_8h.html>`_ that contains the above text.
+  `online section of the rte_ethdev.h docs <https://doc.dpdk.org/api/rte__ethdev_8h.html>`_ that contains the above text.
 
 * The ``@see`` keyword can be used to create a *see also* link to another file or library.
   This directive should be placed on one line at the bottom of the documentation section.
diff --git a/dpdk/doc/guides/contributing/patches.rst b/dpdk/doc/guides/contributing/patches.rst
index 0686450e45..5ca037757e 100644
--- a/dpdk/doc/guides/contributing/patches.rst
+++ b/dpdk/doc/guides/contributing/patches.rst
@@ -28,9 +28,9 @@ The DPDK development process has the following features:
 * All sub-repositories are merged into main repository for ``-rc1`` and ``-rc2`` versions of the release.
 * After the ``-rc2`` release all patches should target the main repository.
 
-The mailing list for DPDK development is `dev@dpdk.org <http://mails.dpdk.org/archives/dev/>`_.
-Contributors will need to `register for the mailing list <http://mails.dpdk.org/listinfo/dev>`_ in order to submit patches.
-It is also worth registering for the DPDK `Patchwork <http://patches.dpdk.org/project/dpdk/list/>`_
+The mailing list for DPDK development is `dev@dpdk.org <https://mails.dpdk.org/archives/dev/>`_.
+Contributors will need to `register for the mailing list <https://mails.dpdk.org/listinfo/dev>`_ in order to submit patches.
+It is also worth registering for the DPDK `Patchwork <https://patches.dpdk.org/project/dpdk/list/>`_
 
 If you are using the GitHub service, you can link your repository to
 the ``travis-ci.org`` build service.  When you push patches to your GitHub
@@ -130,12 +130,12 @@ The source code can be cloned using either of the following:
 main repository::
 
     git clone git://dpdk.org/dpdk
-    git clone http://dpdk.org/git/dpdk
+    git clone https://dpdk.org/git/dpdk
 
-sub-repositories (`list <http://git.dpdk.org/next>`_)::
+sub-repositories (`list <https://git.dpdk.org/next>`_)::
 
     git clone git://dpdk.org/next/dpdk-next-*
-    git clone http://dpdk.org/git/next/dpdk-next-*
+    git clone https://dpdk.org/git/next/dpdk-next-*
 
 Make your Changes
 -----------------
@@ -182,7 +182,7 @@ A good way of thinking about whether a patch should be split is to consider whet
 applied without dependencies as a backport.
 
 It is better to keep the related documentation changes in the same patch
-file as the code, rather than one big documentation patch at then end of a
+file as the code, rather than one big documentation patch at the end of a
 patchset. This makes it easier for future maintenance and development of the
 code.
 
@@ -320,7 +320,7 @@ Patch for Stable Releases
 ~~~~~~~~~~~~~~~~~~~~~~~~~
 
 All fix patches to the master branch that are candidates for backporting
-should also be CCed to the `stable@dpdk.org <http://mails.dpdk.org/listinfo/stable>`_
+should also be CCed to the `stable@dpdk.org <https://mails.dpdk.org/listinfo/stable>`_
 mailing list.
 In the commit message body the Cc: stable@dpdk.org should be inserted as follows::
 
@@ -423,7 +423,7 @@ are loaded from the following files, in order of preference::
    ~/.config/dpdk/devel.config
    /etc/dpdk/devel.config.
 
-Once the environment variable the script can be run as follows::
+Once the environment variable is set, the script can be run as follows::
 
    devtools/checkpatches.sh ~/patch/
 
@@ -548,7 +548,7 @@ If the patch is in relation to a previous email thread you can add it to the sam
    git send-email --to dev@dpdk.org --in-reply-to <1234-foo@bar.com> 000*.patch
 
 The Message ID can be found in the raw text of emails or at the top of each Patchwork patch,
-`for example <http://patches.dpdk.org/patch/7646/>`_.
+`for example <https://patches.dpdk.org/patch/7646/>`_.
 Shallow threading (``--thread --no-chain-reply-to``) is preferred for a patch series.
 
 Once submitted your patches will appear on the mailing list and in Patchwork.
diff --git a/dpdk/doc/guides/contributing/stable.rst b/dpdk/doc/guides/contributing/stable.rst
index 4d38bb8606..021c762fc6 100644
--- a/dpdk/doc/guides/contributing/stable.rst
+++ b/dpdk/doc/guides/contributing/stable.rst
@@ -51,7 +51,7 @@ agreement and a commitment from a maintainer. The current policy is that each
 year's November (X.11) release will be maintained as an LTS for 2 years.
 
 After the X.11 release, an LTS branch will be created for it at
-http://git.dpdk.org/dpdk-stable where bugfixes will be backported to.
+https://git.dpdk.org/dpdk-stable where bugfixes will be backported to.
 
 A LTS release may align with the declaration of a new major ABI version,
 please read the :doc:`abi_policy` for more information.
@@ -107,7 +107,7 @@ The Stable and LTS release are coordinated on the stable@dpdk.org mailing
 list.
 
 All fix patches to the master branch that are candidates for backporting
-should also be CCed to the `stable@dpdk.org <http://mails.dpdk.org/listinfo/stable>`_
+should also be CCed to the `stable@dpdk.org <https://mails.dpdk.org/listinfo/stable>`_
 mailing list.
 
 
@@ -118,7 +118,7 @@ A Stable Release will be released by:
 
 * Tagging the release with YY.MM.n (year, month, number).
 * Uploading a tarball of the release to dpdk.org.
-* Sending an announcement to the `announce@dpdk.org <http://mails.dpdk.org/listinfo/announce>`_
+* Sending an announcement to the `announce@dpdk.org <https://mails.dpdk.org/listinfo/announce>`_
   list.
 
-Stable releases are available on the `dpdk.org download page <http://core.dpdk.org/download/>`_.
+Stable releases are available on the `dpdk.org download page <https://core.dpdk.org/download/>`_.
diff --git a/dpdk/doc/guides/contributing/vulnerability.rst b/dpdk/doc/guides/contributing/vulnerability.rst
index 5484119d19..da00acd4f0 100644
--- a/dpdk/doc/guides/contributing/vulnerability.rst
+++ b/dpdk/doc/guides/contributing/vulnerability.rst
@@ -36,11 +36,11 @@ Report
 
 Do not use Bugzilla (unsecured).
 Instead, send GPG-encrypted emails
-to `security@dpdk.org <http://core.dpdk.org/security#contact>`_.
+to `security@dpdk.org <https://core.dpdk.org/security#contact>`_.
 Anyone can post to this list.
 In order to reduce the disclosure of a vulnerability in the early stages,
 membership of this list is intentionally limited to a `small number of people
-<http://mails.dpdk.org/roster/security>`_.
+<https://mails.dpdk.org/roster/security>`_.
 
 It is additionally encouraged to GPG-sign one-on-one conversations
 as part of the security process.
@@ -188,7 +188,7 @@ Downstream stakeholders are expected not to deploy or disclose patches
 until the embargo is passed, otherwise they will be removed from the list.
 
 Downstream stakeholders (in `security-prerelease list
-<http://mails.dpdk.org/roster/security-prerelease>`_), are:
+<https://mails.dpdk.org/roster/security-prerelease>`_), are:
 
 * Operating system vendors known to package DPDK
 * Major DPDK users, considered trustworthy by the technical board, who
diff --git a/dpdk/doc/guides/cryptodevs/aesni_gcm.rst b/dpdk/doc/guides/cryptodevs/aesni_gcm.rst
index 151aa30606..a8ea3206ba 100644
--- a/dpdk/doc/guides/cryptodevs/aesni_gcm.rst
+++ b/dpdk/doc/guides/cryptodevs/aesni_gcm.rst
@@ -45,6 +45,19 @@ can be downloaded in `<https://github.com/01org/intel-ipsec-mb/archive/v0.53.zip
     make
     make install
 
+The library requires NASM to be built. Depending on the library version, it might require a minimum NASM version (e.g. v0.53 requires at least NASM 2.13.03).
+
+NASM is packaged for different OS. However, on some OS the version is too old, so a manual installation is required.
+In that case, NASM can be downloaded from
+`NASM website <https://www.nasm.us/pub/nasm/releasebuilds/?C=M;O=D>`_.
+Once it is downloaded, extract it and follow these steps:
+
+.. code-block:: console
+
+    ./configure
+    make
+    make install
+
 As a reference, the following table shows a mapping between the past DPDK versions
 and the external crypto libraries supported by them:
 
diff --git a/dpdk/doc/guides/cryptodevs/aesni_mb.rst b/dpdk/doc/guides/cryptodevs/aesni_mb.rst
index 5d8fb46efe..ca6c169858 100644
--- a/dpdk/doc/guides/cryptodevs/aesni_mb.rst
+++ b/dpdk/doc/guides/cryptodevs/aesni_mb.rst
@@ -72,6 +72,19 @@ can be downloaded from `<https://github.com/01org/intel-ipsec-mb/archive/v0.53.z
     make
     make install
 
+The library requires NASM to be built. Depending on the library version, it might require a minimum NASM version (e.g. v0.53 requires at least NASM 2.13.03).
+
+NASM is packaged for different OS. However, on some OS the version is too old, so a manual installation is required.
+In that case, NASM can be downloaded from
+`NASM website <https://www.nasm.us/pub/nasm/releasebuilds/?C=M;O=D>`_.
+Once it is downloaded, extract it and follow these steps:
+
+.. code-block:: console
+
+    ./configure
+    make
+    make install
+
 As a reference, the following table shows a mapping between the past DPDK versions
 and the Multi-Buffer library version supported by them:
 
diff --git a/dpdk/doc/guides/cryptodevs/features/kasumi.ini b/dpdk/doc/guides/cryptodevs/features/kasumi.ini
index f3d061009b..7ee866e8f4 100644
--- a/dpdk/doc/guides/cryptodevs/features/kasumi.ini
+++ b/dpdk/doc/guides/cryptodevs/features/kasumi.ini
@@ -6,6 +6,7 @@
 [Features]
 Symmetric crypto       = Y
 Sym operation chaining = Y
+OOP LB  In LB  Out     = Y
 
 ;
 ; Supported crypto algorithms of the 'kasumi' crypto driver.
diff --git a/dpdk/doc/guides/cryptodevs/features/octeontx.ini b/dpdk/doc/guides/cryptodevs/features/octeontx.ini
index 1c036c5baf..629e6bfc41 100644
--- a/dpdk/doc/guides/cryptodevs/features/octeontx.ini
+++ b/dpdk/doc/guides/cryptodevs/features/octeontx.ini
@@ -11,6 +11,7 @@ HW Accelerated         = Y
 In Place SGL           = Y
 OOP SGL In LB  Out     = Y
 OOP SGL In SGL Out     = Y
+OOP LB  In LB  Out     = Y
 RSA PRIV OP KEY QT     = Y
 
 ;
diff --git a/dpdk/doc/guides/cryptodevs/features/octeontx2.ini b/dpdk/doc/guides/cryptodevs/features/octeontx2.ini
index 7d07053cb1..6a205870af 100644
--- a/dpdk/doc/guides/cryptodevs/features/octeontx2.ini
+++ b/dpdk/doc/guides/cryptodevs/features/octeontx2.ini
@@ -11,6 +11,7 @@ HW Accelerated         = Y
 In Place SGL           = Y
 OOP SGL In LB  Out     = Y
 OOP SGL In SGL Out     = Y
+OOP LB  In LB  Out     = Y
 RSA PRIV OP KEY QT     = Y
 
 ;
diff --git a/dpdk/doc/guides/cryptodevs/features/qat.ini b/dpdk/doc/guides/cryptodevs/features/qat.ini
index 6e350eb81f..a722419979 100644
--- a/dpdk/doc/guides/cryptodevs/features/qat.ini
+++ b/dpdk/doc/guides/cryptodevs/features/qat.ini
@@ -44,10 +44,15 @@ ZUC EEA3       = Y
 [Auth]
 NULL         = Y
 MD5 HMAC     = Y
+SHA1         = Y
 SHA1 HMAC    = Y
+SHA224       = Y
 SHA224 HMAC  = Y
+SHA256       = Y
 SHA256 HMAC  = Y
+SHA384       = Y
 SHA384 HMAC  = Y
+SHA512       = Y
 SHA512 HMAC  = Y
 AES GMAC     = Y
 SNOW3G UIA2  = Y
diff --git a/dpdk/doc/guides/cryptodevs/features/snow3g.ini b/dpdk/doc/guides/cryptodevs/features/snow3g.ini
index ec2daf6c64..c4a1a84484 100644
--- a/dpdk/doc/guides/cryptodevs/features/snow3g.ini
+++ b/dpdk/doc/guides/cryptodevs/features/snow3g.ini
@@ -6,6 +6,7 @@
 [Features]
 Symmetric crypto       = Y
 Sym operation chaining = Y
+OOP LB  In LB  Out     = Y
 
 ;
 ; Supported crypto algorithms of the 'snow3g' crypto driver.
diff --git a/dpdk/doc/guides/cryptodevs/features/zuc.ini b/dpdk/doc/guides/cryptodevs/features/zuc.ini
index 9b6a4287e8..29cc258aae 100644
--- a/dpdk/doc/guides/cryptodevs/features/zuc.ini
+++ b/dpdk/doc/guides/cryptodevs/features/zuc.ini
@@ -6,6 +6,7 @@
 [Features]
 Symmetric crypto       = Y
 Sym operation chaining = Y
+OOP LB  In LB  Out     = Y
 
 ;
 ; Supported crypto algorithms of the 'zuc' crypto driver.
diff --git a/dpdk/doc/guides/cryptodevs/qat.rst b/dpdk/doc/guides/cryptodevs/qat.rst
index 6197875fe3..c8bc514d61 100644
--- a/dpdk/doc/guides/cryptodevs/qat.rst
+++ b/dpdk/doc/guides/cryptodevs/qat.rst
@@ -52,10 +52,15 @@ Cipher algorithms:
 
 Hash algorithms:
 
+* ``RTE_CRYPTO_AUTH_SHA1``
 * ``RTE_CRYPTO_AUTH_SHA1_HMAC``
+* ``RTE_CRYPTO_AUTH_SHA224``
 * ``RTE_CRYPTO_AUTH_SHA224_HMAC``
+* ``RTE_CRYPTO_AUTH_SHA256``
 * ``RTE_CRYPTO_AUTH_SHA256_HMAC``
+* ``RTE_CRYPTO_AUTH_SHA384``
 * ``RTE_CRYPTO_AUTH_SHA384_HMAC``
+* ``RTE_CRYPTO_AUTH_SHA512``
 * ``RTE_CRYPTO_AUTH_SHA512_HMAC``
 * ``RTE_CRYPTO_AUTH_AES_XCBC_MAC``
 * ``RTE_CRYPTO_AUTH_SNOW3G_UIA2``
@@ -72,6 +77,29 @@ Supported AEAD algorithms:
 * ``RTE_CRYPTO_AEAD_AES_CCM``
 
 
+Supported Chains
+~~~~~~~~~~~~~~~~
+
+All the usual chains are supported and also some mixed chains:
+
+.. table:: Supported hash-cipher chains for wireless digest-encrypted cases
+
+   +------------------+-----------+-------------+----------+----------+
+   | Cipher algorithm | NULL AUTH | SNOW3G UIA2 | ZUC EIA3 | AES CMAC |
+   +==================+===========+=============+==========+==========+
+   | NULL CIPHER      | Y         | 2&3         | 2&3      | Y        |
+   +------------------+-----------+-------------+----------+----------+
+   | SNOW3G UEA2      | 2&3       | Y           | 2&3      | 2&3      |
+   +------------------+-----------+-------------+----------+----------+
+   | ZUC EEA3         | 2&3       | 2&3         | 2&3      | 2&3      |
+   +------------------+-----------+-------------+----------+----------+
+   | AES CTR          | Y         | 2&3         | 2&3      | Y        |
+   +------------------+-----------+-------------+----------+----------+
+
+* The combinations marked as "Y" are supported on all QAT hardware versions.
+* The combinations marked as "2&3" are supported on GEN2/GEN3 QAT hardware only.
+
+
 Limitations
 ~~~~~~~~~~~
 
@@ -81,7 +109,10 @@ Limitations
 * No BSD support as BSD QAT kernel driver not available.
 * ZUC EEA3/EIA3 is not supported by dh895xcc devices
 * Maximum additional authenticated data (AAD) for GCM is 240 bytes long and must be passed to the device in a buffer rounded up to the nearest block-size multiple (x16) and padded with zeros.
-* Queue pairs are not thread-safe (that is, within a single queue pair, RX and TX from different lcores is not supported).
+* Queue-pairs are thread-safe on Intel CPUs but Queues are not (that is, within a single
+  queue-pair all enqueues to the TX queue must be done from one thread and all dequeues
+  from the RX queue must be done from one thread, but enqueues and dequeues may be done
+  in different threads.)
 * A GCM limitation exists, but only in the case where there are multiple
   generations of QAT devices on a single platform.
   To optimise performance, the GCM crypto session should be initialised for the
@@ -93,6 +124,8 @@ Limitations
   enqueued to the device and will be marked as failed. The simplest way to
   mitigate this is to use the bdf whitelist to avoid mixing devices of different
   generations in the same process if planning to use for GCM.
+* The mixed algo feature on GEN2 is not supported by all kernel drivers. Check
+  the notes under the Available Kernel Drivers table below for specific details.
 
 Extra notes on KASUMI F9
 ~~~~~~~~~~~~~~~~~~~~~~~~
@@ -133,7 +166,10 @@ Limitations
 ~~~~~~~~~~~
 
 * Big integers longer than 4096 bits are not supported.
-* Queue pairs are not thread-safe (that is, within a single queue pair, RX and TX from different lcores is not supported).
+* Queue-pairs are thread-safe on Intel CPUs but Queues are not (that is, within a single
+  queue-pair all enqueues to the TX queue must be done from one thread and all dequeues
+  from the RX queue must be done from one thread, but enqueues and dequeues may be done
+  in different threads.)
 * RSA-2560, RSA-3584 are not supported
 
 .. _building_qat:
@@ -237,6 +273,27 @@ allocated while for GEN1 devices, 12 buffers are allocated, plus 1472 bytes over
 	larger than the input size).
 
 
+Running QAT PMD with minimum threshold for burst size
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+If only a small number or packets can be enqueued. Each enqueue causes an expensive MMIO write.
+These MMIO write occurrences can be optimised by setting any of the following parameters
+- qat_sym_enq_threshold
+- qat_asym_enq_threshold
+- qat_comp_enq_threshold
+When any of these parameters is set rte_cryptodev_enqueue_burst function will
+return 0 (thereby avoiding an MMIO) if the device is congested and number of packets
+possible to enqueue is smaller.
+
+To use this feature the user must set the parameter on process start as a device additional parameter::
+
+      example: -w 03:01.1,qat_sym_enq_threshold=32,qat_comp_enq_threshold=16
+
+All parameters can be used with the same device regardless of order. Parameters are separated
+by comma. When the same parameter is used more than once first occurrence of the parameter
+is used.
+Maximum threshold that can be set is 32.
+
 Device and driver naming
 ~~~~~~~~~~~~~~~~~~~~~~~~
 
@@ -326,6 +383,8 @@ to see the full table)
    | Yes | No  | No  | 3   | C4xxx    | p             | qat_c4xxx     | c4xxx      | 18a0   | 1    | 18a1   | 128    |
    +-----+-----+-----+-----+----------+---------------+---------------+------------+--------+------+--------+--------+
 
+* Note: Symmetric mixed crypto algorithms feature on Gen 2 works only with 01.org driver version 4.9.0+
+
 The first 3 columns indicate the service:
 
 * S = Symmetric crypto service (via cryptodev API)
diff --git a/dpdk/doc/guides/eventdevs/index.rst b/dpdk/doc/guides/eventdevs/index.rst
index 570905b813..bb66a5eacc 100644
--- a/dpdk/doc/guides/eventdevs/index.rst
+++ b/dpdk/doc/guides/eventdevs/index.rst
@@ -5,7 +5,7 @@ Event Device Drivers
 ====================
 
 The following are a list of event device PMDs, which can be used from an
-application trough the eventdev API.
+application through the eventdev API.
 
 .. toctree::
     :maxdepth: 2
diff --git a/dpdk/doc/guides/eventdevs/octeontx2.rst b/dpdk/doc/guides/eventdevs/octeontx2.rst
index fad84cf42d..d4b2515ce5 100644
--- a/dpdk/doc/guides/eventdevs/octeontx2.rst
+++ b/dpdk/doc/guides/eventdevs/octeontx2.rst
@@ -66,7 +66,7 @@ Runtime Config Options
   upper limit for in-flight events.
   For example::
 
-    --dev "0002:0e:00.0,xae_cnt=16384"
+    -w 0002:0e:00.0,xae_cnt=16384
 
 - ``Force legacy mode``
 
@@ -74,7 +74,7 @@ Runtime Config Options
   single workslot mode in SSO and disable the default dual workslot mode.
   For example::
 
-    --dev "0002:0e:00.0,single_ws=1"
+    -w 0002:0e:00.0,single_ws=1
 
 - ``Event Group QoS support``
 
@@ -89,7 +89,7 @@ Runtime Config Options
   default.
   For example::
 
-    --dev "0002:0e:00.0,qos=[1-50-50-50]"
+    -w 0002:0e:00.0,qos=[1-50-50-50]
 
 - ``Selftest``
 
@@ -98,7 +98,7 @@ Runtime Config Options
   The tests are run once the vdev creation is successfully complete.
   For example::
 
-    --dev "0002:0e:00.0,selftest=1"
+    -w 0002:0e:00.0,selftest=1
 
 - ``TIM disable NPA``
 
@@ -107,7 +107,7 @@ Runtime Config Options
   parameter disables NPA and uses software mempool to manage chunks
   For example::
 
-    --dev "0002:0e:00.0,tim_disable_npa=1"
+    -w 0002:0e:00.0,tim_disable_npa=1
 
 - ``TIM modify chunk slots``
 
@@ -118,7 +118,7 @@ Runtime Config Options
   to SSO. The default value is 255 and the max value is 4095.
   For example::
 
-    --dev "0002:0e:00.0,tim_chnk_slots=1023"
+    -w 0002:0e:00.0,tim_chnk_slots=1023
 
 - ``TIM enable arm/cancel statistics``
 
@@ -126,7 +126,7 @@ Runtime Config Options
   event timer adapter.
   For example::
 
-    --dev "0002:0e:00.0,tim_stats_ena=1"
+    -w 0002:0e:00.0,tim_stats_ena=1
 
 - ``TIM limit max rings reserved``
 
@@ -136,7 +136,7 @@ Runtime Config Options
   rings.
   For example::
 
-    --dev "0002:0e:00.0,tim_rings_lmt=5"
+    -w 0002:0e:00.0,tim_rings_lmt=5
 
 - ``TIM ring control internal parameters``
 
@@ -146,7 +146,7 @@ Runtime Config Options
   default values.
   For Example::
 
-    --dev "0002:0e:00.0,tim_ring_ctl=[2-1023-1-0]"
+    -w 0002:0e:00.0,tim_ring_ctl=[2-1023-1-0]
 
 Debugging Options
 ~~~~~~~~~~~~~~~~~
diff --git a/dpdk/doc/guides/freebsd_gsg/install_from_ports.rst b/dpdk/doc/guides/freebsd_gsg/install_from_ports.rst
index 29f16cc6c5..dce028bc62 100644
--- a/dpdk/doc/guides/freebsd_gsg/install_from_ports.rst
+++ b/dpdk/doc/guides/freebsd_gsg/install_from_ports.rst
@@ -62,7 +62,7 @@ environmental variables should be set as below:
 .. note::
 
    To install a copy of the DPDK compiled using gcc, please download the
-   official DPDK package from http://core.dpdk.org/download/ and install manually using
+   official DPDK package from https://core.dpdk.org/download/ and install manually using
    the instructions given in the next chapter, :ref:`building_from_source`
 
 An example application can therefore be copied to a user's home directory and
diff --git a/dpdk/doc/guides/linux_gsg/build_dpdk.rst b/dpdk/doc/guides/linux_gsg/build_dpdk.rst
index 4aeb4697d9..c536e354ef 100644
--- a/dpdk/doc/guides/linux_gsg/build_dpdk.rst
+++ b/dpdk/doc/guides/linux_gsg/build_dpdk.rst
@@ -167,60 +167,32 @@ Installation of DPDK Target Environment using Make
    is therefore recommended that DPDK installation is done using meson and
    ninja as described above.
 
-The format of a DPDK target is::
+Get a native target environment automatically::
 
-    ARCH-MACHINE-EXECENV-TOOLCHAIN
-
-where:
-
-* ``ARCH`` can be:  ``i686``, ``x86_64``, ``ppc_64``, ``arm64``
-
-* ``MACHINE`` can be:  ``native``, ``power8``, ``armv8a``
-
-* ``EXECENV`` can be:  ``linux``,  ``freebsd``
-
-* ``TOOLCHAIN`` can be:  ``gcc``,  ``icc``
-
-The targets to be installed depend on the 32-bit and/or 64-bit packages and compilers installed on the host.
-Available targets can be found in the DPDK/config directory.
-The defconfig\_ prefix should not be used.
+   make defconfig O=mybuild
 
 .. note::
 
-    Configuration files are provided with the ``RTE_MACHINE`` optimization level set.
     Within the configuration files, the ``RTE_MACHINE`` configuration value is set to native,
     which means that the compiled software is tuned for the platform on which it is built.
-    For more information on this setting, and its possible values, see the *DPDK Programmers Guide*.
 
-When using the Intel® C++ Compiler (icc), one of the following commands should be invoked for 64-bit or 32-bit use respectively.
-Notice that the shell scripts update the ``$PATH`` variable and therefore should not be performed in the same session.
-Also, verify the compiler's installation directory since the path may be different:
+Or get a specific target environment::
 
-.. code-block:: console
+   make config T=x86_64-native-linux-gcc O=mybuild
 
-    source /opt/intel/bin/iccvars.sh intel64
-    source /opt/intel/bin/iccvars.sh ia32
+The format of a DPDK target is "ARCH-MACHINE-EXECENV-TOOLCHAIN".
+Available targets can be found with::
 
-To install and make targets, use the ``make install T=<target>`` command in the top-level DPDK directory.
+   make help
 
-For example, to compile a 64-bit target using icc, run:
+Customize the target configuration in the generated ``.config`` file.
+Example for enabling the pcap PMD::
 
-.. code-block:: console
+   sed -ri 's,(PMD_PCAP=).*,\1y,' mybuild/.config
 
-    make install T=x86_64-native-linux-icc
+Compile the target::
 
-To compile a 32-bit build using gcc, the make command should be:
-
-.. code-block:: console
-
-    make install T=i686-native-linux-gcc
-
-To prepare a target without building it, for example, if the configuration changes need to be made before compilation,
-use the ``make config T=<target>`` command:
-
-.. code-block:: console
-
-    make config T=x86_64-native-linux-gcc
+   make -j4 O=mybuild
 
 .. warning::
 
@@ -229,15 +201,13 @@ use the ``make config T=<target>`` command:
     If the DPDK is not being built on the target machine,
     the ``RTE_KERNELDIR`` environment variable should be used to point the compilation at a copy of the kernel version to be used on the target machine.
 
-Once the target environment is created, the user may move to the target environment directory and continue to make code changes and re-compile.
-The user may also make modifications to the compile-time DPDK configuration by editing the .config file in the build directory.
-(This is a build-local copy of the defconfig file from the top- level config directory).
+Install the target in a separate directory::
 
-.. code-block:: console
+   make install O=mybuild DESTDIR=myinstall prefix=
+
+The environment is ready to build a DPDK application::
 
-    cd x86_64-native-linux-gcc
-    vi .config
-    make
+   RTE_SDK=$(pwd)/myinstall/share/dpdk RTE_TARGET=x86_64-native-linux-gcc make -C myapp
 
 In addition, the make clean command can be used to remove any existing compiled files for a subsequent full, clean rebuild of the code.
 
@@ -245,5 +215,5 @@ Browsing the Installed DPDK Environment Target
 ----------------------------------------------
 
 Once a target is created it contains all libraries, including poll-mode drivers, and header files for the DPDK environment that are required to build customer applications.
-In addition, the test and testpmd applications are built under the build/app directory, which may be used for testing.
+In addition, the test applications are built under the app directory, which may be used for testing.
 A kmod  directory is also present that contains kernel modules which may be loaded if needed.
diff --git a/dpdk/doc/guides/linux_gsg/build_sample_apps.rst b/dpdk/doc/guides/linux_gsg/build_sample_apps.rst
index 2f606535c3..2c2f5faec5 100644
--- a/dpdk/doc/guides/linux_gsg/build_sample_apps.rst
+++ b/dpdk/doc/guides/linux_gsg/build_sample_apps.rst
@@ -4,7 +4,7 @@
 Compiling and Running Sample Applications
 =========================================
 
-The chapter describes how to compile and run applications in an DPDK environment.
+The chapter describes how to compile and run applications in a DPDK environment.
 It also provides a pointer to where sample applications are stored.
 
 .. note::
@@ -185,7 +185,7 @@ Each bit of the mask corresponds to the equivalent logical core number as report
 Since these logical core numbers, and their mapping to specific cores on specific NUMA sockets, can vary from platform to platform,
 it is recommended that the core layout for each platform be considered when choosing the coremask/corelist to use in each case.
 
-On initialization of the EAL layer by an DPDK application, the logical cores to be used and their socket location are displayed.
+On initialization of the EAL layer by a DPDK application, the logical cores to be used and their socket location are displayed.
 This information can also be determined for all cores on the system by examining the ``/proc/cpuinfo`` file, for example, by running cat ``/proc/cpuinfo``.
 The physical id attribute listed for each processor indicates the CPU socket to which it belongs.
 This can be useful when using other processors to understand the mapping of the logical cores to the sockets.
diff --git a/dpdk/doc/guides/linux_gsg/eal_args.include.rst b/dpdk/doc/guides/linux_gsg/eal_args.include.rst
index ed8b0e35b0..7b2f6b1d43 100644
--- a/dpdk/doc/guides/linux_gsg/eal_args.include.rst
+++ b/dpdk/doc/guides/linux_gsg/eal_args.include.rst
@@ -132,7 +132,7 @@ Debugging options
 
     Specify log level for a specific component. For example::
 
-        --log-level eal:8
+        --log-level lib.eal:debug
 
     Can be specified multiple times.
 
diff --git a/dpdk/doc/guides/linux_gsg/enable_func.rst b/dpdk/doc/guides/linux_gsg/enable_func.rst
index b2bda80bb7..459a952ce3 100644
--- a/dpdk/doc/guides/linux_gsg/enable_func.rst
+++ b/dpdk/doc/guides/linux_gsg/enable_func.rst
@@ -58,22 +58,51 @@ The application can then determine what action to take, if any, if the HPET is n
     if any, and on what is available on the system at runtime.
 
 Running DPDK Applications Without Root Privileges
---------------------------------------------------------
+-------------------------------------------------
 
-.. note::
+In order to run DPDK as non-root, the following Linux filesystem objects'
+permissions should be adjusted to ensure that the Linux account being used to
+run the DPDK application has access to them:
+
+*   All directories which serve as hugepage mount points, for example, ``/dev/hugepages``
+
+*   If the HPET is to be used,  ``/dev/hpet``
+
+When running as non-root user, there may be some additional resource limits
+that are imposed by the system. Specifically, the following resource limits may
+need to be adjusted in order to ensure normal DPDK operation:
+
+* RLIMIT_LOCKS (number of file locks that can be held by a process)
+
+* RLIMIT_NOFILE (number of open file descriptors that can be held open by a process)
+
+* RLIMIT_MEMLOCK (amount of pinned pages the process is allowed to have)
+
+The above limits can usually be adjusted by editing
+``/etc/security/limits.conf`` file, and rebooting.
 
-    The instructions below will allow running DPDK as non-root with older
-    Linux kernel versions. However, since version 4.0, the kernel does not allow
-    unprivileged processes to read the physical address information from
-    the pagemaps file, making it impossible for those processes to use HW
-    devices which require physical addresses
+Additionally, depending on which kernel driver is in use, the relevant
+resources also should be accessible by the user running the DPDK application.
 
-Although applications using the DPDK use network ports and other hardware resources directly,
-with a number of small permission adjustments it is possible to run these applications as a user other than "root".
-To do so, the ownership, or permissions, on the following Linux file system objects should be adjusted to ensure that
-the Linux user account being used to run the DPDK application has access to them:
+For ``vfio-pci`` kernel driver, the following Linux file system objects'
+permissions should be adjusted:
 
-*   All directories which serve as hugepage mount points, for example,   ``/mnt/huge``
+* The VFIO device file, ``/dev/vfio/vfio``
+
+* The directories under ``/dev/vfio`` that correspond to IOMMU group numbers of
+  devices intended to be used by DPDK, for example, ``/dev/vfio/50``
+
+.. note::
+
+    The instructions below will allow running DPDK with ``igb_uio`` or
+    ``uio_pci_generic`` drivers as non-root with older Linux kernel versions.
+    However, since version 4.0, the kernel does not allow unprivileged processes
+    to read the physical address information from the pagemaps file, making it
+    impossible for those processes to be used by non-privileged users. In such
+    cases, using the VFIO driver is recommended.
+
+For ``igb_uio`` or ``uio_pci_generic`` kernel drivers, the following Linux file
+system objects' permissions should be adjusted:
 
 *   The userspace-io device files in  ``/dev``, for example,  ``/dev/uio0``, ``/dev/uio1``, and so on
 
@@ -82,11 +111,6 @@ the Linux user account being used to run the DPDK application has access to them
        /sys/class/uio/uio0/device/config
        /sys/class/uio/uio0/device/resource*
 
-*   If the HPET is to be used,  ``/dev/hpet``
-
-.. note::
-
-    On some Linux installations, ``/dev/hugepages``  is also a hugepage mount point created by default.
 
 Power Management and Power Saving Functionality
 -----------------------------------------------
@@ -112,7 +136,7 @@ In addition, C3 and C6 should be enabled as well for power management. The path
 Using Linux Core Isolation to Reduce Context Switches
 -----------------------------------------------------
 
-While the threads used by an DPDK application are pinned to logical cores on the system,
+While the threads used by a DPDK application are pinned to logical cores on the system,
 it is possible for the Linux scheduler to run other tasks on those cores also.
 To help prevent additional workloads from running on those cores,
 it is possible to use the ``isolcpus`` Linux kernel parameter to isolate them from the general Linux scheduler.
diff --git a/dpdk/doc/guides/linux_gsg/linux_drivers.rst b/dpdk/doc/guides/linux_gsg/linux_drivers.rst
index 238f3e9002..96817e78cd 100644
--- a/dpdk/doc/guides/linux_gsg/linux_drivers.rst
+++ b/dpdk/doc/guides/linux_gsg/linux_drivers.rst
@@ -52,8 +52,8 @@ be loaded as shown below:
 
    If the devices used for DPDK are bound to the ``uio_pci_generic`` kernel module,
    please make sure that the IOMMU is disabled or passthrough. One can add
-   ``intel_iommu=off`` or ``amd_iommu=off`` or ``intel_iommu=on iommu=pt``in GRUB
-   command line on x86_64 systems, or add ``iommu.passthrough=1`` on arm64 system.
+   ``intel_iommu=off`` or ``amd_iommu=off`` or ``intel_iommu=on iommu=pt`` in GRUB
+   command line on x86_64 systems, or add ``iommu.passthrough=1`` on aarch64 system.
 
 Since DPDK release 1.7 onward provides VFIO support, use of UIO is optional
 for platforms that support using VFIO.
@@ -120,7 +120,7 @@ Binding and Unbinding Network Ports to/from the Kernel Modules
     PMDs Which use the bifurcated driver should not be unbind from their kernel drivers. this section is for PMDs which use the UIO or VFIO drivers.
 
 As of release 1.4, DPDK applications no longer automatically unbind all supported network ports from the kernel driver in use.
-Instead, in case the PMD being used use the UIO or VFIO drivers, all ports that are to be used by an DPDK application must be bound to the
+Instead, in case the PMD being used use the UIO or VFIO drivers, all ports that are to be used by a DPDK application must be bound to the
 ``uio_pci_generic``, ``igb_uio`` or ``vfio-pci`` module before the application is run.
 For such PMDs, any network ports under Linux* control will be ignored and cannot be used by the application.
 
diff --git a/dpdk/doc/guides/linux_gsg/nic_perf_intel_platform.rst b/dpdk/doc/guides/linux_gsg/nic_perf_intel_platform.rst
index c554c2159c..b70a151bcc 100644
--- a/dpdk/doc/guides/linux_gsg/nic_perf_intel_platform.rst
+++ b/dpdk/doc/guides/linux_gsg/nic_perf_intel_platform.rst
@@ -1,3 +1,6 @@
+..  SPDX-License-Identifier: BSD-3-Clause
+    Copyright(c) 2015 Intel Corporation.
+
 How to get best performance with NICs on Intel platforms
 ========================================================
 
@@ -64,7 +67,7 @@ This aligns with the previous output which showed that each channel has one memo
 Network Interface Card Requirements
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-Use a `DPDK supported <http://core.dpdk.org/supported/>`_ high end NIC such as the Intel XL710 40GbE.
+Use a `DPDK supported <https://core.dpdk.org/supported/>`_ high end NIC such as the Intel XL710 40GbE.
 
 Make sure each NIC has been flashed the latest version of NVM/firmware.
 
diff --git a/dpdk/doc/guides/linux_gsg/sys_reqs.rst b/dpdk/doc/guides/linux_gsg/sys_reqs.rst
index 7c47ec04ce..0af0b22813 100644
--- a/dpdk/doc/guides/linux_gsg/sys_reqs.rst
+++ b/dpdk/doc/guides/linux_gsg/sys_reqs.rst
@@ -107,7 +107,7 @@ e.g. :doc:`../nics/index`
 Running DPDK Applications
 -------------------------
 
-To run an DPDK application, some customization may be required on the target machine.
+To run a DPDK application, some customization may be required on the target machine.
 
 System Software
 ~~~~~~~~~~~~~~~
@@ -157,8 +157,36 @@ Without hugepages, high TLB miss rates would occur with the standard 4k page siz
 Reserving Hugepages for DPDK Use
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-The allocation of hugepages should be done at boot time or as soon as possible after system boot
-to prevent memory from being fragmented in physical memory.
+The reservation of hugepages can be performed at run time.
+This is done by echoing the number of hugepages required
+to a ``nr_hugepages`` file in the ``/sys/kernel/`` directory
+corresponding to a specific page size (in Kilobytes).
+For a single-node system, the command to use is as follows
+(assuming that 1024 of 2MB pages are required)::
+
+    echo 1024 > /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages
+
+On a NUMA machine, the above command will usually divide the number of hugepages
+equally across all NUMA nodes (assuming there is enough memory on all NUMA nodes).
+However, pages can also be reserved explicitly on individual NUMA nodes
+using a ``nr_hugepages`` file in the ``/sys/devices/`` directory::
+
+    echo 1024 > /sys/devices/system/node/node0/hugepages/hugepages-2048kB/nr_hugepages
+    echo 1024 > /sys/devices/system/node/node1/hugepages/hugepages-2048kB/nr_hugepages
+
+.. note::
+
+    Some kernel versions may not allow reserving 1 GB hugepages at run time,
+    so reserving them at boot time may be the only option.
+    Please see below for instructions.
+
+**Alternative:**
+
+In the general case, reserving hugepages at run time is perfectly fine,
+but in use cases where having lots of physically contiguous memory is required,
+it is preferable to reserve hugepages at boot time,
+as that will help in preventing physical memory from becoming heavily fragmented.
+
 To reserve hugepages at boot time, a parameter is passed to the Linux kernel on the kernel command line.
 
 For 2 MB pages, just pass the hugepages option to the kernel. For example, to reserve 1024 pages of 2 MB, use::
@@ -187,35 +215,29 @@ the number of hugepages reserved at boot time is generally divided equally betwe
 
 See the Documentation/admin-guide/kernel-parameters.txt file in your Linux source tree for further details of these and other kernel options.
 
-**Alternative:**
-
-For 2 MB pages, there is also the option of allocating hugepages after the system has booted.
-This is done by echoing the number of hugepages required to a nr_hugepages file in the ``/sys/devices/`` directory.
-For a single-node system, the command to use is as follows (assuming that 1024 pages are required)::
-
-    echo 1024 > /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages
-
-On a NUMA machine, pages should be allocated explicitly on separate nodes::
-
-    echo 1024 > /sys/devices/system/node/node0/hugepages/hugepages-2048kB/nr_hugepages
-    echo 1024 > /sys/devices/system/node/node1/hugepages/hugepages-2048kB/nr_hugepages
+Using Hugepages with the DPDK
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
-.. note::
+If secondary process support is not required, DPDK is able to use hugepages
+without any configuration by using "in-memory" mode.
+Please see :doc:`linux_eal_parameters` for more details.
 
-    For 1G pages, it is not possible to reserve the hugepage memory after the system has booted.
+If secondary process support is required,
+mount points for hugepages need to be created.
+On modern Linux distributions, a default mount point for hugepages
+is provided by the system and is located at ``/dev/hugepages``.
+This mount point will use the default hugepage size
+set by the kernel parameters as described above.
 
-Using Hugepages with the DPDK
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+However, in order to use hugepage sizes other than the default, it is necessary
+to manually create mount points for those hugepage sizes (e.g. 1GB pages).
 
-Once the hugepage memory is reserved, to make the memory available for DPDK use, perform the following steps::
+To make the hugepages of size 1GB available for DPDK use,
+following steps must be performed::
 
     mkdir /mnt/huge
-    mount -t hugetlbfs nodev /mnt/huge
+    mount -t hugetlbfs pagesize=1GB /mnt/huge
 
 The mount point can be made permanent across reboots, by adding the following line to the ``/etc/fstab`` file::
 
-    nodev /mnt/huge hugetlbfs defaults 0 0
-
-For 1GB pages, the page size must be specified as a mount option::
-
-    nodev /mnt/huge_1GB hugetlbfs pagesize=1GB 0 0
+    nodev /mnt/huge hugetlbfs pagesize=1GB 0 0
diff --git a/dpdk/doc/guides/meson.build b/dpdk/doc/guides/meson.build
index 7931ef3bb5..732e7ad3a9 100644
--- a/dpdk/doc/guides/meson.build
+++ b/dpdk/doc/guides/meson.build
@@ -3,26 +3,22 @@
 
 sphinx = find_program('sphinx-build', required: get_option('enable_docs'))
 
-if sphinx.found()
-	htmldir = join_paths('share', 'doc', 'dpdk')
-	html_guides_build = custom_target('html_guides_build',
-		input: meson.current_source_dir(),
-		output: 'guides',
-		command: [sphinx, '-b', 'html',
-			'-d', meson.current_build_dir() + '/.doctrees',
-			'@INPUT@', meson.current_build_dir() + '/guides'],
-		build_by_default: get_option('enable_docs'),
-		install: get_option('enable_docs'),
-		install_dir: htmldir)
+if not sphinx.found()
+	subdir_done()
+endif
 
-	doc_targets += html_guides_build
-	doc_target_names += 'HTML_Guides'
+htmldir = join_paths(get_option('datadir'), 'doc', 'dpdk')
+html_guides = custom_target('html_guides',
+	input: files('index.rst'),
+	output: 'html',
+	command: [sphinx_wrapper, sphinx, meson.current_source_dir(), meson.current_build_dir()],
+	depfile: '.html.d',
+	build_by_default: get_option('enable_docs'),
+	install: get_option('enable_docs'),
+	install_dir: htmldir)
 
-	# sphinx leaves a .buildinfo in the target directory, which we don't
-	# want to install. Note that sh -c has to be used, otherwise the
-	# env var does not get expanded if calling rm/install directly.
-	meson.add_install_script('sh', '-c',
-		'rm -f $MESON_INSTALL_DESTDIR_PREFIX/share/doc/dpdk/guides/.buildinfo')
-	meson.add_install_script('sh', '-c',
-		'install -D -m0644 $MESON_SOURCE_ROOT/doc/guides/custom.css $MESON_INSTALL_DESTDIR_PREFIX/share/doc/dpdk/guides/_static/css/custom.css')
-endif
+install_data(files('custom.css'),
+			install_dir: join_paths(htmldir,'_static', 'css'))
+
+doc_targets += html_guides
+doc_target_names += 'HTML_Guides'
diff --git a/dpdk/doc/guides/nics/dpaa2.rst b/dpdk/doc/guides/nics/dpaa2.rst
index fdfa6fdd5a..e54a5ff4d2 100644
--- a/dpdk/doc/guides/nics/dpaa2.rst
+++ b/dpdk/doc/guides/nics/dpaa2.rst
@@ -1,5 +1,5 @@
 ..  SPDX-License-Identifier: BSD-3-Clause
-    Copyright 2016 NXP
+    Copyright 2016,2020 NXP
 
 
 DPAA2 Poll Mode Driver
@@ -300,7 +300,7 @@ The diagram below shows the dpaa2 drivers involved in a networking
 scenario and the objects bound to each driver.  A brief description
 of each driver follows.
 
-.. code-block: console
+.. code-block:: console
 
 
                                        +------------+
diff --git a/dpdk/doc/guides/nics/enic.rst b/dpdk/doc/guides/nics/enic.rst
index 65e536d422..24d2b5713a 100644
--- a/dpdk/doc/guides/nics/enic.rst
+++ b/dpdk/doc/guides/nics/enic.rst
@@ -14,7 +14,7 @@ How to obtain ENIC PMD integrated DPDK
 --------------------------------------
 
 ENIC PMD support is integrated into the DPDK suite. dpdk-<version>.tar.gz
-should be downloaded from http://core.dpdk.org/download/
+should be downloaded from https://core.dpdk.org/download/
 
 
 Configuration information
diff --git a/dpdk/doc/guides/nics/fail_safe.rst b/dpdk/doc/guides/nics/fail_safe.rst
index 6c02d7ef6d..60bbf40f7f 100644
--- a/dpdk/doc/guides/nics/fail_safe.rst
+++ b/dpdk/doc/guides/nics/fail_safe.rst
@@ -49,7 +49,7 @@ The Fail-safe PMD can be used like most other DPDK virtual devices, by passing a
 ``--vdev`` parameter to the EAL when starting the application. The device name
 must start with the *net_failsafe* prefix, followed by numbers or letters. This
 name must be unique for each device. Each fail-safe instance must have at least one
-sub-device, up to ``RTE_MAX_ETHPORTS-1``.
+sub-device, and at most two.
 
 A sub-device can be any legal DPDK device, including possibly another fail-safe
 instance.
diff --git a/dpdk/doc/guides/nics/features/hns3.ini b/dpdk/doc/guides/nics/features/hns3.ini
index 6df789ed10..cd5c08a9d7 100644
--- a/dpdk/doc/guides/nics/features/hns3.ini
+++ b/dpdk/doc/guides/nics/features/hns3.ini
@@ -5,6 +5,7 @@
 ;
 [Features]
 Link status          = Y
+Rx interrupt         = Y
 MTU update           = Y
 Jumbo frame          = Y
 Promiscuous mode     = Y
diff --git a/dpdk/doc/guides/nics/features/hns3_vf.ini b/dpdk/doc/guides/nics/features/hns3_vf.ini
index 41497c4c2d..fd00ac3e22 100644
--- a/dpdk/doc/guides/nics/features/hns3_vf.ini
+++ b/dpdk/doc/guides/nics/features/hns3_vf.ini
@@ -5,6 +5,7 @@
 ;
 [Features]
 Link status          = Y
+Rx interrupt         = Y
 MTU update           = Y
 Jumbo frame          = Y
 Unicast MAC filter   = Y
diff --git a/dpdk/doc/guides/nics/features/i40e.ini b/dpdk/doc/guides/nics/features/i40e.ini
index e5ae6ded08..c2717cdc47 100644
--- a/dpdk/doc/guides/nics/features/i40e.ini
+++ b/dpdk/doc/guides/nics/features/i40e.ini
@@ -18,7 +18,6 @@ TSO                  = Y
 Promiscuous mode     = Y
 Allmulticast mode    = Y
 Unicast MAC filter   = Y
-Multicast MAC filter = Y
 RSS hash             = Y
 RSS key update       = Y
 RSS reta update      = Y
diff --git a/dpdk/doc/guides/nics/features/ice.ini b/dpdk/doc/guides/nics/features/ice.ini
index 65923f0bc0..949d09f423 100644
--- a/dpdk/doc/guides/nics/features/ice.ini
+++ b/dpdk/doc/guides/nics/features/ice.ini
@@ -18,7 +18,6 @@ TSO                  = Y
 Promiscuous mode     = Y
 Allmulticast mode    = Y
 Unicast MAC filter   = Y
-Multicast MAC filter = Y
 RSS hash             = Y
 RSS key update       = Y
 RSS reta update      = Y
diff --git a/dpdk/doc/guides/nics/features/igb.ini b/dpdk/doc/guides/nics/features/igb.ini
index 0351f8495d..167c0cabe8 100644
--- a/dpdk/doc/guides/nics/features/igb.ini
+++ b/dpdk/doc/guides/nics/features/igb.ini
@@ -15,6 +15,7 @@ TSO                  = Y
 Promiscuous mode     = Y
 Allmulticast mode    = Y
 Unicast MAC filter   = Y
+Multicast MAC filter = Y
 RSS hash             = Y
 RSS key update       = Y
 RSS reta update      = Y
diff --git a/dpdk/doc/guides/nics/features/ixgbe.ini b/dpdk/doc/guides/nics/features/ixgbe.ini
index c412d7af1a..1c7a2a5240 100644
--- a/dpdk/doc/guides/nics/features/ixgbe.ini
+++ b/dpdk/doc/guides/nics/features/ixgbe.ini
@@ -17,6 +17,7 @@ TSO                  = Y
 Promiscuous mode     = Y
 Allmulticast mode    = Y
 Unicast MAC filter   = Y
+Multicast MAC filter = Y
 RSS hash             = Y
 RSS key update       = Y
 RSS reta update      = Y
diff --git a/dpdk/doc/guides/nics/features/mlx5.ini b/dpdk/doc/guides/nics/features/mlx5.ini
index b0a2f8e5f7..30a4d80ead 100644
--- a/dpdk/doc/guides/nics/features/mlx5.ini
+++ b/dpdk/doc/guides/nics/features/mlx5.ini
@@ -41,6 +41,7 @@ Basic stats          = Y
 Extended stats       = Y
 Stats per queue      = Y
 FW version           = Y
+Module EEPROM dump   = Y
 Multiprocess aware   = Y
 Other kdrv           = Y
 ARMv8                = Y
diff --git a/dpdk/doc/guides/nics/hns3.rst b/dpdk/doc/guides/nics/hns3.rst
index 505488b6ca..567c65d536 100644
--- a/dpdk/doc/guides/nics/hns3.rst
+++ b/dpdk/doc/guides/nics/hns3.rst
@@ -22,13 +22,14 @@ Features of the HNS3 PMD are:
 - Port hardware statistics
 - Jumbo frames
 - Link state information
+- Interrupt mode for RX
 - VLAN stripping
 - NUMA support
 
 Prerequisites
 -------------
 - Get the information about Kunpeng920 chip using
-  `<http://www.hisilicon.com/en/Products/ProductList/Kunpeng>`_.
+  `<https://www.hisilicon.com/en/products/Kunpeng>`_.
 
 - Follow the DPDK :ref:`Getting Started Guide for Linux <linux_gsg>` to setup the basic DPDK environment.
 
diff --git a/dpdk/doc/guides/nics/i40e.rst b/dpdk/doc/guides/nics/i40e.rst
index 38acf5906d..cfeb156935 100644
--- a/dpdk/doc/guides/nics/i40e.rst
+++ b/dpdk/doc/guides/nics/i40e.rst
@@ -69,7 +69,9 @@ to chapter Tested Platforms/Tested NICs in release notes.
    +--------------+-----------------------+------------------+
    | DPDK version | Kernel driver version | Firmware version |
    +==============+=======================+==================+
-   |    19.08     |         2.9.21        |       7.00       |
+   |    19.11     |         2.9.21        |       7.00       |
+   +--------------+-----------------------+------------------+
+   |    19.08     |         2.8.43        |       7.00       |
    +--------------+-----------------------+------------------+
    |    19.05     |         2.7.29        |       6.80       |
    +--------------+-----------------------+------------------+
@@ -580,6 +582,15 @@ When a packet is over maximum frame size, the packet is dropped.
 However, the Rx statistics, when calling `rte_eth_stats_get` incorrectly
 shows it as received.
 
+RX/TX statistics may be incorrect when register overflowed
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+The rx_bytes/tx_bytes statistics register is 48 bit length.
+Although this limitation is enlarged to 64 bit length on the software side,
+but there is no way to detect if the overflow occurred more than once.
+So rx_bytes/tx_bytes statistics data is correct when statistics are
+updated at least once between two overflows.
+
 VF & TC max bandwidth setting
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
@@ -665,6 +676,15 @@ Use 16 Bytes RX Descriptor Size
 As i40e PMD supports both 16 and 32 bytes RX descriptor sizes, and 16 bytes size can provide helps to high performance of small packets.
 Configuration of ``CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC`` in config files can be changed to use 16 bytes size RX descriptors.
 
+Input set requirement of each pctype for FDIR
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Each PCTYPE can only have one specific FDIR input set at one time.
+For example, if creating 2 rte_flow rules with different input set for one PCTYPE,
+it will fail and return the info "Conflict with the first rule's input set",
+which means the current rule's input set conflicts with the first rule's.
+Remove the first rule if want to change the input set of the PCTYPE.
+
 Example of getting best performance with l3fwd example
 ------------------------------------------------------
 
diff --git a/dpdk/doc/guides/nics/ice.rst b/dpdk/doc/guides/nics/ice.rst
index 9b90b389ec..58eb023983 100644
--- a/dpdk/doc/guides/nics/ice.rst
+++ b/dpdk/doc/guides/nics/ice.rst
@@ -54,10 +54,6 @@ Please note that enabling debugging options may affect system performance.
 
   Toggle display of generic debugging messages.
 
-- ``CONFIG_RTE_LIBRTE_ICE_RX_ALLOW_BULK_ALLOC`` (default ``y``)
-
-  Toggle bulk allocation for RX.
-
 - ``CONFIG_RTE_LIBRTE_ICE_16BYTE_RX_DESC`` (default ``n``)
 
Louis Abel's avatar
Louis Abel committed
12201 12202 12203 12204 12205 12206 12207 12208 12209 12210 12211 12212 12213 12214 12215 12216 12217 12218 12219 12220 12221 12222 12223 12224 12225 12226 12227 12228 12229 12230 12231 12232 12233 12234 12235 12236 12237 12238 12239 12240 12241 12242 12243 12244 12245 12246 12247 12248 12249 12250 12251 12252 12253 12254 12255 12256 12257 12258 12259 12260 12261 12262 12263 12264 12265 12266 12267 12268 12269 12270 12271 12272 12273 12274 12275 12276 12277 12278 12279 12280 12281 12282 12283 12284 12285 12286 12287 12288 12289 12290 12291 12292 12293 12294 12295 12296 12297 12298 12299 12300 12301 12302 12303 12304 12305 12306 12307 12308 12309 12310 12311 12312 12313 12314 12315 12316 12317 12318 12319 12320 12321 12322 12323 12324 12325 12326 12327 12328 12329 12330 12331 12332 12333 12334 12335 12336 12337 12338 12339 12340 12341 12342 12343 12344 12345 12346 12347 12348 12349 12350 12351 12352 12353 12354 12355 12356 12357 12358 12359 12360 12361 12362 12363 12364 12365 12366 12367 12368 12369 12370 12371 12372 12373 12374 12375 12376 12377 12378 12379 12380 12381 12382 12383 12384 12385 12386 12387 12388 12389 12390 12391 12392 12393 12394 12395 12396 12397 12398 12399 12400 12401 12402 12403 12404 12405 12406 12407 12408 12409 12410 12411 12412 12413 12414 12415 12416 12417 12418 12419 12420 12421 12422 12423 12424 12425 12426 12427 12428 12429 12430 12431 12432 12433 12434 12435 12436 12437 12438 12439 12440 12441 12442 12443 12444 12445 12446 12447 12448 12449 12450 12451 12452 12453 12454 12455 12456 12457 12458 12459 12460 12461 12462 12463 12464 12465 12466 12467 12468 12469 12470 12471 12472 12473 12474 12475 12476 12477 12478 12479 12480 12481 12482 12483 12484 12485 12486 12487 12488 12489 12490 12491 12492 12493 12494 12495 12496 12497 12498 12499 12500 12501 12502 12503 12504 12505 12506 12507 12508 12509 12510 12511 12512 12513 12514 12515 12516 12517 12518 12519 12520 12521 12522 12523 12524 12525 12526 12527 12528 12529 12530 12531 12532 12533 12534 12535 12536 12537 12538 12539 12540 12541 12542 12543 12544 12545 12546 12547 12548 12549 12550 12551 12552 12553 12554 12555 12556 12557 12558 12559 12560 12561 12562 12563 12564 12565 12566 12567 12568 12569 12570 12571 12572 12573 12574 12575 12576 12577 12578 12579 12580 12581 12582 12583 12584 12585 12586 12587 12588 12589 12590 12591 12592 12593 12594 12595 12596 12597 12598 12599 12600 12601 12602 12603 12604 12605 12606 12607 12608 12609 12610 12611 12612 12613 12614 12615 12616 12617 12618 12619 12620 12621 12622 12623 12624 12625 12626 12627 12628 12629 12630 12631 12632 12633 12634 12635 12636 12637 12638 12639 12640 12641 12642 12643 12644 12645 12646 12647 12648 12649 12650 12651 12652 12653 12654 12655 12656 12657 12658 12659 12660 12661 12662 12663 12664 12665 12666 12667 12668 12669 12670 12671 12672 12673 12674 12675 12676 12677 12678 12679 12680 12681 12682 12683 12684 12685 12686 12687 12688 12689 12690 12691 12692 12693 12694 12695 12696 12697 12698 12699 12700 12701 12702 12703 12704 12705 12706 12707 12708 12709 12710 12711 12712 12713 12714 12715 12716 12717 12718 12719 12720 12721 12722 12723 12724 12725 12726 12727 12728 12729 12730 12731 12732 12733 12734 12735 12736 12737 12738 12739 12740 12741 12742 12743 12744 12745 12746 12747 12748 12749 12750 12751 12752 12753 12754 12755 12756 12757 12758 12759 12760 12761 12762 12763 12764 12765 12766 12767 12768 12769 12770 12771 12772 12773 12774 12775 12776 12777 12778 12779 12780 12781 12782 12783 12784 12785 12786 12787 12788 12789 12790 12791 12792 12793 12794 12795 12796 12797 12798 12799 12800 12801 12802 12803 12804 12805 12806 12807 12808 12809 12810 12811 12812 12813 12814 12815 12816 12817 12818 12819 12820 12821 12822 12823 12824 12825 12826 12827 12828 12829 12830 12831 12832 12833 12834 12835 12836 12837 12838 12839 12840 12841 12842 12843 12844 12845 12846 12847 12848 12849 12850 12851 12852 12853 12854 12855 12856 12857 12858 12859 12860 12861 12862 12863 12864 12865 12866 12867 12868 12869 12870 12871 12872 12873 12874 12875 12876 12877 12878 12879 12880 12881 12882 12883 12884 12885 12886 12887 12888 12889 12890 12891 12892 12893 12894 12895 12896 12897 12898 12899 12900 12901 12902 12903 12904 12905 12906 12907 12908 12909 12910 12911 12912 12913 12914 12915 12916 12917 12918 12919 12920 12921 12922 12923 12924 12925 12926 12927 12928 12929 12930 12931 12932 12933 12934 12935 12936 12937 12938 12939 12940 12941 12942 12943 12944 12945 12946 12947 12948 12949 12950 12951 12952 12953 12954 12955 12956 12957 12958 12959 12960 12961 12962 12963 12964 12965 12966 12967 12968 12969 12970 12971 12972 12973 12974 12975 12976 12977 12978 12979 12980 12981 12982 12983 12984 12985 12986 12987 12988 12989 12990 12991 12992 12993 12994 12995 12996 12997 12998 12999 13000 13001 13002 13003 13004 13005 13006 13007 13008 13009 13010 13011 13012 13013 13014 13015 13016 13017 13018 13019 13020 13021 13022 13023 13024 13025 13026 13027 13028 13029 13030 13031 13032 13033 13034 13035 13036 13037 13038 13039 13040 13041 13042 13043 13044 13045 13046 13047 13048 13049 13050 13051 13052 13053 13054 13055 13056 13057 13058 13059 13060 13061 13062 13063 13064 13065 13066 13067 13068 13069 13070 13071 13072 13073 13074 13075 13076 13077 13078 13079 13080 13081 13082 13083 13084 13085 13086 13087 13088 13089 13090 13091 13092 13093 13094 13095 13096 13097 13098 13099 13100 13101 13102 13103 13104 13105 13106 13107 13108 13109 13110 13111 13112 13113 13114 13115 13116 13117 13118 13119 13120 13121 13122 13123 13124 13125 13126 13127 13128 13129 13130 13131 13132 13133 13134 13135 13136 13137 13138 13139 13140 13141 13142 13143 13144 13145 13146 13147 13148 13149 13150 13151 13152 13153 13154 13155 13156 13157 13158 13159 13160 13161 13162 13163 13164 13165 13166 13167 13168 13169 13170 13171 13172 13173 13174 13175 13176 13177 13178 13179 13180 13181 13182 13183 13184 13185 13186 13187 13188 13189 13190 13191 13192 13193 13194 13195 13196 13197 13198 13199 13200 13201 13202 13203 13204 13205 13206 13207 13208 13209 13210 13211 13212 13213 13214 13215 13216 13217 13218 13219 13220 13221 13222 13223 13224 13225 13226 13227 13228 13229 13230 13231 13232 13233 13234 13235 13236 13237 13238 13239 13240 13241 13242 13243 13244 13245 13246 13247 13248 13249 13250 13251 13252 13253 13254 13255 13256 13257 13258 13259 13260 13261 13262 13263 13264 13265 13266 13267 13268 13269 13270 13271 13272 13273 13274 13275 13276 13277 13278 13279 13280 13281 13282 13283 13284 13285 13286 13287 13288 13289 13290 13291 13292 13293 13294 13295 13296 13297 13298 13299 13300 13301 13302 13303 13304 13305 13306 13307 13308 13309 13310 13311 13312 13313 13314 13315 13316 13317 13318 13319 13320 13321 13322 13323 13324 13325 13326 13327 13328 13329 13330 13331 13332 13333 13334 13335 13336 13337 13338 13339 13340 13341 13342 13343 13344 13345 13346 13347 13348 13349 13350 13351 13352 13353 13354 13355 13356 13357 13358 13359 13360 13361 13362 13363 13364 13365 13366 13367 13368 13369 13370 13371 13372 13373 13374 13375 13376 13377 13378 13379 13380 13381 13382 13383 13384 13385 13386 13387 13388 13389 13390 13391 13392 13393 13394 13395 13396 13397 13398 13399 13400 13401 13402 13403 13404 13405 13406 13407 13408 13409 13410 13411 13412 13413 13414 13415 13416 13417 13418 13419 13420 13421 13422 13423 13424 13425 13426 13427 13428 13429 13430 13431 13432 13433 13434 13435 13436 13437 13438 13439 13440 13441 13442 13443 13444 13445 13446 13447 13448 13449 13450 13451 13452 13453 13454 13455 13456 13457 13458 13459 13460 13461 13462 13463 13464 13465 13466 13467 13468 13469 13470 13471 13472 13473 13474 13475 13476 13477 13478 13479 13480 13481 13482 13483 13484 13485 13486 13487 13488 13489 13490 13491 13492 13493 13494 13495 13496 13497 13498 13499 13500 13501 13502 13503 13504 13505 13506 13507 13508 13509 13510 13511 13512 13513 13514 13515 13516 13517 13518 13519 13520 13521 13522 13523 13524 13525 13526 13527 13528 13529 13530 13531 13532 13533 13534 13535 13536 13537 13538 13539 13540 13541 13542 13543 13544 13545 13546 13547 13548 13549 13550 13551 13552 13553 13554 13555 13556 13557 13558 13559 13560 13561 13562 13563 13564 13565 13566 13567 13568 13569 13570 13571 13572 13573 13574 13575 13576 13577 13578 13579 13580 13581 13582 13583 13584 13585 13586 13587 13588 13589 13590 13591 13592 13593 13594 13595 13596 13597 13598 13599 13600 13601 13602 13603 13604 13605 13606 13607 13608 13609 13610 13611 13612 13613 13614 13615 13616 13617 13618 13619 13620 13621 13622 13623 13624 13625 13626 13627 13628 13629 13630 13631 13632 13633 13634 13635 13636 13637 13638 13639 13640 13641 13642 13643 13644 13645 13646 13647 13648 13649 13650 13651 13652 13653 13654 13655 13656 13657 13658 13659 13660 13661 13662 13663 13664 13665 13666 13667 13668 13669 13670 13671 13672 13673 13674 13675 13676 13677 13678 13679 13680 13681 13682 13683 13684 13685 13686 13687 13688 13689 13690 13691 13692 13693 13694 13695 13696 13697 13698 13699 13700 13701 13702 13703 13704 13705 13706 13707 13708 13709 13710 13711 13712 13713 13714 13715 13716 13717 13718 13719 13720 13721 13722 13723 13724 13725 13726 13727 13728 13729 13730 13731 13732 13733 13734 13735 13736 13737 13738 13739 13740 13741 13742 13743 13744 13745 13746 13747 13748 13749 13750 13751 13752 13753 13754 13755 13756 13757 13758 13759 13760 13761 13762 13763 13764 13765 13766 13767 13768 13769 13770 13771 13772 13773 13774 13775 13776 13777 13778 13779 13780 13781 13782 13783 13784 13785 13786 13787 13788 13789 13790 13791 13792 13793 13794 13795 13796 13797 13798 13799 13800 13801 13802 13803 13804 13805 13806 13807 13808 13809 13810 13811 13812 13813 13814 13815 13816 13817 13818 13819 13820 13821 13822 13823 13824 13825 13826 13827 13828 13829 13830 13831 13832 13833 13834 13835 13836 13837 13838 13839 13840 13841 13842 13843 13844 13845 13846 13847 13848 13849 13850 13851 13852 13853 13854 13855 13856 13857 13858 13859 13860 13861 13862 13863 13864 13865 13866 13867 13868 13869 13870 13871 13872 13873 13874 13875 13876 13877 13878 13879 13880 13881 13882 13883 13884 13885 13886 13887 13888 13889 13890 13891 13892 13893 13894 13895 13896 13897 13898 13899 13900 13901 13902 13903 13904 13905 13906 13907 13908 13909 13910 13911 13912 13913 13914 13915 13916 13917 13918 13919 13920 13921 13922 13923 13924 13925 13926 13927 13928 13929 13930 13931 13932 13933 13934 13935 13936 13937 13938 13939 13940 13941 13942 13943 13944 13945 13946 13947 13948 13949 13950 13951 13952 13953 13954 13955 13956 13957 13958 13959 13960 13961 13962 13963 13964 13965 13966 13967 13968 13969 13970 13971 13972 13973 13974 13975 13976 13977 13978 13979 13980 13981 13982 13983 13984 13985 13986 13987 13988 13989 13990 13991 13992 13993 13994 13995 13996 13997 13998 13999 14000 14001 14002 14003 14004 14005 14006 14007 14008 14009 14010 14011 14012 14013 14014 14015 14016 14017 14018 14019 14020 14021 14022 14023 14024 14025 14026 14027 14028 14029 14030 14031 14032 14033 14034 14035 14036 14037 14038 14039 14040 14041 14042 14043 14044 14045 14046 14047 14048 14049 14050 14051 14052 14053 14054 14055 14056 14057 14058 14059 14060 14061 14062 14063 14064 14065 14066 14067 14068 14069 14070 14071 14072 14073 14074 14075 14076 14077 14078 14079 14080 14081 14082 14083 14084 14085 14086 14087 14088 14089 14090 14091 14092 14093 14094 14095 14096 14097 14098 14099 14100 14101 14102 14103 14104 14105 14106 14107 14108 14109 14110 14111 14112 14113 14114 14115 14116 14117 14118 14119 14120 14121 14122 14123 14124 14125 14126 14127 14128 14129 14130 14131 14132 14133 14134 14135 14136 14137 14138 14139 14140 14141 14142 14143 14144 14145 14146 14147 14148 14149 14150 14151 14152 14153 14154 14155 14156 14157 14158 14159 14160 14161 14162 14163 14164 14165 14166 14167 14168 14169 14170 14171 14172 14173 14174 14175 14176 14177 14178 14179 14180 14181 14182 14183 14184 14185 14186 14187 14188 14189 14190 14191 14192 14193 14194 14195 14196 14197 14198 14199 14200
   Toggle to use a 16-byte RX descriptor, by default the RX descriptor is 32 byte.
diff --git a/dpdk/doc/guides/nics/ixgbe.rst b/dpdk/doc/guides/nics/ixgbe.rst
index 5c3a7e4f26..6ca2a33f09 100644
--- a/dpdk/doc/guides/nics/ixgbe.rst
+++ b/dpdk/doc/guides/nics/ixgbe.rst
@@ -253,6 +253,16 @@ Before binding ``vfio`` with legacy mode in X550 NICs, use ``modprobe vfio ``
 ``nointxmask=1`` to load ``vfio`` module if the intx is not shared with other
 devices.
 
+UDP with zero checksum is reported as error
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Intel 82599 10 Gigabit Ethernet Controller Specification Update (Revision 2.87)
+Errata: 44 Integrity Error Reported for IPv4/UDP Packets With Zero Checksum
+
+To support UDP zero checksum, the zero and bad UDP checksum packet is marked as
+PKT_RX_L4_CKSUM_UNKNOWN, so the application needs to recompute the checksum to
+validate it.
+
 Inline crypto processing support
 --------------------------------
 
diff --git a/dpdk/doc/guides/nics/mlx4.rst b/dpdk/doc/guides/nics/mlx4.rst
index d0e8a8b2ff..1f1e2f6c77 100644
--- a/dpdk/doc/guides/nics/mlx4.rst
+++ b/dpdk/doc/guides/nics/mlx4.rst
@@ -92,6 +92,10 @@ These options can be modified in the ``.config`` file.
   adds additional run-time checks and debugging messages at the cost of
   lower performance.
 
+This option is available in meson:
+
+- ``ibverbs_link`` can be ``static``, ``shared``, or ``dlopen``.
+
 Environment variables
 ~~~~~~~~~~~~~~~~~~~~~
 
@@ -294,11 +298,6 @@ Installing Mellanox OFED
 
 5. Continue with :ref:`section 2 of the Quick Start Guide <QSG_2>`.
 
-Supported NICs
---------------
-
-* Mellanox(R) ConnectX(R)-3 Pro 40G MCX354A-FCC_Ax (2*40G)
-
 .. _qsg:
 
 Quick Start Guide
diff --git a/dpdk/doc/guides/nics/mlx5.rst b/dpdk/doc/guides/nics/mlx5.rst
index 18573cf6a0..bbad7d0d5b 100644
--- a/dpdk/doc/guides/nics/mlx5.rst
+++ b/dpdk/doc/guides/nics/mlx5.rst
@@ -2,12 +2,14 @@
     Copyright 2015 6WIND S.A.
     Copyright 2015 Mellanox Technologies, Ltd
 
+.. include:: <isonum.txt>
+
 MLX5 poll mode driver
 =====================
 
 The MLX5 poll mode driver library (**librte_pmd_mlx5**) provides support
 for **Mellanox ConnectX-4**, **Mellanox ConnectX-4 Lx** , **Mellanox
-ConnectX-5**, **Mellanox ConnectX-6**, **Mellanox ConnectX-6DX** and
+ConnectX-5**, **Mellanox ConnectX-6**, **Mellanox ConnectX-6 Dx** and
 **Mellanox BlueField** families of 10/25/40/50/100/200 Gb/s adapters
 as well as their virtual functions (VF) in SR-IOV context.
 
@@ -107,22 +109,37 @@ Limitations
     process. If the external memory is registered by primary process but has
     different virtual address in secondary process, unexpected error may happen.
 
-- Flow pattern without any specific vlan will match for vlan packets as well:
+- When using Verbs flow engine (``dv_flow_en`` = 0), flow pattern without any
+  specific VLAN will match for VLAN packets as well:
 
   When VLAN spec is not specified in the pattern, the matching rule will be created with VLAN as a wild card.
   Meaning, the flow rule::
 
         flow create 0 ingress pattern eth / vlan vid is 3 / ipv4 / end ...
 
-  Will only match vlan packets with vid=3. and the flow rules::
+  Will only match vlan packets with vid=3. and the flow rule::
+
+        flow create 0 ingress pattern eth / ipv4 / end ...
+
+  Will match any ipv4 packet (VLAN included).
+
+- When using DV flow engine (``dv_flow_en`` = 1), flow pattern without VLAN item
+  will match untagged packets only.
+  The flow rule::
 
         flow create 0 ingress pattern eth / ipv4 / end ...
 
-  Or::
+  Will match untagged packets only.
+  The flow rule::
 
         flow create 0 ingress pattern eth / vlan / ipv4 / end ...
 
-  Will match any ipv4 packet (VLAN included).
+  Will match tagged packets only, with any VLAN ID value.
+  The flow rule::
+
+        flow create 0 ingress pattern eth / vlan vid is 3 / ipv4 / end ...
+
+  Will only match tagged packets with VLAN ID 3.
 
 - VLAN pop offload command:
 
@@ -270,6 +287,10 @@ These options can be modified in the ``.config`` file.
    64. Default armv8a configuration of make build and meson build set it to 128
    then brings performance degradation.
 
+This option is available in meson:
+
+- ``ibverbs_link`` can be ``static``, ``shared``, or ``dlopen``.
+
 Environment variables
 ~~~~~~~~~~~~~~~~~~~~~
 
@@ -315,9 +336,9 @@ Run-time configuration
 
   Supported on:
 
-  - x86_64 with ConnectX-4, ConnectX-4 LX, ConnectX-5, ConnectX-6, ConnectX-6 DX
+  - x86_64 with ConnectX-4, ConnectX-4 Lx, ConnectX-5, ConnectX-6, ConnectX-6 Dx
     and BlueField.
-  - POWER9 and ARMv8 with ConnectX-4 LX, ConnectX-5, ConnectX-6, ConnectX-6 DX
+  - POWER9 and ARMv8 with ConnectX-4 Lx, ConnectX-5, ConnectX-6, ConnectX-6 Dx
     and BlueField.
 
 - ``rxq_cqe_pad_en`` parameter [int]
@@ -348,17 +369,16 @@ Run-time configuration
 
   Supported on:
 
-  - x86_64 with ConnectX-4, ConnectX-4 LX, ConnectX-5, ConnectX-6, ConnectX-6 DX
+  - x86_64 with ConnectX-4, ConnectX-4 Lx, ConnectX-5, ConnectX-6, ConnectX-6 Dx
     and BlueField.
-  - POWER8 and ARMv8 with ConnectX-4 LX, ConnectX-5, ConnectX-6, ConnectX-6 DX
+  - POWER8 and ARMv8 with ConnectX-4 Lx, ConnectX-5, ConnectX-6, ConnectX-6 Dx
     and BlueField.
 
 - ``mprq_en`` parameter [int]
 
   A nonzero value enables configuring Multi-Packet Rx queues. Rx queue is
   configured as Multi-Packet RQ if the total number of Rx queues is
-  ``rxqs_min_mprq`` or more and Rx scatter isn't configured. Disabled by
-  default.
+  ``rxqs_min_mprq`` or more. Disabled by default.
 
   Multi-Packet Rx Queue (MPRQ a.k.a Striding RQ) can further save PCIe bandwidth
   by posting a single large buffer for multiple packets. Instead of posting a
@@ -383,6 +403,20 @@ Run-time configuration
 
   The size of Rx queue should be bigger than the number of strides.
 
+- ``mprq_log_stride_size`` parameter [int]
+
+  Log 2 of the size of a stride for Multi-Packet Rx queue. Configuring a smaller
+  stride size can save some memory and reduce probability of a depletion of all
+  available strides due to unreleased packets by an application. If configured
+  value is not in the range of device capability, the default value will be set
+  with a warning message. The default value is 11 which is 2048 bytes per a
+  stride, valid only if ``mprq_en`` is set. With ``mprq_log_stride_size`` set
+  it is possible for a packet to span across multiple strides. This mode allows
+  support of jumbo frames (9K) with MPRQ. The memcopy of some packets (or part
+  of a packet if Rx scatter is configured) may be required in case there is no
+  space left for a head room at the end of a stride which incurs some
+  performance penalty.
+
 - ``mprq_max_memcpy_len`` parameter [int]
 
   The maximum length of packet to memcpy in case of Multi-Packet Rx queue. Rx
@@ -453,14 +487,14 @@ Run-time configuration
   If ``txq_inline_min`` key is not present, the value may be queried by the
   driver from the NIC via DevX if this feature is available. If there is no DevX
   enabled/supported the value 18 (supposing L2 header including VLAN) is set
-  for ConnectX-4 and ConnectX-4LX, and 0 is set by default for ConnectX-5
+  for ConnectX-4 and ConnectX-4 Lx, and 0 is set by default for ConnectX-5
   and newer NICs. If packet is shorter the ``txq_inline_min`` value, the entire
   packet is inlined.
 
   For ConnectX-4 NIC, driver does not allow specifying value below 18
   (minimal L2 header, including VLAN), error will be raised.
 
-  For ConnectX-4LX NIC, it is allowed to specify values below 18, but
+  For ConnectX-4 Lx NIC, it is allowed to specify values below 18, but
   it is not recommended and may prevent NIC from sending packets over
   some configurations.
 
@@ -543,7 +577,7 @@ Run-time configuration
 - ``txq_mpw_en`` parameter [int]
 
   A nonzero value enables Enhanced Multi-Packet Write (eMPW) for ConnectX-5,
-  ConnectX-6, ConnectX-6 DX and BlueField. eMPW allows the TX burst function to pack
+  ConnectX-6, ConnectX-6 Dx and BlueField. eMPW allows the TX burst function to pack
   up multiple packets in a single descriptor session in order to save PCI bandwidth
   and improve performance at the cost of a slightly higher CPU usage. When
   ``txq_inline_mpw`` is set along with ``txq_mpw_en``, TX burst function copies
@@ -559,16 +593,17 @@ Run-time configuration
   The rdma core library can map doorbell register in two ways, depending on the
   environment variable "MLX5_SHUT_UP_BF":
 
-  - As regular cached memory, if the variable is either missing or set to zero.
+  - As regular cached memory (usually with write combining attribute), if the
+    variable is either missing or set to zero.
   - As non-cached memory, if the variable is present and set to not "0" value.
 
   The type of mapping may slightly affect the Tx performance, the optimal choice
   is strongly relied on the host architecture and should be deduced practically.
 
   If ``tx_db_nc`` is set to zero, the doorbell is forced to be mapped to regular
-  memory, the PMD will perform the extra write memory barrier after writing to
-  doorbell, it might increase the needed CPU clocks per packet to send, but
-  latency might be improved.
+  memory (with write combining), the PMD will perform the extra write memory barrier
+  after writing to doorbell, it might increase the needed CPU clocks per packet
+  to send, but latency might be improved.
 
   If ``tx_db_nc`` is set to one, the doorbell is forced to be mapped to non
   cached memory, the PMD will not perform the extra write memory barrier
@@ -589,7 +624,7 @@ Run-time configuration
 
 - ``tx_vec_en`` parameter [int]
 
-  A nonzero value enables Tx vector on ConnectX-5, ConnectX-6, ConnectX-6 DX
+  A nonzero value enables Tx vector on ConnectX-5, ConnectX-6, ConnectX-6 Dx
   and BlueField NICs if the number of global Tx queues on the port is less than
   ``txqs_max_vec``. The parameter is deprecated and ignored.
 
@@ -658,7 +693,7 @@ Run-time configuration
   +------+-----------+-----------+-------------+-------------+
   | 1    | 24 bits   | vary 0-32 | 32 bits     | yes         |
   +------+-----------+-----------+-------------+-------------+
-  | 2    | vary 0-32 | 32 bits   | 32 bits     | yes         |
+  | 2    | vary 0-24 | 32 bits   | 32 bits     | yes         |
   +------+-----------+-----------+-------------+-------------+
 
   If there is no E-Switch configuration the ``dv_xmeta_en`` parameter is
@@ -670,6 +705,17 @@ Run-time configuration
   of the extensive metadata features. The legacy Verbs supports FLAG and
   MARK metadata actions over NIC Rx steering domain only.
 
+  Setting META value to zero in flow action means there is no item provided
+  and receiving datapath will not report in mbufs the metadata are present.
+  Setting MARK value to zero in flow action means the zero FDIR ID value
+  will be reported on packet receiving.
+
+  For the MARK action the last 16 values in the full range are reserved for
+  internal PMD purposes (to emulate FLAG action). The valid range for the
+  MARK action values is 0-0xFFEF for the 16-bit mode and 0-xFFFFEF
+  for the 24-bit mode, the flows with the MARK action value outside
+  the specified range will be rejected.
+
 - ``dv_flow_en`` parameter [int]
 
   A nonzero value enables the DV flow steering assuming it is supported
@@ -886,7 +932,7 @@ Mellanox OFED/EN
   - ConnectX-5: **16.21.1000** and above.
   - ConnectX-5 Ex: **16.21.1000** and above.
   - ConnectX-6: **20.99.5374** and above.
-  - ConnectX-6 DX: **22.27.0090** and above.
+  - ConnectX-6 Dx: **22.27.0090** and above.
   - BlueField: **18.25.1010** and above.
 
 While these libraries and kernel modules are available on OpenFabrics
@@ -911,28 +957,43 @@ required from that distribution.
 Supported NICs
 --------------
 
-* Mellanox(R) ConnectX(R)-4 10G MCX4111A-XCAT (1x10G)
-* Mellanox(R) ConnectX(R)-4 10G MCX4121A-XCAT (2x10G)
-* Mellanox(R) ConnectX(R)-4 25G MCX4111A-ACAT (1x25G)
-* Mellanox(R) ConnectX(R)-4 25G MCX4121A-ACAT (2x25G)
-* Mellanox(R) ConnectX(R)-4 40G MCX4131A-BCAT (1x40G)
-* Mellanox(R) ConnectX(R)-4 40G MCX413A-BCAT (1x40G)
-* Mellanox(R) ConnectX(R)-4 40G MCX415A-BCAT (1x40G)
-* Mellanox(R) ConnectX(R)-4 50G MCX4131A-GCAT (1x50G)
-* Mellanox(R) ConnectX(R)-4 50G MCX413A-GCAT (1x50G)
-* Mellanox(R) ConnectX(R)-4 50G MCX414A-BCAT (2x50G)
-* Mellanox(R) ConnectX(R)-4 50G MCX415A-GCAT (2x50G)
-* Mellanox(R) ConnectX(R)-4 50G MCX416A-BCAT (2x50G)
-* Mellanox(R) ConnectX(R)-4 50G MCX416A-GCAT (2x50G)
-* Mellanox(R) ConnectX(R)-4 50G MCX415A-CCAT (1x100G)
-* Mellanox(R) ConnectX(R)-4 100G MCX416A-CCAT (2x100G)
-* Mellanox(R) ConnectX(R)-4 Lx 10G MCX4121A-XCAT (2x10G)
-* Mellanox(R) ConnectX(R)-4 Lx 25G MCX4121A-ACAT (2x25G)
-* Mellanox(R) ConnectX(R)-5 100G MCX556A-ECAT (2x100G)
-* Mellanox(R) ConnectX(R)-5 Ex EN 100G MCX516A-CDAT (2x100G)
-* Mellanox(R) ConnectX(R)-6 200G MCX654106A-HCAT (4x200G)
-* Mellanox(R) ConnectX(R)-6DX EN 100G MCX623106AN-CDAT (2*100g)
-* Mellanox(R) ConnectX(R)-6DX EN 200G MCX623105AN-VDAT (1*200g)
+The following Mellanox device families are supported by the same mlx5 driver:
+
+  - ConnectX-4
+  - ConnectX-4 Lx
+  - ConnectX-5
+  - ConnectX-5 Ex
+  - ConnectX-6
+  - ConnectX-6 Dx
+  - BlueField
+
+Below are detailed device names:
+
+* Mellanox\ |reg| ConnectX\ |reg|-4 10G MCX4111A-XCAT (1x10G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 10G MCX412A-XCAT (2x10G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 25G MCX4111A-ACAT (1x25G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 25G MCX412A-ACAT (2x25G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 40G MCX413A-BCAT (1x40G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 40G MCX4131A-BCAT (1x40G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 40G MCX415A-BCAT (1x40G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX413A-GCAT (1x50G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX4131A-GCAT (1x50G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX414A-BCAT (2x50G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX415A-GCAT (1x50G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX416A-BCAT (2x50G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX416A-GCAT (2x50G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 50G MCX415A-CCAT (1x100G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 100G MCX416A-CCAT (2x100G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 Lx 10G MCX4111A-XCAT (1x10G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 Lx 10G MCX4121A-XCAT (2x10G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 Lx 25G MCX4111A-ACAT (1x25G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 Lx 25G MCX4121A-ACAT (2x25G)
+* Mellanox\ |reg| ConnectX\ |reg|-4 Lx 40G MCX4131A-BCAT (1x40G)
+* Mellanox\ |reg| ConnectX\ |reg|-5 100G MCX556A-ECAT (2x100G)
+* Mellanox\ |reg| ConnectX\ |reg|-5 Ex EN 100G MCX516A-CDAT (2x100G)
+* Mellanox\ |reg| ConnectX\ |reg|-6 200G MCX654106A-HCAT (2x200G)
+* Mellanox\ |reg| ConnectX\ |reg|-6 Dx EN 100G MCX623106AN-CDAT (2x100G)
+* Mellanox\ |reg| ConnectX\ |reg|-6 Dx EN 200G MCX623105AN-VDAT (1x200G)
 
 Quick Start Guide on OFED/EN
 ----------------------------
@@ -1195,6 +1256,19 @@ Supported hardware offloads
    |                       | |  ConnectX-5   | | ConnectX-5    |
    +-----------------------+-----------------+-----------------+
 
+Notes for metadata
+------------------
+
+MARK and META items are interrelated with datapath - they might move from/to
+the applications in mbuf fields. Hence, zero value for these items has the
+special meaning - it means "no metadata are provided", not zero values are
+treated by applications and PMD as valid ones.
+
+Moreover in the flow engine domain the value zero is acceptable to match and
+set, and we should allow to specify zero values as rte_flow parameters for the
+META and MARK items and actions. In the same time zero mask has no meaning and
+should be rejected on validation stage.
+
 Notes for testpmd
 -----------------
 
diff --git a/dpdk/doc/guides/nics/nfp.rst b/dpdk/doc/guides/nics/nfp.rst
index 5f2a0698f6..020e37d131 100644
--- a/dpdk/doc/guides/nics/nfp.rst
+++ b/dpdk/doc/guides/nics/nfp.rst
@@ -102,22 +102,39 @@ directory per firmware application. Options 1 and 2 for firmware filenames allow
 more than one SmartNIC, same type of SmartNIC or different ones, and to upload a
 different firmware to each SmartNIC.
 
+   .. Note::
+      Currently the NFP PMD supports using the PF with Agilio Basic Firmware. See
+      https://help.netronome.com/support/solutions for more information on the
+      various firmwares supported by the Netronome Agilio CX smartNIC.
 
 PF multiport support
 --------------------
 
-Some NFP cards support several physical ports with just one single PCI device.
-The DPDK core is designed with a 1:1 relationship between PCI devices and DPDK
-ports, so NFP PMD PF support requires handling the multiport case specifically.
-During NFP PF initialization, the PMD will extract the information about the
-number of PF ports from the firmware and will create as many DPDK ports as
-needed.
+The NFP PMD can work with up to 8 ports on the same PF device. The number of
+available ports is firmware and hardware dependent, and the driver looks for a
+firmware symbol during initialization to know how many can be used.
 
-Because the unusual relationship between a single PCI device and several DPDK
-ports, there are some limitations when using more than one PF DPDK port: there
-is no support for RX interrupts and it is not possible either to use those PF
-ports with the device hotplug functionality.
+DPDK apps work with ports, and a port is usually a PF or a VF PCI device.
+However, with the NFP PF multiport there is just one PF PCI device. Supporting
+this particular configuration requires the PMD to create ports in a special way,
+although once they are created, DPDK apps should be able to use them as normal
+PCI ports.
 
+NFP ports belonging to same PF can be seen inside PMD initialization with a
+suffix added to the PCI ID: wwww:xx:yy.z_port_n. For example, a PF with PCI ID
+0000:03:00.0 and four ports is seen by the PMD code as:
+
+   .. code-block:: console
+
+      0000:03:00.0_port_0
+      0000:03:00.0_port_1
+      0000:03:00.0_port_2
+      0000:03:00.0_port_3
+
+   .. Note::
+
+      There are some limitations with multiport support: RX interrupts and
+      device hot-plugging are not supported.
 
 PF multiprocess support
 -----------------------
diff --git a/dpdk/doc/guides/nics/pcap_ring.rst b/dpdk/doc/guides/nics/pcap_ring.rst
index cf230ae40a..8fdb49179a 100644
--- a/dpdk/doc/guides/nics/pcap_ring.rst
+++ b/dpdk/doc/guides/nics/pcap_ring.rst
@@ -166,7 +166,7 @@ Forward packets through two network interfaces:
 .. code-block:: console
 
     $RTE_TARGET/app/testpmd -l 0-3 -n 4 \
-        --vdev 'net_pcap0,iface=eth0' --vdev='net_pcap1;iface=eth1'
+        --vdev 'net_pcap0,iface=eth0' --vdev='net_pcap1,iface=eth1'
 
 Enable 2 tx queues on a network interface:
 
diff --git a/dpdk/doc/guides/nics/sfc_efx.rst b/dpdk/doc/guides/nics/sfc_efx.rst
index 67d9b054d5..f79ebf518c 100644
--- a/dpdk/doc/guides/nics/sfc_efx.rst
+++ b/dpdk/doc/guides/nics/sfc_efx.rst
@@ -295,7 +295,7 @@ whitelist option like "-w 02:00.0,arg1=value1,...".
 Case-insensitive 1/y/yes/on or 0/n/no/off may be used to specify
 boolean parameters value.
 
-- ``rx_datapath`` [auto|efx|ef10|ef10_esps] (default **auto**)
+- ``rx_datapath`` [auto|efx|ef10|ef10_essb] (default **auto**)
 
   Choose receive datapath implementation.
   **auto** allows the driver itself to make a choice based on firmware
@@ -304,7 +304,7 @@ boolean parameters value.
   **ef10** chooses EF10 (SFN7xxx, SFN8xxx, X2xxx) native datapath which is
   more efficient than libefx-based and provides richer packet type
   classification.
-  **ef10_esps** chooses SFNX2xxx equal stride packed stream datapath
+  **ef10_essb** chooses SFNX2xxx equal stride super-buffer datapath
   which may be used on DPDK firmware variant only
   (see notes about its limitations above).
 
diff --git a/dpdk/doc/guides/prog_guide/cryptodev_lib.rst b/dpdk/doc/guides/prog_guide/cryptodev_lib.rst
index ac16437740..c839379885 100644
--- a/dpdk/doc/guides/prog_guide/cryptodev_lib.rst
+++ b/dpdk/doc/guides/prog_guide/cryptodev_lib.rst
@@ -1097,4 +1097,4 @@ Asymmetric Crypto Device API
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 The cryptodev Library API is described in the
-`DPDK API Reference <http://doc.dpdk.org/api/>`_
+`DPDK API Reference <https://doc.dpdk.org/api/>`_
diff --git a/dpdk/doc/guides/prog_guide/img/ring-mp-enqueue3.svg b/dpdk/doc/guides/prog_guide/img/ring-mp-enqueue3.svg
index da483b031e..83ef7dba13 100644
--- a/dpdk/doc/guides/prog_guide/img/ring-mp-enqueue3.svg
+++ b/dpdk/doc/guides/prog_guide/img/ring-mp-enqueue3.svg
@@ -16,7 +16,7 @@
    height="403.06647"
    id="svg3388"
    version="1.1"
-   inkscape:version="0.48.4 r9939"
+   inkscape:version="0.92.4 (f8dce91, 2019-08-02)"
    sodipodi:docname="ring-mp-enqueue3.svg">
   <defs
      id="defs3390">
@@ -359,15 +359,15 @@
      inkscape:pageshadow="2"
      inkscape:zoom="1.4"
      inkscape:cx="201.35119"
-     inkscape:cy="221.79811"
+     inkscape:cy="107.5124"
      inkscape:document-units="px"
      inkscape:current-layer="layer1"
      showgrid="false"
-     inkscape:window-width="958"
-     inkscape:window-height="1002"
-     inkscape:window-x="223"
-     inkscape:window-y="22"
-     inkscape:window-maximized="0"
+     inkscape:window-width="1313"
+     inkscape:window-height="713"
+     inkscape:window-x="53"
+     inkscape:window-y="27"
+     inkscape:window-maximized="1"
      inkscape:snap-grids="false"
      inkscape:snap-to-guides="true"
      showguides="false"
@@ -382,8 +382,10 @@
        visible="true"
        enabled="true"
        snapvisiblegridlinesonly="true"
-       originx="-162.97143px"
-       originy="-370.03525px" />
+       originx="-162.97143"
+       originy="-370.03525"
+       spacingx="1"
+       spacingy="1" />
   </sodipodi:namedview>
   <metadata
      id="metadata3393">
@@ -393,7 +395,7 @@
         <dc:format>image/svg+xml</dc:format>
         <dc:type
            rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
-        <dc:title />
+        <dc:title></dc:title>
       </cc:Work>
     </rdf:RDF>
   </metadata>
@@ -490,37 +492,37 @@
     </g>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="313.90488"
        y="495.49646"
-       id="text4269"
-       sodipodi:linespacing="125%"><tspan
+       id="text4269"><tspan
          sodipodi:role="line"
          id="tspan4271"
          x="313.90488"
-         y="495.49646">obj1</tspan></text>
+         y="495.49646"
+         style="font-size:14px;line-height:1.25">obj1</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="368.95203"
        y="495.49646"
-       id="text4269-4"
-       sodipodi:linespacing="125%"><tspan
+       id="text4269-4"><tspan
          sodipodi:role="line"
          id="tspan4271-5"
          x="368.95203"
-         y="495.49646">obj2</tspan></text>
+         y="495.49646"
+         style="font-size:14px;line-height:1.25">obj2</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="422.99518"
        y="495.49646"
-       id="text4269-5"
-       sodipodi:linespacing="125%"><tspan
+       id="text4269-5"><tspan
          sodipodi:role="line"
          id="tspan4271-4"
          x="422.99518"
-         y="495.49646">obj3</tspan></text>
+         y="495.49646"
+         style="font-size:14px;line-height:1.25">obj3</tspan></text>
     <path
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend);font-family:Arial;-inkscape-font-specification:Arial"
        d="m 323.57143,578.07647 0,-42.14286"
@@ -533,48 +535,48 @@
        inkscape:connector-curvature="0" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="289.85715"
        y="589.505"
-       id="text4787"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787"><tspan
          sodipodi:role="line"
          id="tspan4789"
          x="289.85715"
-         y="589.505">cons_head</tspan></text>
+         y="589.505"
+         style="font-size:14px;line-height:1.25">cons_head</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="293.45334"
        y="603.41034"
-       id="text4787-3"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-3"><tspan
          sodipodi:role="line"
          id="tspan4789-0"
          x="293.45334"
-         y="603.41034">cons_tail</tspan></text>
+         y="603.41034"
+         style="font-size:14px;line-height:1.25">cons_tail</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
-       x="527.01239"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
+       x="567.01239"
        y="587.9577"
-       id="text4787-7"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-7"><tspan
          sodipodi:role="line"
          id="tspan4789-8"
-         x="527.01239"
-         y="587.9577">prod_head</tspan></text>
+         x="567.01239"
+         y="587.9577"
+         style="font-size:14px;line-height:1.25">prod_head</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="460.7514"
        y="602.57739"
-       id="text4787-3-6"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-3-6"><tspan
          sodipodi:role="line"
          id="tspan4789-0-8"
          x="460.7514"
-         y="602.57739">prod_tail</tspan></text>
+         y="602.57739"
+         style="font-size:14px;line-height:1.25">prod_tail</tspan></text>
     <rect
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:1, 1;stroke-dashoffset:0;font-family:Arial;-inkscape-font-specification:Arial"
        id="rect4889"
@@ -586,19 +588,20 @@
        ry="11.631636" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="174.28571"
        y="328.93362"
-       id="text4891"
-       sodipodi:linespacing="125%"><tspan
+       id="text4891"><tspan
          sodipodi:role="line"
          id="tspan4893"
          x="174.28571"
-         y="328.93362">local variables</tspan><tspan
+         y="328.93362"
+         style="font-size:14px;line-height:1.25">local variables</tspan><tspan
          sodipodi:role="line"
          x="174.28571"
          y="346.43362"
-         id="tspan4150">core 2</tspan></text>
+         id="tspan4150"
+         style="font-size:14px;line-height:1.25">core 2</tspan></text>
     <rect
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:1, 1;stroke-dashoffset:0;font-family:Arial;-inkscape-font-specification:Arial"
        id="rect4889-8"
@@ -610,15 +613,15 @@
        ry="11.631636" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="170.89287"
-       y="682.09021"
-       id="text4891-4"
-       sodipodi:linespacing="125%"><tspan
+       y="664.09021"
+       id="text4891-4"><tspan
          sodipodi:role="line"
          id="tspan4893-3"
          x="170.89287"
-         y="682.09021">structure state</tspan></text>
+         y="664.09021"
+         style="font-size:14px;line-height:1.25">structure state</tspan></text>
     <path
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend);font-family:Arial;-inkscape-font-specification:Arial"
        d="m 325.25296,407.43361 0,42.14286"
@@ -631,37 +634,37 @@
        inkscape:connector-curvature="0" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="296.992"
        y="401.48123"
-       id="text4787-3-64"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-3-64"><tspan
          sodipodi:role="line"
          id="tspan4789-0-9"
          x="296.992"
-         y="401.48123">cons_tail</tspan></text>
+         y="401.48123"
+         style="font-size:14px;line-height:1.25">cons_tail</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="440.26532"
        y="401.48123"
-       id="text4787-7-5"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-7-5"><tspan
          sodipodi:role="line"
          id="tspan4789-8-0"
          x="440.26532"
-         y="401.48123">prod_head</tspan></text>
+         y="401.48123"
+         style="font-size:14px;line-height:1.25">prod_head</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="522.43298"
        y="401.48123"
-       id="text4787-3-6-4"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-3-6-4"><tspan
          sodipodi:role="line"
          id="tspan4789-0-8-8"
          x="522.43298"
-         y="401.48123">prod_next</tspan></text>
+         y="401.48123"
+         style="font-size:14px;line-height:1.25">prod_next</tspan></text>
     <path
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend);font-family:Arial;-inkscape-font-specification:Arial"
        d="m 537.14285,407.43361 0,42.14286"
@@ -678,19 +681,20 @@
        ry="11.631636" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="174.65646"
        y="398.23306"
-       id="text4891-3"
-       sodipodi:linespacing="125%"><tspan
+       id="text4891-3"><tspan
          sodipodi:role="line"
          id="tspan4893-1"
          x="174.65646"
-         y="398.23306">local variables</tspan><tspan
+         y="398.23306"
+         style="font-size:14px;line-height:1.25">local variables</tspan><tspan
          sodipodi:role="line"
          x="174.65646"
          y="415.73306"
-         id="tspan4152">core 1</tspan></text>
+         id="tspan4152"
+         style="font-size:14px;line-height:1.25">core 1</tspan></text>
     <path
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend);font-family:Arial;-inkscape-font-specification:Arial"
        d="m 326.73097,334.53006 0,42.14286"
@@ -703,37 +707,37 @@
        inkscape:connector-curvature="0" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="298.47"
        y="328.57767"
-       id="text4787-3-64-5"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-3-64-5"><tspan
          sodipodi:role="line"
          id="tspan4789-0-9-0"
          x="298.47"
-         y="328.57767">cons_tail</tspan></text>
+         y="328.57767"
+         style="font-size:14px;line-height:1.25">cons_tail</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="489.02905"
        y="328.57767"
-       id="text4787-7-5-3"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-7-5-3"><tspan
          sodipodi:role="line"
          id="tspan4789-8-0-6"
          x="489.02905"
-         y="328.57767">prod_head</tspan></text>
+         y="328.57767"
+         style="font-size:14px;line-height:1.25">prod_head</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="571.19672"
        y="328.57767"
-       id="text4787-3-6-4-1"
-       sodipodi:linespacing="125%"><tspan
+       id="text4787-3-6-4-1"><tspan
          sodipodi:role="line"
          id="tspan4789-0-8-8-0"
          x="571.19672"
-         y="328.57767">prod_next</tspan></text>
+         y="328.57767"
+         style="font-size:14px;line-height:1.25">prod_next</tspan></text>
     <path
        style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend);font-family:Arial;-inkscape-font-specification:Arial"
        d="m 587.90657,334.53006 0,42.14286"
@@ -741,45 +745,46 @@
        inkscape:connector-curvature="0" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="447.85715"
        y="289.505"
-       id="text3320"
-       sodipodi:linespacing="125%"><tspan
+       id="text3320"><tspan
          sodipodi:role="line"
          id="tspan3322"
          x="447.85715"
-         y="289.505">compare and swap succeeds</tspan><tspan
+         y="289.505"
+         style="font-size:14px;line-height:1.25">compare and swap succeeds</tspan><tspan
          sodipodi:role="line"
          x="447.85715"
          y="307.005"
-         id="tspan3324">on core 2</tspan></text>
+         id="tspan3324"
+         style="font-size:14px;line-height:1.25">on core 2</tspan></text>
     <path
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend);font-family:Arial;-inkscape-font-specification:Arial"
-       d="m 542.85715,575.57647 0,-42.14286"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:14px;line-height:125%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend)"
+       d="M 602.85715,575.57647 V 533.43361"
        id="path4309-4-0"
        inkscape:connector-curvature="0" />
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="477.22983"
        y="495.49646"
-       id="text4269-5-5"
-       sodipodi:linespacing="125%"><tspan
+       id="text4269-5-5"><tspan
          sodipodi:role="line"
          id="tspan4271-4-5"
          x="477.22983"
-         y="495.49646">obj4</tspan></text>
+         y="495.49646"
+         style="font-size:14px;line-height:1.25">obj4</tspan></text>
     <text
        xml:space="preserve"
-       style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Arial;-inkscape-font-specification:Arial"
+       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:0%;font-family:Arial;-inkscape-font-specification:Arial;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none"
        x="531.27301"
        y="496.00156"
-       id="text4269-5-7"
-       sodipodi:linespacing="125%"><tspan
+       id="text4269-5-7"><tspan
          sodipodi:role="line"
          id="tspan4271-4-6"
          x="531.27301"
-         y="496.00156">obj5</tspan></text>
+         y="496.00156"
+         style="font-size:14px;line-height:1.25">obj5</tspan></text>
   </g>
 </svg>
diff --git a/dpdk/doc/guides/prog_guide/kernel_nic_interface.rst b/dpdk/doc/guides/prog_guide/kernel_nic_interface.rst
index 32d09ccf82..f5904f4d1b 100644
--- a/dpdk/doc/guides/prog_guide/kernel_nic_interface.rst
+++ b/dpdk/doc/guides/prog_guide/kernel_nic_interface.rst
@@ -178,7 +178,7 @@ KNI Creation and Deletion
 -------------------------
 
 Before any KNI interfaces can be created, the ``rte_kni`` kernel module must
-be loaded into the kernel and configured withe ``rte_kni_init()`` function.
+be loaded into the kernel and configured with the ``rte_kni_init()`` function.
 
 The KNI interfaces are created by a DPDK application dynamically via the
 ``rte_kni_alloc()`` function.
diff --git a/dpdk/doc/guides/prog_guide/lto.rst b/dpdk/doc/guides/prog_guide/lto.rst
index 43f4c63379..277a6f1090 100644
--- a/dpdk/doc/guides/prog_guide/lto.rst
+++ b/dpdk/doc/guides/prog_guide/lto.rst
@@ -31,7 +31,7 @@ the whole DPDK by setting:
 
 .. code-block:: console
 
-    CONFIG_ENABLE_LTO=y
+    CONFIG_RTE_ENABLE_LTO=y
 
 in config file.
 
diff --git a/dpdk/doc/guides/prog_guide/multi_proc_support.rst b/dpdk/doc/guides/prog_guide/multi_proc_support.rst
index a84083b96c..1a4a9e2d4d 100644
--- a/dpdk/doc/guides/prog_guide/multi_proc_support.rst
+++ b/dpdk/doc/guides/prog_guide/multi_proc_support.rst
@@ -75,7 +75,7 @@ and point to the same objects, in both processes.
 
 
 The EAL also supports an auto-detection mode (set by EAL ``--proc-type=auto`` flag ),
-whereby an DPDK process is started as a secondary instance if a primary instance is already running.
+whereby a DPDK process is started as a secondary instance if a primary instance is already running.
 
 Deployment Models
 -----------------
diff --git a/dpdk/doc/guides/prog_guide/packet_classif_access_ctrl.rst b/dpdk/doc/guides/prog_guide/packet_classif_access_ctrl.rst
index 2945eacf55..f99302a5e8 100644
--- a/dpdk/doc/guides/prog_guide/packet_classif_access_ctrl.rst
+++ b/dpdk/doc/guides/prog_guide/packet_classif_access_ctrl.rst
@@ -373,6 +373,12 @@ There are several implementations of classify algorithm:
 
 *   **RTE_ACL_CLASSIFY_AVX2**: vector implementation, can process up to 16 flows in parallel. Requires AVX2 support.
 
+*   **RTE_ACL_CLASSIFY_NEON**: vector implementation, can process up to 8 flows
+    in parallel. Requires NEON support.
+
+*   **RTE_ACL_CLASSIFY_ALTIVEC**: vector implementation, can process up to 8
+    flows in parallel. Requires ALTIVEC support.
+
 It is purely a runtime decision which method to choose, there is no build-time difference.
 All implementations operates over the same internal RT structures and use similar principles. The main difference is that vector implementations can manually exploit IA SIMD instructions and process several input data flows in parallel.
 At startup ACL library determines the highest available classify method for the given platform and sets it as default one. Though the user has an ability to override the default classifier function for a given ACL context or perform particular search using non-default classify method. In that case it is user responsibility to make sure that given platform supports selected classify implementation.
diff --git a/dpdk/doc/guides/prog_guide/rcu_lib.rst b/dpdk/doc/guides/prog_guide/rcu_lib.rst
index 8d0dfcf291..9b0bf138f6 100644
--- a/dpdk/doc/guides/prog_guide/rcu_lib.rst
+++ b/dpdk/doc/guides/prog_guide/rcu_lib.rst
@@ -61,7 +61,7 @@ wait till thread 2 enters quiescent state as well.
 
 However, the writer does not need to wait for reader thread 3 to enter
 quiescent state. Reader thread 3 was not accessing D1 when the delete
-operation happened. So, reader thread 1 will not have a reference to the
+operation happened. So, reader thread 3 will not have a reference to the
 deleted entry.
 
 It can be noted that, the critical sections for D2 is a quiescent state
diff --git a/dpdk/doc/guides/prog_guide/thread_safety_dpdk_functions.rst b/dpdk/doc/guides/prog_guide/thread_safety_dpdk_functions.rst
index 0f539db2b8..5618e25e47 100644
--- a/dpdk/doc/guides/prog_guide/thread_safety_dpdk_functions.rst
+++ b/dpdk/doc/guides/prog_guide/thread_safety_dpdk_functions.rst
@@ -61,8 +61,8 @@ rather than subsequently in the forwarding threads.
 However, the DPDK performs checks to ensure that libraries are only initialized once.
 If initialization is attempted more than once, an error is returned.
 
-In the multi-process case, the configuration information of shared memory will only be initialized by the master process.
-Thereafter, both master and secondary processes can allocate/release any objects of memory that finally rely on rte_malloc or memzones.
+In the multi-process case, the configuration information of shared memory will only be initialized by the primary process.
+Thereafter, both primary and secondary processes can allocate/release any objects of memory that finally rely on rte_malloc or memzones.
 
 Interrupt Thread
 ----------------
diff --git a/dpdk/doc/guides/rawdevs/ntb.rst b/dpdk/doc/guides/rawdevs/ntb.rst
index 58472135f5..aa7d809649 100644
--- a/dpdk/doc/guides/rawdevs/ntb.rst
+++ b/dpdk/doc/guides/rawdevs/ntb.rst
@@ -52,11 +52,11 @@ NTB PMD needs kernel PCI driver to support write combining (WC) to get
 better performance. The difference will be more than 10 times.
 To enable WC, there are 2 ways.
 
-- Insert igb_uio with ``wc_active=1`` flag if use igb_uio driver.
+- Insert igb_uio with ``wc_activate=1`` flag if use igb_uio driver.
 
 .. code-block:: console
 
-  insmod igb_uio.ko wc_active=1
+  insmod igb_uio.ko wc_activate=1
 
 - Enable WC for NTB device's Bar 2 and Bar 4 (Mapped memory) manually.
   The reference is https://www.kernel.org/doc/html/latest/x86/mtrr.html
diff --git a/dpdk/doc/guides/rel_notes/deprecation.rst b/dpdk/doc/guides/rel_notes/deprecation.rst
index afa94b43e2..58109590cc 100644
--- a/dpdk/doc/guides/rel_notes/deprecation.rst
+++ b/dpdk/doc/guides/rel_notes/deprecation.rst
@@ -67,12 +67,6 @@ Deprecation Notices
   In 19.11 PMDs will still update the field even when the offload is not
   enabled.
 
-* cryptodev: support for using IV with all sizes is added, J0 still can
-  be used but only when IV length in following structs ``rte_crypto_auth_xform``,
-  ``rte_crypto_aead_xform`` is set to zero. When IV length is greater or equal
-  to one it means it represents IV, when is set to zero it means J0 is used
-  directly, in this case 16 bytes of J0 need to be passed.
-
 * sched: To allow more traffic classes, flexible mapping of pipe queues to
   traffic classes, and subport level configuration of pipes and queues
   changes will be made to macros, data structures and API functions defined
@@ -81,8 +75,3 @@ Deprecation Notices
 
 * metrics: The function ``rte_metrics_init`` will have a non-void return
   in order to notify errors instead of calling ``rte_exit``.
-
-* power: ``rte_power_set_env`` function will no longer return 0 on attempt
-  to set new power environment if power environment was already initialized.
-  In this case the function will return -1 unless the environment is unset first
-  (using ``rte_power_unset_env``). Other function usage scenarios will not change.
diff --git a/dpdk/doc/guides/rel_notes/release_18_08.rst b/dpdk/doc/guides/rel_notes/release_18_08.rst
index 8a09dee95c..4ae388c331 100644
--- a/dpdk/doc/guides/rel_notes/release_18_08.rst
+++ b/dpdk/doc/guides/rel_notes/release_18_08.rst
@@ -546,4 +546,4 @@ Tested Platforms
      * Mellanox MLNX_OFED 4.2-1.4.21.0
 
   * DPDK application running on ARM cores inside SmartNIC
-  * Bluefield representors support planned for next release.
+  * BlueField representors support planned for next release.
diff --git a/dpdk/doc/guides/rel_notes/release_19_02.rst b/dpdk/doc/guides/rel_notes/release_19_02.rst
index ace1534eff..87dfbf5c7d 100644
--- a/dpdk/doc/guides/rel_notes/release_19_02.rst
+++ b/dpdk/doc/guides/rel_notes/release_19_02.rst
@@ -109,7 +109,7 @@ New Features
     ``CONFIG_RTE_IBVERBS_LINK_DLOPEN`` for make and ``ibverbs_link`` for meson.
   * Added static linkage of ``mlx`` dependency.
   * Improved stability of E-Switch flow driver.
-  * Added new make build configuration to set the cacheline size for Bluefield
+  * Added new make build configuration to set the cacheline size for BlueField
     correctly - ``arm64-bluefield-linux-gcc``.
 
 * **Updated the enic driver.**
diff --git a/dpdk/doc/guides/rel_notes/release_19_11.rst b/dpdk/doc/guides/rel_notes/release_19_11.rst
index 84aa03a1f2..511d7f87bd 100644
--- a/dpdk/doc/guides/rel_notes/release_19_11.rst
+++ b/dpdk/doc/guides/rel_notes/release_19_11.rst
@@ -206,7 +206,7 @@ New Features
   * Added support for VLAN set VID offload command.
   * Added support for matching on packets withe Geneve tunnel header.
   * Added hairpin support.
-  * Added ConnectX6-DX support.
+  * Added ConnectX-6 Dx support.
   * Flow engine selected based on RDMA Core library version.
     DV flow engine selected if version is rdma-core-24.0 or higher.
     Verbs flow engine selected otherwise.
@@ -474,9 +474,8 @@ API Changes
 
 * event: The function ``rte_event_eth_tx_adapter_enqueue`` takes an additional
   input as ``flags``. Flag ``RTE_EVENT_ETH_TX_ADAPTER_ENQUEUE_SAME_DEST`` which
-  has been introduced in this release is used when used when all the packets
-  enqueued in the Tx adapter are destined for the same Ethernet port ans Tx
-  queue.
+  has been introduced in this release is used when all the packets enqueued in
+  the Tx adapter are destined for the same Ethernet port and Tx queue.
 
 * sched: The pipe nodes configuration parameters such as number of pipes,
   pipe queue sizes, pipe profiles, etc., are moved from port level structure
@@ -918,3 +917,2313 @@ Tested Platforms
   * OFED:
 
     * MLNX_OFED 4.7-1.0.0.2
+
+19.11.1 Release Notes
+---------------------
+
+19.11.1 Fixes
+~~~~~~~~~~~~~
+
+* acl: fix 32-bit match for range field
+* app/eventdev: fix pipeline test with meson build
+* app/pdump: fix build with clang
+* app/testpmd: add port check before manual detach
+* app/testpmd: call cleanup on exit
+* app/testpmd: fix device mcast list error handling
+* app/testpmd: fix GENEVE flow item
+* app/testpmd: fix hot-unplug detaching
+* app/testpmd: fix identifier size for port attach
+* app/testpmd: fix initial value when setting PFC
+* app/testpmd: fix RFC addresses for Tx only
+* app/testpmd: fix txonly flow generation entropy
+* app/testpmd: fix uninitialized members of MPLS
+* app/testpmd: fix uninitialized members when setting PFC
+* app/testpmd: rename function for detaching by devargs
+* app/testpmd: update Rx offload after setting MTU
+* app/test: remove meson dependency on file in /sys
+* bpf: fix headers install with meson
+* build: explicitly enable sse4 for meson
+* build: fix libm detection in meson
+* build: remove unneeded function versioning
+* bus/fslmc: remove conflicting memory barrier macro
+* cfgfile: fix symbols map
+* ci: fix Travis config warnings
+* ci: use meson 0.47.1
+* common/cpt: check cipher and auth keys are set
+* common/cpt: fix component for empty IOV buffer
+* crypto/armv8: fix clang build
+* crypto/ccp: fix queue alignment
+* crypto/dpaa_sec: fix IOVA conversions
+* crypto/octeontx2: add kmod dependency info
+* devtools: add fixes flag to commit listing
+* devtools: fix debug build test
+* doc: add module EEPROM dump to mlx5 features
+* doc: clarify memory write combining in mlx5 guide
+* doc: fix build with python 3.8
+* doc: fix devargs in OCTEON TX2 event device guide
+* doc: fix igb_uio parameter in ntb guide
+* doc: fix multi-producer enqueue figure in ring guide
+* doc: fix naming of Mellanox devices
+* doc: fix quiescent state description in RCU guide
+* doc: fix typos in 19.11 release notes
+* doc: fix warning with meson
+* doc: reduce indentation in meson build file
+* doc: reduce whitespace in meson build file
+* doc: update recommended versions for i40e
+* drivers/crypto: fix session-less mode
+* eal/linux: fix build error on RHEL 7.6
+* eal/linux: fix build when VFIO is disabled
+* eal/linux: fix uninitialized data valgrind warning
+* eal/windows: fix cpuset macro name
+* ethdev: fix callback unregister with wildcard argument list
+* ethdev: fix flow API doxygen comment
+* ethdev: fix secondary process memory overwrite
+* ethdev: fix switching domain allocation
+* ethdev: fix VLAN offloads set if no driver callback
+* event/dpaa2: set number of order sequences
+* event/dsw: avoid credit leak on oversized enqueue bursts
+* event/dsw: flush buffers immediately on zero-sized enqueue
+* event/octeontx2: fix device name in device info
+* examples/ethtool: fix unchecked return value
+* examples/fips_validation: fix AES-GCM cipher length parsing
+* examples/fips_validation: fix cipher length for AES-GCM
+* examples/fips_validation: fix string token for CT length
+* examples/ioat: fix failure check for ioat dequeue
+* examples/ioat: fix invalid link status check
+* examples/ioat: fix unchecked return value
+* examples/ipsec-secgw: extend inline session to non AES-GCM
+* examples/ipsec-secgw: fix crash on unsupported algo
+* examples/l2fwd-event: fix core allocation in poll mode
+* examples/l2fwd-event: fix error checking
+* examples/l2fwd-event: fix ethdev RSS setup
+* examples/l2fwd-event: fix event device config
+* examples/l3fwd-power: fix a typo
+* examples/l3fwd-power: fix interrupt disable
+* examples/ntb: fix mempool ops setting
+* examples/power: fix ack for enable/disable turbo
+* examples/tep_term: remove redundant info get
+* examples/vhost_blk: check unused value on init
+* examples/vhost_blk: fix check of device path
+* fib: fix possible integer overflow
+* fix Mellanox copyright and SPDX tag
+* hash: fix lock-free flag doxygen
+* hash: fix meson headers packaging
+* kni: fix build with Linux 5.6
+* kni: fix meson warning about console keyword
+* kni: fix not contiguous FIFO
+* kni: rename variable with namespace prefix
+* latency: fix calculation for multi-thread
+* lib: fix unnecessary double negation
+* maintainers: resign from flow API maintenance
+* maintainers: update for failsafe and PCI library
+* mem: fix munmap in error unwind
+* mempool: fix anonymous populate
+* mempool: fix populate with small virtual chunks
+* mempool: fix slow allocation of large pools
+* mempool/octeontx: fix error handling in initialization
+* mk: avoid combining -r and -export-dynamic linker options
+* net/af_xdp: fix fill queue addresses
+* net/af_xdp: fix maximum MTU
+* net/af_xdp: fix redundant check for wakeup need
+* net/af_xdp: fix umem frame size and headroom
+* net/bnx2x: fix reset of scan FP flag
+* net/bnx2x: fix to sync fastpath Rx queue access
+* net/bnx2x: fix VLAN stripped flag
+* net/bnx2x: support secondary process
+* net/bnxt: add a field for FW capabilities
+* net/bnxt: allow group ID 0 for RSS action
+* net/bnxt: do not log error if stats queried before start
+* net/bnxt: fix alloc filter to use a common routine
+* net/bnxt: fix buffer allocation reattempt
+* net/bnxt: fix bumping of L2 filter reference count
+* net/bnxt: fix crash in port stop while handling events
+* net/bnxt: fix default timeout for getting FW version
+* net/bnxt: fix enable/disable VLAN filtering
+* net/bnxt: fix flow creation
+* net/bnxt: fix flow flush to sync with flow destroy
+* net/bnxt: fix IOVA mapping
+* net/bnxt: fix link during port toggle
+* net/bnxt: fix MAC address setting when port is stopped
+* net/bnxt: fix max rings calculation
+* net/bnxt: fix non matching flow hitting filter rule
+* net/bnxt: fix overwriting error message
+* net/bnxt: fix port stop on error recovery failure
+* net/bnxt: fix probe in FreeBSD
+* net/bnxt: fix race condition when port is stopped
+* net/bnxt: fix recovery alarm race condition in port close
+* net/bnxt: fix request for hot reset support
+* net/bnxt: fix return code handling in VLAN config
+* net/bnxt: fix reusing L2 filter
+* net/bnxt: fix Tx queue profile selection
+* net/bnxt: fix unnecessary delay in port stop
+* net/bnxt: fix VLAN strip
+* net/bnxt: fix VLAN strip flags in SSE Rx
+* net/bnxt: handle HW filter setting when port is stopped
+* net/bnxt: remove a redundant variable
+* net/bnxt: remove redundant if statement
+* net/bnxt: remove redundant macro
+* net/bnxt: remove unnecessary memset
+* net/bnxt: remove unnecessary structure variable
+* net/bnxt: restore MAC filters during reset recovery
+* net/bnxt: restore VLAN filters during reset recovery
+* net/bnxt: use macro for PCI log format
+* net/cxgbe: announce Tx multi-segments offload
+* net/dpaa: fix Rx offload flags on jumbo MTU set
+* net/failsafe: fix reported hash key size in device info
+* net/fm10k: fix descriptor VLAN field filling in Tx
+* net/fm10k: fix non-x86 build
+* net/hns3: fix crash when closing port
+* net/hns3: fix dumping VF register information
+* net/hns3: fix link status on failed query
+* net/hns3: fix ring vector related mailbox command format
+* net/hns3: fix Rx queue search with broadcast packet
+* net/hns3: fix triggering reset procedure in slave process
+* net/i40e/base: add new link speed constants
+* net/i40e/base: fix buffer address
+* net/i40e/base: fix display of FEC settings
+* net/i40e/base: fix error message
+* net/i40e/base: fix missing link modes
+* net/i40e/base: fix retrying logic
+* net/i40e/base: fix Tx descriptors number
+* net/i40e: fix port close in FreeBSD
+* net/i40e: fix Tx when TSO is enabled
+* net/i40e: fix unchecked Tx cleanup error
+* net/i40e: set fixed flag for exact link speed
+* net/iavf: add TSO offload use basic path
+* net/iavf/base: fix adminq return
+* net/iavf/base: fix command buffer memory leak
+* net/iavf: fix Rx total stats
+* net/iavf: fix virtual channel return
+* net/ice: add outer IPv4 matching for GTP-U flow
+* net/ice/base: fix loop limit
+* net/ice/base: increase PF reset wait timeout
+* net/ice: disable TSO offload in vector path
+* net/ice: fix flow director flag
+* net/ice: fix flow director GTP-U pattern
+* net/ice: fix flow director passthru
+* net/ice: fix flow FDIR/switch memory leak
+* net/ice: fix GTP-U rule conflict
+* net/ice: fix packet type table
+* net/ice: fix queue MSI-X interrupt binding
+* net/ice: fix Tx when TSO is enabled
+* net/ice: fix unchecked Tx cleanup error
+* net/ice: fix VSI context
+* net/ice: use ethernet copy API to do MAC assignment
+* net/ipn3ke: fix line side statistics register read
+* net/ipn3ke: fix meson build
+* net/ixgbe: check for illegal Tx packets
+* net/ixgbe: fix blocking system events
+* net/ixgbe: fix flow control mode setting
+* net/ixgbe: fix link status
+* net/ixgbe: fix link up in FreeBSD
+* net/ixgbe: remove dead code
+* net/ixgbe: remove duplicate function declaration
+* net/ixgbe: set fixed flag for exact link speed
+* net/mlx5: add free on completion queue
+* net/mlx5: allow push VLAN without VID
+* net/mlx5: block pop VLAN action on Tx
+* net/mlx5: block push VLAN action on Rx
+* net/mlx5: clean up redundant assignment
+* net/mlx5: engage free on completion queue
+* net/mlx5: fix bit mask to validate push VLAN
+* net/mlx5: fix blocker for push VLAN on Rx
+* net/mlx5: fix build with clang 3.4.2
+* net/mlx5: fix check for VLAN actions
+* net/mlx5: fix crash when meter action conf is null
+* net/mlx5: fix crash when setting hairpin queues
+* net/mlx5: fix dirty array of actions
+* net/mlx5: fix doorbell register offset type
+* net/mlx5: fix encap/decap validation
+* net/mlx5: fix flow match on GRE key
+* net/mlx5: fix GENEVE tunnel flow validation
+* net/mlx5: fix hairpin queue capacity
+* net/mlx5: fix ICMPv6 header rewrite actions
+* net/mlx5: fix ICMPv6 header rewrite action validation
+* net/mlx5: fix inline packet size for ConnectX-4 Lx
+* net/mlx5: fix item flag on GENEVE item validation
+* net/mlx5: fix L3 VXLAN RSS expansion
+* net/mlx5: fix layer flags missing in metadata
+* net/mlx5: fix layer type in header modify action
+* net/mlx5: fix layer validation with decapsulation
+* net/mlx5: fix legacy multi-packet write session
+* net/mlx5: fix masks of encap and decap actions
+* net/mlx5: fix matcher field usage for metadata entities
+* net/mlx5: fix match information in meter
+* net/mlx5: fix matching for ICMP fragments
+* net/mlx5: fix match on ethertype and CVLAN tag
+* net/mlx5: fix memory regions release deadlock
+* net/mlx5: fix metadata item endianness conversion
+* net/mlx5: fix metadata split with encap action
+* net/mlx5: fix meter header modify before decap
+* net/mlx5: fix meter suffix flow
+* net/mlx5: fix modify actions support limitation
+* net/mlx5: fix multiple flow table hash list
+* net/mlx5: fix pop VLAN action validation
+* net/mlx5: fix register usage in meter
+* net/mlx5: fix running without Rx queue
+* net/mlx5: fix setting of port ID for egress rules
+* net/mlx5: fix setting of Rx hash fields
+* net/mlx5: fix shared metadata matcher field setup
+* net/mlx5: fix tunnel flow priority
+* net/mlx5: fix Tx burst routines set
+* net/mlx5: fix VLAN actions in meter
+* net/mlx5: fix VLAN ID action offset
+* net/mlx5: fix VLAN match for DV mode
+* net/mlx5: fix VLAN VID action validation
+* net/mlx5: fix VXLAN-GPE item translation
+* net/mlx5: fix zero out UDP checksum in encap data
+* net/mlx5: make FDB default rule optional
+* net/mlx5: move Tx complete request routine
+* net/mlx5: optimize Rx hash fields conversion
+* net/mlx5: support maximum flow id allocation
+* net/mlx5: unify validation of drop action
+* net/mlx5: update description of validation functions
+* net/mlx5: update Tx error handling routine
+* net/mlx: add static ibverbs linkage with meson
+* net/mlx: fix build with clang 9
+* net/mlx: fix overlinking with meson and glue dlopen
+* net/mlx: rename meson variable for dlopen option
+* net/mlx: workaround static linkage with meson
+* net/netvsc: disable before changing RSS parameters
+* net/netvsc: fix crash in secondary process
+* net/netvsc: fix RSS offload flag
+* net/netvsc: initialize link state
+* net/octeontx2: fix flow control initial state
+* net/octeontx2: fix getting supported packet types
+* net/octeontx2: fix PTP
+* net/octeontx2: fix PTP and HIGIG2 coexistence
+* net/octeontx2: fix Tx flow control for HIGIG
+* net/octeontx2: fix VF configuration
+* net/octeontx: fix memory leak of MAC address table
+* net/qede/base: fix number of ports per engine
+* net/qede: do not stop vport if not started
+* net/qede: fix VF reload
+* net/sfc: fix log format specifiers
+* net/tap: fix memory leak when unregister intr handler
+* net/vhost: allocate interface name from heap
+* net/vhost: check creation failure
+* net/vhost: delay driver setup
+* net/vhost: fix probing in secondary process
+* net/vhost: fix setup error path
+* net/vhost: prevent multiple setups on reconfiguration
+* net/virtio-user: check file descriptor before closing
+* net/virtio-user: check tap offload setting failure
+* net/virtio-user: do not close tap when disabling queue pairs
+* net/virtio-user: do not reset virtqueues for split ring
+* net/virtio-user: fix packed ring server mode
+* raw/ntb: fix write memory barrier
+* service: don't walk out of bounds when checking services
+* test/common: fix log2 check
+* test/compress: replace test vector
+* test/crypto: fix missing operation status check
+* test/event: fix OCTEON TX2 event device name
+* test/event: fix unintended vdev creation
+* test: fix build without ring PMD
+* test/ipsec: fix a typo in function name
+* usertools: fix syntax warning in python 3.8
+* usertools: fix telemetry client with python 3
+* vfio: fix mapping failures in ppc64le
+* vhost: catch overflow causing mmap of size 0
+* vhost: check message header size read
+* vhost/crypto: fix fetch size
+* vhost: do not treat empty socket message as error
+* vhost: fix crash on port deletion
+* vhost: fix deadlock on port deletion
+* vhost: fix inflight resubmit check
+* vhost: fix packed virtqueue ready condition
+* vhost: fix socket initial value
+* vhost: flush shadow Tx if no more packets
+* vhost: protect log address translation in IOTLB update
+
+19.11.1 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Red Hat(R) Testing
+
+   * Platform
+
+      * RHEL 8
+      * Kernel 4.18
+      * Qemu 4.2
+      * X540-AT2 NIC(ixgbe, 10G)
+
+   * Functionality
+
+      * Guest with device assignment(PF) throughput testing(1G hugepage size)
+      * Guest with device assignment(PF) throughput testing(2M hugepage size)
+      * Guest with device assignment(VF) throughput testing
+      * PVP (host dpdk testpmd as vswitch) 1Q: throughput testing
+      * PVP vhost-user 2Q throughput testing
+      * PVP vhost-user 1Q - cross numa node  throughput testing
+      * Guest with vhost-user 2 queues throughput testing
+      * vhost-user reconnect with dpdk-client, qemu-server: qemu reconnect
+      * PVP 1Q live migration testing
+      * PVP 1Q cross numa node live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing (2M)
+      * Guest with ovs+dpdk+vhost-user 2Q live migration testing
+
+* Intel(R) Testing
+
+   * Basic Intel(R) NIC(ixgbe, i40e and ice) testing
+      * PF (i40e)
+      * PF (ixgbe)
+      * PF (ice)
+      * VF
+      * Compile Testing
+      * Intel NIC single core/NIC performance
+
+   * Basic cryptodev and virtio testing
+
+      * cryptodev
+      * vhost/virtio basic loopback, PVP and performance test
+
+* Mellanox(R) Testing
+
+   * Basic functionality with testpmd
+
+      * Tx/Rx
+      * xstats
+      * Timestamps
+      * Link status
+      * RTE flow and flow_director
+      * RSS
+      * VLAN stripping and insertion
+      * Checksum/TSO
+      * ptype
+      * l3fwd-power example application
+      * Multi-process example applications
+
+   * ConnectX-5
+
+      * RHEL 7.4
+      * Kernel 3.10.0-693.el7.x86_64
+      * Driver MLNX_OFED_LINUX-5.0-1.0.0.0
+      * fw 16.27.1016
+
+   * ConnectX-4 Lx
+
+      * RHEL 7.4
+      * Kernel 3.10.0-693.el7.x86_64
+      * Driver MLNX_OFED_LINUX-5.0-1.0.0.0
+      * fw 14.27.1016
+
+* Broadcom(R) Testing
+
+   * Functionality
+
+      * Tx/Rx
+      * Link status
+      * RSS
+      * Checksum/TSO
+      * VLAN filtering
+      * statistics
+      * MTU
+
+   * Platform
+
+      * BCM57414 NetXtreme-E 10Gb/25Gb Ethernet Controller, Firmware: 216.1.169.0
+      * BCM57508 NetXtreme-E 10Gb/25Gb/40Gb/50Gb/100Gb/200Gb Ethernet, Firmware : 216.0.314.0
+
+* IBM(R) Testing
+
+   * Functionality
+
+      * Basic PF on Mellanox
+      * Single port stability test using l3fwd (16 cpus) and TRex, tested 64
+        and 1500 byte packets at a 0.0% drop rate for 4 hours each
+      * Performance: no degradation compared to 19.11.0
+
+   * Platform
+
+      * Ubuntu 18.04.4 LTS
+      * Kernel 4.15.0-88-generic
+      * IBM Power9 Model 8335-101 CPU: 2.3 (pvr 004e 1203)
+      * Mellanox Technologies MT28800 Family [ConnectX-5 Ex], firmware version: 16.26.4012, MLNX_OFED_LINUX-4.7-3.2.9.1
+
+19.11.2 Release Notes
+---------------------
+
+19.11.2 Fixes
+~~~~~~~~~~~~~
+
+* 2cf9c470eb vhost: check log mmap offset and size overflow (CVE-2020-10722)
+* 8e9652b0b6 vhost: fix translated address not checked (CVE-2020-10723)
+* 95e1f29c26 vhost/crypto: validate keys lengths (CVE-2020-10724)
+* 963b6eea05 vhost: fix potential memory space leak (CVE-2020-10725)
+* c9c630a117 vhost: fix potential fd leak (CVE-2020-10726)
+* cd0ea71bb6 vhost: fix vring index check (CVE-2020-10726)
+
+19.11.2 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Red Hat(R) Testing
+
+   * Platform
+
+      * RHEL 8.3
+      * Kernel 4.18
+      * Qemu 4.2
+      * X540-AT2 NIC(ixgbe, 10G)
+
+   * Functionality
+
+      * PVP (host dpdk testpmd as vswitch) 1Q: throughput testing
+      * PVP vhost-user 2Q throughput testing
+      * PVP vhost-user 1Q - cross numa node  throughput testing
+      * PVP 1Q live migration testing
+      * PVP 1Q cross numa node live migration testing
+
+* Intel(R) Testing
+
+   * Virtio features
+
+      * vhost/virtio loopback test with virtio user as server mode
+      * loopback multi queues
+      * loopback multi paths port restart
+      * vhost/virtio pvp multi-paths performance
+      * pvp multi-queues and port restart
+      * vhost dequeue zero copy
+      * pvp share lib
+      * pvp vhost user reconnect
+      * pvp test with 4k pages
+      * pvp test with 2M hugepages
+      * pvp virtio bonding
+      * pvp test with diff qemu version
+      * vhost enqueue interrupt
+      * vhost event idx interrupt
+      * vhost virtio pmd interrupt
+      * vhost virtio user interrupt
+      * virtio event idx interrupt
+      * virtio user for container networking
+      * virtio user as exceptional path
+      * vhost xstats
+      * virtio-pmd multi-process
+      * vm2vm virtio pmd
+      * vm2vm virtio-net iperf
+      * vm2vm virtio-user
+      * vhost user live migration
+
+19.11.3 Release Notes
+---------------------
+
+19.11.3 Fixes
+~~~~~~~~~~~~~
+
+* app/crypto-perf: fix display of sample test vector
+* app/eventdev: check Tx adapter service ID
+* app: fix usage help of options separated by dashes
+* app/pipeline: fix build with gcc 10
+* app: remove extra new line after link duplex
+* app/testpmd: add parsing for QinQ VLAN headers
+* app/testpmd: fix DCB set
+* app/testpmd: fix memory failure handling for i40e DDP
+* app/testpmd: fix PPPoE flow command
+* app/testpmd: fix statistics after reset
+* baseband/turbo_sw: fix exposed LLR decimals assumption
+* bbdev: fix doxygen comments
+* build: disable gcc 10 zero-length-bounds warning
+* build: fix linker warnings with clang on Windows
+* build: support MinGW-w64 with Meson
+* buildtools: get static mlx dependencies for meson
+* bus/fslmc: fix dereferencing null pointer
+* bus/fslmc: fix size of qman fq descriptor
+* bus/pci: fix devargs on probing again
+* bus/pci: fix UIO resource access from secondary process
+* bus/vmbus: fix comment spelling
+* ci: fix telemetry dependency in Travis
+* common/iavf: update copyright
+* common/mlx5: fix build with -fno-common
+* common/mlx5: fix build with rdma-core 21
+* common/mlx5: fix netlink buffer allocation from stack
+* common/mlx5: fix umem buffer alignment
+* common/octeontx: fix gcc 9.1 ABI break
+* common/qat: fix GEN3 marketing name
+* contigmem: cleanup properly when load fails
+* crypto/caam_jr: fix check of file descriptors
+* crypto/caam_jr: fix IRQ functions return type
+* crypto/ccp: fix fd leak on probe failure
+* cryptodev: add asymmetric session-less feature name
+* cryptodev: fix missing device id range checking
+* cryptodev: fix SHA-1 digest enum comment
+* crypto/kasumi: fix extern declaration
+* crypto/nitrox: fix CSR register address generation
+* crypto/nitrox: fix oversized device name
+* crypto/octeontx2: fix build with gcc 10
+* crypto/openssl: fix out-of-place encryption
+* crypto/qat: fix cipher descriptor for ZUC and SNOW
+* crypto/qat: support plain SHA1..SHA512 hashes
+* devtools: fix symbol map change check
+* doc: add i40e limitation for flow director
+* doc: add NASM installation steps
+* doc: fix API index
+* doc: fix build issue in ABI guide
+* doc: fix build with doxygen 1.8.18
+* doc: fix default symbol binding in ABI guide
+* doc: fix log level example in Linux guide
+* doc: fix LTO config option
+* doc: fix matrix CSS for recent sphinx
+* doc: fix multicast filter feature announcement
+* doc: fix number of failsafe sub-devices
+* doc: fix reference in ABI guide
+* doc: fix sphinx compatibility
+* doc: fix typo in contributors guide
+* doc: fix typo in contributors guide
+* doc: fix typos in ABI policy
+* doc: prefer https when pointing to dpdk.org
+* drivers: add crypto as dependency for event drivers
+* drivers/crypto: disable gcc 10 no-common errors
+* drivers/crypto: fix build with make 4.3
+* drivers/crypto: fix log type variables for -fno-common
+* drivers: fix log type variables for -fno-common
+* eal/arm64: fix precise TSC
+* eal: fix C++17 compilation
+* eal: fix comments spelling
+* eal: fix log message print for regex
+* eal: fix PRNG init with HPET enabled
+* eal: fix typo in endian conversion macros
+* eal/freebsd: fix queuing duplicate alarm callbacks
+* eal/ppc: fix bool type after altivec include
+* eal/ppc: fix build with gcc 9.3
+* eal/x86: ignore gcc 10 stringop-overflow warnings
+* ethdev: fix build when vtune profiling is on
+* ethdev: fix spelling
+* eventdev: fix probe and remove for secondary process
+* event/dsw: avoid reusing previously recorded events
+* event/dsw: fix enqueue burst return value
+* event/dsw: remove redundant control ring poll
+* event/dsw: remove unnecessary read barrier
+* event/octeontx2: fix build for O1 optimization
+* event/octeontx2: fix queue removal from Rx adapter
+* examples/eventdev: fix build with gcc 10
+* examples/eventdev: fix crash on exit
+* examples/fips_validation: fix parsing of algorithms
+* examples/ip_pipeline: remove check of null response
+* examples/ipsec-gw: fix gcc 10 maybe-uninitialized warning
+* examples/kni: fix crash during MTU set
+* examples/kni: fix MTU change to setup Tx queue
+* examples/l2fwd-keepalive: fix mbuf pool size
+* examples/qos_sched: fix build with gcc 10
+* examples: remove extra new line after link duplex
+* examples/vhost_blk: fix build with gcc 10
+* examples/vmdq: fix output of pools/queues
+* examples/vmdq: fix RSS configuration
+* examples/vm_power: drop Unix path limit redefinition
+* examples/vm_power: fix build with -fno-common
+* fib: fix headers for C++ support
+* fix same typo in multiple places
+* fix various typos found by Lintian
+* ipsec: check SAD lookup error
+* ipsec: fix build dependency on hash lib
+* kvargs: fix buffer overflow when parsing list
+* kvargs: fix invalid token parsing on FreeBSD
+* kvargs: fix strcmp helper documentation
+* log: fix level picked with globbing on type register
+* lpm6: fix comments spelling
+* lpm6: fix size of tbl8 group
+* mem: fix overflow on allocation
+* mem: mark pages as not accessed when freeing memory
+* mem: mark pages as not accessed when reserving VA
+* mempool/dpaa2: install missing header with meson
+* mempool/octeontx2: fix build for gcc O1 optimization
+* mempool: remove inline functions from export list
+* mem: preallocate VA space in no-huge mode
+* mk: fix static linkage of mlx dependency
+* net/avp: fix gcc 10 maybe-uninitialized warning
+* net/bnxt: do not use PMD log type
+* net/bnxt: fix error log for command timeout
+* net/bnxt: fix FW version query
+* net/bnxt: fix HWRM command during FW reset
+* net/bnxt: fix max ring count
+* net/bnxt: fix memory leak during queue restart
+* net/bnxt: fix number of TQM ring
+* net/bnxt: fix port start failure handling
+* net/bnxt: fix possible stack smashing
+* net/bnxt: fix Rx ring producer index
+* net/bnxt: fix storing MAC address twice
+* net/bnxt: fix TQM ring context memory size
+* net/bnxt: fix using RSS config struct
+* net/bnxt: fix VLAN add when port is stopped
+* net/bnxt: fix VNIC Rx queue count on VNIC free
+* net/bnxt: use true/false for bool types
+* net/dpaa2: fix 10G port negotiation
+* net/dpaa2: fix congestion ID for multiple traffic classes
+* net/dpaa: use dynamic log type
+* net/e1000: fix port hotplug for multi-process
+* net/ena/base: fix documentation of functions
+* net/ena/base: fix indentation in CQ polling
+* net/ena/base: fix indentation of multiple defines
+* net/ena/base: fix testing for supported hash function
+* net/ena/base: make allocation macros thread-safe
+* net/ena/base: prevent allocation of zero sized memory
+* net/ena: fix build for O1 optimization
+* net/ena: set IO ring size to valid value
+* net/enetc: fix Rx lock-up
+* net/enic: fix flow action reordering
+* net/failsafe: fix fd leak
+* net/hinic: allocate IO memory with socket id
+* net/hinic/base: fix PF firmware hot-active problem
+* net/hinic/base: fix port start during FW hot update
+* net/hinic: fix LRO
+* net/hinic: fix queues resource free
+* net/hinic: fix repeating cable log and length check
+* net/hinic: fix snprintf length of cable info
+* net/hinic: fix TSO
+* net/hinic: fix Tx mbuf length while copying
+* net/hns3: add free threshold in Rx
+* net/hns3: add RSS hash offload to capabilities
+* net/hns3: clear residual flow rules on init
+* net/hns3: fix configuring illegal VLAN PVID
+* net/hns3: fix configuring RSS hash when rules are flushed
+* net/hns3: fix crash when flushing RSS flow rules with FLR
+* net/hns3: fix default error code of command interface
+* net/hns3: fix default VLAN filter configuration for PF
+* net/hns3: fix mailbox opcode data type
+* net/hns3: fix MSI-X interrupt during initialization
+* net/hns3: fix packets offload features flags in Rx
+* net/hns3: fix promiscuous mode for PF
+* net/hns3: fix return value of setting VLAN offload
+* net/hns3: fix return value when clearing statistics
+* net/hns3: fix RSS indirection table configuration
+* net/hns3: fix RSS key length
+* net/hns3: fix Rx interrupt after reset
+* net/hns3: fix status after repeated resets
+* net/hns3: fix Tx interrupt when enabling Rx interrupt
+* net/hns3: fix VLAN filter when setting promisucous mode
+* net/hns3: fix VLAN PVID when configuring device
+* net/hns3: reduce judgements of free Tx ring space
+* net/hns3: remove one IO barrier in Rx
+* net/hns3: remove unnecessary assignments in Tx
+* net/hns3: replace memory barrier with data dependency order
+* net/hns3: support different numbers of Rx and Tx queues
+* net/hns3: support Rx interrupt
+* net/i40e/base: update copyright
+* net/i40e: fix flow director enabling
+* net/i40e: fix flow director for ARP packets
+* net/i40e: fix flow director initialisation
+* net/i40e: fix flush of flow director filter
+* net/i40e: fix queue region in RSS flow
+* net/i40e: fix queue related exception handling
+* net/i40e: fix setting L2TAG
+* net/i40e: fix wild pointer
+* net/i40e: fix X722 performance
+* net/i40e: relax barrier in Tx
+* net/i40e: relax barrier in Tx for NEON
+* net/iavf: fix link speed
+* net/iavf: fix setting L2TAG
+* net/iavf: fix stats query error code
+* net/ice: add action number check for switch
+* net/ice/base: check memory pointer before copying
+* net/ice/base: fix binary order for GTPU filter
+* net/ice/base: fix MAC write command
+* net/ice/base: fix uninitialized stack variables
+* net/ice/base: minor fixes
+* net/ice/base: read PSM clock frequency from register
+* net/ice/base: remove unused code in switch rule
+* net/ice/base: update copyright
+* net/ice: change default tunnel type
+* net/ice: fix crash in switch filter
+* net/ice: fix hash flow crash
+* net/ice: fix input set of VLAN item
+* net/ice: fix RSS advanced rule
+* net/ice: fix RSS for GTPU
+* net/ice: fix setting L2TAG
+* net/ice: fix variable initialization
+* net/ice: remove bulk alloc option
+* net/ice: remove unnecessary variable
+* net/ice: support mark only action for flow director
+* net/ipn3ke: use control thread to check link status
+* net/ixgbe/base: update copyright
+* net/ixgbe: check driver type in MACsec API
+* net/ixgbe: fix link state timing on fiber ports
+* net/ixgbe: fix link status after port reset
+* net/ixgbe: fix link status inconsistencies
+* net/ixgbe: fix link status synchronization on BSD
+* net/ixgbe: fix resource leak after thread exits normally
+* net/ixgbe: fix statistics in flow control mode
+* net/memif: fix init when already connected
+* net/memif: fix resource leak
+* net/mlx4: fix build with -fno-common
+* net/mlx4: fix drop queue error handling
+* net/mlx5: add device parameter for MPRQ stride size
+* net/mlx5: add multi-segment packets in MPRQ mode
+* net/mlx5: enable MPRQ multi-stride operations
+* net/mlx5: fix actions validation on root table
+* net/mlx5: fix assert in doorbell lookup
+* net/mlx5: fix assert in dynamic metadata handling
+* net/mlx5: fix assert in modify converting
+* net/mlx5: fix build with separate glue lib for dlopen
+* net/mlx5: fix call to modify action without init item
+* net/mlx5: fix counter container usage
+* net/mlx5: fix crash when releasing meter table
+* net/mlx5: fix CVLAN tag set in IP item translation
+* net/mlx5: fix doorbell bitmap management offsets
+* net/mlx5: fix gcc 10 enum-conversion warning
+* net/mlx5: fix header modify action validation
+* net/mlx5: fix imissed counter overflow
+* net/mlx5: fix jump table leak
+* net/mlx5: fix mask used for IPv6 item validation
+* net/mlx5: fix matching for UDP tunnels with Verbs
+* net/mlx5: fix match on empty VLAN item in DV mode
+* net/mlx5: fix metadata for compressed Rx CQEs
+* net/mlx5: fix meter color register consideration
+* net/mlx5: fix meter suffix table leak
+* net/mlx5: fix packet length assert in MPRQ
+* net/mlx5: fix push VLAN action to use item info
+* net/mlx5: fix RSS enablement
+* net/mlx5: fix RSS key copy to TIR context
+* net/mlx5: fix Tx queue release debug log timing
+* net/mlx5: fix validation of push VLAN without full mask
+* net/mlx5: fix validation of VXLAN/VXLAN-GPE specs
+* net/mlx5: fix VLAN flow action with wildcard VLAN item
+* net/mlx5: fix VLAN ID check
+* net/mlx5: fix VLAN PCP item calculation
+* net/mlx5: fix zero metadata action
+* net/mlx5: fix zero value validation for metadata
+* net/mlx5: improve logging of MPRQ selection
+* net/mlx5: reduce Tx completion index memory loads
+* net/mlx5: set dynamic flow metadata in Rx queues
+* net/mlx5: update VLAN and encap actions validation
+* net/mlx5: use open/read/close for ib stats query
+* net/mvneta: do not use PMD log type
+* net/mvpp2: fix build with gcc 10
+* net/netvsc: avoid possible live lock
+* net/netvsc: do not configure RSS if disabled
+* net/netvsc: do RSS across Rx queue only
+* net/netvsc: fix comment spelling
+* net/netvsc: fix memory free on device close
+* net/netvsc: handle Rx packets during multi-channel setup
+* net/netvsc: handle Tx completions based on burst size
+* net/netvsc: propagate descriptor limits from VF
+* net/netvsc: remove process event optimization
+* net/netvsc: split send buffers from Tx descriptors
+* net/nfp: fix dangling pointer on probe failure
+* net/nfp: fix log format specifiers
+* net/null: fix secondary burst function selection
+* net/null: remove redundant check
+* net/octeontx2: disable unnecessary error interrupts
+* net/octeontx2: enable error and RAS interrupt in configure
+* net/octeontx2: fix buffer size assignment
+* net/octeontx2: fix device configuration sequence
+* net/octeontx2: fix link information for loopback port
+* net/octeontx: fix dangling pointer on init failure
+* net/octeontx: fix meson build for disabled drivers
+* net/pfe: do not use PMD log type
+* net/pfe: fix double free of MAC address
+* net/qede: fix link state configuration
+* net/qede: fix port reconfiguration
+* net/ring: fix device pointer on allocation
+* net/sfc/base: fix build when EVB is enabled
+* net/sfc/base: fix manual filter delete in EF10
+* net/sfc/base: handle manual and auto filter clashes in EF10
+* net/sfc/base: reduce filter priorities to implemented only
+* net/sfc/base: refactor filter lookup loop in EF10
+* net/sfc/base: reject automatic filter creation by users
+* net/sfc/base: use simpler EF10 family conditional check
+* net/sfc/base: use simpler EF10 family run-time checks
+* net/sfc: fix initialization error path
+* net/sfc: fix promiscuous and allmulticast toggles errors
+* net/sfc: fix reported promiscuous/multicast mode
+* net/sfc: fix Rx queue start failure path
+* net/sfc: set priority of created filters to manual
+* net/softnic: fix memory leak for thread
+* net/softnic: fix resource leak for pipeline
+* net/tap: do not use PMD log type
+* net/tap: fix check for mbuf number of segment
+* net/tap: fix crash in flow destroy
+* net/tap: fix fd leak on creation failure
+* net/tap: fix file close on remove
+* net/tap: fix mbuf and mem leak during queue release
+* net/tap: fix mbuf double free when writev fails
+* net/tap: fix queues fd check before close
+* net/tap: fix unexpected link handler
+* net/tap: remove unused assert
+* net/thunderx: use dynamic log type
+* net/vhost: fix potential memory leak on close
+* net/virtio: do not use PMD log type
+* net/virtio: fix crash when device reconnecting
+* net/virtio: fix outdated comment
+* net/virtio: fix unexpected event after reconnect
+* net/virtio-user: fix devargs parsing
+* net/vmxnet3: fix RSS setting on v4
+* net/vmxnet3: handle bad host framing
+* pci: accept 32-bit domain numbers
+* pci: fix build on FreeBSD
+* pci: fix build on ppc
+* pci: reject negative values in PCI id
+* pci: remove unneeded includes in public header file
+* remove references to private PCI probe function
+* Revert "common/qat: fix GEN3 marketing name"
+* Revert "net/bnxt: fix number of TQM ring"
+* Revert "net/bnxt: fix TQM ring context memory size"
+* security: fix crash at accessing non-implemented ops
+* security: fix return types in documentation
+* security: fix session counter
+* security: fix verification of parameters
+* service: fix crash on exit
+* service: fix identification of service running on other lcore
+* service: fix race condition for MT unsafe service
+* service: remove rte prefix from static functions
+* telemetry: fix port stats retrieval
+* test/crypto: fix flag check
+* test/crypto: fix statistics case
+* test: fix build with gcc 10
+* test/flow_classify: enable multi-sockets system
+* test/ipsec: fix crash in session destroy
+* test/kvargs: fix invalid cases check
+* test/kvargs: fix to consider empty elements as valid
+* test: load drivers when required
+* test: remove redundant macro
+* test: skip some subtests in no-huge mode
+* timer: protect initialization with lock
+* usertools: check for pci.ids in /usr/share/misc
+* vfio: fix race condition with sysfs
+* vfio: fix use after free with multiprocess
+* vhost/crypto: add missing user protocol flag
+* vhost: fix packed ring zero-copy
+* vhost: fix peer close check
+* vhost: fix shadowed descriptors not flushed
+* vhost: fix shadow update
+* vhost: fix zero-copy server mode
+* vhost: handle mbuf allocation failure
+* vhost: make IOTLB cache name unique among processes
+* vhost: prevent zero-copy with incompatible client mode
+* vhost: remove unused variable
+
+19.11.3 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Intel(R) Testing
+
+   * Basic Intel(R) NIC(ixgbe, i40e and ice) testing
+      * PF (i40e)
+      * PF (ixgbe)
+      * PF (ice)
+      * VF (i40e)
+      * VF (ixgbe)
+      * VF (ice)
+      * Compile Testing
+      * Intel NIC single core/NIC performance
+
+   * Basic cryptodev and virtio testing
+
+      * vhost/virtio basic loopback, PVP and performance test
+      * cryptodev Function/Performance
+
+* Mellanox(R) Testing
+
+   * Basic functionality with testpmd
+
+      * Tx/Rx
+      * xstats
+      * Timestamps
+      * Link status
+      * RTE flow and flow_director
+      * RSS
+      * VLAN stripping and insertion
+      * Checksum/TSO
+      * ptype
+      * l3fwd-power example application
+      * Multi-process example applications
+
+   * ConnectX-5
+
+      * RHEL 7.4
+      * Driver MLNX_OFED_LINUX-5.0-2.1.8.0
+      * fw 16.27.2008
+
+   * ConnectX-4 Lx
+
+      * RHEL 7.4
+      * Driver MLNX_OFED_LINUX-5.0-2.1.8.0
+      * fw 14.27.1016
+
+* Red Hat(R) Testing
+
+   * Platform
+
+      * RHEL 8
+      * Kernel 4.18
+      * Qemu 4.2
+      * X540-AT2 NIC(ixgbe, 10G)
+
+   * Functionality
+
+      * Guest with device assignment(PF) throughput testing(1G hugepage size)
+      * Guest with device assignment(PF) throughput testing(2M hugepage size)
+      * Guest with device assignment(VF) throughput testing
+      * PVP (host dpdk testpmd as vswitch) 1Q: throughput testing
+      * PVP vhost-user 2Q throughput testing
+      * PVP vhost-user 1Q - cross numa node  throughput testing
+      * Guest with vhost-user 2 queues throughput testing
+      * vhost-user reconnect with dpdk-client, qemu-server: qemu reconnect
+      * PVP 1Q live migration testing
+      * PVP 1Q cross numa node live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing (2M)
+      * Guest with ovs+dpdk+vhost-user 2Q live migration testing
+      * Allocate memory from the NUMA node which Virtio device locates
+
+
+* Intel(R) Testing with Open vSwitch
+
+   * OVS testing with OVS branches master and 2.13 with VSPERF
+
+   * Tested NICs
+
+      * i40e (X710)
+      * ixgbe (82599ES)
+      * ice
Louis Abel's avatar
Louis Abel committed
14201 14202 14203 14204 14205 14206 14207 14208 14209 14210 14211 14212 14213 14214 14215 14216 14217 14218 14219 14220 14221 14222 14223 14224 14225 14226 14227 14228 14229 14230 14231 14232 14233 14234 14235 14236 14237 14238 14239 14240 14241 14242 14243 14244 14245 14246 14247 14248 14249 14250 14251 14252 14253 14254 14255 14256 14257 14258 14259 14260 14261 14262 14263 14264 14265 14266 14267 14268 14269 14270 14271 14272 14273 14274 14275 14276 14277 14278 14279 14280 14281 14282 14283 14284 14285 14286 14287 14288 14289 14290 14291 14292 14293 14294 14295 14296 14297 14298 14299 14300 14301 14302 14303 14304 14305 14306 14307 14308 14309 14310 14311 14312 14313 14314 14315 14316 14317 14318 14319 14320 14321 14322 14323 14324 14325 14326 14327 14328 14329 14330 14331 14332 14333 14334 14335 14336 14337 14338 14339 14340 14341 14342 14343 14344 14345 14346 14347 14348 14349 14350 14351 14352 14353 14354 14355 14356 14357 14358 14359 14360 14361 14362 14363 14364 14365 14366 14367 14368 14369 14370 14371 14372 14373 14374 14375 14376 14377 14378 14379 14380 14381 14382 14383 14384 14385 14386 14387 14388 14389 14390 14391 14392 14393 14394 14395 14396 14397 14398 14399 14400 14401 14402 14403 14404 14405 14406 14407 14408 14409 14410 14411 14412 14413 14414 14415 14416 14417 14418 14419 14420 14421 14422 14423 14424 14425 14426 14427 14428 14429 14430 14431 14432 14433 14434 14435 14436 14437 14438 14439 14440 14441 14442 14443 14444 14445 14446 14447 14448 14449 14450 14451 14452 14453 14454 14455 14456 14457 14458 14459 14460 14461 14462 14463 14464 14465 14466 14467 14468 14469 14470 14471 14472 14473 14474 14475 14476 14477 14478 14479 14480 14481 14482 14483 14484 14485 14486 14487 14488 14489 14490 14491 14492 14493 14494 14495 14496 14497 14498 14499 14500 14501 14502 14503 14504 14505 14506 14507 14508 14509 14510 14511 14512 14513 14514 14515 14516 14517 14518 14519 14520 14521 14522 14523 14524 14525 14526 14527 14528 14529 14530 14531 14532 14533 14534 14535 14536 14537 14538 14539 14540 14541 14542 14543 14544 14545 14546 14547 14548 14549 14550 14551 14552 14553 14554 14555 14556 14557 14558 14559 14560 14561 14562 14563 14564 14565 14566 14567 14568 14569 14570 14571 14572 14573 14574 14575 14576 14577 14578 14579 14580 14581 14582 14583 14584 14585 14586 14587 14588 14589 14590 14591 14592 14593 14594 14595 14596 14597 14598 14599 14600 14601 14602 14603 14604 14605 14606 14607 14608 14609 14610 14611 14612 14613 14614 14615 14616 14617 14618 14619 14620 14621 14622 14623 14624 14625 14626 14627 14628 14629 14630 14631 14632 14633 14634 14635 14636 14637 14638 14639 14640 14641 14642 14643 14644 14645 14646 14647 14648 14649 14650 14651 14652 14653 14654 14655 14656 14657 14658 14659 14660 14661 14662 14663 14664 14665 14666 14667 14668 14669 14670 14671 14672 14673 14674 14675 14676 14677 14678 14679 14680 14681 14682 14683 14684 14685 14686 14687 14688 14689 14690 14691 14692 14693 14694 14695 14696 14697 14698 14699 14700 14701 14702 14703 14704 14705 14706 14707 14708 14709 14710 14711 14712 14713 14714 14715 14716 14717 14718 14719 14720 14721 14722 14723 14724 14725 14726 14727 14728 14729 14730 14731 14732 14733 14734 14735 14736 14737 14738 14739 14740 14741 14742 14743 14744 14745 14746 14747 14748 14749 14750 14751 14752 14753 14754 14755 14756 14757 14758 14759 14760 14761 14762 14763 14764 14765 14766 14767 14768 14769 14770 14771 14772 14773 14774 14775 14776 14777 14778 14779 14780 14781 14782 14783 14784 14785 14786 14787 14788 14789 14790 14791 14792 14793 14794 14795 14796 14797 14798 14799 14800 14801 14802 14803 14804 14805 14806 14807 14808 14809 14810 14811 14812 14813 14814 14815 14816 14817 14818 14819 14820 14821 14822 14823 14824 14825 14826 14827 14828 14829 14830 14831 14832 14833 14834 14835 14836 14837 14838 14839 14840 14841 14842 14843 14844 14845 14846 14847 14848 14849 14850 14851 14852 14853 14854 14855 14856 14857 14858 14859 14860 14861 14862 14863 14864 14865 14866 14867 14868 14869 14870 14871 14872 14873 14874 14875 14876 14877 14878 14879 14880 14881 14882 14883 14884 14885 14886 14887 14888 14889 14890 14891 14892 14893 14894 14895 14896 14897 14898 14899 14900 14901 14902 14903 14904 14905 14906 14907 14908 14909 14910 14911 14912 14913 14914 14915 14916 14917 14918 14919 14920 14921 14922 14923 14924 14925 14926 14927 14928 14929 14930 14931 14932 14933 14934 14935 14936 14937 14938 14939 14940 14941 14942 14943 14944 14945 14946 14947 14948 14949 14950 14951 14952 14953 14954 14955 14956 14957 14958 14959 14960 14961 14962 14963 14964 14965 14966 14967 14968 14969 14970 14971 14972 14973 14974 14975 14976 14977 14978 14979 14980 14981 14982 14983 14984 14985 14986 14987 14988 14989 14990 14991 14992 14993 14994 14995 14996 14997 14998 14999 15000 15001 15002 15003 15004 15005 15006 15007 15008 15009 15010 15011 15012 15013 15014 15015 15016 15017 15018 15019 15020 15021 15022 15023 15024 15025 15026 15027 15028 15029 15030 15031 15032 15033 15034 15035 15036 15037 15038 15039 15040 15041 15042 15043 15044 15045 15046 15047 15048 15049 15050 15051 15052 15053 15054 15055 15056 15057 15058 15059 15060 15061 15062 15063 15064 15065 15066 15067 15068 15069 15070 15071 15072 15073 15074 15075 15076 15077 15078 15079 15080 15081 15082 15083 15084 15085 15086 15087 15088 15089 15090 15091 15092 15093 15094 15095 15096 15097 15098 15099 15100 15101 15102 15103 15104 15105 15106 15107 15108 15109 15110 15111 15112 15113 15114 15115 15116 15117 15118 15119 15120 15121 15122 15123 15124 15125 15126 15127 15128 15129 15130 15131 15132 15133 15134 15135 15136 15137 15138 15139 15140 15141 15142 15143 15144 15145 15146 15147 15148 15149 15150 15151 15152 15153 15154 15155 15156 15157 15158 15159 15160 15161 15162 15163 15164 15165 15166 15167 15168 15169 15170 15171 15172 15173 15174 15175 15176 15177 15178 15179 15180 15181 15182 15183 15184 15185 15186 15187 15188 15189 15190 15191 15192 15193 15194 15195 15196 15197 15198 15199 15200 15201 15202 15203 15204 15205 15206 15207 15208 15209 15210 15211 15212 15213 15214 15215 15216 15217 15218 15219 15220 15221 15222 15223 15224 15225 15226 15227 15228 15229 15230 15231 15232 15233 15234 15235 15236 15237 15238 15239 15240 15241 15242 15243 15244 15245 15246 15247 15248 15249 15250 15251 15252 15253 15254 15255 15256 15257 15258 15259 15260 15261 15262 15263 15264 15265 15266 15267 15268 15269 15270 15271 15272 15273 15274 15275 15276 15277 15278 15279 15280 15281 15282 15283 15284 15285 15286 15287 15288 15289 15290 15291 15292 15293 15294 15295 15296 15297 15298 15299 15300 15301 15302 15303 15304 15305 15306 15307 15308 15309 15310 15311 15312 15313 15314 15315 15316 15317 15318 15319 15320 15321 15322 15323 15324 15325 15326 15327 15328 15329 15330 15331 15332 15333 15334 15335 15336 15337 15338 15339 15340 15341 15342 15343 15344 15345 15346 15347 15348 15349 15350 15351 15352 15353 15354 15355 15356 15357 15358 15359 15360 15361 15362 15363 15364 15365 15366 15367 15368 15369 15370 15371 15372 15373 15374 15375 15376 15377 15378 15379 15380 15381 15382 15383 15384 15385 15386 15387 15388 15389 15390 15391 15392 15393 15394 15395 15396 15397 15398 15399 15400 15401 15402 15403 15404 15405 15406 15407 15408 15409 15410 15411 15412 15413 15414 15415 15416 15417 15418 15419 15420 15421 15422 15423 15424 15425 15426 15427 15428 15429 15430 15431 15432 15433 15434 15435 15436 15437 15438 15439 15440 15441 15442 15443 15444 15445 15446 15447 15448 15449 15450 15451 15452 15453 15454 15455 15456 15457 15458 15459 15460 15461 15462 15463 15464 15465 15466 15467 15468 15469 15470 15471 15472 15473 15474 15475 15476 15477 15478 15479 15480 15481 15482 15483 15484 15485 15486 15487 15488 15489 15490 15491 15492 15493 15494 15495 15496 15497 15498 15499 15500 15501 15502 15503 15504 15505 15506 15507 15508 15509 15510 15511 15512 15513 15514 15515 15516 15517 15518 15519 15520 15521 15522 15523 15524 15525 15526 15527 15528 15529 15530 15531 15532 15533 15534 15535 15536 15537 15538 15539 15540 15541 15542 15543 15544 15545 15546 15547 15548 15549 15550 15551 15552 15553 15554 15555 15556 15557 15558 15559 15560 15561 15562 15563 15564 15565 15566 15567 15568 15569 15570 15571 15572 15573 15574 15575 15576 15577 15578 15579 15580 15581 15582 15583 15584 15585 15586 15587 15588 15589 15590 15591 15592 15593 15594 15595 15596 15597 15598 15599 15600 15601 15602 15603 15604 15605 15606 15607 15608 15609 15610 15611 15612 15613 15614 15615 15616 15617 15618 15619 15620 15621 15622 15623 15624 15625 15626 15627 15628 15629 15630 15631 15632 15633 15634 15635 15636 15637 15638 15639 15640 15641 15642 15643 15644 15645 15646 15647 15648 15649 15650 15651 15652 15653 15654 15655 15656 15657 15658 15659 15660 15661 15662 15663 15664 15665 15666 15667 15668 15669 15670 15671 15672 15673 15674 15675 15676 15677 15678 15679 15680 15681 15682 15683 15684 15685 15686 15687 15688 15689 15690 15691 15692 15693 15694 15695 15696 15697 15698 15699 15700 15701 15702 15703 15704 15705 15706 15707 15708 15709 15710 15711 15712 15713 15714 15715 15716 15717 15718 15719 15720 15721 15722 15723 15724 15725 15726 15727 15728 15729 15730 15731 15732 15733 15734 15735 15736 15737 15738 15739 15740 15741 15742 15743 15744 15745 15746 15747 15748 15749 15750 15751 15752 15753 15754 15755 15756 15757 15758 15759 15760 15761 15762 15763 15764 15765 15766 15767 15768 15769 15770 15771 15772 15773 15774 15775 15776 15777 15778 15779 15780 15781 15782 15783 15784 15785 15786 15787 15788 15789 15790 15791 15792 15793 15794 15795 15796 15797 15798 15799 15800 15801 15802 15803 15804 15805 15806 15807 15808 15809 15810 15811 15812 15813 15814 15815 15816 15817 15818 15819 15820 15821 15822 15823 15824 15825 15826 15827 15828 15829 15830 15831 15832 15833 15834 15835 15836 15837 15838 15839 15840 15841 15842 15843 15844 15845 15846 15847 15848 15849 15850 15851 15852 15853 15854 15855 15856 15857 15858 15859 15860 15861 15862 15863 15864 15865 15866 15867 15868 15869 15870 15871 15872 15873 15874 15875 15876 15877 15878 15879 15880 15881 15882 15883 15884 15885 15886 15887 15888 15889 15890 15891 15892 15893 15894 15895 15896 15897 15898 15899 15900 15901 15902 15903 15904 15905 15906 15907 15908 15909 15910 15911 15912 15913 15914 15915 15916 15917 15918 15919 15920 15921 15922 15923 15924 15925 15926 15927 15928 15929 15930 15931 15932 15933 15934 15935 15936 15937 15938 15939 15940 15941 15942 15943 15944 15945 15946 15947 15948 15949 15950 15951 15952 15953 15954 15955 15956 15957 15958 15959 15960 15961 15962 15963 15964 15965 15966 15967 15968 15969 15970 15971 15972 15973 15974 15975 15976 15977 15978 15979 15980 15981 15982 15983 15984 15985 15986 15987 15988 15989 15990 15991 15992 15993 15994 15995 15996 15997 15998 15999 16000 16001 16002 16003 16004 16005 16006 16007 16008 16009 16010 16011 16012 16013 16014 16015 16016 16017 16018 16019 16020 16021 16022 16023 16024 16025 16026 16027 16028 16029 16030 16031 16032 16033 16034 16035 16036 16037 16038 16039 16040 16041 16042 16043 16044 16045 16046 16047 16048 16049 16050 16051 16052 16053 16054 16055 16056 16057 16058 16059 16060 16061 16062 16063 16064 16065 16066 16067 16068 16069 16070 16071 16072 16073 16074 16075 16076 16077 16078 16079 16080 16081 16082 16083 16084 16085 16086 16087 16088 16089 16090 16091 16092 16093 16094 16095 16096 16097 16098 16099 16100 16101 16102 16103 16104 16105 16106 16107 16108 16109 16110 16111 16112 16113 16114 16115 16116 16117 16118 16119 16120 16121 16122 16123 16124 16125 16126 16127 16128 16129 16130 16131 16132 16133 16134 16135 16136 16137 16138 16139 16140 16141 16142 16143 16144 16145 16146 16147 16148 16149 16150 16151 16152 16153 16154 16155 16156 16157 16158 16159 16160 16161 16162 16163 16164 16165 16166 16167 16168 16169 16170 16171 16172 16173 16174 16175 16176 16177 16178 16179 16180 16181 16182 16183 16184 16185 16186 16187 16188 16189 16190 16191 16192 16193 16194 16195 16196 16197 16198 16199 16200
+      * vhost
+
+   * Functionality
+
+      * P2P
+      * PVP
+      * PVPV
+      * PVVP
+      * Multiqueue RSS
+      * Vhost reconnect
+      * Jumbo frames 1500, 6000, 9702
+
+
+* Microsoft(R) Testing
+
+   * Platform
+
+      * Azure
+         * Ubuntu 16.04-LTS
+         * Ubuntu 18.04-DAILY-LTS
+         * RHEL 7-RAW
+         * RHEL 7.5
+         * CentOS 7.5
+         * SLES-15-sp1 gen1
+      * Mellanox(R) ConnectX-4
+      * LISAv2 test framework
+
+   * Functionality
+
+      * VERIFY-DPDK-COMPLIANCE - verifies kernel is supported and that the build is successful
+      * VERIFY-DPDK-BUILD-AND-TESTPMD-TEST - verifies using testpmd that packets can be sent from a VM to another VM
+      * VERIFY-SRIOV-FAILSAFE-FOR-DPDK - disables/enables Accelerated Networking for the NICs under test and makes sure DPDK works in both scenarios
+      * VERIFY-DPDK-FAILSAFE-DURING-TRAFFIC - disables/enables Accelerated Networking for the NICs while generating traffic using testpmd
+      * PERF-DPDK-FWD-PPS-DS15 - verifies DPDK forwarding performance using testpmd on 2, 4, 8 cores, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-SINGLE-CORE-PPS-DS4 - verifies DPDK performance using testpmd on 1 core, rx and io mode on size Standard_DS4_v2
+      * PERF-DPDK-SINGLE-CORE-PPS-DS15 - verifies DPDK performance using testpmd on 1 core, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-MULTICORE-PPS-DS15 - verifies DPDK performance using testpmd on 2, 4, 8 cores, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-MULTICORE-PPS-F32 - verifies DPDK performance using testpmd on 2, 4, 8, 16 cores, rx and io mode on size Standard_F32s_v2
+      * DPDK-RING-LATENCY - verifies DPDK CPU latency using dpdk-ring-ping
+      * VERIFY-DPDK-PRIMARY-SECONDARY-PROCESSES - verifies primary / secondary processes support for DPDK. Runs only on RHEL and Ubuntu distros with Linux kernel >= 4.20
+      * VERIFY-DPDK-OVS - builds OVS with DPDK support and tests if the OVS DPDK ports can be created. Runs only on Ubuntu distro.
+
+19.11.4 Release Notes
+---------------------
+
+19.11.4 Fixes
+~~~~~~~~~~~~~
+
+* app/eventdev: fix capability check in pipeline ATQ test
+* app/testpmd: fix burst percentage calculation
+* app/testpmd: fix CPU cycles per packet stats on Tx modes
+* app/testpmd: fix error detection in MTU command
+* app/testpmd: fix memory leak on error path
+* app/testpmd: fix stats error message
+* app/testpmd: remove hardcoded descriptors limit
+* app/testpmd: use clock time in throughput calculation
+* avoid libfdt checks adding full paths to pkg-config
+* bpf: fix add/sub min/max estimations
+* build: fix drivers library path on Windows
+* bus/dpaa: fix iterating on a class type
+* bus/fslmc: fix getting FD error
+* bus/fslmc: fix iterating on a class type
+* bus/fslmc: fix memory leak in secondary process
+* bus/pci: fix VF memory access
+* bus/vdev: fix a typo in doxygen comment
+* bus/vmbus: fix ring buffer mapping
+* cfgfile: fix stack buffer underflow
+* common/cpt: fix encryption offset
+* common/dpaax: fix 12-bit null auth case
+* common/mlx5: fix code arrangement in tag allocation
+* common/mlx5: fix queue doorbell record size
+* common/mlx5: fix void parameters in glue wrappers
+* common/octeontx2: fix crash on running procinfo
+* common/qat: fix uninitialized variable
+* common/qat: get firmware version
+* common/qat: move max inflights param into qp
+* common/qat: remove tail write coalescing
+* common/qat: support dual threads for enqueue/dequeue
+* crypto/armv8: remove debug option
+* crypto/armv8: use dedicated log type
+* crypto/dpaa2_sec: fix HFN override
+* crypto/dpaax_sec: fix 18-bit PDCP cases with HFN override
+* crypto/dpaax_sec: fix inline query for descriptors
+* crypto/qat: add minimum enq threshold
+* crypto/qat: fix AES-XTS capabilities
+* crypto/qat: handle mixed hash-cipher on GEN2
+* crypto/qat: handle mixed hash-cipher requests on GEN3
+* devtools: fix path in forbidden token check
+* doc: add RIB and FIB into the API index
+* doc: fix a typo in mlx5 guide
+* doc: fix doc build after qat threshold patch
+* doc: fix ethtool app path
+* doc: fix reference to master process
+* doc: fix some typos in Linux guide
+* doc: fix typo in bbdev test guide
+* doc: rebuild with meson whenever a file changes
+* doc: update build instructions in the Linux guide
+* drivers/crypto: add missing OOP feature flag
+* drivers/net: fix exposing internal headers
+* drivers/qat: add handling of capabilities in multi process
+* drivers/qat: add multi process handling of driver id
+* drivers/qat: improve multi process on qat
+* eal/arm: add vcopyq intrinsic for aarch32
+* eal/armv8: fix timer frequency calibration with PMU
+* eal: fix lcore accessors for non-EAL threads
+* eal: fix parentheses in alignment macros
+* eal: fix uuid header dependencies
+* eal/linux: fix epoll fd list rebuild for interrupts
+* eal: remove redundant newline in alert message
+* eal/windows: fix symbol export
+* ethdev: fix data room size verification in Rx queue setup
+* ethdev: fix log type for some error messages
+* ethdev: fix VLAN offloads set if no relative capabilities
+* eventdev: fix race condition on timer list counter
+* eventdev: relax SMP barriers with C11 atomics
+* eventdev: remove redundant reset on timer cancel
+* eventdev: use C11 atomics for lcore timer armed flag
+* event/dpaa2: add all-types queue capability flag
+* event/dpaa: remove dead code
+* event/octeontx2: fix device reconfigure
+* event/octeontx2: fix sub event type
+* examples: add flush after stats printing
+* examples/eventdev: fix 32-bit coremask
+* examples/fips_validation: fix count overwrite for TDES
+* examples/fips_validation: fix parsing of TDES vectors
+* examples/fips_validation: fix TDES interim callback
+* examples/packet_ordering: use proper exit method
+* hash: fix out-of-memory handling in hash creation
+* kni: fix reference to master/slave process
+* lib: remind experimental status in headers
+* mbuf: fix boundary check at dynamic field registration
+* mbuf: fix dynamic field dump log
+* mbuf: fix error code in dynamic field/flag registration
+* mbuf: fix free space update for dynamic field
+* mbuf: remove unused next member in dynamic flag/field
+* mem: fix 32-bit init config with meson
+* mempool: fix allocation in memzone during retry
+* meter: remove inline functions from export list
+* net/af_packet: fix check of file descriptors
+* net/af_packet: fix memory leak on init failure
+* net/af_packet: fix munmap on init failure
+* net/af_xdp: remove mempool freeing on umem destruction
+* net/bnxt: fix flow error on filter creation
+* net/bnxt: fix freeing filters on flow creation failure
+* net/bnxt: fix logical AND in if condition
+* net/bnxt: fix performance for Arm
+* net/bnxt: fix unnecessary HWRM command
+* net/bnxt: remove unused enum declaration
+* net/bonding: change state machine to defaulted
+* net/bonding: delete redundant code
+* net/bonding: fix dead loop on RSS RETA update
+* net/bonding: fix error code on device creation
+* net/bonding: fix LACP negotiation
+* net/bonding: fix MAC address when one port resets
+* net/bonding: fix MAC address when switching active port
+* net/bonding: fix socket ID check
+* net/cxgbe: fix CLIP leak in filter error path
+* net/cxgbe: fix double MPS alloc by flow validate and create
+* net/cxgbe: fix L2T leak in filter error and free path
+* net/dpaa: fix FD offset data type
+* net/e1000: fix crash on Tx done clean up
+* net/e1000: report VLAN extend capability
+* net/failsafe: fix RSS RETA size info
+* net: fix checksum on big endian CPUs
+* net: fix IPv4 checksum
+* net: fix pedantic build
+* net: fix unneeded replacement of TCP checksum 0
+* net/hinic/base: avoid system time jump
+* net/hinic/base: check output of management sync channel
+* net/hinic/base: remove unused function parameters
+* net/hinic: check memory allocations in flow creation
+* net/hinic: fix setting promiscuous mode
+* net/hinic: optimize Rx performance for x86
+* net/hns3: add RSS hash offload to Rx configuration
+* net/hns3: check multi-process action register result
+* net/hns3: clear promiscuous on PF uninit
+* net/hns3: clear residual hardware configurations on init
+* net/hns3: fix adding multicast MAC address
+* net/hns3: fix flow director error message
+* net/hns3: fix key length when configuring RSS
+* net/hns3: fix RSS configuration on empty RSS type
+* net/hns3: fix Rx buffer size
+* net/hns3: fix Tx less than 60 bytes
+* net/hns3: fix unintended sign extension in dump operation
+* net/hns3: fix unintended sign extension in fd operation
+* net/hns3: fix VLAN strip configuration when setting PVID
+* net/hns3: fix VLAN tags reported in Rx
+* net/hns3: get link status change through mailbox
+* net/hns3: ignore function return on reset error path
+* net/hns3: optimize default RSS algorithm
+* net/hns3: remove restriction on setting VF MTU
+* net/hns3: remove unnecessary branch
+* net/hns3: remove unsupported VLAN capabilities
+* net/i40e: enable NEON Rx/Tx in meson
+* net/i40e: enable QinQ stripping
+* net/i40e: fix binding interrupt without MSI-X vector
+* net/i40e: fix filter pctype
+* net/i40e: fix flow director MSI-X resource allocation
+* net/i40e: fix flow director Rx writeback packet
+* net/i40e: fix getting EEPROM information
+* net/i40e: fix queue pairs configuration in VF
+* net/i40e: remove duplicate tunnel type check
+* net/i40e: report VLAN filter capability
+* net/i40e: support aarch32
+* net/iavf: fix RSS RETA after restart
+* net/iavf: fix uninitialized variable
+* net/ice: add input set byte number check
+* net/ice: add memory allocation check in RSS init
+* net/ice/base: fix GTP-U inner RSS IPv4 IPv6 co-exist
+* net/ice/base: fix initializing resource for field vector
+* net/ice/base: fix memory leak on error path
+* net/ice/base: fix memory leak on GTPU RSS
+* net/ice/base: fix reference count on VSI list update
+* net/ice/base: fix return value
+* net/ice/base: fix RSS interference
+* net/ice/base: fix RSS removal for GTP-U
+* net/ice/base: fix VSI ID mask to 10 bits
+* net/ice: calculate TCP header size for offload
+* net/ice: fix bytes statistics
+* net/ice: fix error log in generic flow
+* net/ice: fix memory leak when releasing VSI
+* net/ice: fix switch action number check
+* net/ice: fix TCP checksum offload
+* net/ice: fix Tx hang with TSO
+* net/ice: revert fake TSO fixes
+* net/ixgbe/base: fix host interface shadow RAM read
+* net/ixgbe/base: fix infinite recursion on PCIe link down
+* net/ixgbe/base: fix x550em 10G NIC link status
+* net/ixgbe/base: remove dead code
+* net/ixgbe: fix flow control status
+* net/ixgbe: fix include of vector header file
+* net/ixgbe: fix MAC control frame forward
+* net/ixgbe: report 10Mbps link speed for x553
+* net/kni: set packet input port in Rx
+* net/mlx4: optimize stack memory size in probe
+* net/mlx5: do not select legacy MPW implicitly
+* net/mlx5: fix counter query
+* net/mlx5: fix crash in NVGRE item translation
+* net/mlx5: fix descriptors number adjustment
+* net/mlx5: fix flow items size calculation
+* net/mlx5: fix flow META item validation
+* net/mlx5: fix hairpin Rx queue creation error flow
+* net/mlx5: fix hairpin Tx queue creation error flow
+* net/mlx5: fix HW counters path in switchdev mode
+* net/mlx5: fix initialization of steering registers
+* net/mlx5: fix interrupt installation timing
+* net/mlx5: fix iterator type in Rx queue management
+* net/mlx5: fix LRO checksum
+* net/mlx5: fix metadata storing for NEON Rx
+* net/mlx5: fix secondary process resources release
+* net/mlx5: fix tunnel flow priority
+* net/mlx5: fix typos in meter error messages
+* net/mlx5: fix UAR lock sharing for multiport devices
+* net/mlx5: fix unnecessary init in mark conversion
+* net/mlx5: fix unreachable MPLS error path
+* net/mlx5: fix vectorized Rx burst termination
+* net/mlx5: fix VF MAC address set over BlueField
+* net/mlx5: fix VLAN pop with decap action validation
+* net/mlx5: fix VLAN push action on hairpin queue
+* net/mlx5: remove ineffective increment in hairpin split
+* net/mlx5: remove needless Tx queue initialization check
+* net/mlx5: remove redundant newline from logs
+* net/mvpp2: fix non-EAL thread support
+* net/netvsc: do not query VF link state
+* net/netvsc: do not spin forever waiting for reply
+* net/netvsc: fix chimney index
+* net/netvsc: fix crash during Tx
+* net/netvsc: fix underflow when Rx external mbuf
+* net/netvsc: fix warning when VF is removed
+* net/nfp: fix RSS hash configuration reporting
+* net/octeontx2: fix DMAC filtering
+* net/qede: fix multicast drop in promiscuous mode
+* net/qede: remove dead code
+* net/sfc: do not enforce hash offload in RSS multi-queue
+* net/virtio-user: check tap system call setting
+* net/virtio-user: fix status management
+* pci: fix address domain format size
+* rawdev: allow getting info for unknown device
+* rawdev: export dump function in map file
+* rawdev: fill NUMA socket ID in info
+* rawdev: remove remaining experimental tags
+* raw/ifpga/base: fix NIOS SPI init
+* raw/ifpga/base: fix SPI transaction
+* rib: add C++ include guard
+* sched: fix 64-bit rate
+* sched: fix port time rounding
+* sched: fix subport freeing
+* service: fix C++ linkage
+* service: fix core mapping reset
+* service: fix lcore iteration
+* test: allow no-huge mode for fast-tests
+* test/bpf: fix few small issues
+* test/crypto: add mixed encypted-digest
+* test/crypto: change cipher offset for ESN vector
+* test/crypto: fix asymmetric session mempool creation
+* test/cycles: restore default delay callback
+* test: fix build with ring PMD but no bond PMD
+* test: fix rpath for drivers with meson
+* test/hash: move lock-free tests to perf tests
+* test/mbuf: fix a dynamic flag log
+* test/ring: fix statistics in bulk enq/dequeue
+* version: 19.11.4-rc1
+* vfio: map contiguous areas in one go
+* vfio: remove unused variable
+* vhost: fix double-free with zero-copy
+* vhost: fix features definition location
+* vhost: fix virtio ready flag check
+* vhost: remove zero-copy and client mode restriction
+
+19.11.4 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Canonical(R) Testing
+
+   * Build tests on all Ubuntu architectures
+   * OVS-DPDK tests on x86_64
+
+* Red Hat(R) Testing
+
+   * Platform
+
+      * RHEL 8
+      * Kernel 4.18
+      * Qemu 5.1
+      * X540-AT2 NIC(ixgbe, 10G)
+
+   * Functionality
+
+      * Guest with device assignment(PF) throughput testing(1G hugepage size)
+      * Guest with device assignment(PF) throughput testing(2M hugepage size)
+      * Guest with device assignment(VF) throughput testing
+      * PVP (host dpdk testpmd as vswitch) 1Q: throughput testing
+      * PVP vhost-user 2Q throughput testing
+      * PVP vhost-user 1Q - cross numa node  throughput testing
+      * Guest with vhost-user 2 queues throughput testing
+      * vhost-user reconnect with dpdk-client, qemu-server: qemu reconnect
+      * PVP 1Q live migration testing
+      * PVP 1Q cross numa node live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing (2M)
+      * Guest with ovs+dpdk+vhost-user 2Q live migration testing
+      * Allocate memory from the NUMA node which Virtio device locates
+      * Host PF + DPDK testing
+      * Host VF + DPDK testing
+
+* Intel(R) Testing
+
+   * Basic Intel(R) NIC(ixgbe, i40e and ice) testing
+      * PF (i40e)
+      * PF (ixgbe)
+      * PF (ice)
+      * VF (i40e)
+      * VF (ixgbe)
+      * VF (ice)
+      * Compile Testing
+      * Intel NIC single core/NIC performance
+
+   * Basic cryptodev and virtio testing
+
+      * vhost/virtio basic loopback, PVP and performance test
+      * cryptodev Function/Performance
+
+
+* Intel(R) Testing with Open vSwitch
+
+   * OVS testing with OVS branches master and 2.13 with VSPERF
+
+   * Tested NICs
+
+      * i40e (X710)
+      * ixgbe (82599ES)
+      * ice
+      * vhost user client
+
+   * Functionality
+
+      *  Performance tests
+      *  vHost zero-copy
+      *  Flow control
+      *  RSS
+      *  Partial HW offloading
+
+* Mellanox(R) Testing
+
+   * Basic functionality with testpmd
+
+      * Tx/Rx
+      * xstats
+      * Timestamps
+      * Link status
+      * RTE flow and flow_director
+      * RSS
+      * VLAN stripping and insertion
+      * Checksum/TSO
+      * ptype
+      * l3fwd-power example application
+      * Multi-process example applications
+
+   * ConnectX-5
+
+      * RHEL 7.4
+      * Driver MLNX_OFED_LINUX-5.1-0.6.6.0
+      * fw 16.28.1002
+
+   * ConnectX-4 Lx
+
+      * RHEL 7.4
+      * Driver MLNX_OFED_LINUX-5.1-0.6.6.0
+      * fw 14.28.1002
+
+
+* Microsoft(R) Testing
+
+   * Platform
+
+      * Azure
+         * Ubuntu 16.04-LTS
+         * Ubuntu 18.04-DAILY-LTS
+         * RHEL 7-RAW
+         * RHEL 7.5
+         * CentOS 7.5
+         * SLES-15-sp1 gen1
+      * Mellanox(R) ConnectX-4
+      * LISAv2 test framework
+
+   * Functionality
+
+      * VERIFY-DPDK-COMPLIANCE - verifies kernel is supported and that the build is successful
+      * VERIFY-DPDK-BUILD-AND-TESTPMD-TEST - verifies using testpmd that packets can be sent from a VM to another VM
+      * VERIFY-SRIOV-FAILSAFE-FOR-DPDK - disables/enables Accelerated Networking for the NICs under test and makes sure DPDK works in both scenarios
+      * VERIFY-DPDK-FAILSAFE-DURING-TRAFFIC - disables/enables Accelerated Networking for the NICs while generating traffic using testpmd
+      * PERF-DPDK-FWD-PPS-DS15 - verifies DPDK forwarding performance using testpmd on 2, 4, 8 cores, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-SINGLE-CORE-PPS-DS4 - verifies DPDK performance using testpmd on 1 core, rx and io mode on size Standard_DS4_v2
+      * PERF-DPDK-SINGLE-CORE-PPS-DS15 - verifies DPDK performance using testpmd on 1 core, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-MULTICORE-PPS-DS15 - verifies DPDK performance using testpmd on 2, 4, 8 cores, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-MULTICORE-PPS-F32 - verifies DPDK performance using testpmd on 2, 4, 8, 16 cores, rx and io mode on size Standard_F32s_v2
+      * DPDK-RING-LATENCY - verifies DPDK CPU latency using dpdk-ring-ping
+      * VERIFY-DPDK-PRIMARY-SECONDARY-PROCESSES - verifies primary / secondary processes support for DPDK. Runs only on RHEL and Ubuntu distros with Linux kernel >= 4.20
+      * VERIFY-DPDK-OVS - builds OVS with DPDK support and tests if the OVS DPDK ports can be created. Runs only on Ubuntu distro.
+
+19.11.4 Known Issues
+~~~~~~~~~~~~~~~~~~~~
+
+* ICE
+
+   * Exception on VF port reset
+   * MD5 is not same between kernel ethtool and dpdk ethtool when testing
+     userspace_ethtool/retrieve_eeprom
+
+* vhost/virtio
+
+   * udp-fragmentation-offload cannot be setup on Ubuntu 19.10 VMs.
+     https://bugzilla.kernel.org/show_bug.cgi?id=207075
+   * l3fwd-power can wake up lcore, but then cannot sleep again
+
+* cryptodev
+
+   * fips_cryptodev test fails for TDES
+
+* vdev_netvsc
+
+   * hot-removal of VF driver can fail
+
+19.11.5 Release Notes
+---------------------
+
+19.11.5 Fixes
+~~~~~~~~~~~~~
+
+* vhost/crypto: fix data length check (CVE-2020-14374)
+* vhost/crypto: fix incorrect descriptor deduction (CVE-2020-14378)
+* vhost/crypto: fix incorrect write back source
+* vhost/crypto: fix missed request check for copy mode (CVE-2020-14376 CVE-2020-14377)
+* vhost/crypto: fix pool allocation
+* vhost/crypto: fix possible TOCTOU attack (CVE-2020-14375)
+
+19.11.5 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Intel(R) Testing
+
+   * Basic cryptodev testing
+
+      * vhost_crypto Unit test and Function/Performance test
+
+19.11.6 Release Notes
+---------------------
+
+19.11.6 Fixes
+~~~~~~~~~~~~~
+
+* acl: fix x86 build for compiler without AVX2
+* app/bbdev: fix test vector symlink
+* app/eventdev: check timer adadpters number
+* app: fix ethdev port id size
+* app: fix missing dependencies
+* app/testpmd: do not allow dynamic change of core number
+* app/testpmd: fix bonding xmit balance policy command
+* app/testpmd: fix build with gcc 11
+* app/testpmd: fix descriptor id check
+* app/testpmd: fix displaying Rx/Tx queues information
+* app/testpmd: fix max Rx packet length for VLAN packet
+* app/testpmd: fix MTU after device configure
+* app/testpmd: fix name of bitrate library in meson build
+* app/testpmd: fix packet header in txonly mode
+* app/testpmd: fix port id check in Tx VLAN command
+* app/testpmd: fix RSS key for flow API RSS rule
+* app/testpmd: fix VLAN configuration on failure
+* app/testpmd: remove restriction on Tx segments set
+* app/testpmd: revert max Rx packet length adjustment
+* app/testpmd: revert setting MTU explicitly after configure
+* app/test-sad: fix uninitialized variable
+* baseband/fpga_lte_fec: fix crash with debug
+* baseband/turbo_sw: fix memory leak in error path
+* build: fix gcc warning requiring Wformat
+* build: fix install on Windows
+* build: fix MS linker flag with meson 0.54
+* build: skip detecting libpcap via pcap-config
+* bus/dpaa: fix fd check before close
+* bus/dpaa: remove logically dead code
+* bus/fslmc: fix atomic queues on NXP LX2 platform
+* bus/fslmc: fix dpio close
+* bus/fslmc: fix VFIO group descriptor check
+* bus/pci: fix leak on VFIO mapping error
+* bus/pci: fix memory leak when unmapping VFIO resource
+* bus/pci: remove duplicate declaration
+* bus/pci: remove unused scan by address
+* common/mlx5: fix DevX SQ object creation
+* common/mlx5: fix name for ConnectX VF device ID
+* common/mlx5: fix PCI address lookup
+* common/qat: add missing kmod dependency info
+* compress/isal: check allocation in queue setup
+* config: add Graviton2(arm64) defconfig
+* config: enable packet prefetching with Meson
+* crypto/aesni_mb: fix CCM digest size check
+* crypto/aesni_mb: fix GCM digest size check
+* crypto/armv8: fix mempool object returning
+* crypto/caam_jr: fix device tree parsing for SEC_ERA
+* cryptodev: fix parameter parsing
+* crypto/dpaa2_sec: fix stats query without queue pair
+* crypto/dpaa2_sec: remove dead code
+* crypto/dpaa_sec: fix a null pointer dereference
+* crypto/octeontx2: fix multi-process
+* crypto/octeontx2: fix out-of-place support
+* crypto/octeontx2: fix session-less mode
+* crypto/octeontx: fix out-of-place support
+* crypto/scheduler: fix header install with meson
+* crypto/scheduler: remove unused internal seqn
+* devtools: fix build test config inheritance from env
+* devtools: fix directory filter in forbidden token check
+* devtools: fix x86-default build test install env
+* distributor: fix API documentation
+* distributor: fix buffer use after free
+* distributor: fix clearing returns buffer
+* distributor: fix flushing in flight packets
+* distributor: fix handshake deadlock
+* distributor: fix handshake synchronization
+* distributor: fix return pkt calls in single mode
+* distributor: fix scalar matching
+* distributor: handle worker shutdown in burst mode
+* doc: add SPDX license tag header to Intel performance guide
+* doc: add SPDX license tag header to meson guide
+* doc: clarify instructions on running as non-root
+* doc: fix diagram in dpaa2 guide
+* doc: fix EF10 Rx mode name in sfc guide
+* doc: fix ethdev port id size
+* doc: fix formatting of notes in meson guide
+* doc: fix grammar
+* doc: fix missing classify methods in ACL guide
+* doc: fix rule file parameters in l3fwd-acl guide
+* doc: fix typo in ipsec-secgw guide
+* doc: fix typo in KNI guide
+* doc: fix typo in pcap guide
+* doc: improve multiport PF in nfp guide
+* doc: remove notice about AES-GCM IV and J0
+* doc: remove obsolete deprecation notice for power library
+* doc: update information on using hugepages
+* drivers/net: fix port id size
+* eal/arm: fix build with gcc optimization level 0
+* eal/arm: fix clang build of native target
+* eal: fix doxygen for EAL cleanup
+* eal: fix leak on device event callback unregister
+* eal: fix MCS lock and ticketlock headers install
+* eal/linux: change udev debug message
+* eal/linux: fix memory leak in uevent handling
+* eal/x86: fix memcpy AVX-512 enablement
+* efd: fix tailq entry leak in error path
+* ethdev: fix data type for port id
+* ethdev: fix memory ordering for callback functions
+* ethdev: fix RSS flow expansion in case of mismatch
+* ethdev: move non-offload capabilities
+* ethdev: remove redundant license text
+* eventdev: check allocation in Tx adapter
+* eventdev: fix adapter leak in error path
+* event/dpaa2: fix dereference before null check
+* event/dpaa2: remove dead code from self test
+* event/octeontx2: unlink queues during port release
+* examples/fips_validation: fix buffer overflow
+* examples/fips_validation: fix build with pkg-config
+* examples/fips_validation: fix missed version line
+* examples/fips_validation: fix version compatibility
+* examples: fix flattening directory layout on install
+* examples/ioat: fix stats print
+* examples/ip_pipeline: fix external build
+* examples/ip_pipeline: use POSIX network address conversion
+* examples/ipsec-secgw: use POSIX network address conversion
+* examples/kni: fix build with pkg-config
+* examples/l2fwd-crypto: fix build with pkg-config
+* examples/l2fwd-crypto: fix missing dependency
+* examples/l2fwd-keepalive: skip meson build if no librt
+* examples/l3fwd-power: check packet types after start
+* examples/multi_process: fix build on Ubuntu 20.04
+* examples/ntb: fix clean target
+* examples/performance-thread: fix build with low core count
+* examples/performance-thread: fix build with pkg-config
+* examples/qos_sched: fix usage string
+* examples/rxtx_callbacks: fix build with pkg-config
+* examples/vhost_blk: check driver start failure
+* examples/vhost_blk: fix build with pkg-config
+* examples/vhost_crypto: add new line character in usage
+* examples/vm_power: fix 32-bit build
+* examples/vm_power: fix build on Ubuntu 20.04
+* fix spellings that Lintian complains about
+* gro: fix packet type detection with IPv6 tunnel
+* gso: fix payload unit size for UDP
+* ipc: fix spelling in log and comment
+* kni: fix build on RHEL 8.3
+* kni: fix build with Linux 5.9
+* license: add licenses for exception cases
+* maintainers: update Mellanox emails
+* malloc: fix style in free list index computation
+* mbuf: fix dynamic fields and flags with multiprocess
+* mbuf: fix typo in dynamic field convention note
+* mcslock: fix hang in weak memory model
+* mem: fix allocation failure on non-NUMA kernel
+* mem: fix allocation in container with SELinux
+* mem: fix config name in error logs
+* mempool/octeontx: fix aura to pool mapping
+* net/af_xdp: avoid deadlock due to empty fill queue
+* net/af_xdp: change return value from Rx to unsigned
+* net/af_xdp: fix pointer storage size
+* net/af_xdp: fix umem size
+* net/af_xdp: use strlcpy instead of strncpy
+* net/bnx2x: add QLogic vendor id for BCM57840
+* net/bnxt: add memory allocation check in VF info init
+* net/bnxt: add separate mutex for FW health check
+* net/bnxt: fix boolean operator usage
+* net/bnxt: fix checking VNIC in shutdown path
+* net/bnxt: fix crash in vector mode Tx
+* net/bnxt: fix doorbell barrier location
+* net/bnxt: fix drop enable in get Rx queue info
+* net/bnxt: fix endianness while setting L4 destination port
+* net/bnxt: fix L2 filter allocation
+* net/bnxt: fix link status during device recovery
+* net/bnxt: fix link update
+* net/bnxt: fix LRO configuration
+* net/bnxt: fix memory leak when freeing VF info
+* net/bnxt: fix queue get info
+* net/bnxt: fix queue release
+* net/bnxt: fix resetting mbuf data offset
+* net/bnxt: fix Rx performance by removing spinlock
+* net/bnxt: fix shift operation
+* net/bnxt: fix structure variable initialization
+* net/bnxt: fix vnic Rx queue cnt updation
+* net/bnxt: fix xstats by id
+* net/bnxt: increase size of Rx CQ
+* net/bnxt: remove useless prefetches
+* net/bonding: fix possible unbalanced packet receiving
+* net/bonding: fix Rx queue conversion
+* net: check segment pointer in raw checksum processing
+* net/cxgbe: fix crash when accessing empty Tx mbuf list
+* net/cxgbe: fix duplicate MAC addresses in MPS TCAM
+* net/cxgbe: fix queue DMA ring leaks during port close
+* net/dpaa2: fix build with timesync functions
+* net/dpaa2: fix misuse of interface index
+* net/dpaa: fix port ID type in API
+* net/ena/base: align IO CQ allocation to 4K
+* net/ena/base: fix release of wait event
+* net/ena/base: specify delay operations
+* net/ena/base: use min/max macros with type conversion
+* net/ena: fix getting xstats global stats offset
+* net/ena: fix setting Rx checksum flags in mbuf
+* net/ena: remove unused macro
+* net/enic: fix header sizes when copying flow patterns
+* net/enic: generate VXLAN src port if it is zero in template
+* net/enic: ignore VLAN inner type when it is zero
+* net/failsafe: fix double space in warning log
+* net/failsafe: fix state synchro cleanup
+* net/fm10k: fix memory leak when thresh check fails
+* net/fm10k: fix memory leak when Tx thresh check fails
+* net/fm10k: fix vector Rx
+* net/hinic/base: add message check for command channel
+* net/hinic/base: fix clock definition with glibc version
+* net/hinic/base: fix log info for PF command channel
+* net/hinic/base: get default cos from chip
+* net/hinic/base: remove queue number limitation
+* net/hinic/base: support two or more AEQS for chip
+* net/hinic: fix filters on memory allocation failure
+* net/hinic: fix negative array index read
+* net/hinic: fix Rx nombuf stats
+* net/hinic: remove optical module operation
+* net/hns3: check PCI config space reads
+* net/hns3: check PCI config space write
+* net/hns3: check setting VF PCI bus return value
+* net/hns3: decrease non-nearby memory access in Rx
+* net/hns3: fix configurations of port-level scheduling rate
+* net/hns3: fix configuring device with RSS enabled
+* net/hns3: fix config when creating RSS rule after flush
+* net/hns3: fix crash with multi-TC
+* net/hns3: fix data type to store queue number
+* net/hns3: fix default MAC address from firmware
+* net/hns3: fix deleting default VLAN from PF
+* net/hns3: fix error type when validating RSS flow action
+* net/hns3: fix flow error type
+* net/hns3: fix flow RSS queue number 0
+* net/hns3: fix flushing RSS rule
+* net/hns3: fix out of bounds access
+* net/hns3: fix queue offload capability
+* net/hns3: fix reassembling multiple segment packets in Tx
+* net/hns3: fix RSS max queue id allowed in multi-TC
+* net/hns3: fix some incomplete command structures
+* net/hns3: fix storing RSS info when creating flow action
+* net/hns3: fix TX checksum with fix header length
+* net/hns3: reduce address calculation in Rx
+* net/hns3: report Rx drop packets enable configuration
+* net/hns3: report Rx free threshold
+* net/hns3: skip VF register access when PF in FLR
+* net/i40e: add C++ include guard
+* net/i40e/base: fix function header arguments
+* net/i40e/base: fix Rx only for unicast promisc on VLAN
+* net/i40e: fix build for log format specifier
+* net/i40e: fix byte counters
+* net/i40e: fix flow director for eth + VLAN pattern
+* net/i40e: fix incorrect FDIR flex configuration
+* net/i40e: fix link status
+* net/i40e: fix QinQ flow pattern to allow non full mask
+* net/i40e: fix recreating flexible flow director rule
+* net/i40e: fix vector Rx
+* net/i40e: fix virtual channel conflict
+* net/iavf: downgrade error log
+* net/iavf: enable port reset
+* net/iavf: fix command after PF reset
+* net/iavf: fix flow flush after PF reset
+* net/iavf: fix iterator for RSS LUT
+* net/iavf: fix performance drop after port reset
+* net/iavf: fix port start during configuration restore
+* net/iavf: fix releasing mbufs
+* net/iavf: fix scattered Rx enabling
+* net/iavf: fix setting of MAC address
+* net/iavf: fix unchecked Tx cleanup error
+* net/iavf: fix vector Rx
+* net/iavf: support multicast configuration
+* net/ice/base: fix issues around move nodes
+* net/ice/base: fix parameter name in comment
+* net/ice: fix flow validation for unsupported patterns
+* net/ice: fix ptype parsing
+* net/ice: fix Rx offload flags in SSE path
+* net/ice: fix vector Rx
+* net/ice: update writeback policy to reduce latency
+* net/ixgbe: check switch domain allocation result
+* net/ixgbe: fix vector Rx
+* net/ixgbe: fix VF reset HW error handling
+* net/ixgbe: remove redundant MAC flag check
+* net/memif: do not update local copy of tail in Tx
+* net/memif: relax load of ring head for M2S ring
+* net/memif: relax load of ring head for S2M ring
+* net/memif: relax load of ring tail for M2S ring
+* net/mlx5: fix debug configuration build issue
+* net/mlx5: fix hairpin dependency on destination DevX TIR
+* net/mlx5: fix meter table definitions
+* net/mlx5: fix missing meter packet
+* net/mlx5: fix port shared data reference count
+* net/mlx5: fix raw encap/decap limit
+* net/mlx5: fix representor interrupts handler
+* net/mlx5: fix RSS queue type validation
+* net/mlx5: fix RSS RETA reset on start
+* net/mlx5: fix Rx descriptor status
+* net/mlx5: fix Rx packet padding config via DevX
+* net/mlx5: fix Rx queue completion index consistency
+* net/mlx5: fix Rx queue count calculation
+* net/mlx5: fix Rx queue count calculation
+* net/mlx5: fix switch port id when representor in bonding
+* net/mlx5: fix xstats reset reinitialization
+* net/mlx5: free MR resource on device DMA unmap
+* net/mlx5: remove unused includes
+* net/mlx5: remove unused log macros
+* net/mlx5: remove unused variable in Tx queue creation
+* net/mlx5: validate MPLSoGRE with GRE key
+* net/mlx: do not enforce RSS hash offload
+* net/mvpp2: fix memory leak in error path
+* net/netvsc: allocate contiguous physical memory for RNDIS
+* net/netvsc: check for overflow on packet info from host
+* net/netvsc: disable external mbuf on Rx by default
+* net/netvsc: fix multiple channel Rx
+* net/netvsc: fix rndis packet addresses
+* net/netvsc: fix stale value after free
+* net/netvsc: fix Tx queue leak in error path
+* net/netvsc: manage VF port under read/write lock
+* net/netvsc: replace compiler builtin overflow check
+* net/nfp: expand device info get
+* net/octeontx2: fix multi segment mode for jumbo packets
+* net/octeontx2: fix RSS flow create
+* net/octeontx2: remove useless check before free
+* net/pcap: fix crash on exit for infinite Rx
+* net/pcap: fix input only Rx
+* net/pfe: fix misuse of interface index
+* net/qede: fix dereference before null check
+* net/qede: fix getting link details
+* net/qede: fix milliseconds sleep macro
+* net/ring: check internal arguments
+* net/ring: fix typo in log message
+* net/sfc/base: fix tunnel configuration
+* net/sfc: fix RSS hash flag when offload is disabled
+* net/sfc: fix RSS hash offload if queue action is used
+* net/softnic: use POSIX network address conversion
+* net/tap: free mempool when closing
+* net/thunderx: fix memory leak on rbdr desc ring failure
+* net/vdev_netvsc: fix device probing error flow
+* net/vhost: fix xstats after clearing stats
+* net/virtio: check raw checksum failure
+* net/virtio: fix packed ring indirect descricptors setup
+* pmdinfogen: fix build with gcc 11
+* port: remove useless assignment
+* power: fix current frequency index
+* raw/dpaa2_qdma: fix reset
+* raw/ifpga/base: fix interrupt handler instance usage
+* raw/ifpga/base: fix return of IRQ unregister
+* raw/ifpga/base: handle unsupported interrupt type
+* raw/ifpga: terminate string filled by readlink with null
+* raw/ifpga: use trusted buffer to free
+* raw/ioat: fix missing close function
+* raw/skeleton: allow closing already closed device
+* raw/skeleton: reset test statistics
+* rcu: avoid literal suffix warning in C++ mode
+* Revert "app/testpmd: fix name of bitrate library in meson build"
+* Revert "Revert "build: always link whole DPDK static libraries""
+* Revert "Revert "build/pkg-config: improve static linking flags""
+* Revert "Revert "build/pkg-config: move pkg-config file creation""
+* Revert "Revert "build/pkg-config: output drivers first for static build""
+* Revert "Revert "build/pkg-config: prevent overlinking""
+* Revert "Revert "devtools: test static linkage with pkg-config""
+* stack: fix uninitialized variable
+* stack: reload head when pop fails
+* table: fix hash for 32-bit
+* test/crypto: fix device number
+* test/crypto: fix stats test
+* test/distributor: collect return mbufs
+* test/distributor: ensure all packets are delivered
+* test/distributor: fix freeing mbufs
+* test/distributor: fix lcores statistics
+* test/distributor: fix mbuf leak on failure
+* test/distributor: fix quitting workers in burst mode
+* test/distributor: fix race conditions on shutdown
+* test/distributor: fix shutdown of busy worker
+* test/event_crypto_adapter: fix configuration
+* test/event: fix function arguments for crypto adapter
+* test/mbuf: skip field registration at busy offset
+* test/rcu: fix build with low core count
+* test/ring: fix number of single element enqueue/dequeue
+* timer: add limitation note for sync stop and reset
+* usertools: fix CPU layout script to be PEP8 compliant
+* usertools: fix pmdinfo parsing
+* vdpa/ifc: fix build with recent kernels
+* version: 19.11.6-rc1
+* vfio: fix group descriptor check
+* vhost: fix error path when setting memory tables
+* vhost: fix external mbuf creation
+* vhost: fix fd leak in dirty logging setup
+* vhost: fix fd leak in kick setup
+* vhost: fix IOTLB mempool single-consumer flag
+* vhost: fix virtio-net header length with packed ring
+* vhost: fix virtqueue initialization
+* vhost: fix virtqueues metadata allocation
+* vhost: validate index in available entries API
+* vhost: validate index in guest notification API
+* vhost: validate index in inflight API
+* vhost: validate index in live-migration API
+
+19.11.6 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Intel(R) Testing
+
+   * Basic Intel(R) NIC(ixgbe, i40e and ice) testing
+      * PF (i40e)
+      * PF (ixgbe)
+      * PF (ice)
+      * VF (i40e)
+      * VF (ixgbe)
+      * VF (ice)
+      * Compile Testing
+      * Intel NIC single core/NIC performance
+
+   * Basic cryptodev and virtio testing
+
+      * vhost/virtio basic loopback, PVP and performance test
+      * cryptodev Function/Performance
+
+
+* Microsoft(R) Testing
+
+   * Platform
+
+      * Azure
+         * Ubuntu 16.04-LTS
+         * Ubuntu 18.04-DAILY-LTS
+         * RHEL 7.5
+         * Openlogic CentOS 7.5
+         * SLES-15-sp1 gen1
+      * Mellanox(R) ConnectX-4
+      * LISAv2 test framework
+
+   * Functionality
+
+      * VERIFY-DPDK-COMPLIANCE       * verifies kernel is supported and that the build is successful
+      * VERIFY-DPDK-BUILD-AND-TESTPMD-TEST       * verifies using testpmd that packets can be sent from a VM to another VM
+      * VERIFY-SRIOV-FAILSAFE-FOR-DPDK       * disables/enables Accelerated Networking for the NICs under test and makes sure DPDK works in both scenarios
+      * VERIFY-DPDK-FAILSAFE-DURING-TRAFFIC       * disables/enables Accelerated Networking for the NICs while generating traffic using testpmd
+      * PERF-DPDK-FWD-PPS-DS15       * verifies DPDK forwarding performance using testpmd on 2, 4, 8 cores, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-SINGLE-CORE-PPS-DS4       * verifies DPDK performance using testpmd on 1 core, rx and io mode on size Standard_DS4_v2
+      * PERF-DPDK-SINGLE-CORE-PPS-DS15       * verifies DPDK performance using testpmd on 1 core, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-MULTICORE-PPS-DS15       * verifies DPDK performance using testpmd on 2, 4, 8 cores, rx and io mode on size Standard_DS15_v2
+      * PERF-DPDK-MULTICORE-PPS-F32       * verifies DPDK performance using testpmd on 2, 4, 8, 16 cores, rx and io mode on size Standard_F32s_v2
+      * DPDK-RING-LATENCY       * verifies DPDK CPU latency using dpdk-ring-ping
+      * VERIFY-DPDK-OVS       * builds OVS with DPDK support and tests if the OVS DPDK ports can be created. Runs only on Ubuntu distro.
+      * VERIFY-DPDK-BUILD-AND-NETVSCPMD-TEST       * verifies using testpmd with netvsc pmd that packets can be sent from a VM to another VM.
+      * VERIFY-SRIOV-FAILSAFE-FOR-DPDK-NETVSCPMD       * disables/enables Accelerated Networking for the NICs under test and makes sure DPDK with netvsc pmd works in both scenarios.
+      * VERIFY-DPDK-FAILSAFE-DURING-TRAFFIC-NETVSCPMD       * Verify Accelerated Networking (VF) removed and readded for the NICs while generating traffic using testpmd with netvsc pmd.
+
+
+* Red Hat(R) Testing
+
+   * Platform
+
+      * RHEL 8
+      * Kernel 4.18
+      * Qemu 5.2
+      * X540-AT2 NIC(ixgbe, 10G)
+
+   * Functionality
+
+      * Guest with device assignment(PF) throughput testing(1G hugepage size)
+      * Guest with device assignment(PF) throughput testing(2M hugepage size)
+      * Guest with device assignment(VF) throughput testing
+      * PVP (host dpdk testpmd as vswitch) 1Q: throughput testing
+      * PVP vhost-user 2Q throughput testing
+      * PVP vhost-user 1Q       * cross numa node  throughput testing
+      * Guest with vhost-user 2 queues throughput testing
+      * vhost-user reconnect with dpdk-client, qemu-server: qemu reconnect
+      * vhost-user reconnect with dpdk-client, qemu-server: ovs reconnect: PASS
+      * PVP 1Q live migration testing
+      * PVP 1Q cross numa node live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing (2M)
+      * Guest with ovs+dpdk+vhost-user 2Q live migration testing
+      * Allocate memory from the NUMA node which Virtio device locates
+      * Host PF + DPDK testing
+      * Host VF + DPDK testing
+
+
+* Intel(R) Testing with Open vSwitch
+
+   * OVS testing with OVS 2.14.1
+
+   * Performance
+
+      * ICE Device
+
+         * Basic performance tests (RFC2544 P2P, PVP_CONT, RFC2544 PVP_TPUT, RFC2544 PVVP_TPUT, PVPV) Jumbo frames RSS
+
+      * i40e Device
+
+         * Basic performance (RFC2544 P2P, PVP_CONT, RFC2544 PVP_TPUT, RFC2544 PVVP_TPUT, PVPV) Jumbo frames RSS Flow control
+
+      * ixgbe Device
+
+         * Basic performance tests (RFC2544 P2P, PVP_CONT, RFC2544 PVP_TPUT, RFC2544 PVVP_TPUT, PVPV) Jumbo frames RSS
+
+   * Functionality
+
+      * vhostuserclient device
+      * jumbo frames
+      * dpdkvhostuserclient re-connect
+      * dpdkvhostuserclient NUMA node
+
+
+* Nvidia(R) Testing
+
+   * Basic functionality with testpmd
+
+      * Tx/Rx
+      * xstats
+      * Timestamps
+      * Link status
+      * RTE flow and flow_director
+      * RSS
+      * VLAN stripping and insertion
+      * Checksum/TSO
+      * ptype
+      * l3fwd-power example application
+      * Multi-process example applications
+
+   * Build tests
+
+      * Ubuntu 20.04 with MLNX_OFED_LINUX-5.1-2.5.8.0.
+      * Ubuntu 20.04 with rdma-core master (6a5c1b7).
+      * Ubuntu 20.04 with rdma-core v28.0.
+      * Ubuntu 18.04 with rdma-core v17.1.
+      * Ubuntu 18.04 with rdma-core master (6a5c1b7) (i386).
+      * Ubuntu 16.04 with rdma-core v22.7.
+      * Fedora 32 with rdma-core v32.0.
+      * CentOS 7 7.9.2009 with rdma-core master (6a5c1b7).
+      * CentOS 7 7.9.2009 with MLNX_OFED_LINUX-5.1-2.5.8.0.
+      * CentOS 8 8.3.2011 with rdma-core master (6a5c1b7).
+      * openSUSE Leap 15.2 with rdma-core v27.1.
+
+   * ConnectX-5
+
+      * RHEL 7.4
+      * Driver MLNX_OFED_LINUX-5.1-2.5.8.0
+      * fw 14.28.2006
+
+   * ConnectX-4 Lx
+
+      * RHEL 7.4
+      * Driver MLNX_OFED_LINUX-5.1-2.5.8.0
+      * fw 16.28.2006
+
+19.11.6 Known Issues
+~~~~~~~~~~~~~~~~~~~~
+
+* i40e
+
+   * rss_to_rte_flow/set_key_keylen: create rule can fail.
+     https://bugs.dpdk.org/show_bug.cgi?id=573
+   * inconsistency with expected queue after creating a flow rule - firmware issue.
+
+* vhost/virtio
+
+   * udp-fragmentation-offload cannot be setup on Ubuntu 19.10 VMs.
+     https://bugzilla.kernel.org/show_bug.cgi?id=207075
+
+* vdev_netvsc
+
+   * hot-removal of VF driver can fail
+
+19.11.7 Release Notes
+---------------------
+
+19.11.7 Fixes
+~~~~~~~~~~~~~
+
+* app/crypto-perf: fix CSV output format
+* app/crypto-perf: fix latency CSV output
+* app/crypto-perf: fix spelling in output
+* app/crypto-perf: remove always true condition
+* app/eventdev: adjust event count order for pipeline test
+* app/eventdev: fix SMP barrier in performance test
+* app/eventdev: remove redundant enqueue in burst Tx
+* app: fix build with extra include paths
+* app/procinfo: fix check on xstats-ids
+* app/procinfo: fix _filters stats reporting
+* app/procinfo: remove useless memset
+* app/testpmd: avoid exit without terminal restore
+* app/testpmd: fix help of metering commands
+* app/testpmd: fix IP checksum calculation
+* app/testpmd: fix key for RSS flow rule
+* app/testpmd: fix max Rx packet length for VLAN packets
+* app/testpmd: fix packets dump overlapping
+* app/testpmd: release flows left before port stop
+* build: fix linker flags on Windows
+* build: fix plugin load on static build
+* build: fix scheduler macro definition for meson
+* build: force pkg-config for dependency detection
+* build: provide suitable error for "both" libraries option
+* common/mlx5: fix pointer cast on Windows
+* common/octeontx2: fix build with SVE
+* crypto/dpaa2_sec: fix memory allocation check
+* doc: fix mark action zero value in mlx5 guide
+* doc: fix product link in hns3 guide
+* doc: fix QinQ flow rules in testpmd guide
+* doc: update flow mark action in mlx5 guide
+* eal/arm: fix debug build with gcc for 128-bit atomics
+* eal: fix MCS lock header include
+* eal: fix reciprocal header include
+* eal/linux: fix handling of error events from epoll
+* ethdev: fix max Rx packet length check
+* ethdev: fix missing header include
+* eventdev: fix a return value comment
+* examples/eventdev: add info output for main core
+* examples/eventdev: check CPU core enabling
+* examples/eventdev: move ethdev stop to the end
+* examples/l3fwd: remove limitation on Tx queue count
+* fbarray: fix overlap check
+* fib: fix missing header includes
+* ip_frag: remove padding length of fragment
+* ipsec: fix missing header include
+* lib/power: fix make build error
+* lpm: fix vector IPv4 lookup
+* mbuf: add C++ include guard for dynamic fields header
+* mbuf: fix missing header include
+* mem: exclude unused memory from core dump
+* net/af_xdp: remove useless assignment
+* net/avp: remove always true condition
+* net/bnxt: disable end of packet padding for Rx
+* net/bnxt: fix cleanup on mutex init failure
+* net/bnxt: fix doorbell write ordering
+* net/bnxt: fix fallback mbuf allocation logic
+* net/bnxt: fix FW version log
+* net/bnxt: fix max rings computation
+* net/bnxt: fix memory leak when mapping fails
+* net/bnxt: fix null termination of Rx mbuf chain
+* net/bnxt: fix outer UDP checksum Rx offload capability
+* net/bnxt: fix Rx rings in RSS redirection table
+* net/bnxt: fix VNIC config on Rx queue stop
+* net/bnxt: fix VNIC RSS configure function
+* net/bnxt: propagate FW command failure to application
+* net/bnxt: release HWRM lock in error
+* net/bonding: fix PCI address comparison on non-PCI ports
+* net/bonding: fix port id validity check on parsing
+* net/bonding: remove local variable shadowing outer one
+* net/cxgbe: fix jumbo frame flag condition
+* net/dpaa2: fix jumbo frame flag condition for MTU set
+* net/dpaa: fix jumbo frame flag condition for MTU set
+* net/e1000: fix flow control mode setting
+* net/e1000: fix jumbo frame flag condition for MTU set
+* net/ena: flush Rx buffers memory pool cache
+* net/enetc: fix jumbo frame flag condition for MTU set
+* net/enic: fix filter log message
+* net/enic: fix filter type used for flow API
+* net/hns3: adjust format specifier for enum
+* net/hns3: fix data overwriting during register dump
+* net/hns3: fix dump register out of range
+* net/hns3: fix error code in xstats
+* net/hns3: fix firmware exceptions by concurrent commands
+* net/hns3: fix flow director rule residue on malloc failure
+* net/hns3: fix interception with flow director
+* net/hns3: fix jumbo frame flag condition for MTU set
+* net/hns3: fix memory leak on secondary process exit
+* net/hns3: fix register length when dumping registers
+* net/hns3: fix Rx/Tx errors stats
+* net/hns3: fix VF query link status in dev init
+* net/hns3: fix VF reset on mailbox failure
+* net/hns3: fix xstats with id and names
+* net/hns3: remove MPLS from supported flow items
+* net/hns3: use new opcode for clearing hardware resource
+* net/hns3: validate requested maximum Rx frame length
+* net/i40e: add null input checks
+* net/i40e: fix global register recovery
+* net/i40e: fix jumbo frame flag condition
+* net/i40e: fix L4 checksum flag
+* net/i40e: fix returned code for RSS hardware failure
+* net/i40e: fix Rx bytes statistics
+* net/i40e: fix stats counters
+* net/i40e: fix VLAN stripping in VF
+* net/i40e: fix X722 for 802.1ad frames ability
+* net/iavf: fix jumbo frame flag condition
+* net/iavf: fix vector mapping with queue
+* net/ice/base: fix memory handling
+* net/ice/base: fix null pointer dereference
+* net/ice/base: fix tunnel destroy
+* net/ice: check Rx queue number on RSS init
+* net/ice: disable IPv4 checksum offload in vector Tx
+* net/ice: enlarge Rx queue rearm threshold to 64
+* net/ice: fix jumbo frame flag condition
+* net/ice: fix outer checksum flags
+* net/ice: fix outer UDP Tx checksum offload
+* net/ice: fix RSS lookup table initialization
+* net/ipn3ke: fix jumbo frame flag condition for MTU set
+* net/ixgbe: add new flag of stripped VLAN for NEON
+* net/ixgbe: detect failed VF MTU set
+* net/ixgbe: disable NFS filtering
+* net/ixgbe: enable IXGBE NEON vector PMD when CHECKSUM need to checksum
+* net/ixgbe: fix configuration of max frame size
+* net/ixgbe: fix flex bytes flow director rule
+* net/ixgbe: fix jumbo frame flag condition
+* net/ixgbe: fix UDP zero checksum on x86
+* net/ixgbe: support bad checksum flag for NEON
+* net/ixgbe: support good checksum flag for NEON
+* net/liquidio: fix jumbo frame flag condition for MTU set
+* net/mlx4: fix handling of probing failure
+* net/mlx4: fix port attach in secondary process
+* net/mlx5: fix comparison sign in flow engine
+* net/mlx5: fix crash on secondary process port close
+* net/mlx5: fix leak on Rx queue creation failure
+* net/mlx5: fix leak on Tx queue creation failure
+* net/mlx5: refuse empty VLAN in flow pattern
+* net/mvneta: check allocation in Rx queue flush
+* net/mvpp2: fix frame size checking
+* net/mvpp2: fix stack corruption
+* net/mvpp2: remove CRC length from MRU validation
+* net/mvpp2: remove debug log on fast-path
+* net/mvpp2: remove VLAN flush
+* net/netvsc: ignore unsupported packet on sync command
+* net/nfp: fix jumbo frame flag condition for MTU set
+* net/nfp: read chip model from PluDevice register
+* net/octeontx2: fix corruption in segments list
+* net/octeontx2: fix jumbo frame flag condition for MTU
+* net/octeontx2: fix PF flow action for Tx
+* net/octeontx: fix build with SVE
+* net/pcap: fix byte stats for drop Tx
+* net/pcap: fix infinite Rx with large files
+* net/pcap: remove local variable shadowing outer one
+* net/qede: fix jumbo frame flag condition for MTU set
+* net/qede: fix promiscuous enable
+* net/sfc: fix generic byte statistics to exclude FCS bytes
+* net/sfc: fix jumbo frame flag condition for MTU set
+* net/sfc: fix TSO and checksum offloads for EF10
+* net/thunderx: fix jumbo frame flag condition for MTU set
+* net/virtio-user: fix run closing stdin and close callfd
+* power: clean up includes
+* power: create guest channel public header file
+* power: export guest channel header file
+* power: fix missing header includes
+* power: make channel message functions public
+* power: rename constants
+* power: rename public structs
+* Revert "app/testpmd: release flows left before port stop"
+* rib: fix insertion in some cases
+* rib: fix missing header include
+* rib: fix missing header includes
+* (tag: 19.11.7-20.11-21.02-rc2) app/testpmd: fix setting maximum packet length
+* (tag: 19.11.7-20.11-21.02-rc2-backports) net/mlx5: fix port attach in secondary process
+* (tag: 19.11.7-21.02rc2-21.02-rc3-backports) net/mlx5: fix VXLAN decap on non-VXLAN flow
+* (tag: 19.11.7-21.02rc2-21.02-rc3) mempool: fix panic on dump or audit
+* (tag: 19.11.7-21.02rc3-21.02-backports) mem: fix build
+* (tag: 19.11.7-21.02rc3-21.02) usertools: fix binding built-in kernel driver
+* (tag: v19.11.7-rc1) version: 19.11.7-rc1
+* test/distributor: fix return buffer queue overload
+* test/event_crypto: set cipher operation in transform
+* test: fix buffer overflow in Tx burst
+* test: fix terminal settings on exit
+* test/ipsec: fix result code for not supported
+* test/mcslock: remove unneeded per lcore copy
+* usertools: fix Python compatibility issue
+* vhost: fix packed ring dequeue offloading
+* vhost: fix vid allocation race
+
+19.11.7 Validation
+~~~~~~~~~~~~~~~~~~
+
+* Red Hat(R) Testing
+
+   * Platform
+
+      * RHEL 8
+      * Kernel 4.18
+      * Qemu 5.2
+      * X540-AT2 NIC(ixgbe, 10G)
+      * Tested on 19.11.7-RC1
+
+   * Tests
+
+      * Guest with device assignment(PF) throughput testing(1G hugepage size): PASS
+      * Guest with device assignment(PF) throughput testing(2M hugepage size) : PASS
+      * Guest with device assignment(VF) throughput testing: PASS
+      * PVP (host dpdk testpmd as vswitch) 1Q: throughput testing: PASS
+      * PVP vhost-user 2Q throughput testing: PASS
+      * PVP vhost-user 1Q - cross numa node throughput testing: PASS
+      * Guest with vhost-user 2 queues throughput testing: PASS
+      * vhost-user reconnect with dpdk-client, qemu-server: qemu reconnect: PASS
+      * vhost-user reconnect with dpdk-client, qemu-server: ovs reconnect: PASS
+      * PVP 1Q live migration testing: PASS
+      * PVP 1Q cross numa node live migration testing: PASS
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing: PASS
+      * Guest with ovs+dpdk+vhost-user 1Q live migration testing (2M): PASS
+      * Guest with ovs+dpdk+vhost-user 2Q live migration testing: PASS
+      * Host PF + DPDK testing: PASS
+      * Host VF + DPDK testing: PASS
+
+* Nvidia (R) Testing
+
+   * functional tests on Mellanox hardware
+
+      * NIC: ConnectX-4 Lx / OS: RHEL7.4 / Driver: MLNX_OFED_LINUX-5.2-2.2.0.0 Firmware: 14.29.2002
+      * NIC: ConnectX-5 / OS: RHEL7.4 / Driver: MLNX_OFED_LINUX-5.2-2.2.0.0 Firmware: 16.29.2002
+
+   * Basic functionality:
+
+      * Send and receive multiple types of traffic.
+      * testpmd xstats counter test.
+      * testpmd timestamp test.
+      * Changing/checking link status through testpmd.
+      * RTE flow tests: Items: eth / vlan / ipv4 / ipv6 / tcp / udp / icmp / gre / nvgre / vxlan ip in ip / mplsoudp / mplsogre
+      * Actions: drop / queue / rss / mark / flag / jump / count / raw_encap / raw_decap / vxlan_encap / vxlan_decap / NAT / dec_ttl
+      * Some RSS tests.
+      * VLAN filtering, stripping and insertion tests.
+      * Checksum and TSO tests.
+      * ptype tests.
+      * link_status_interrupt example application tests.
+      * l3fwd-power example application tests.
+      * Multi-process example applications tests.
+
+   * Compilation tests with multiple configurations in the following OS/driver combinations are also passing:
+
+      * Ubuntu 20.04.2 with MLNX_OFED_LINUX-5.2-2.2.0.0.
+      * Ubuntu 20.04.2 with rdma-core master (a1a9ffb).
+      * Ubuntu 20.04.2 with rdma-core v28.0.
+      * Ubuntu 18.04.5 with rdma-core v17.1.
+      * Ubuntu 18.04.5 with rdma-core master (a1a9ffb) (i386).
+      * Ubuntu 16.04.7 with rdma-core v22.7.
+      * Fedora 32 with rdma-core v33.0.
+      * CentOS 7 7.9.2009 with rdma-core master (a1a9ffb).
+      * CentOS 7 7.9.2009 with MLNX_OFED_LINUX-5.2-2.2.0.0.
+      * CentOS 8 8.3.2011 with rdma-core master (a1a9ffb).
+      * OpenSUSE Leap 15.2 with rdma-core v27.1.
+
+* Intel(R) Testing
+
+   * Basic Intel NIC (ixgbe, i40e) testing
+
+      * PF (i40e)
+      * PF (ixgbe)
+      * VF (i40e)
+      * VF (ixgbe)
+      * Compile Testing
+      * Intel NIC single core/NIC performance
+
+   * Basic cryptodev and virtio testing
+
+      * vhost/virtio basic loopback, PVP and performance test
+      * cryptodev Function/Performance
+
+* Intel(R) Testing with Open vSwitch
+
+   * OVS testing with OVS 2.14.3
+
+      * I40e: Performance Tests Jumbo frames RSS
+      * Niantic: Performance Tests Jumbo frames RSS
+      * Ice: Performance Tests Jumbo frames RSS
+      * Vhost: Port addition, deletion, jumbo frames and RSS multi-queue tests.
+
+* Canonical(R) Testing
+
+   * Build tests on Ubuntu 21.04
+   * OVS-DPDK tests on x86_64
+
+      * performance tests
+
+         * test guest-openvswitch for OVS-5CPU  => Pass
+         * test guest-dpdk-vhost-user-client-multiq for OVSDPDK-VUC  => Pass
+
+      * VUC endurance tests
+
+         * start stop guests (client)  => Pass
+         * add/remove ports (client)  => Pass
+
+19.11.7 Known Issues
+~~~~~~~~~~~~~~~~~~~~
+
+* The UDP fragmentation offload feature of Virtio-net device can not be turned on in the VM. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=207075
+
+* mlx5 VLAN packets will not do RSS. Bug: https://bugs.dpdk.org/show_bug.cgi?id=661
diff --git a/dpdk/doc/guides/sample_app_ug/ethtool.rst b/dpdk/doc/guides/sample_app_ug/ethtool.rst
index 8f7fc6ca66..253004dd00 100644
--- a/dpdk/doc/guides/sample_app_ug/ethtool.rst
+++ b/dpdk/doc/guides/sample_app_ug/ethtool.rst
@@ -24,7 +24,7 @@ The only available options are the standard ones for the EAL:
 
 .. code-block:: console
 
-    ./ethtool-app/ethtool-app/${RTE_TARGET}/ethtool [EAL options]
+    ./ethtool-app/${RTE_TARGET}/ethtool [EAL options]
 
 Refer to the *DPDK Getting Started Guide* for general information on
 running applications and the Environment Abstraction Layer (EAL)
diff --git a/dpdk/doc/guides/sample_app_ug/eventdev_pipeline.rst b/dpdk/doc/guides/sample_app_ug/eventdev_pipeline.rst
index dc7972aa9a..24fb23b898 100644
--- a/dpdk/doc/guides/sample_app_ug/eventdev_pipeline.rst
+++ b/dpdk/doc/guides/sample_app_ug/eventdev_pipeline.rst
@@ -34,6 +34,7 @@ options.
 An example eventdev pipeline running with the software eventdev PMD using
 these settings is shown below:
 
+ * ``-l 0,2,8-15``: lcore to use
  * ``-r1``: core mask 0x1 for RX
  * ``-t1``: core mask 0x1 for TX
  * ``-e4``: core mask 0x4 for the software scheduler
@@ -46,7 +47,8 @@ these settings is shown below:
 
 .. code-block:: console
 
-    ./build/eventdev_pipeline --vdev event_sw0 -- -r1 -t1 -e4 -w FF00 -s4 -n0 -c32 -W1000 -D
+    ./build/eventdev_pipeline --vdev event_sw0 -l 0,2,8-15 -- -r1 -t1 \
+    -e4 -w FF00 -s4 -n0 -c32 -W1000 -D
 
 The application has some sanity checking built-in, so if there is a function
 (e.g.; the RX core) which doesn't have a cpu core mask assigned, the application
diff --git a/dpdk/doc/guides/sample_app_ug/flow_classify.rst b/dpdk/doc/guides/sample_app_ug/flow_classify.rst
index bc234b50a7..451a0db88f 100644
--- a/dpdk/doc/guides/sample_app_ug/flow_classify.rst
+++ b/dpdk/doc/guides/sample_app_ug/flow_classify.rst
@@ -271,7 +271,7 @@ Forwarding application is shown below:
 .. code-block:: c
 
     static inline int
-    port_init(uint8_t port, struct rte_mempool *mbuf_pool)
+    port_init(uint16_t port, struct rte_mempool *mbuf_pool)
     {
         struct rte_eth_conf port_conf = port_conf_default;
         const uint16_t rx_rings = 1, tx_rings = 1;
diff --git a/dpdk/doc/guides/sample_app_ug/flow_filtering.rst b/dpdk/doc/guides/sample_app_ug/flow_filtering.rst
index 5e5a6cd8a0..d3653e57b2 100644
--- a/dpdk/doc/guides/sample_app_ug/flow_filtering.rst
+++ b/dpdk/doc/guides/sample_app_ug/flow_filtering.rst
@@ -384,7 +384,7 @@ This function is located in the ``flow_blocks.c`` file.
 .. code-block:: c
 
    static struct rte_flow *
-   generate_ipv4_flow(uint8_t port_id, uint16_t rx_q,
+   generate_ipv4_flow(uint16_t port_id, uint16_t rx_q,
                    uint32_t src_ip, uint32_t src_mask,
                    uint32_t dest_ip, uint32_t dest_mask,
                    struct rte_flow_error *error)
diff --git a/dpdk/doc/guides/sample_app_ug/ipsec_secgw.rst b/dpdk/doc/guides/sample_app_ug/ipsec_secgw.rst
index d6d8d44686..eb1a57a98f 100644
--- a/dpdk/doc/guides/sample_app_ug/ipsec_secgw.rst
+++ b/dpdk/doc/guides/sample_app_ug/ipsec_secgw.rst
@@ -92,7 +92,7 @@ The application has a number of command line options::
 
    ./build/ipsec-secgw [EAL options] --
                         -p PORTMASK -P -u PORTMASK -j FRAMESIZE
-                        -l -w REPLAY_WINOW_SIZE -e -a
+                        -l -w REPLAY_WINDOW_SIZE -e -a
                         --config (port,queue,lcore)[,(port,queue,lcore]
                         --single-sa SAIDX
                         --rxoffload MASK
@@ -122,7 +122,7 @@ Where:
 
 *   ``-l``: enables code-path that uses librte_ipsec.
 
-*   ``-w REPLAY_WINOW_SIZE``: specifies the IPsec sequence number replay window
+*   ``-w REPLAY_WINDOW_SIZE``: specifies the IPsec sequence number replay window
     size for each Security Association (available only with librte_ipsec
     code path).
 
diff --git a/dpdk/doc/guides/sample_app_ug/l2_forward_event.rst b/dpdk/doc/guides/sample_app_ug/l2_forward_event.rst
index 8c519c3046..c5fad93d00 100644
--- a/dpdk/doc/guides/sample_app_ug/l2_forward_event.rst
+++ b/dpdk/doc/guides/sample_app_ug/l2_forward_event.rst
@@ -202,9 +202,6 @@ chapters that related to the Poll Mode and Event mode Driver in the
 
 .. code-block:: c
 
-    if (rte_pci_probe() < 0)
-        rte_panic("Cannot probe PCI\n");
-
     /* reset l2fwd_dst_ports */
 
     for (portid = 0; portid < RTE_MAX_ETHPORTS; portid++)
@@ -234,11 +231,6 @@ chapters that related to the Poll Mode and Event mode Driver in the
         rte_eth_dev_info_get((uint8_t) portid, &dev_info);
     }
 
-Observe that:
-
-*   rte_pci_probe() parses the devices on the PCI bus and initializes recognized
-    devices.
-
 The next step is to configure the RX and TX queues. For each port, there is only
 one RX queue (only one lcore is able to poll a given port). The number of TX
 queues depends on the number of available lcores. The rte_eth_dev_configure()
diff --git a/dpdk/doc/guides/sample_app_ug/l2_forward_real_virtual.rst b/dpdk/doc/guides/sample_app_ug/l2_forward_real_virtual.rst
index 39d6b0067a..671d0c7c19 100644
--- a/dpdk/doc/guides/sample_app_ug/l2_forward_real_virtual.rst
+++ b/dpdk/doc/guides/sample_app_ug/l2_forward_real_virtual.rst
@@ -194,9 +194,6 @@ in the *DPDK Programmer's Guide* - Rel 1.4 EAR and the *DPDK API Reference*.
 
 .. code-block:: c
 
-    if (rte_pci_probe() < 0)
-        rte_exit(EXIT_FAILURE, "Cannot probe PCI\n");
-
     /* reset l2fwd_dst_ports */
 
     for (portid = 0; portid < RTE_MAX_ETHPORTS; portid++)
@@ -226,12 +223,6 @@ in the *DPDK Programmer's Guide* - Rel 1.4 EAR and the *DPDK API Reference*.
         rte_eth_dev_info_get((uint8_t) portid, &dev_info);
     }
 
-Observe that:
-
-*   rte_igb_pmd_init_all() simultaneously registers the driver as a PCI driver and as an Ethernet* Poll Mode Driver.
-
-*   rte_pci_probe() parses the devices on the PCI bus and initializes recognized devices.
-
 The next step is to configure the RX and TX queues.
 For each port, there is only one RX queue (only one lcore is able to poll a given port).
 The number of TX queues depends on the number of available lcores.
diff --git a/dpdk/doc/guides/sample_app_ug/l3_forward_access_ctrl.rst b/dpdk/doc/guides/sample_app_ug/l3_forward_access_ctrl.rst
index a44fbcd52c..4e58c6c612 100644
--- a/dpdk/doc/guides/sample_app_ug/l3_forward_access_ctrl.rst
+++ b/dpdk/doc/guides/sample_app_ug/l3_forward_access_ctrl.rst
@@ -236,7 +236,7 @@ The application has a number of command line options:
 
 ..  code-block:: console
 
-    ./build/l3fwd-acl [EAL options] -- -p PORTMASK [-P] --config(port,queue,lcore)[,(port,queue,lcore)] --rule_ipv4 FILENAME rule_ipv6 FILENAME [--scalar] [--enable-jumbo [--max-pkt-len PKTLEN]] [--no-numa]
+    ./build/l3fwd-acl [EAL options] -- -p PORTMASK [-P] --config(port,queue,lcore)[,(port,queue,lcore)] --rule_ipv4 FILENAME --rule_ipv6 FILENAME [--scalar] [--enable-jumbo [--max-pkt-len PKTLEN]] [--no-numa]
 
 
 where,
@@ -268,7 +268,7 @@ To enable L3 forwarding between two ports, assuming that both ports are in the s
 
 ..  code-block:: console
 
-    ./build/l3fwd-acl -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)" --rule_ipv4="./rule_ipv4.db" -- rule_ipv6="./rule_ipv6.db" --scalar
+    ./build/l3fwd-acl -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)" --rule_ipv4="./rule_ipv4.db" --rule_ipv6="./rule_ipv6.db" --scalar
 
 In this command:
 
@@ -290,9 +290,9 @@ In this command:
     |          |            |           |                                     |
     +----------+------------+-----------+-------------------------------------+
 
-*   The --rule_ipv4 option specifies the reading of IPv4 rules sets from the ./ rule_ipv4.db file.
+*   The --rule_ipv4 option specifies the reading of IPv4 rules sets from the rule_ipv4.db file.
 
-*   The --rule_ipv6 option specifies the reading of IPv6 rules sets from the ./ rule_ipv6.db file.
+*   The --rule_ipv6 option specifies the reading of IPv6 rules sets from the rule_ipv6.db file.
 
 *   The --scalar option specifies the performing of rule lookup with a scalar function.
 
diff --git a/dpdk/doc/guides/sample_app_ug/l3_forward_power_man.rst b/dpdk/doc/guides/sample_app_ug/l3_forward_power_man.rst
index 6ec24f4ad8..dbdaa743dd 100644
--- a/dpdk/doc/guides/sample_app_ug/l3_forward_power_man.rst
+++ b/dpdk/doc/guides/sample_app_ug/l3_forward_power_man.rst
@@ -49,7 +49,7 @@ to set the CPUFreq governor and set the frequency of specific cores.
 
 This application includes a P-state power management algorithm to generate a frequency hint to be sent to CPUFreq.
 The algorithm uses the number of received and available Rx packets on recent polls to make a heuristic decision to scale frequency up/down.
-Specifically, some thresholds are checked to see whether a specific core running an DPDK polling thread needs to increase frequency
+Specifically, some thresholds are checked to see whether a specific core running a DPDK polling thread needs to increase frequency
 a step up based on the near to full trend of polled Rx queues.
 Also, it decreases frequency a step if packet processed per loop is far less than the expected threshold
 or the thread's sleeping time exceeds a threshold.
diff --git a/dpdk/doc/guides/sample_app_ug/link_status_intr.rst b/dpdk/doc/guides/sample_app_ug/link_status_intr.rst
index 5283be8b7c..04c40f2854 100644
--- a/dpdk/doc/guides/sample_app_ug/link_status_intr.rst
+++ b/dpdk/doc/guides/sample_app_ug/link_status_intr.rst
@@ -88,9 +88,6 @@ To fully understand this code, it is recommended to study the chapters that rela
 
 .. code-block:: c
 
-    if (rte_pci_probe() < 0)
-        rte_exit(EXIT_FAILURE, "Cannot probe PCI\n");
-
     /*
      * Each logical core is assigned a dedicated TX queue on each port.
      */
@@ -115,10 +112,6 @@ To fully understand this code, it is recommended to study the chapters that rela
         rte_eth_dev_info_get((uint8_t) portid, &dev_info);
     }
 
-Observe that:
-
-*   rte_pci_probe()  parses the devices on the PCI bus and initializes recognized devices.
-
 The next step is to configure the RX and TX queues.
 For each port, there is only one RX queue (only one lcore is able to poll a given port).
 The number of TX queues depends on the number of available lcores.
diff --git a/dpdk/doc/guides/sample_app_ug/multi_process.rst b/dpdk/doc/guides/sample_app_ug/multi_process.rst
index 9c374da6f7..f2a79a6397 100644
--- a/dpdk/doc/guides/sample_app_ug/multi_process.rst
+++ b/dpdk/doc/guides/sample_app_ug/multi_process.rst
@@ -209,7 +209,7 @@ How the Application Works
 ^^^^^^^^^^^^^^^^^^^^^^^^^
 
 The initialization calls in both the primary and secondary instances are the same for the most part,
-calling the rte_eal_init(), 1 G and 10 G driver initialization and then rte_pci_probe() functions.
+calling the rte_eal_init(), 1 G and 10 G driver initialization and then probing devices.
 Thereafter, the initialization done depends on whether the process is configured as a primary or secondary instance.
 
 In the primary instance, a memory pool is created for the packet mbufs and the network ports to be used are initialized -
diff --git a/dpdk/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/dpdk/doc/guides/testpmd_app_ug/testpmd_funcs.rst
index 73ef0b41d3..17a41c21e5 100644
--- a/dpdk/doc/guides/testpmd_app_ug/testpmd_funcs.rst
+++ b/dpdk/doc/guides/testpmd_app_ug/testpmd_funcs.rst
@@ -237,7 +237,7 @@ Display the RSS hash functions and RSS hash key of a port::
 clear port
 ~~~~~~~~~~
 
-Clear the port statistics for a given port or for all ports::
+Clear the port statistics and forward engine statistics for a given port or for all ports::
 
    testpmd> clear port (info|stats|xstats|fdir|stat_qmap) (port_id|all)
 
@@ -2437,16 +2437,16 @@ For example, to set the MAC address of a Link Bonding device (port 10) to 00:00:
 
    testpmd> set bonding mac 10 00:00:00:00:00:01
 
-set bonding xmit_balance_policy
+set bonding balance_xmit_policy
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 Set the transmission policy for a Link Bonding device when it is in Balance XOR mode::
 
-   testpmd> set bonding xmit_balance_policy (port_id) (l2|l23|l34)
+   testpmd> set bonding balance_xmit_policy (port_id) (l2|l23|l34)
 
 For example, set a Link Bonding device (port 10) to use a balance policy of layer 3+4 (IP addresses & UDP ports)::
 
-   testpmd> set bonding xmit_balance_policy 10 l34
+   testpmd> set bonding balance_xmit_policy 10 l34
 
 
 set bonding mon_period
@@ -4435,14 +4435,14 @@ Sample QinQ flow rules
 Before creating QinQ rule(s) the following commands should be issued to enable QinQ::
 
    testpmd> port stop 0
-   testpmd> vlan set qinq_strip on 0
+   testpmd> vlan set extend on 0
 
 The above command sets the inner and outer TPID's to 0x8100.
 
 To change the TPID's the following commands should be used::
 
-   testpmd> vlan set outer tpid 0xa100 0
-   testpmd> vlan set inner tpid 0x9100 0
+   testpmd> vlan set outer tpid 0x88A8 0
+   testpmd> vlan set inner tpid 0x8100 0
    testpmd> port start 0
 
 Validate and create a QinQ rule on port 0 to steer traffic to a VF queue in a VM.
diff --git a/dpdk/doc/guides/tools/testbbdev.rst b/dpdk/doc/guides/tools/testbbdev.rst
index 7e95696609..bddfd8ae83 100644
--- a/dpdk/doc/guides/tools/testbbdev.rst
+++ b/dpdk/doc/guides/tools/testbbdev.rst
@@ -6,7 +6,7 @@ dpdk-test-bbdev Application
 
 The ``dpdk-test-bbdev`` tool is a Data Plane Development Kit (DPDK) utility that
 allows measuring performance parameters of PMDs available in the bbdev framework.
-Available tests available for execution are: latency, throughput, validation and
+Tests available for execution are: latency, throughput, validation and
 sanity tests. Execution of tests can be customized using various parameters
 passed to a python running script.
 
diff --git a/dpdk/doc/guides/windows_gsg/build_dpdk.rst b/dpdk/doc/guides/windows_gsg/build_dpdk.rst
index 6711e07e21..a0e51dfcb3 100644
--- a/dpdk/doc/guides/windows_gsg/build_dpdk.rst
+++ b/dpdk/doc/guides/windows_gsg/build_dpdk.rst
@@ -7,15 +7,22 @@ Compiling the DPDK Target from Source
 System Requirements
 -------------------
 
-The DPDK and its applications require the Clang-LLVM C compiler
-and Microsoft MSVC linker.
+Building the DPDK and its applications requires one of the following
+environments:
+
+* The Clang-LLVM C compiler and Microsoft MSVC linker.
+* The MinGW-w64 toolchain (either native or cross).
+
 The Meson Build system is used to prepare the sources for compilation
 with the Ninja backend.
 The installation of these tools is covered in this section.
 
 
+Option 1. Clang-LLVM C Compiler and Microsoft MSVC Linker
+---------------------------------------------------------
+
 Install the Compiler
---------------------
+~~~~~~~~~~~~~~~~~~~~
 
 Download and install the clang compiler from
 `LLVM website <http://releases.llvm.org/download.html>`_.
@@ -25,7 +32,7 @@ For example, Clang-LLVM direct download link::
 
 
 Install the Linker
-------------------
+~~~~~~~~~~~~~~~~~~
 
 Download and install the Build Tools for Visual Studio to link and build the
 files on windows,
@@ -34,6 +41,18 @@ When installing build tools, select the "Visual C++ build tools" option
 and ensure the Windows SDK is selected.
 
 
+Option 2. MinGW-w64 Toolchain
+-----------------------------
+
+Obtain the latest version from
+`MinGW-w64 website <http://mingw-w64.org/doku.php/download>`_.
+On Windows, install to a folder without spaces in its name, like ``C:\MinGW``.
+This path is assumed for the rest of this guide.
+
+Version 4.0.4 for Ubuntu 16.04 cannot be used due to a
+`MinGW-w64 bug <https://sourceforge.net/p/mingw-w64/bugs/562/>`_.
+
+
 Install the Build System
 ------------------------
 
@@ -43,6 +62,8 @@ A good option to choose is the MSI installer for both meson and ninja together::
 
 	http://mesonbuild.com/Getting-meson.html#installing-meson-and-ninja-with-the-msi-installer%22
 
+Recommended version is either Meson 0.47.1 (baseline) or the latest release.
+
 Install the Backend
 -------------------
 
@@ -56,23 +77,30 @@ Build the code
 The build environment is setup to build the EAL and the helloworld example by
 default.
 
-Using the ninja backend
-~~~~~~~~~~~~~~~~~~~~~~~~
+Option 1. Native Build on Windows
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-Specifying the compiler might be required to complete the meson command.
+When using Clang-LLVM, specifying the compiler might be required to complete
+the meson command:
 
 .. code-block:: console
 
     set CC=clang
 
+When using MinGW-w64, it is sufficient to have toolchain executables in PATH:
+
+.. code-block:: console
+
+    set PATH=C:\MinGW\mingw64\bin;%PATH%
+
 To compile the examples, the flag ``-Dexamples`` is required.
 
 .. code-block:: console
 
     cd C:\Users\me\dpdk
     meson -Dexamples=helloworld build
-    cd build
-    ninja
+    ninja -C build
+
 
 Run the helloworld example
 ==========================
@@ -87,3 +115,8 @@ Navigate to the examples in the build directory and run `dpdk-helloworld.exe`.
     hello from core 3
     hello from core 0
     hello from core 2
+
+Note for MinGW-w64: applications are linked to ``libwinpthread-1.dll``
+by default. To run the example, either add toolchain executables directory
+to the PATH or copy the library to the working directory.
+Alternatively, static linking may be used (mind the LGPLv2.1 license).
diff --git a/dpdk/drivers/Makefile b/dpdk/drivers/Makefile
index 7d5da5d9f5..cfc24b2d0b 100644
--- a/dpdk/drivers/Makefile
+++ b/dpdk/drivers/Makefile
@@ -19,7 +19,7 @@ DEPDIRS-common/qat := bus mempool
 DIRS-$(CONFIG_RTE_LIBRTE_COMPRESSDEV) += compress
 DEPDIRS-compress := bus mempool
 DIRS-$(CONFIG_RTE_LIBRTE_EVENTDEV) += event
-DEPDIRS-event := common bus mempool net
+DEPDIRS-event := common bus mempool net crypto
 DIRS-$(CONFIG_RTE_LIBRTE_RAWDEV) += raw
 DEPDIRS-raw := common bus mempool net event
 
diff --git a/dpdk/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c b/dpdk/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c
index 8bd10b401a..0a75a0ff13 100644
--- a/dpdk/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c
+++ b/dpdk/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c
@@ -2325,7 +2325,7 @@ fpga_lte_fec_init(struct rte_bbdev *dev, struct rte_pci_driver *drv)
 
 	rte_bbdev_log_debug(
 			"Init device %s [%s] @ virtaddr %p phyaddr %#"PRIx64,
-			dev->device->driver->name, dev->data->name,
+			drv->driver.name, dev->data->name,
 			(void *)pci_dev->mem_resource[0].addr,
 			pci_dev->mem_resource[0].phys_addr);
 }
@@ -2380,7 +2380,7 @@ fpga_lte_fec_probe(struct rte_pci_driver *pci_drv,
 		((uint16_t)(version_id >> 16)), ((uint16_t)version_id));
 
 #ifdef RTE_LIBRTE_BBDEV_DEBUG
-	if (!strcmp(bbdev->device->driver->name,
+	if (!strcmp(pci_drv->driver.name,
 			RTE_STR(FPGA_LTE_FEC_PF_DRIVER_NAME)))
 		print_static_reg_debug_info(d->mmio_base);
 #endif
diff --git a/dpdk/drivers/baseband/turbo_sw/bbdev_turbo_software.c b/dpdk/drivers/baseband/turbo_sw/bbdev_turbo_software.c
index f2fe7a2194..18c4649917 100644
--- a/dpdk/drivers/baseband/turbo_sw/bbdev_turbo_software.c
+++ b/dpdk/drivers/baseband/turbo_sw/bbdev_turbo_software.c
@@ -10,6 +10,7 @@
 #include <rte_ring.h>
 #include <rte_kvargs.h>
 #include <rte_cycles.h>
+#include <rte_errno.h>
 
 #include <rte_bbdev.h>
 #include <rte_bbdev_pmd.h>
@@ -218,7 +219,7 @@ info_get(struct rte_bbdev *dev, struct rte_bbdev_driver_info *dev_info)
 					RTE_BBDEV_LDPC_HQ_COMBINE_OUT_ENABLE |
 					RTE_BBDEV_LDPC_ITERATION_STOP_ENABLE,
 			.llr_size = 8,
-			.llr_decimals = 2,
+			.llr_decimals = 4,
 			.harq_memory_size = 0,
 			.num_buffers_src =
 					RTE_BBDEV_LDPC_MAX_CODE_BLOCKS,
@@ -303,7 +304,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->enc_out = rte_zmalloc_socket(name,
 			((RTE_BBDEV_TURBO_MAX_TB_SIZE >> 3) + 3) *
@@ -312,6 +314,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->enc_out == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -323,7 +326,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->enc_in = rte_zmalloc_socket(name,
 			(RTE_BBDEV_LDPC_MAX_CB_SIZE >> 3) * sizeof(*q->enc_in),
@@ -331,6 +335,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->enc_in == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -341,7 +346,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->ag = rte_zmalloc_socket(name,
 			RTE_BBDEV_TURBO_MAX_CB_SIZE * 10 * sizeof(*q->ag),
@@ -349,6 +355,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->ag == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -359,7 +366,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->code_block = rte_zmalloc_socket(name,
 			RTE_BBDEV_TURBO_MAX_CB_SIZE * sizeof(*q->code_block),
@@ -367,6 +375,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->code_block == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -378,7 +387,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->deint_input = rte_zmalloc_socket(name,
 			DEINT_INPUT_BUF_SIZE * sizeof(*q->deint_input),
@@ -386,6 +396,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->deint_input == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -397,7 +408,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->deint_output = rte_zmalloc_socket(NULL,
 			DEINT_OUTPUT_BUF_SIZE * sizeof(*q->deint_output),
@@ -405,6 +417,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->deint_output == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -416,7 +429,8 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->adapter_output = rte_zmalloc_socket(NULL,
 			ADAPTER_OUTPUT_BUF_SIZE * sizeof(*q->adapter_output),
@@ -424,6 +438,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	if (q->adapter_output == NULL) {
 		rte_bbdev_log(ERR,
 			"Failed to allocate queue memory for %s", name);
+		ret = -ENOMEM;
 		goto free_q;
 	}
 
@@ -434,12 +449,14 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 		rte_bbdev_log(ERR,
 				"Creating queue name for device %u queue %u failed",
 				dev->data->dev_id, q_id);
-		return -ENAMETOOLONG;
+		ret = -ENAMETOOLONG;
+		goto free_q;
 	}
 	q->processed_pkts = rte_ring_create(name, queue_conf->queue_size,
 			queue_conf->socket, RING_F_SP_ENQ | RING_F_SC_DEQ);
 	if (q->processed_pkts == NULL) {
 		rte_bbdev_log(ERR, "Failed to create ring for %s", name);
+		ret = -rte_errno;
 		goto free_q;
 	}
 
@@ -459,7 +476,7 @@ q_setup(struct rte_bbdev *dev, uint16_t q_id,
 	rte_free(q->deint_output);
 	rte_free(q->adapter_output);
 	rte_free(q);
-	return -EFAULT;
+	return ret;
 }
 
 static const struct rte_bbdev_ops pmd_ops = {
diff --git a/dpdk/drivers/bus/dpaa/base/qbman/qman_driver.c b/dpdk/drivers/bus/dpaa/base/qbman/qman_driver.c
index 69244ef701..e1dee17542 100644
--- a/dpdk/drivers/bus/dpaa/base/qbman/qman_driver.c
+++ b/dpdk/drivers/bus/dpaa/base/qbman/qman_driver.c
@@ -132,7 +132,7 @@ struct qman_portal *fsl_qman_fq_portal_create(int *fd)
 	struct qm_portal_config *q_pcfg;
 	struct dpaa_ioctl_irq_map irq_map;
 	struct dpaa_ioctl_portal_map q_map = {0};
-	int q_fd = 0, ret;
+	int q_fd, ret;
 
 	q_pcfg = kzalloc((sizeof(struct qm_portal_config)), 0);
 	if (!q_pcfg) {
@@ -169,7 +169,7 @@ struct qman_portal *fsl_qman_fq_portal_create(int *fd)
 	if (!portal) {
 		pr_err("Qman portal initialisation failed (%d)\n",
 		       q_pcfg->cpu);
-		goto err;
+		goto err_alloc;
 	}
 
 	irq_map.type = dpaa_portal_qman;
@@ -178,11 +178,9 @@ struct qman_portal *fsl_qman_fq_portal_create(int *fd)
 
 	*fd = q_fd;
 	return portal;
+err_alloc:
+	close(q_fd);
 err:
-	if (portal)
-		qman_free_global_portal(portal);
-	if (q_fd)
-		close(q_fd);
 	process_portal_unmap(&q_map.addr);
 	kfree(q_pcfg);
 	return NULL;
diff --git a/dpdk/drivers/bus/dpaa/dpaa_bus.c b/dpdk/drivers/bus/dpaa/dpaa_bus.c
index f27820db37..327d9269f7 100644
--- a/dpdk/drivers/bus/dpaa/dpaa_bus.c
+++ b/dpdk/drivers/bus/dpaa/dpaa_bus.c
@@ -700,6 +700,11 @@ dpaa_bus_dev_iterate(const void *start, const char *str,
 	struct rte_dpaa_device *dev;
 	char *dup, *dev_name = NULL;
Louis Abel's avatar
Louis Abel committed
16201 16202 16203 16204 16205 16206 16207 16208 16209 16210 16211 16212 16213 16214 16215 16216 16217 16218 16219 16220 16221 16222 16223 16224 16225 16226 16227 16228 16229 16230 16231 16232 16233 16234 16235 16236 16237 16238 16239 16240 16241 16242 16243 16244 16245 16246 16247 16248 16249 16250 16251 16252 16253 16254 16255 16256 16257 16258 16259 16260 16261 16262 16263 16264 16265 16266 16267 16268 16269 16270 16271 16272 16273 16274 16275 16276 16277 16278 16279 16280 16281 16282 16283 16284 16285 16286 16287 16288 16289 16290 16291 16292 16293 16294 16295 16296 16297 16298 16299 16300 16301 16302 16303 16304 16305 16306 16307 16308 16309 16310 16311 16312 16313 16314 16315 16316 16317 16318 16319 16320 16321 16322 16323 16324 16325 16326 16327 16328 16329 16330 16331 16332 16333 16334 16335 16336 16337 16338 16339 16340 16341 16342 16343 16344 16345 16346 16347 16348 16349 16350 16351 16352 16353 16354 16355 16356 16357 16358 16359 16360 16361 16362 16363 16364 16365 16366 16367 16368 16369 16370 16371 16372 16373 16374 16375 16376 16377 16378 16379 16380 16381 16382 16383 16384 16385 16386 16387 16388 16389 16390 16391 16392 16393 16394 16395 16396 16397 16398 16399 16400 16401 16402 16403 16404 16405 16406 16407 16408 16409 16410 16411 16412 16413 16414 16415 16416 16417 16418 16419 16420 16421 16422 16423 16424 16425 16426 16427 16428 16429 16430 16431 16432 16433 16434 16435 16436 16437 16438 16439 16440 16441 16442 16443 16444 16445 16446 16447 16448 16449 16450 16451 16452 16453 16454 16455 16456 16457 16458 16459 16460 16461 16462 16463 16464 16465 16466 16467 16468 16469 16470 16471 16472 16473 16474 16475 16476 16477 16478 16479 16480 16481 16482 16483 16484 16485 16486 16487 16488 16489 16490 16491 16492 16493 16494 16495 16496 16497 16498 16499 16500 16501 16502 16503 16504 16505 16506 16507 16508 16509 16510 16511 16512 16513 16514 16515 16516 16517 16518 16519 16520 16521 16522 16523 16524 16525 16526 16527 16528 16529 16530 16531 16532 16533 16534 16535 16536 16537 16538 16539 16540 16541 16542 16543 16544 16545 16546 16547 16548 16549 16550 16551 16552 16553 16554 16555 16556 16557 16558 16559 16560 16561 16562 16563 16564 16565 16566 16567 16568 16569 16570 16571 16572 16573 16574 16575 16576 16577 16578 16579 16580 16581 16582 16583 16584 16585 16586 16587 16588 16589 16590 16591 16592 16593 16594 16595 16596 16597 16598 16599 16600 16601 16602 16603 16604 16605 16606 16607 16608 16609 16610 16611 16612 16613 16614 16615 16616 16617 16618 16619 16620 16621 16622 16623 16624 16625 16626 16627 16628 16629 16630 16631 16632 16633 16634 16635 16636 16637 16638 16639 16640 16641 16642 16643 16644 16645 16646 16647 16648 16649 16650 16651 16652 16653 16654 16655 16656 16657 16658 16659 16660 16661 16662 16663 16664 16665 16666 16667 16668 16669 16670 16671 16672 16673 16674 16675 16676 16677 16678 16679 16680 16681 16682 16683 16684 16685 16686 16687 16688 16689 16690 16691 16692 16693 16694 16695 16696 16697 16698 16699 16700 16701 16702 16703 16704 16705 16706 16707 16708 16709 16710 16711 16712 16713 16714 16715 16716 16717 16718 16719 16720 16721 16722 16723 16724 16725 16726 16727 16728 16729 16730 16731 16732 16733 16734 16735 16736 16737 16738 16739 16740 16741 16742 16743 16744 16745 16746 16747 16748 16749 16750 16751 16752 16753 16754 16755 16756 16757 16758 16759 16760 16761 16762 16763 16764 16765 16766 16767 16768 16769 16770 16771 16772 16773 16774 16775 16776 16777 16778 16779 16780 16781 16782 16783 16784 16785 16786 16787 16788 16789 16790 16791 16792 16793 16794 16795 16796 16797 16798 16799 16800 16801 16802 16803 16804 16805 16806 16807 16808 16809 16810 16811 16812 16813 16814 16815 16816 16817 16818 16819 16820 16821 16822 16823 16824 16825 16826 16827 16828 16829 16830 16831 16832 16833 16834 16835 16836 16837 16838 16839 16840 16841 16842 16843 16844 16845 16846 16847 16848 16849 16850 16851 16852 16853 16854 16855 16856 16857 16858 16859 16860 16861 16862 16863 16864 16865 16866 16867 16868 16869 16870 16871 16872 16873 16874 16875 16876 16877 16878 16879 16880 16881 16882 16883 16884 16885 16886 16887 16888 16889 16890 16891 16892 16893 16894 16895 16896 16897 16898 16899 16900 16901 16902 16903 16904 16905 16906 16907 16908 16909 16910 16911 16912 16913 16914 16915 16916 16917 16918 16919 16920 16921 16922 16923 16924 16925 16926 16927 16928 16929 16930 16931 16932 16933 16934 16935 16936 16937 16938 16939 16940 16941 16942 16943 16944 16945 16946 16947 16948 16949 16950 16951 16952 16953 16954 16955 16956 16957 16958 16959 16960 16961 16962 16963 16964 16965 16966 16967 16968 16969 16970 16971 16972 16973 16974 16975 16976 16977 16978 16979 16980 16981 16982 16983 16984 16985 16986 16987 16988 16989 16990 16991 16992 16993 16994 16995 16996 16997 16998 16999 17000 17001 17002 17003 17004 17005 17006 17007 17008 17009 17010 17011 17012 17013 17014 17015 17016 17017 17018 17019 17020 17021 17022 17023 17024 17025 17026 17027 17028 17029 17030 17031 17032 17033 17034 17035 17036 17037 17038 17039 17040 17041 17042 17043 17044 17045 17046 17047 17048 17049 17050 17051 17052 17053 17054 17055 17056 17057 17058 17059 17060 17061 17062 17063 17064 17065 17066 17067 17068 17069 17070 17071 17072 17073 17074 17075 17076 17077 17078 17079 17080 17081 17082 17083 17084 17085 17086 17087 17088 17089 17090 17091 17092 17093 17094 17095 17096 17097 17098 17099 17100 17101 17102 17103 17104 17105 17106 17107 17108 17109 17110 17111 17112 17113 17114 17115 17116 17117 17118 17119 17120 17121 17122 17123 17124 17125 17126 17127 17128 17129 17130 17131 17132 17133 17134 17135 17136 17137 17138 17139 17140 17141 17142 17143 17144 17145 17146 17147 17148 17149 17150 17151 17152 17153 17154 17155 17156 17157 17158 17159 17160 17161 17162 17163 17164 17165 17166 17167 17168 17169 17170 17171 17172 17173 17174 17175 17176 17177 17178 17179 17180 17181 17182 17183 17184 17185 17186 17187 17188 17189 17190 17191 17192 17193 17194 17195 17196 17197 17198 17199 17200 17201 17202 17203 17204 17205 17206 17207 17208 17209 17210 17211 17212 17213 17214 17215 17216 17217 17218 17219 17220 17221 17222 17223 17224 17225 17226 17227 17228 17229 17230 17231 17232 17233 17234 17235 17236 17237 17238 17239 17240 17241 17242 17243 17244 17245 17246 17247 17248 17249 17250 17251 17252 17253 17254 17255 17256 17257 17258 17259 17260 17261 17262 17263 17264 17265 17266 17267 17268 17269 17270 17271 17272 17273 17274 17275 17276 17277 17278 17279 17280 17281 17282 17283 17284 17285 17286 17287 17288 17289 17290 17291 17292 17293 17294 17295 17296 17297 17298 17299 17300 17301 17302 17303 17304 17305 17306 17307 17308 17309 17310 17311 17312 17313 17314 17315 17316 17317 17318 17319 17320 17321 17322 17323 17324 17325 17326 17327 17328 17329 17330 17331 17332 17333 17334 17335 17336 17337 17338 17339 17340 17341 17342 17343 17344 17345 17346 17347 17348 17349 17350 17351 17352 17353 17354 17355 17356 17357 17358 17359 17360 17361 17362 17363 17364 17365 17366 17367 17368 17369 17370 17371 17372 17373 17374 17375 17376 17377 17378 17379 17380 17381 17382 17383 17384 17385 17386 17387 17388 17389 17390 17391 17392 17393 17394 17395 17396 17397 17398 17399 17400 17401 17402 17403 17404 17405 17406 17407 17408 17409 17410 17411 17412 17413 17414 17415 17416 17417 17418 17419 17420 17421 17422 17423 17424 17425 17426 17427 17428 17429 17430 17431 17432 17433 17434 17435 17436 17437 17438 17439 17440 17441 17442 17443 17444 17445 17446 17447 17448 17449 17450 17451 17452 17453 17454 17455 17456 17457 17458 17459 17460 17461 17462 17463 17464 17465 17466 17467 17468 17469 17470 17471 17472 17473 17474 17475 17476 17477 17478 17479 17480 17481 17482 17483 17484 17485 17486 17487 17488 17489 17490 17491 17492 17493 17494 17495 17496 17497 17498 17499 17500 17501 17502 17503 17504 17505 17506 17507 17508 17509 17510 17511 17512 17513 17514 17515 17516 17517 17518 17519 17520 17521 17522 17523 17524 17525 17526 17527 17528 17529 17530 17531 17532 17533 17534 17535 17536 17537 17538 17539 17540 17541 17542 17543 17544 17545 17546 17547 17548 17549 17550 17551 17552 17553 17554 17555 17556 17557 17558 17559 17560 17561 17562 17563 17564 17565 17566 17567 17568 17569 17570 17571 17572 17573 17574 17575 17576 17577 17578 17579 17580 17581 17582 17583 17584 17585 17586 17587 17588 17589 17590 17591 17592 17593 17594 17595 17596 17597 17598 17599 17600 17601 17602 17603 17604 17605 17606 17607 17608 17609 17610 17611 17612 17613 17614 17615 17616 17617 17618 17619 17620 17621 17622 17623 17624 17625 17626 17627 17628 17629 17630 17631 17632 17633 17634 17635 17636 17637 17638 17639 17640 17641 17642 17643 17644 17645 17646 17647 17648 17649 17650 17651 17652 17653 17654 17655 17656 17657 17658 17659 17660 17661 17662 17663 17664 17665 17666 17667 17668 17669 17670 17671 17672 17673 17674 17675 17676 17677 17678 17679 17680 17681 17682 17683 17684 17685 17686 17687 17688 17689 17690 17691 17692 17693 17694 17695 17696 17697 17698 17699 17700 17701 17702 17703 17704 17705 17706 17707 17708 17709 17710 17711 17712 17713 17714 17715 17716 17717 17718 17719 17720 17721 17722 17723 17724 17725 17726 17727 17728 17729 17730 17731 17732 17733 17734 17735 17736 17737 17738 17739 17740 17741 17742 17743 17744 17745 17746 17747 17748 17749 17750 17751 17752 17753 17754 17755 17756 17757 17758 17759 17760 17761 17762 17763 17764 17765 17766 17767 17768 17769 17770 17771 17772 17773 17774 17775 17776 17777 17778 17779 17780 17781 17782 17783 17784 17785 17786 17787 17788 17789 17790 17791 17792 17793 17794 17795 17796 17797 17798 17799 17800 17801 17802 17803 17804 17805 17806 17807 17808 17809 17810 17811 17812 17813 17814 17815 17816 17817 17818 17819 17820 17821 17822 17823 17824 17825 17826 17827 17828 17829 17830 17831 17832 17833 17834 17835 17836 17837 17838 17839 17840 17841 17842 17843 17844 17845 17846 17847 17848 17849 17850 17851 17852 17853 17854 17855 17856 17857 17858 17859 17860 17861 17862 17863 17864 17865 17866 17867 17868 17869 17870 17871 17872 17873 17874 17875 17876 17877 17878 17879 17880 17881 17882 17883 17884 17885 17886 17887 17888 17889 17890 17891 17892 17893 17894 17895 17896 17897 17898 17899 17900 17901 17902 17903 17904 17905 17906 17907 17908 17909 17910 17911 17912 17913 17914 17915 17916 17917 17918 17919 17920 17921 17922 17923 17924 17925 17926 17927 17928 17929 17930 17931 17932 17933 17934 17935 17936 17937 17938 17939 17940 17941 17942 17943 17944 17945 17946 17947 17948 17949 17950 17951 17952 17953 17954 17955 17956 17957 17958 17959 17960 17961 17962 17963 17964 17965 17966 17967 17968 17969 17970 17971 17972 17973 17974 17975 17976 17977 17978 17979 17980 17981 17982 17983 17984 17985 17986 17987 17988 17989 17990 17991 17992 17993 17994 17995 17996 17997 17998 17999 18000 18001 18002 18003 18004 18005 18006 18007 18008 18009 18010 18011 18012 18013 18014 18015 18016 18017 18018 18019 18020 18021 18022 18023 18024 18025 18026 18027 18028 18029 18030 18031 18032 18033 18034 18035 18036 18037 18038 18039 18040 18041 18042 18043 18044 18045 18046 18047 18048 18049 18050 18051 18052 18053 18054 18055 18056 18057 18058 18059 18060 18061 18062 18063 18064 18065 18066 18067 18068 18069 18070 18071 18072 18073 18074 18075 18076 18077 18078 18079 18080 18081 18082 18083 18084 18085 18086 18087 18088 18089 18090 18091 18092 18093 18094 18095 18096 18097 18098 18099 18100 18101 18102 18103 18104 18105 18106 18107 18108 18109 18110 18111 18112 18113 18114 18115 18116 18117 18118 18119 18120 18121 18122 18123 18124 18125 18126 18127 18128 18129 18130 18131 18132 18133 18134 18135 18136 18137 18138 18139 18140 18141 18142 18143 18144 18145 18146 18147 18148 18149 18150 18151 18152 18153 18154 18155 18156 18157 18158 18159 18160 18161 18162 18163 18164 18165 18166 18167 18168 18169 18170 18171 18172 18173 18174 18175 18176 18177 18178 18179 18180 18181 18182 18183 18184 18185 18186 18187 18188 18189 18190 18191 18192 18193 18194 18195 18196 18197 18198 18199 18200
 
+	if (str == NULL) {
+		DPAA_BUS_DEBUG("No device string");
+		return NULL;
+	}
+
 	/* Expectation is that device would be name=device_name */
 	if (strncmp(str, "name=", 5) != 0) {
 		DPAA_BUS_DEBUG("Invalid device string (%s)\n", str);
diff --git a/dpdk/drivers/bus/dpaa/rte_dpaa_bus.h b/dpdk/drivers/bus/dpaa/rte_dpaa_bus.h
index 9bf2cd9d68..373aca9785 100644
--- a/dpdk/drivers/bus/dpaa/rte_dpaa_bus.h
+++ b/dpdk/drivers/bus/dpaa/rte_dpaa_bus.h
@@ -132,7 +132,23 @@ static inline void *rte_dpaa_mem_ptov(phys_addr_t paddr)
 	}
 
 	/* If not, Fallback to full memseg list searching */
-	return rte_mem_iova2virt(paddr);
+	va = rte_mem_iova2virt(paddr);
+
+	dpaax_iova_table_update(paddr, va, RTE_CACHE_LINE_SIZE);
+
+	return va;
+}
+
+static inline rte_iova_t
+rte_dpaa_mem_vtop(void *vaddr)
+{
+	const struct rte_memseg *ms;
+
+	ms = rte_mem_virt2memseg(vaddr, NULL);
+	if (ms)
+		return ms->iova + RTE_PTR_DIFF(vaddr, ms->addr);
+
+	return (size_t)NULL;
 }
 
 /**
diff --git a/dpdk/drivers/bus/fslmc/fslmc_bus.c b/dpdk/drivers/bus/fslmc/fslmc_bus.c
index b3e964aa92..7431177f2e 100644
--- a/dpdk/drivers/bus/fslmc/fslmc_bus.c
+++ b/dpdk/drivers/bus/fslmc/fslmc_bus.c
@@ -608,6 +608,11 @@ fslmc_bus_dev_iterate(const void *start, const char *str,
 	struct rte_dpaa2_device *dev;
 	char *dup, *dev_name = NULL;
 
+	if (str == NULL) {
+		DPAA2_BUS_DEBUG("No device string");
+		return NULL;
+	}
+
 	/* Expectation is that device would be name=device_name */
 	if (strncmp(str, "name=", 5) != 0) {
 		DPAA2_BUS_DEBUG("Invalid device string (%s)\n", str);
diff --git a/dpdk/drivers/bus/fslmc/fslmc_vfio.c b/dpdk/drivers/bus/fslmc/fslmc_vfio.c
index 970969d2bf..bf9e3e49a5 100644
--- a/dpdk/drivers/bus/fslmc/fslmc_vfio.c
+++ b/dpdk/drivers/bus/fslmc/fslmc_vfio.c
@@ -448,11 +448,14 @@ fslmc_vfio_setup_device(const char *sysfs_base, const char *dev_addr,
 
 	/* get the actual group fd */
 	vfio_group_fd = rte_vfio_get_group_fd(iommu_group_no);
-	if (vfio_group_fd < 0)
+	if (vfio_group_fd < 0 && vfio_group_fd != -ENOENT)
 		return -1;
 
-	/* if group_fd == 0, that means the device isn't managed by VFIO */
-	if (vfio_group_fd == 0) {
+	/*
+	 * if vfio_group_fd == -ENOENT, that means the device
+	 * isn't managed by VFIO
+	 */
+	if (vfio_group_fd == -ENOENT) {
 		RTE_LOG(WARNING, EAL, " %s not managed by VFIO driver, skipping\n",
 				dev_addr);
 		return 1;
@@ -730,7 +733,6 @@ fslmc_process_mcp(struct rte_dpaa2_device *dev)
 {
 	int ret;
 	intptr_t v_addr;
-	char *dev_name = NULL;
 	struct fsl_mc_io dpmng  = {0};
 	struct mc_version mc_ver_info = {0};
 
@@ -741,13 +743,6 @@ fslmc_process_mcp(struct rte_dpaa2_device *dev)
 		goto cleanup;
 	}
 
-	dev_name = strdup(dev->device.name);
-	if (!dev_name) {
-		DPAA2_BUS_ERR("Unable to allocate MC device name memory");
-		ret = -ENOMEM;
-		goto cleanup;
-	}
-
 	v_addr = vfio_map_mcp_obj(dev->device.name);
 	if (v_addr == (intptr_t)MAP_FAILED) {
 		DPAA2_BUS_ERR("Error mapping region (errno = %d)", errno);
@@ -784,13 +779,9 @@ fslmc_process_mcp(struct rte_dpaa2_device *dev)
 	}
 	rte_mcp_ptr_list[0] = (void *)v_addr;
 
-	free(dev_name);
 	return 0;
 
 cleanup:
-	if (dev_name)
-		free(dev_name);
-
 	if (rte_mcp_ptr_list) {
 		free(rte_mcp_ptr_list);
 		rte_mcp_ptr_list = NULL;
diff --git a/dpdk/drivers/bus/fslmc/mc/fsl_mc_sys.h b/dpdk/drivers/bus/fslmc/mc/fsl_mc_sys.h
index d0c7b39f8d..a310c5697e 100644
--- a/dpdk/drivers/bus/fslmc/mc/fsl_mc_sys.h
+++ b/dpdk/drivers/bus/fslmc/mc/fsl_mc_sys.h
@@ -32,11 +32,10 @@ struct fsl_mc_io {
 #include <sys/uio.h>
 #include <linux/byteorder/little_endian.h>
 
-#ifndef dmb
-#define dmb() {__asm__ __volatile__("" : : : "memory"); }
-#endif
-#define __iormb()	dmb()
-#define __iowmb()	dmb()
+#include <rte_atomic.h>
+
+#define __iormb()	rte_io_rmb()
+#define __iowmb()	rte_io_wmb()
 #define __arch_getq(a)		(*(volatile uint64_t *)(a))
 #define __arch_putq(v, a)	(*(volatile uint64_t *)(a) = (v))
 #define __arch_putq32(v, a)	(*(volatile uint32_t *)(a) = (v))
diff --git a/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c b/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c
index 3ca3ae4f51..9c09c69fe9 100644
--- a/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c
+++ b/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c
@@ -546,8 +546,13 @@ dpaa2_create_dpio_device(int vdev_fd,
 
 err:
 	if (dpio_dev->dpio) {
-		dpio_disable(dpio_dev->dpio, CMD_PRI_LOW, dpio_dev->token);
-		dpio_close(dpio_dev->dpio, CMD_PRI_LOW,  dpio_dev->token);
+		if (dpio_dev->token) {
+			dpio_disable(dpio_dev->dpio, CMD_PRI_LOW,
+				     dpio_dev->token);
+			dpio_close(dpio_dev->dpio, CMD_PRI_LOW,
+				   dpio_dev->token);
+		}
+
 		rte_free(dpio_dev->dpio);
 	}
 
diff --git a/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h b/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h
index ab2b213f8d..00ef4ee539 100644
--- a/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h
+++ b/dpdk/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h
@@ -289,7 +289,7 @@ enum qbman_fd_format {
 #define DPAA2_GET_FD_FRC(fd)   ((fd)->simple.frc)
 #define DPAA2_GET_FD_FLC(fd) \
 	(((uint64_t)((fd)->simple.flc_hi) << 32) + (fd)->simple.flc_lo)
-#define DPAA2_GET_FD_ERR(fd)   ((fd)->simple.bpid_offset & 0x000000FF)
+#define DPAA2_GET_FD_ERR(fd)   ((fd)->simple.ctrl & 0x000000FF)
 #define DPAA2_GET_FLE_OFFSET(fle) (((fle)->fin_bpid_offset & 0x0FFF0000) >> 16)
 #define DPAA2_SET_FLE_SG_EXT(fle) ((fle)->fin_bpid_offset |= (uint64_t)1 << 29)
 #define DPAA2_IS_SET_FLE_SG_EXT(fle)	\
diff --git a/dpdk/drivers/bus/fslmc/qbman/qbman_debug.c b/dpdk/drivers/bus/fslmc/qbman/qbman_debug.c
index 0bb2ce880f..34374ae4b6 100644
--- a/dpdk/drivers/bus/fslmc/qbman/qbman_debug.c
+++ b/dpdk/drivers/bus/fslmc/qbman/qbman_debug.c
@@ -20,26 +20,27 @@ struct qbman_fq_query_desc {
 	uint8_t verb;
 	uint8_t reserved[3];
 	uint32_t fqid;
-	uint8_t reserved2[57];
+	uint8_t reserved2[56];
 };
 
 int qbman_fq_query_state(struct qbman_swp *s, uint32_t fqid,
 			 struct qbman_fq_query_np_rslt *r)
 {
 	struct qbman_fq_query_desc *p;
+	struct qbman_fq_query_np_rslt *var;
 
 	p = (struct qbman_fq_query_desc *)qbman_swp_mc_start(s);
 	if (!p)
 		return -EBUSY;
 
 	p->fqid = fqid;
-	*r = *(struct qbman_fq_query_np_rslt *)qbman_swp_mc_complete(s, p,
-						QBMAN_FQ_QUERY_NP);
-	if (!r) {
+	var = qbman_swp_mc_complete(s, p, QBMAN_FQ_QUERY_NP);
+	if (!var) {
 		pr_err("qbman: Query FQID %d NP fields failed, no response\n",
 		       fqid);
 		return -EIO;
 	}
+	*r = *var;
 
 	/* Decode the outcome */
 	QBMAN_BUG_ON((r->verb & QBMAN_RESPONSE_VERB_MASK) != QBMAN_FQ_QUERY_NP);
diff --git a/dpdk/drivers/bus/fslmc/qbman/qbman_portal.c b/dpdk/drivers/bus/fslmc/qbman/qbman_portal.c
index d4223bdc8b..54bea97820 100644
--- a/dpdk/drivers/bus/fslmc/qbman/qbman_portal.c
+++ b/dpdk/drivers/bus/fslmc/qbman/qbman_portal.c
@@ -999,6 +999,8 @@ static int qbman_swp_enqueue_multiple_mem_back(struct qbman_swp *s,
 				QBMAN_CENA_SWP_EQCR(eqcr_pi & half_mask));
 		memcpy(&p[1], &cl[1], 28);
 		memcpy(&p[8], &fd[i], sizeof(*fd));
+		p[0] = cl[0] | s->eqcr.pi_vb;
+
 		if (flags && (flags[i] & QBMAN_ENQUEUE_FLAG_DCA)) {
 			struct qbman_eq_desc *d = (struct qbman_eq_desc *)p;
 
@@ -1006,7 +1008,6 @@ static int qbman_swp_enqueue_multiple_mem_back(struct qbman_swp *s,
 				((flags[i]) & QBMAN_EQCR_DCA_IDXMASK);
 		}
 		eqcr_pi++;
-		p[0] = cl[0] | s->eqcr.pi_vb;
 
 		if (!(eqcr_pi & half_mask))
 			s->eqcr.pi_vb ^= QB_VALID_BIT;
diff --git a/dpdk/drivers/bus/ifpga/ifpga_bus.c b/dpdk/drivers/bus/ifpga/ifpga_bus.c
index dfd6b1fba9..addbc3e86b 100644
--- a/dpdk/drivers/bus/ifpga/ifpga_bus.c
+++ b/dpdk/drivers/bus/ifpga/ifpga_bus.c
@@ -24,6 +24,7 @@
 #include <rte_kvargs.h>
 #include <rte_alarm.h>
 #include <rte_string_fns.h>
+#include <rte_debug.h>
 
 #include "rte_rawdev.h"
 #include "rte_rawdev_pmd.h"
diff --git a/dpdk/drivers/bus/ifpga/rte_bus_ifpga.h b/dpdk/drivers/bus/ifpga/rte_bus_ifpga.h
index 88a6289642..a6eeaaf568 100644
--- a/dpdk/drivers/bus/ifpga/rte_bus_ifpga.h
+++ b/dpdk/drivers/bus/ifpga/rte_bus_ifpga.h
@@ -17,6 +17,7 @@ extern "C" {
 
 #include <rte_bus.h>
 #include <rte_pci.h>
+#include <rte_interrupts.h>
 #include <rte_spinlock.h>
 
 /** Name of Intel FPGA Bus */
diff --git a/dpdk/drivers/bus/pci/bsd/pci.c b/dpdk/drivers/bus/pci/bsd/pci.c
index ebbfeb13a8..081c62ab06 100644
--- a/dpdk/drivers/bus/pci/bsd/pci.c
+++ b/dpdk/drivers/bus/pci/bsd/pci.c
@@ -392,55 +392,6 @@ pci_device_iova_mode(const struct rte_pci_driver *pdrv __rte_unused,
 	return RTE_IOVA_PA;
 }
 
-int
-pci_update_device(const struct rte_pci_addr *addr)
-{
-	int fd;
-	struct pci_conf matches[2];
-	struct pci_match_conf match = {
-		.pc_sel = {
-			.pc_domain = addr->domain,
-			.pc_bus = addr->bus,
-			.pc_dev = addr->devid,
-			.pc_func = addr->function,
-		},
-	};
-	struct pci_conf_io conf_io = {
-		.pat_buf_len = 0,
-		.num_patterns = 1,
-		.patterns = &match,
-		.match_buf_len = sizeof(matches),
-		.matches = &matches[0],
-	};
-
-	fd = open("/dev/pci", O_RDONLY);
-	if (fd < 0) {
-		RTE_LOG(ERR, EAL, "%s(): error opening /dev/pci\n", __func__);
-		goto error;
-	}
-
-	if (ioctl(fd, PCIOCGETCONF, &conf_io) < 0) {
-		RTE_LOG(ERR, EAL, "%s(): error with ioctl on /dev/pci: %s\n",
-				__func__, strerror(errno));
-		goto error;
-	}
-
-	if (conf_io.num_matches != 1)
-		goto error;
-
-	if (pci_scan_one(fd, &matches[0]) < 0)
-		goto error;
-
-	close(fd);
-
-	return 0;
-
-error:
-	if (fd >= 0)
-		close(fd);
-	return -1;
-}
-
 /* Read PCI config space. */
 int rte_pci_read_config(const struct rte_pci_device *dev,
 		void *buf, size_t len, off_t offset)
diff --git a/dpdk/drivers/bus/pci/linux/pci.c b/dpdk/drivers/bus/pci/linux/pci.c
index 740a2cdad4..dba87f1275 100644
--- a/dpdk/drivers/bus/pci/linux/pci.c
+++ b/dpdk/drivers/bus/pci/linux/pci.c
@@ -377,6 +377,11 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr)
 						 */
 						RTE_LOG(ERR, EAL, "Unexpected device scan at %s!\n",
 							filename);
+					else if (dev2->device.devargs !=
+						 dev->device.devargs) {
+						rte_devargs_remove(dev2->device.devargs);
+						pci_name_set(dev2);
+					}
 				}
 				free(dev);
 			}
@@ -389,18 +394,6 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr)
 	return 0;
 }
 
-int
-pci_update_device(const struct rte_pci_addr *addr)
-{
-	char filename[PATH_MAX];
-
-	snprintf(filename, sizeof(filename), "%s/" PCI_PRI_FMT,
-		 rte_pci_get_sysfs_path(), addr->domain, addr->bus, addr->devid,
-		 addr->function);
-
-	return pci_scan_one(filename, addr);
-}
-
 /*
  * split up a pci address into its constituent parts.
  */
diff --git a/dpdk/drivers/bus/pci/linux/pci_vfio.c b/dpdk/drivers/bus/pci/linux/pci_vfio.c
index 64cd84a689..a0bb1f5fd3 100644
--- a/dpdk/drivers/bus/pci/linux/pci_vfio.c
+++ b/dpdk/drivers/bus/pci/linux/pci_vfio.c
@@ -149,6 +149,38 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
 	return 0;
 }
 
+/* enable PCI bus memory space */
+static int
+pci_vfio_enable_bus_memory(int dev_fd)
+{
+	uint16_t cmd;
+	int ret;
+
+	ret = pread64(dev_fd, &cmd, sizeof(cmd),
+		      VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+		      PCI_COMMAND);
+
+	if (ret != sizeof(cmd)) {
+		RTE_LOG(ERR, EAL, "Cannot read command from PCI config space!\n");
+		return -1;
+	}
+
+	if (cmd & PCI_COMMAND_MEMORY)
+		return 0;
+
+	cmd |= PCI_COMMAND_MEMORY;
+	ret = pwrite64(dev_fd, &cmd, sizeof(cmd),
+		       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+		       PCI_COMMAND);
+
+	if (ret != sizeof(cmd)) {
+		RTE_LOG(ERR, EAL, "Cannot write command to PCI config space!\n");
+		return -1;
+	}
+
+	return 0;
+}
+
 /* set PCI bus mastering */
 static int
 pci_vfio_set_bus_master(int dev_fd, bool op)
@@ -427,6 +459,11 @@ pci_rte_vfio_setup_device(struct rte_pci_device *dev, int vfio_dev_fd)
 		return -1;
 	}
 
+	if (pci_vfio_enable_bus_memory(vfio_dev_fd)) {
+		RTE_LOG(ERR, EAL, "Cannot enable bus memory!\n");
+		return -1;
+	}
+
 	/* set bus mastering for the device */
 	if (pci_vfio_set_bus_master(vfio_dev_fd, true)) {
 		RTE_LOG(ERR, EAL, "Cannot set up bus mastering!\n");
@@ -789,7 +826,8 @@ pci_vfio_map_resource_primary(struct rte_pci_device *dev)
 err_vfio_res:
 	rte_free(vfio_res);
 err_vfio_dev_fd:
-	close(vfio_dev_fd);
+	rte_vfio_release_device(rte_pci_get_sysfs_path(),
+			pci_addr, vfio_dev_fd);
 	return -1;
 }
 
@@ -857,7 +895,8 @@ pci_vfio_map_resource_secondary(struct rte_pci_device *dev)
 
 	return 0;
 err_vfio_dev_fd:
-	close(vfio_dev_fd);
+	rte_vfio_release_device(rte_pci_get_sysfs_path(),
+			pci_addr, vfio_dev_fd);
 	return -1;
 }
 
@@ -966,7 +1005,7 @@ pci_vfio_unmap_resource_primary(struct rte_pci_device *dev)
 	}
 
 	TAILQ_REMOVE(vfio_res_list, vfio_res, next);
-
+	rte_free(vfio_res);
 	return 0;
 }
 
diff --git a/dpdk/drivers/bus/pci/pci_common.c b/dpdk/drivers/bus/pci/pci_common.c
index 3f55420769..ab73c009ac 100644
--- a/dpdk/drivers/bus/pci/pci_common.c
+++ b/dpdk/drivers/bus/pci/pci_common.c
@@ -288,8 +288,8 @@ pci_probe_all_drivers(struct rte_pci_device *dev)
  * all registered drivers that have a matching entry in its id_table
  * for discovered devices.
  */
-int
-rte_pci_probe(void)
+static int
+pci_probe(void)
 {
 	struct rte_pci_device *dev = NULL;
 	size_t probed = 0, failed = 0;
@@ -675,7 +675,7 @@ rte_pci_get_iommu_class(void)
 struct rte_pci_bus rte_pci_bus = {
 	.bus = {
 		.scan = rte_pci_scan,
-		.probe = rte_pci_probe,
+		.probe = pci_probe,
 		.find_device = pci_find_device,
 		.plug = pci_plug,
 		.unplug = pci_unplug,
diff --git a/dpdk/drivers/bus/pci/pci_common_uio.c b/dpdk/drivers/bus/pci/pci_common_uio.c
index 7ea73dbc5b..f4dca9da91 100644
--- a/dpdk/drivers/bus/pci/pci_common_uio.c
+++ b/dpdk/drivers/bus/pci/pci_common_uio.c
@@ -70,6 +70,7 @@ pci_uio_map_secondary(struct rte_pci_device *dev)
 				}
 				return -1;
 			}
+			dev->mem_resource[i].addr = mapaddr;
 		}
 		return 0;
 	}
diff --git a/dpdk/drivers/bus/pci/private.h b/dpdk/drivers/bus/pci/private.h
index a205d4d9f0..81735e4c0a 100644
--- a/dpdk/drivers/bus/pci/private.h
+++ b/dpdk/drivers/bus/pci/private.h
@@ -15,18 +15,6 @@ extern struct rte_pci_bus rte_pci_bus;
 struct rte_pci_driver;
 struct rte_pci_device;
 
-extern struct rte_pci_bus rte_pci_bus;
-
-/**
- * Probe the PCI bus
- *
- * @return
- *   - 0 on success.
- *   - !0 on error.
- */
-int
-rte_pci_probe(void);
-
 /**
  * Scan the content of the PCI bus, and the devices in the devices
  * list
@@ -67,19 +55,6 @@ void rte_pci_add_device(struct rte_pci_device *pci_dev);
 void rte_pci_insert_device(struct rte_pci_device *exist_pci_dev,
 		struct rte_pci_device *new_pci_dev);
 
-/**
- * Update a pci device object by asking the kernel for the latest information.
- *
- * This function is private to EAL.
- *
- * @param addr
- *	The PCI Bus-Device-Function address to look for
- * @return
- *   - 0 on success.
- *   - negative on error.
- */
-int pci_update_device(const struct rte_pci_addr *addr);
-
 /**
  * Map the PCI resource of a PCI device in virtual memory
  *
diff --git a/dpdk/drivers/bus/vdev/rte_bus_vdev.h b/dpdk/drivers/bus/vdev/rte_bus_vdev.h
index 2bc46530c9..78a032cea8 100644
--- a/dpdk/drivers/bus/vdev/rte_bus_vdev.h
+++ b/dpdk/drivers/bus/vdev/rte_bus_vdev.h
@@ -155,7 +155,7 @@ int rte_vdev_init(const char *name, const char *args);
  * Uninitalize a driver specified by name.
  *
  * @param name
- *   The pointer to a driver name to be initialized.
+ *   The pointer to a driver name to be uninitialized.
  * @return
  *  0 on success, negative on error
  */
diff --git a/dpdk/drivers/bus/vmbus/linux/vmbus_uio.c b/dpdk/drivers/bus/vmbus/linux/vmbus_uio.c
index 10e50c9b5a..5dc0c47de6 100644
--- a/dpdk/drivers/bus/vmbus/linux/vmbus_uio.c
+++ b/dpdk/drivers/bus/vmbus/linux/vmbus_uio.c
@@ -165,7 +165,7 @@ vmbus_uio_map_resource_by_index(struct rte_vmbus_device *dev, int idx,
 	dev->resource[idx].addr = mapaddr;
 	vmbus_map_addr = RTE_PTR_ADD(mapaddr, size);
 
-	/* Record result of sucessful mapping for use by secondary */
+	/* Record result of successful mapping for use by secondary */
 	maps[idx].addr = mapaddr;
 	maps[idx].size = size;
 
@@ -242,7 +242,7 @@ static int vmbus_uio_map_subchan(const struct rte_vmbus_device *dev,
 	*ring_size = file_size / 2;
 	*ring_buf = mapaddr;
 
-	vmbus_map_addr = RTE_PTR_ADD(ring_buf, file_size);
+	vmbus_map_addr = RTE_PTR_ADD(mapaddr, file_size);
 	return 0;
 }
 
diff --git a/dpdk/drivers/bus/vmbus/vmbus_common.c b/dpdk/drivers/bus/vmbus/vmbus_common.c
index 48a219f735..3adef01c95 100644
--- a/dpdk/drivers/bus/vmbus/vmbus_common.c
+++ b/dpdk/drivers/bus/vmbus/vmbus_common.c
@@ -131,7 +131,7 @@ vmbus_probe_one_driver(struct rte_vmbus_driver *dr,
 }
 
 /*
- * IF device class GUID mathces, call the probe function of
+ * If device class GUID matches, call the probe function of
  * registere drivers for the vmbus device.
  * Return -1 if initialization failed,
  * and 1 if no driver found for this device.
diff --git a/dpdk/drivers/common/cpt/cpt_ucode.h b/dpdk/drivers/common/cpt/cpt_ucode.h
index d5a0135d73..e92e3678c6 100644
--- a/dpdk/drivers/common/cpt/cpt_ucode.h
+++ b/dpdk/drivers/common/cpt/cpt_ucode.h
@@ -298,7 +298,7 @@ cpt_fc_ciph_set_key(void *ctx, cipher_type_t type, const uint8_t *key,
 		cpt_fc_ciph_set_key_kasumi_f8_cbc(cpt_ctx, key, key_len);
 		goto success;
 	default:
-		break;
+		return -1;
 	}
 
 	/* Only for FC_GEN case */
@@ -377,7 +377,7 @@ fill_sg_comp_from_iov(sg_comp_t *list,
 {
 	int32_t j;
 	uint32_t extra_len = extra_buf ? extra_buf->size : 0;
-	uint32_t size = *psize - extra_len;
+	uint32_t size = *psize;
 	buf_ptr_t *bufs;
 
 	bufs = from->bufs;
@@ -386,9 +386,6 @@ fill_sg_comp_from_iov(sg_comp_t *list,
 		uint32_t e_len;
 		sg_comp_t *to = &list[i >> 2];
 
-		if (!bufs[j].size)
-			continue;
-
 		if (unlikely(from_offset)) {
 			if (from_offset >= bufs[j].size) {
 				from_offset -= bufs[j].size;
@@ -420,18 +417,19 @@ fill_sg_comp_from_iov(sg_comp_t *list,
 				to->u.s.len[i % 4] = rte_cpu_to_be_16(e_len);
 			}
 
+			extra_len = RTE_MIN(extra_len, size);
 			/* Insert extra data ptr */
 			if (extra_len) {
 				i++;
 				to = &list[i >> 2];
 				to->u.s.len[i % 4] =
-					rte_cpu_to_be_16(extra_buf->size);
+					rte_cpu_to_be_16(extra_len);
 				to->ptr[i % 4] =
 					rte_cpu_to_be_64(extra_buf->dma_addr);
-
-				/* size already decremented by extra len */
+				size -= extra_len;
 			}
 
+			next_len = RTE_MIN(next_len, size);
 			/* insert the rest of the data */
 			if (next_len) {
 				i++;
@@ -720,9 +718,6 @@ cpt_enc_hmac_prep(uint32_t flags,
 	m_vaddr = (uint8_t *)m_vaddr + size;
 	m_dma += size;
 
-	if (hash_type == GMAC_TYPE)
-		encr_data_len = 0;
-
 	if (unlikely(!(flags & VALID_IV_BUF))) {
 		iv_len = 0;
 		iv_offset = ENCR_IV_OFFSET(d_offs);
@@ -754,6 +749,11 @@ cpt_enc_hmac_prep(uint32_t flags,
 	opcode.s.major = CPT_MAJOR_OP_FC;
 	opcode.s.minor = 0;
 
+	if (hash_type == GMAC_TYPE) {
+		encr_offset = 0;
+		encr_data_len = 0;
+	}
+
 	auth_dlen = auth_offset + auth_data_len;
 	enc_dlen = encr_data_len + encr_offset;
 	if (unlikely(encr_data_len & 0xf)) {
@@ -764,11 +764,6 @@ cpt_enc_hmac_prep(uint32_t flags,
 			enc_dlen = ROUNDUP16(encr_data_len) + encr_offset;
 	}
 
-	if (unlikely(hash_type == GMAC_TYPE)) {
-		encr_offset = auth_dlen;
-		enc_dlen = 0;
-	}
-
 	if (unlikely(auth_dlen > enc_dlen)) {
 		inputlen = auth_dlen;
 		outputlen = auth_dlen + mac_len;
@@ -1071,9 +1066,6 @@ cpt_dec_hmac_prep(uint32_t flags,
 	hash_type = cpt_ctx->hash_type;
 	mac_len = cpt_ctx->mac_len;
 
-	if (hash_type == GMAC_TYPE)
-		encr_data_len = 0;
-
 	if (unlikely(!(flags & VALID_IV_BUF))) {
 		iv_len = 0;
 		iv_offset = ENCR_IV_OFFSET(d_offs);
@@ -1130,6 +1122,11 @@ cpt_dec_hmac_prep(uint32_t flags,
 	opcode.s.major = CPT_MAJOR_OP_FC;
 	opcode.s.minor = 1;
 
+	if (hash_type == GMAC_TYPE) {
+		encr_offset = 0;
+		encr_data_len = 0;
+	}
+
 	enc_dlen = encr_offset + encr_data_len;
 	auth_dlen = auth_offset + auth_data_len;
 
@@ -1141,9 +1138,6 @@ cpt_dec_hmac_prep(uint32_t flags,
 		outputlen = enc_dlen;
 	}
 
-	if (hash_type == GMAC_TYPE)
-		encr_offset = inputlen;
-
 	vq_cmd_w0.u64 = 0;
 	vq_cmd_w0.s.param1 = encr_data_len;
 	vq_cmd_w0.s.param2 = auth_data_len;
@@ -2620,10 +2614,13 @@ fill_sess_aead(struct rte_crypto_sym_xform *xform,
 	sess->iv_length = aead_form->iv.length;
 	sess->aad_length = aead_form->aad_length;
 
-	cpt_fc_ciph_set_key(ctx, enc_type, aead_form->key.data,
-			aead_form->key.length, NULL);
+	if (unlikely(cpt_fc_ciph_set_key(ctx, enc_type, aead_form->key.data,
+			aead_form->key.length, NULL)))
+		return -1;
 
-	cpt_fc_auth_set_key(ctx, auth_type, NULL, 0, aead_form->digest_length);
+	if (unlikely(cpt_fc_auth_set_key(ctx, auth_type, NULL, 0,
+			aead_form->digest_length)))
+		return -1;
 
 	return 0;
 }
@@ -2723,8 +2720,9 @@ fill_sess_cipher(struct rte_crypto_sym_xform *xform,
 	sess->iv_length = c_form->iv.length;
 	sess->is_null = is_null;
 
-	cpt_fc_ciph_set_key(SESS_PRIV(sess), enc_type, c_form->key.data,
-			    c_form->key.length, NULL);
+	if (unlikely(cpt_fc_ciph_set_key(SESS_PRIV(sess), enc_type,
+			c_form->key.data, c_form->key.length, NULL)))
+		return -1;
 
 	return 0;
 }
@@ -2823,8 +2821,10 @@ fill_sess_auth(struct rte_crypto_sym_xform *xform,
 		sess->auth_iv_offset = a_form->iv.offset;
 		sess->auth_iv_length = a_form->iv.length;
 	}
-	cpt_fc_auth_set_key(SESS_PRIV(sess), auth_type, a_form->key.data,
-			    a_form->key.length, a_form->digest_length);
+	if (unlikely(cpt_fc_auth_set_key(SESS_PRIV(sess), auth_type,
+			a_form->key.data, a_form->key.length,
+			a_form->digest_length)))
+		return -1;
 
 	return 0;
 }
@@ -2867,9 +2867,13 @@ fill_sess_gmac(struct rte_crypto_sym_xform *xform,
 	sess->iv_length = a_form->iv.length;
 	sess->mac_len = a_form->digest_length;
 
-	cpt_fc_ciph_set_key(ctx, enc_type, a_form->key.data,
-			a_form->key.length, NULL);
-	cpt_fc_auth_set_key(ctx, auth_type, NULL, 0, a_form->digest_length);
+	if (unlikely(cpt_fc_ciph_set_key(ctx, enc_type, a_form->key.data,
+			a_form->key.length, NULL)))
+		return -1;
+
+	if (unlikely(cpt_fc_auth_set_key(ctx, auth_type, NULL, 0,
+			a_form->digest_length)))
+		return -1;
 
 	return 0;
 }
diff --git a/dpdk/drivers/common/dpaax/caamflib/desc.h b/dpdk/drivers/common/dpaax/caamflib/desc.h
index e4139aaa9f..635d6bad07 100644
--- a/dpdk/drivers/common/dpaax/caamflib/desc.h
+++ b/dpdk/drivers/common/dpaax/caamflib/desc.h
@@ -26,7 +26,7 @@ extern enum rta_sec_era rta_sec_era;
 #define CAAM_CMD_SZ sizeof(uint32_t)
 #define CAAM_PTR_SZ sizeof(dma_addr_t)
 #define CAAM_DESC_BYTES_MAX (CAAM_CMD_SZ * MAX_CAAM_DESCSIZE)
-#define DESC_JOB_IO_LEN (CAAM_CMD_SZ * 5 + CAAM_PTR_SZ * 3)
+#define DESC_JOB_IO_LEN (CAAM_CMD_SZ * 7 + CAAM_PTR_SZ * 3)
 
 /* Block size of any entity covered/uncovered with a KEK/TKEK */
 #define KEK_BLOCKSIZE		16
diff --git a/dpdk/drivers/common/dpaax/caamflib/desc/pdcp.h b/dpdk/drivers/common/dpaax/caamflib/desc/pdcp.h
index b5e2d24e47..476115323c 100644
--- a/dpdk/drivers/common/dpaax/caamflib/desc/pdcp.h
+++ b/dpdk/drivers/common/dpaax/caamflib/desc/pdcp.h
@@ -1,6 +1,6 @@
 /* SPDX-License-Identifier: BSD-3-Clause or GPL-2.0+
  * Copyright 2008-2013 Freescale Semiconductor, Inc.
- * Copyright 2019 NXP
+ * Copyright 2019-2020 NXP
  */
 
 #ifndef __DESC_PDCP_H__
@@ -262,6 +262,50 @@ enum pdb_type_e {
 	PDCP_PDB_TYPE_INVALID
 };
 
+/**
+ * rta_inline_pdcp_query() - Provide indications if a key can be passed as
+ *                           immediate data or shall be referenced in a
+ *                           shared descriptor.
+ * Return: 0 if data can be inlined or 1 if referenced.
+ */
+static inline int
+rta_inline_pdcp_query(enum auth_type_pdcp auth_alg,
+		      enum cipher_type_pdcp cipher_alg,
+		      enum pdcp_sn_size sn_size,
+		      int8_t hfn_ovd)
+{
+	/**
+	 * Shared Descriptors for some of the cases does not fit in the
+	 * MAX_DESC_SIZE of the descriptor especially when non-protocol
+	 * descriptors are formed as in 18bit cases and when HFN override
+	 * is enabled as 2 extra words are added in the job descriptor.
+	 * The cases which exceed are for RTA_SEC_ERA=8 and HFN override
+	 * enabled and 18bit uplane and either of following Algo combinations.
+	 * - SNOW-AES
+	 * - AES-SNOW
+	 * - SNOW-SNOW
+	 * - ZUC-SNOW
+	 *
+	 * We cannot make inline for all cases, as this will impact performance
+	 * due to extra memory accesses for the keys.
+	 */
+	if ((rta_sec_era == RTA_SEC_ERA_8) && hfn_ovd &&
+			(sn_size == PDCP_SN_SIZE_18) &&
+			((cipher_alg == PDCP_CIPHER_TYPE_SNOW &&
+				auth_alg == PDCP_AUTH_TYPE_AES) ||
+			(cipher_alg == PDCP_CIPHER_TYPE_AES &&
+				auth_alg == PDCP_AUTH_TYPE_SNOW) ||
+			(cipher_alg == PDCP_CIPHER_TYPE_SNOW &&
+				auth_alg == PDCP_AUTH_TYPE_SNOW) ||
+			(cipher_alg == PDCP_CIPHER_TYPE_ZUC &&
+				auth_alg == PDCP_AUTH_TYPE_SNOW))) {
+
+		return 1;
+	}
+
+	return 0;
+}
+
 /*
  * Function for appending the portion of a PDCP Control Plane shared descriptor
  * which performs NULL encryption and integrity (i.e. copies the input frame
@@ -3484,6 +3528,15 @@ cnstr_shdsc_pdcp_u_plane_decap(uint32_t *descbuf,
 				KEY(p, KEY2, authdata->key_enc_flags,
 				    (uint64_t)authdata->key, authdata->keylen,
 				    INLINE_KEY(authdata));
+			else if (authdata && authdata->algtype == 0) {
+				err = pdcp_insert_uplane_with_int_op(p, swap,
+						cipherdata, authdata,
+						sn_size, era_2_sw_hfn_ovrd,
+						OP_TYPE_DECAP_PROTOCOL);
+				if (err)
+					return err;
+				break;
+			}
 
 			/* Insert Cipher Key */
 			KEY(p, KEY1, cipherdata->key_enc_flags,
diff --git a/dpdk/drivers/common/octeontx/octeontx_mbox.c b/dpdk/drivers/common/octeontx/octeontx_mbox.c
index 2fd2531072..effe0b267e 100644
--- a/dpdk/drivers/common/octeontx/octeontx_mbox.c
+++ b/dpdk/drivers/common/octeontx/octeontx_mbox.c
@@ -279,7 +279,7 @@ octeontx_start_domain(void)
 }
 
 static int
-octeontx_check_mbox_version(struct mbox_intf_ver app_intf_ver,
+octeontx_check_mbox_version(struct mbox_intf_ver *app_intf_ver,
 			    struct mbox_intf_ver *intf_ver)
 {
 	struct mbox_intf_ver kernel_intf_ver = {0};
@@ -290,8 +290,9 @@ octeontx_check_mbox_version(struct mbox_intf_ver app_intf_ver,
 	hdr.coproc = NO_COPROC;
 	hdr.msg = RM_INTERFACE_VERSION;
 
-	result = octeontx_mbox_send(&hdr, &app_intf_ver, sizeof(app_intf_ver),
-			&kernel_intf_ver, sizeof(kernel_intf_ver));
+	result = octeontx_mbox_send(&hdr, app_intf_ver,
+				    sizeof(struct mbox_intf_ver),
+				    &kernel_intf_ver, sizeof(kernel_intf_ver));
 	if (result != sizeof(kernel_intf_ver)) {
 		mbox_log_err("Could not send interface version. Err=%d. FuncErr=%d\n",
 			     result, hdr.res_code);
@@ -301,9 +302,9 @@ octeontx_check_mbox_version(struct mbox_intf_ver app_intf_ver,
 	if (intf_ver)
 		*intf_ver = kernel_intf_ver;
 
-	if (app_intf_ver.platform != kernel_intf_ver.platform ||
-			app_intf_ver.major != kernel_intf_ver.major ||
-			app_intf_ver.minor != kernel_intf_ver.minor)
+	if (app_intf_ver->platform != kernel_intf_ver.platform ||
+			app_intf_ver->major != kernel_intf_ver.major ||
+			app_intf_ver->minor != kernel_intf_ver.minor)
 		result = -EINVAL;
 
 	return result;
@@ -312,7 +313,7 @@ octeontx_check_mbox_version(struct mbox_intf_ver app_intf_ver,
 int
 octeontx_mbox_init(void)
 {
-	const struct mbox_intf_ver MBOX_INTERFACE_VERSION = {
+	struct mbox_intf_ver MBOX_INTERFACE_VERSION = {
 		.platform = 0x01,
 		.major = 0x01,
 		.minor = 0x03
@@ -330,7 +331,7 @@ octeontx_mbox_init(void)
 		return ret;
 	}
 
-	ret = octeontx_check_mbox_version(MBOX_INTERFACE_VERSION,
+	ret = octeontx_check_mbox_version(&MBOX_INTERFACE_VERSION,
 					  &rm_intf_ver);
 	if (ret < 0) {
 		mbox_log_err("MBOX version: Kernel(%d.%d.%d) != DPDK(%d.%d.%d)",
diff --git a/dpdk/drivers/common/octeontx2/hw/otx2_npc.h b/dpdk/drivers/common/octeontx2/hw/otx2_npc.h
index a0536e0aed..600084ff31 100644
--- a/dpdk/drivers/common/octeontx2/hw/otx2_npc.h
+++ b/dpdk/drivers/common/octeontx2/hw/otx2_npc.h
@@ -201,7 +201,8 @@ enum npc_kpu_lb_ltype {
 };
 
 enum npc_kpu_lc_ltype {
-	NPC_LT_LC_IP = 1,
+	NPC_LT_LC_PTP = 1,
+	NPC_LT_LC_IP,
 	NPC_LT_LC_IP_OPT,
 	NPC_LT_LC_IP6,
 	NPC_LT_LC_IP6_EXT,
@@ -209,11 +210,10 @@ enum npc_kpu_lc_ltype {
 	NPC_LT_LC_RARP,
 	NPC_LT_LC_MPLS,
 	NPC_LT_LC_NSH,
-	NPC_LT_LC_PTP,
 	NPC_LT_LC_FCOE,
 };
 
-/* Don't modify Ltypes upto SCTP, otherwise it will
+/* Don't modify Ltypes up to SCTP, otherwise it will
  * effect flow tag calculation and thus RSS.
  */
 enum npc_kpu_ld_ltype {
@@ -260,7 +260,7 @@ enum npc_kpu_lg_ltype {
 	NPC_LT_LG_TU_ETHER_IN_NSH,
 };
 
-/* Don't modify Ltypes upto SCTP, otherwise it will
+/* Don't modify Ltypes up to SCTP, otherwise it will
  * effect flow tag calculation and thus RSS.
  */
 enum npc_kpu_lh_ltype {
diff --git a/dpdk/drivers/common/octeontx2/otx2_io_arm64.h b/dpdk/drivers/common/octeontx2/otx2_io_arm64.h
index 7e45329b38..3380c9874f 100644
--- a/dpdk/drivers/common/octeontx2/otx2_io_arm64.h
+++ b/dpdk/drivers/common/octeontx2/otx2_io_arm64.h
@@ -21,6 +21,12 @@
 #define otx2_prefetch_store_keep(ptr) ({\
 	asm volatile("prfm pstl1keep, [%x0]\n" : : "r" (ptr)); })
 
+#if defined(__ARM_FEATURE_SVE)
+#define __LSE_PREAMBLE " .cpu  generic+lse+sve\n"
+#else
+#define __LSE_PREAMBLE " .cpu  generic+lse\n"
+#endif
+
 static __rte_always_inline uint64_t
 otx2_atomic64_add_nosync(int64_t incr, int64_t *ptr)
 {
@@ -28,7 +34,7 @@ otx2_atomic64_add_nosync(int64_t incr, int64_t *ptr)
 
 	/* Atomic add with no ordering */
 	asm volatile (
-		".cpu  generic+lse\n"
+		__LSE_PREAMBLE
 		"ldadd %x[i], %x[r], [%[b]]"
 		: [r] "=r" (result), "+m" (*ptr)
 		: [i] "r" (incr), [b] "r" (ptr)
@@ -43,7 +49,7 @@ otx2_atomic64_add_sync(int64_t incr, int64_t *ptr)
 
 	/* Atomic add with ordering */
 	asm volatile (
-		".cpu  generic+lse\n"
+		__LSE_PREAMBLE
 		"ldadda %x[i], %x[r], [%[b]]"
 		: [r] "=r" (result), "+m" (*ptr)
 		: [i] "r" (incr), [b] "r" (ptr)
@@ -57,7 +63,7 @@ otx2_lmt_submit(rte_iova_t io_address)
 	uint64_t result;
 
 	asm volatile (
-		".cpu  generic+lse\n"
+		__LSE_PREAMBLE
 		"ldeor xzr,%x[rf],[%[rs]]" :
 		 [rf] "=r"(result): [rs] "r"(io_address));
 	return result;
@@ -92,4 +98,5 @@ otx2_lmt_mov_seg(void *out, const void *in, const uint16_t segdw)
 		dst128[i] = src128[i];
 }
 
+#undef __LSE_PREAMBLE
 #endif /* _OTX2_IO_ARM64_H_ */
diff --git a/dpdk/drivers/common/octeontx2/otx2_mbox.c b/dpdk/drivers/common/octeontx2/otx2_mbox.c
index c359bf42f3..18bf5b88ee 100644
--- a/dpdk/drivers/common/octeontx2/otx2_mbox.c
+++ b/dpdk/drivers/common/octeontx2/otx2_mbox.c
@@ -9,6 +9,7 @@
 
 #include <rte_atomic.h>
 #include <rte_cycles.h>
+#include <rte_malloc.h>
 
 #include "otx2_mbox.h"
 
@@ -35,7 +36,7 @@ otx2_mbox_fini(struct otx2_mbox *mbox)
 {
 	mbox->reg_base = 0;
 	mbox->hwbase = 0;
-	free(mbox->dev);
+	rte_free(mbox->dev);
 	mbox->dev = NULL;
 }
 
@@ -126,7 +127,9 @@ otx2_mbox_init(struct otx2_mbox *mbox, uintptr_t hwbase,
 		return -ENODEV;
 	}
 
-	mbox->dev = malloc(ndevs * sizeof(struct otx2_mbox_dev));
+	mbox->dev = rte_zmalloc("mbox dev",
+				ndevs * sizeof(struct otx2_mbox_dev),
+				OTX2_ALIGN);
 	if (!mbox->dev) {
 		otx2_mbox_fini(mbox);
 		return -ENOMEM;
diff --git a/dpdk/drivers/common/qat/qat_adf/icp_qat_fw.h b/dpdk/drivers/common/qat/qat_adf/icp_qat_fw.h
index 8f7cb37b43..be10fc9bde 100644
--- a/dpdk/drivers/common/qat/qat_adf/icp_qat_fw.h
+++ b/dpdk/drivers/common/qat/qat_adf/icp_qat_fw.h
@@ -121,6 +121,8 @@ struct icp_qat_fw_comn_resp {
 #define ICP_QAT_FW_COMN_CNV_FLAG_MASK 0x1
 #define ICP_QAT_FW_COMN_CNVNR_FLAG_BITPOS 5
 #define ICP_QAT_FW_COMN_CNVNR_FLAG_MASK 0x1
+#define ICP_QAT_FW_COMN_NULL_VERSION_FLAG_BITPOS 0
+#define ICP_QAT_FW_COMN_NULL_VERSION_FLAG_MASK 0x1
 
 #define ICP_QAT_FW_COMN_OV_SRV_TYPE_GET(icp_qat_fw_comn_req_hdr_t) \
 	icp_qat_fw_comn_req_hdr_t.service_type
@@ -175,6 +177,9 @@ struct icp_qat_fw_comn_resp {
 #define QAT_COMN_PTR_TYPE_SGL 0x1
 #define QAT_COMN_CD_FLD_TYPE_64BIT_ADR 0x0
 #define QAT_COMN_CD_FLD_TYPE_16BYTE_DATA 0x1
+#define QAT_COMN_EXT_FLAGS_BITPOS 8
+#define QAT_COMN_EXT_FLAGS_MASK 0x1
+#define QAT_COMN_EXT_FLAGS_USED 0x1
 
 #define ICP_QAT_FW_COMN_FLAGS_BUILD(cdt, ptr) \
 	((((cdt) & QAT_COMN_CD_FLD_TYPE_MASK) << QAT_COMN_CD_FLD_TYPE_BITPOS) \
diff --git a/dpdk/drivers/common/qat/qat_adf/icp_qat_fw_la.h b/dpdk/drivers/common/qat/qat_adf/icp_qat_fw_la.h
index 38891eb1f9..20eb145def 100644
--- a/dpdk/drivers/common/qat/qat_adf/icp_qat_fw_la.h
+++ b/dpdk/drivers/common/qat/qat_adf/icp_qat_fw_la.h
@@ -273,6 +273,8 @@ struct icp_qat_fw_cipher_auth_cd_ctrl_hdr {
 
 #define ICP_QAT_FW_AUTH_HDR_FLAG_DO_NESTED 1
 #define ICP_QAT_FW_AUTH_HDR_FLAG_NO_NESTED 0
+#define ICP_QAT_FW_AUTH_HDR_FLAG_SNOW3G_UIA2_BITPOS 3
+#define ICP_QAT_FW_AUTH_HDR_FLAG_ZUC_EIA3_BITPOS 4
 #define ICP_QAT_FW_CCM_GCM_AAD_SZ_MAX	240
 #define ICP_QAT_FW_HASH_REQUEST_PARAMETERS_OFFSET 24
 #define ICP_QAT_FW_CIPHER_REQUEST_PARAMETERS_OFFSET (0)
diff --git a/dpdk/drivers/common/qat/qat_common.c b/dpdk/drivers/common/qat/qat_common.c
index 4753866976..5343a1451e 100644
--- a/dpdk/drivers/common/qat/qat_common.c
+++ b/dpdk/drivers/common/qat/qat_common.c
@@ -94,6 +94,9 @@ void qat_stats_get(struct qat_pci_device *dev,
 		stats->dequeued_count += qp[i]->stats.dequeued_count;
 		stats->enqueue_err_count += qp[i]->stats.enqueue_err_count;
 		stats->dequeue_err_count += qp[i]->stats.dequeue_err_count;
+		stats->threshold_hit_count += qp[i]->stats.threshold_hit_count;
+		QAT_LOG(DEBUG, "Threshold was used for qp %d %"PRIu64" times",
+				i, stats->threshold_hit_count);
 	}
 }
 
diff --git a/dpdk/drivers/common/qat/qat_common.h b/dpdk/drivers/common/qat/qat_common.h
index de9a3ba555..cf840fea9b 100644
--- a/dpdk/drivers/common/qat/qat_common.h
+++ b/dpdk/drivers/common/qat/qat_common.h
@@ -61,6 +61,9 @@ struct qat_common_stats {
 	/**< Total error count on operations enqueued */
 	uint64_t dequeue_err_count;
 	/**< Total error count on operations dequeued */
+	uint64_t threshold_hit_count;
+	/**< Total number of times min qp threshold condition was fulfilled */
+
 };
 
 struct qat_pci_device;
diff --git a/dpdk/drivers/common/qat/qat_device.c b/dpdk/drivers/common/qat/qat_device.c
index 2a1cf3e179..e3d2b9c79a 100644
--- a/dpdk/drivers/common/qat/qat_device.c
+++ b/dpdk/drivers/common/qat/qat_device.c
@@ -3,6 +3,8 @@
  */
 
 #include <rte_string_fns.h>
+#include <rte_devargs.h>
+#include <ctype.h>
 
 #include "qat_device.h"
 #include "adf_transport_access_macros.h"
@@ -30,8 +32,8 @@ struct qat_gen_hw_data qat_gen_config[] =  {
 	},
 };
 
-
-static struct qat_pci_device qat_pci_devices[RTE_PMD_QAT_MAX_PCI_DEVICES];
+/* per-process array of device data */
+struct qat_device_info qat_pci_devs[RTE_PMD_QAT_MAX_PCI_DEVICES];
 static int qat_nb_pci_devices;
 
 /*
@@ -57,27 +59,21 @@ static const struct rte_pci_id pci_id_qat_map[] = {
 		{.device_id = 0},
 };
 
-static struct qat_pci_device *
-qat_pci_get_dev(uint8_t dev_id)
-{
-	return &qat_pci_devices[dev_id];
-}
-
 static struct qat_pci_device *
 qat_pci_get_named_dev(const char *name)
 {
-	struct qat_pci_device *dev;
 	unsigned int i;
 
 	if (name == NULL)
 		return NULL;
 
 	for (i = 0; i < RTE_PMD_QAT_MAX_PCI_DEVICES; i++) {
-		dev = &qat_pci_devices[i];
-
-		if ((dev->attached == QAT_ATTACHED) &&
-				(strcmp(dev->name, name) == 0))
-			return dev;
+		if (qat_pci_devs[i].mz &&
+				(strcmp(((struct qat_pci_device *)
+				qat_pci_devs[i].mz->addr)->name, name)
+				== 0))
+			return (struct qat_pci_device *)
+				qat_pci_devs[i].mz->addr;
 	}
 
 	return NULL;
@@ -88,8 +84,9 @@ qat_pci_find_free_device_index(void)
 {
 	uint8_t dev_id;
 
-	for (dev_id = 0; dev_id < RTE_PMD_QAT_MAX_PCI_DEVICES; dev_id++) {
-		if (qat_pci_devices[dev_id].attached == QAT_DETACHED)
+	for (dev_id = 0; dev_id < RTE_PMD_QAT_MAX_PCI_DEVICES;
+			dev_id++) {
+		if (qat_pci_devs[dev_id].mz == NULL)
 			break;
 	}
 	return dev_id;
@@ -105,15 +102,95 @@ qat_get_qat_dev_from_pci_dev(struct rte_pci_device *pci_dev)
 	return qat_pci_get_named_dev(name);
 }
 
+static void qat_dev_parse_cmd(const char *str, struct qat_dev_cmd_param
+		*qat_dev_cmd_param)
+{
+	int i = 0;
+	const char *param;
+
+	while (1) {
+		char value_str[4] = { };
+
+		param = qat_dev_cmd_param[i].name;
+		if (param == NULL)
+			return;
+		long value = 0;
+		const char *arg = strstr(str, param);
+		const char *arg2 = NULL;
+
+		if (arg) {
+			arg2 = arg + strlen(param);
+			if (*arg2 != '=') {
+			QAT_LOG(DEBUG, "parsing error '=' sign"
+						" should immediately follow %s",
+						param);
+				arg2 = NULL;
+			} else
+				arg2++;
+		} else {
+			QAT_LOG(DEBUG, "%s not provided", param);
+		}
+		if (arg2) {
+			int iter = 0;
+
+			while (iter < 2) {
+				if (!isdigit(*(arg2 + iter)))
+					break;
+				iter++;
+			}
+			if (!iter) {
+				QAT_LOG(DEBUG, "parsing error %s"
+					       " no number provided",
+					       param);
+			} else {
+				memcpy(value_str, arg2, iter);
+				value = strtol(value_str, NULL, 10);
+				if (value > MAX_QP_THRESHOLD_SIZE) {
+					QAT_LOG(DEBUG, "Exceeded max size of"
+						" threshold, setting to %d",
+						MAX_QP_THRESHOLD_SIZE);
+					value = MAX_QP_THRESHOLD_SIZE;
+				}
+				QAT_LOG(DEBUG, "parsing %s = %ld",
+						param, value);
+			}
+		}
+		qat_dev_cmd_param[i].val = value;
+		i++;
+	}
+}
+
 struct qat_pci_device *
-qat_pci_device_allocate(struct rte_pci_device *pci_dev)
+qat_pci_device_allocate(struct rte_pci_device *pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param)
 {
 	struct qat_pci_device *qat_dev;
-	uint8_t qat_dev_id;
+	uint8_t qat_dev_id = 0;
 	char name[QAT_DEV_NAME_MAX_LEN];
+	struct rte_devargs *devargs = pci_dev->device.devargs;
 
 	rte_pci_device_name(&pci_dev->addr, name, sizeof(name));
 	snprintf(name+strlen(name), QAT_DEV_NAME_MAX_LEN-strlen(name), "_qat");
+
+	if (rte_eal_process_type() == RTE_PROC_SECONDARY) {
+		const struct rte_memzone *mz = rte_memzone_lookup(name);
+
+		if (mz == NULL) {
+			QAT_LOG(ERR,
+				"Secondary can't find %s mz, did primary create device?",
+				name);
+			return NULL;
+		}
+		qat_dev = mz->addr;
+		qat_pci_devs[qat_dev->qat_dev_id].mz = mz;
+		qat_pci_devs[qat_dev->qat_dev_id].pci_dev = pci_dev;
+		qat_nb_pci_devices++;
+		QAT_LOG(DEBUG, "QAT device %d found, name %s, total QATs %d",
+			qat_dev->qat_dev_id, qat_dev->name, qat_nb_pci_devices);
+		return qat_dev;
+	}
+
+
 	if (qat_pci_get_named_dev(name) != NULL) {
 		QAT_LOG(ERR, "QAT device with name %s already allocated!",
 				name);
@@ -126,12 +203,22 @@ qat_pci_device_allocate(struct rte_pci_device *pci_dev)
 		return NULL;
 	}
 
-	qat_dev = qat_pci_get_dev(qat_dev_id);
+	qat_pci_devs[qat_dev_id].mz = rte_memzone_reserve(name,
+		sizeof(struct qat_pci_device),
+		rte_socket_id(), 0);
+
+	if (qat_pci_devs[qat_dev_id].mz == NULL) {
+		QAT_LOG(ERR, "Error when allocating memzone for QAT_%d",
+			qat_dev_id);
+		return NULL;
+	}
+
+	qat_dev = qat_pci_devs[qat_dev_id].mz->addr;
 	memset(qat_dev, 0, sizeof(*qat_dev));
 	strlcpy(qat_dev->name, name, QAT_DEV_NAME_MAX_LEN);
 	qat_dev->qat_dev_id = qat_dev_id;
-	qat_dev->pci_dev = pci_dev;
-	switch (qat_dev->pci_dev->id.device_id) {
+	qat_pci_devs[qat_dev_id].pci_dev = pci_dev;
+	switch (pci_dev->id.device_id) {
 	case 0x0443:
 		qat_dev->qat_dev_gen = QAT_GEN1;
 		break;
@@ -145,17 +232,19 @@ qat_pci_device_allocate(struct rte_pci_device *pci_dev)
 		break;
 	default:
 		QAT_LOG(ERR, "Invalid dev_id, can't determine generation");
+		rte_memzone_free(qat_pci_devs[qat_dev->qat_dev_id].mz);
 		return NULL;
 	}
 
-	rte_spinlock_init(&qat_dev->arb_csr_lock);
+	if (devargs && devargs->drv_str)
+		qat_dev_parse_cmd(devargs->drv_str, qat_dev_cmd_param);
 
-	qat_dev->attached = QAT_ATTACHED;
+	rte_spinlock_init(&qat_dev->arb_csr_lock);
 
 	qat_nb_pci_devices++;
 
-	QAT_LOG(DEBUG, "QAT device %d allocated, name %s, total QATs %d",
-			qat_dev->qat_dev_id, qat_dev->name, qat_nb_pci_devices);
+	QAT_LOG(DEBUG, "QAT device %d found, name %s, total QATs %d",
+		qat_dev->qat_dev_id, qat_dev->name, qat_nb_pci_devices);
 
 	return qat_dev;
 }
@@ -165,6 +254,7 @@ qat_pci_device_release(struct rte_pci_device *pci_dev)
 {
 	struct qat_pci_device *qat_dev;
 	char name[QAT_DEV_NAME_MAX_LEN];
+	int busy = 0;
 
 	if (pci_dev == NULL)
 		return -EINVAL;
@@ -174,15 +264,35 @@ qat_pci_device_release(struct rte_pci_device *pci_dev)
 	qat_dev = qat_pci_get_named_dev(name);
 	if (qat_dev != NULL) {
 
+		struct qat_device_info *inst =
+				&qat_pci_devs[qat_dev->qat_dev_id];
 		/* Check that there are no service devs still on pci device */
-		if (qat_dev->sym_dev != NULL)
-			return -EBUSY;
 
-		qat_dev->attached = QAT_DETACHED;
+		if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
+			if (qat_dev->sym_dev != NULL) {
+				QAT_LOG(DEBUG, "QAT sym device %s is busy",
+					name);
+				busy = 1;
+			}
+			if (qat_dev->asym_dev != NULL) {
+				QAT_LOG(DEBUG, "QAT asym device %s is busy",
+					name);
+				busy = 1;
+			}
+			if (qat_dev->comp_dev != NULL) {
+				QAT_LOG(DEBUG, "QAT comp device %s is busy",
+					name);
+				busy = 1;
+			}
+			if (busy)
+				return -EBUSY;
+			rte_memzone_free(inst->mz);
+		}
+		memset(inst, 0, sizeof(struct qat_device_info));
 		qat_nb_pci_devices--;
+		QAT_LOG(DEBUG, "QAT device %s released, total QATs %d",
+					name, qat_nb_pci_devices);
 	}
-	QAT_LOG(DEBUG, "QAT device %s released, total QATs %d",
-				name, qat_nb_pci_devices);
 	return 0;
 }
 
@@ -199,37 +309,44 @@ qat_pci_dev_destroy(struct qat_pci_device *qat_pci_dev,
 static int qat_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
 		struct rte_pci_device *pci_dev)
 {
-	int ret = 0;
+	int sym_ret = 0, asym_ret = 0, comp_ret = 0;
 	int num_pmds_created = 0;
 	struct qat_pci_device *qat_pci_dev;
+	struct qat_dev_cmd_param qat_dev_cmd_param[] = {
+			{ SYM_ENQ_THRESHOLD_NAME, 0 },
+			{ ASYM_ENQ_THRESHOLD_NAME, 0 },
+			{ COMP_ENQ_THRESHOLD_NAME, 0 },
+			{ NULL, 0 },
+	};
 
 	QAT_LOG(DEBUG, "Found QAT device at %02x:%02x.%x",
 			pci_dev->addr.bus,
 			pci_dev->addr.devid,
 			pci_dev->addr.function);
 
-	qat_pci_dev = qat_pci_device_allocate(pci_dev);
+	qat_pci_dev = qat_pci_device_allocate(pci_dev, qat_dev_cmd_param);
 	if (qat_pci_dev == NULL)
 		return -ENODEV;
 
-	ret = qat_sym_dev_create(qat_pci_dev);
-	if (ret == 0)
+	sym_ret = qat_sym_dev_create(qat_pci_dev, qat_dev_cmd_param);
+	if (sym_ret == 0) {
 		num_pmds_created++;
+	}
 	else
 		QAT_LOG(WARNING,
 				"Failed to create QAT SYM PMD on device %s",
 				qat_pci_dev->name);
 
-	ret = qat_comp_dev_create(qat_pci_dev);
-	if (ret == 0)
+	comp_ret = qat_comp_dev_create(qat_pci_dev, qat_dev_cmd_param);
+	if (comp_ret == 0)
 		num_pmds_created++;
 	else
 		QAT_LOG(WARNING,
 				"Failed to create QAT COMP PMD on device %s",
 				qat_pci_dev->name);
 
-	ret = qat_asym_dev_create(qat_pci_dev);
-	if (ret == 0)
+	asym_ret = qat_asym_dev_create(qat_pci_dev, qat_dev_cmd_param);
+	if (asym_ret == 0)
 		num_pmds_created++;
 	else
 		QAT_LOG(WARNING,
@@ -264,13 +381,15 @@ static struct rte_pci_driver rte_qat_pmd = {
 };
 
 __rte_weak int
-qat_sym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused)
+qat_sym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused,
+		struct qat_dev_cmd_param *qat_dev_cmd_param __rte_unused)
 {
 	return 0;
 }
 
 __rte_weak int
-qat_asym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused)
+qat_asym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused,
+		struct qat_dev_cmd_param *qat_dev_cmd_param __rte_unused)
 {
 	return 0;
 }
@@ -288,7 +407,8 @@ qat_asym_dev_destroy(struct qat_pci_device *qat_pci_dev __rte_unused)
 }
 
 __rte_weak int
-qat_comp_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused)
+qat_comp_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused,
+		struct qat_dev_cmd_param *qat_dev_cmd_param __rte_unused)
 {
 	return 0;
 }
@@ -301,3 +421,4 @@ qat_comp_dev_destroy(struct qat_pci_device *qat_pci_dev __rte_unused)
 
 RTE_PMD_REGISTER_PCI(QAT_PCI_NAME, rte_qat_pmd);
 RTE_PMD_REGISTER_PCI_TABLE(QAT_PCI_NAME, pci_id_qat_map);
+RTE_PMD_REGISTER_KMOD_DEP(QAT_PCI_NAME, "* igb_uio | uio_pci_generic | vfio-pci");
diff --git a/dpdk/drivers/common/qat/qat_device.h b/dpdk/drivers/common/qat/qat_device.h
index 131375e838..c3f5ae8990 100644
--- a/dpdk/drivers/common/qat/qat_device.h
+++ b/dpdk/drivers/common/qat/qat_device.h
@@ -16,12 +16,53 @@
 
 #define QAT_DEV_NAME_MAX_LEN	64
 
+#define SYM_ENQ_THRESHOLD_NAME "qat_sym_enq_threshold"
+#define ASYM_ENQ_THRESHOLD_NAME "qat_asym_enq_threshold"
+#define COMP_ENQ_THRESHOLD_NAME "qat_comp_enq_threshold"
+#define MAX_QP_THRESHOLD_SIZE	32
+
+struct qat_dev_cmd_param {
+	const char *name;
+	uint16_t val;
+};
+
 enum qat_comp_num_im_buffers {
 	QAT_NUM_INTERM_BUFS_GEN1 = 12,
 	QAT_NUM_INTERM_BUFS_GEN2 = 20,
 	QAT_NUM_INTERM_BUFS_GEN3 = 20
 };
 
+struct qat_device_info {
+	const struct rte_memzone *mz;
+	/**< mz to store the qat_pci_device so it can be
+	 * shared across processes
+	 */
+	struct rte_pci_device *pci_dev;
+	struct rte_device sym_rte_dev;
+	/**< This represents the crypto sym subset of this pci device.
+	 * Register with this rather than with the one in
+	 * pci_dev so that its driver can have a crypto-specific name
+	 */
+
+	struct rte_device asym_rte_dev;
+	/**< This represents the crypto asym subset of this pci device.
+	 * Register with this rather than with the one in
+	 * pci_dev so that its driver can have a crypto-specific name
+	 */
+
+	struct rte_device comp_rte_dev;
+	/**< This represents the compression subset of this pci device.
+	 * Register with this rather than with the one in
+	 * pci_dev so that its driver can have a compression-specific name
+	 */
+};
+
+extern struct qat_device_info qat_pci_devs[];
+
+struct qat_sym_dev_private;
+struct qat_asym_dev_private;
+struct qat_comp_dev_private;
+
 /*
  * This struct holds all the data about a QAT pci device
  * including data about all services it supports.
@@ -29,27 +70,20 @@ enum qat_comp_num_im_buffers {
  *  - hw_data
  *  - config data
  *  - runtime data
+ * Note: as this data can be shared in a multi-process scenario,
+ * any pointers in it must also point to shared memory.
  */
-struct qat_sym_dev_private;
-struct qat_asym_dev_private;
-struct qat_comp_dev_private;
-
 struct qat_pci_device {
 
 	/* Data used by all services */
 	char name[QAT_DEV_NAME_MAX_LEN];
 	/**< Name of qat pci device */
 	uint8_t qat_dev_id;
-	/**< Device instance for this qat pci device */
-	struct rte_pci_device *pci_dev;
-	/**< PCI information. */
+	/**< Id of device instance for this qat pci device */
 	enum qat_device_gen qat_dev_gen;
 	/**< QAT device generation */
 	rte_spinlock_t arb_csr_lock;
 	/**< lock to protect accesses to the arbiter CSR */
-	__extension__
-	uint8_t attached : 1;
-	/**< Flag indicating the device is attached */
 
 	struct qat_qp *qps_in_use[QAT_MAX_SERVICES][ADF_MAX_QPS_ON_ANY_SERVICE];
 	/**< links to qps set up for each service, index same as on API */
@@ -57,32 +91,20 @@ struct qat_pci_device {
 	/* Data relating to symmetric crypto service */
 	struct qat_sym_dev_private *sym_dev;
 	/**< link back to cryptodev private data */
-	struct rte_device sym_rte_dev;
-	/**< This represents the crypto sym subset of this pci device.
-	 * Register with this rather than with the one in
-	 * pci_dev so that its driver can have a crypto-specific name
-	 */
+
+	int qat_sym_driver_id;
+	/**< Symmetric driver id used by this device */
 
 	/* Data relating to asymmetric crypto service */
 	struct qat_asym_dev_private *asym_dev;
 	/**< link back to cryptodev private data */
-	struct rte_device asym_rte_dev;
-	/**< This represents the crypto asym subset of this pci device.
-	 * Register with this rather than with the one in
-	 * pci_dev so that its driver can have a crypto-specific name
-	 */
+
+	int qat_asym_driver_id;
+	/**< Symmetric driver id used by this device */
 
 	/* Data relating to compression service */
 	struct qat_comp_dev_private *comp_dev;
 	/**< link back to compressdev private data */
-	struct rte_device comp_rte_dev;
-	/**< This represents the compression subset of this pci device.
-	 * Register with this rather than with the one in
-	 * pci_dev so that its driver can have a compression-specific name
-	 */
-
-	/* Data relating to asymmetric crypto service */
-
 };
 
 struct qat_gen_hw_data {
@@ -94,7 +116,8 @@ struct qat_gen_hw_data {
 extern struct qat_gen_hw_data qat_gen_config[];
 
 struct qat_pci_device *
-qat_pci_device_allocate(struct rte_pci_device *pci_dev);
+qat_pci_device_allocate(struct rte_pci_device *pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
 qat_pci_device_release(struct rte_pci_device *pci_dev);
@@ -104,10 +127,12 @@ qat_get_qat_dev_from_pci_dev(struct rte_pci_device *pci_dev);
 
 /* declaration needed for weak functions */
 int
-qat_sym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused);
+qat_sym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
-qat_asym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused);
+qat_asym_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
 qat_sym_dev_destroy(struct qat_pci_device *qat_pci_dev __rte_unused);
@@ -116,7 +141,8 @@ int
 qat_asym_dev_destroy(struct qat_pci_device *qat_pci_dev __rte_unused);
 
 int
-qat_comp_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused);
+qat_comp_dev_create(struct qat_pci_device *qat_pci_dev __rte_unused,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
 qat_comp_dev_destroy(struct qat_pci_device *qat_pci_dev __rte_unused);
diff --git a/dpdk/drivers/common/qat/qat_qp.c b/dpdk/drivers/common/qat/qat_qp.c
index 03f11f869e..3f30871562 100644
--- a/dpdk/drivers/common/qat/qat_qp.c
+++ b/dpdk/drivers/common/qat/qat_qp.c
@@ -3,6 +3,7 @@
  */
 
 #include <rte_common.h>
+#include <rte_cycles.h>
 #include <rte_dev.h>
 #include <rte_malloc.h>
 #include <rte_memzone.h>
@@ -19,6 +20,7 @@
 #include "qat_comp.h"
 #include "adf_transport_access_macros.h"
 
+#define QAT_CQ_MAX_DEQ_RETRIES 10
 
 #define ADF_MAX_DESC				4096
 #define ADF_MIN_DESC				128
@@ -191,7 +193,8 @@ int qat_qp_setup(struct qat_pci_device *qat_dev,
 
 {
 	struct qat_qp *qp;
-	struct rte_pci_device *pci_dev = qat_dev->pci_dev;
+	struct rte_pci_device *pci_dev =
+			qat_pci_devs[qat_dev->qat_dev_id].pci_dev;
 	char op_cookie_pool_name[RTE_RING_NAMESIZE];
 	uint32_t i;
 
@@ -230,7 +233,7 @@ int qat_qp_setup(struct qat_pci_device *qat_dev,
 	}
 
 	qp->mmap_bar_addr = pci_dev->mem_resource[0].addr;
-	qp->inflights16 = 0;
+	qp->enqueued = qp->dequeued = 0;
 
 	if (qat_queue_create(qat_dev, &(qp->tx_q), qat_qp_conf,
 					ADF_RING_DIR_TX) != 0) {
@@ -239,6 +242,15 @@ int qat_qp_setup(struct qat_pci_device *qat_dev,
 		goto create_err;
 	}
 
+	qp->max_inflights = ADF_MAX_INFLIGHTS(qp->tx_q.queue_size,
+				ADF_BYTES_TO_MSG_SIZE(qp->tx_q.msg_size));
+
+	if (qp->max_inflights < 2) {
+		QAT_LOG(ERR, "Invalid num inflights");
+		qat_queue_delete(&(qp->tx_q));
+		goto create_err;
+	}
+
 	if (qat_queue_create(qat_dev, &(qp->rx_q), qat_qp_conf,
 					ADF_RING_DIR_RX) != 0) {
 		QAT_LOG(ERR, "Rx queue create failed "
@@ -263,7 +275,7 @@ int qat_qp_setup(struct qat_pci_device *qat_dev,
 				qp->nb_descriptors,
 				qat_qp_conf->cookie_size, 64, 0,
 				NULL, NULL, NULL, NULL,
-				qat_dev->pci_dev->device.numa_node,
+				pci_dev->device.numa_node,
 				0);
 	if (!qp->op_cookie_pool) {
 		QAT_LOG(ERR, "QAT PMD Cannot create"
@@ -312,7 +324,7 @@ int qat_qp_release(struct qat_qp **qp_addr)
 				qp->qat_dev->qat_dev_id);
 
 	/* Don't free memory if there are still responses to be processed */
-	if (qp->inflights16 == 0) {
+	if ((qp->enqueued - qp->dequeued) == 0) {
 		qat_queue_delete(&(qp->tx_q));
 		qat_queue_delete(&(qp->rx_q));
 	} else {
@@ -368,7 +380,8 @@ qat_queue_create(struct qat_pci_device *qat_dev, struct qat_queue *queue,
 	uint64_t queue_base;
 	void *io_addr;
 	const struct rte_memzone *qp_mz;
-	struct rte_pci_device *pci_dev = qat_dev->pci_dev;
+	struct rte_pci_device *pci_dev =
+			qat_pci_devs[qat_dev->qat_dev_id].pci_dev;
 	int ret = 0;
 	uint16_t desc_size = (dir == ADF_RING_DIR_TX ?
 			qp_conf->hw->tx_msg_size : qp_conf->hw->rx_msg_size);
@@ -392,7 +405,7 @@ qat_queue_create(struct qat_pci_device *qat_dev, struct qat_queue *queue,
 		qp_conf->service_str, "qp_mem",
 		queue->hw_bundle_number, queue->hw_queue_number);
 	qp_mz = queue_dma_zone_reserve(queue->memz_name, queue_size_bytes,
-			qat_dev->pci_dev->device.numa_node);
+			pci_dev->device.numa_node);
 	if (qp_mz == NULL) {
 		QAT_LOG(ERR, "Failed to allocate ring memzone");
 		return -ENOMEM;
@@ -416,15 +429,7 @@ qat_queue_create(struct qat_pci_device *qat_dev, struct qat_queue *queue,
 		goto queue_create_err;
 	}
 
-	queue->max_inflights = ADF_MAX_INFLIGHTS(queue->queue_size,
-					ADF_BYTES_TO_MSG_SIZE(desc_size));
 	queue->modulo_mask = (1 << ADF_RING_SIZE_MODULO(queue->queue_size)) - 1;
-
-	if (queue->max_inflights < 2) {
-		QAT_LOG(ERR, "Invalid num inflights");
-		ret = -EINVAL;
-		goto queue_create_err;
-	}
 	queue->head = 0;
 	queue->tail = 0;
 	queue->msg_size = desc_size;
@@ -443,11 +448,11 @@ qat_queue_create(struct qat_pci_device *qat_dev, struct qat_queue *queue,
 			queue->hw_queue_number, queue_base);
 
 	QAT_LOG(DEBUG, "RING: Name:%s, size in CSR: %u, in bytes %u,"
-		" nb msgs %u, msg_size %u, max_inflights %u modulo mask %u",
+		" nb msgs %u, msg_size %u, modulo mask %u",
 			queue->memz_name,
 			queue->queue_size, queue_size_bytes,
 			qp_conf->nb_descriptors, desc_size,
-			queue->max_inflights, queue->modulo_mask);
+			queue->modulo_mask);
 
 	return 0;
 
@@ -538,7 +543,6 @@ static inline void
 txq_write_tail(struct qat_qp *qp, struct qat_queue *q) {
 	WRITE_CSR_RING_TAIL(qp->mmap_bar_addr, q->hw_bundle_number,
 			q->hw_queue_number, q->tail);
-	q->nb_pending_requests = 0;
 	q->csr_tail = q->tail;
 }
 
@@ -575,11 +579,10 @@ qat_enqueue_op_burst(void *qp, void **ops, uint16_t nb_ops)
 	register struct qat_queue *queue;
 	struct qat_qp *tmp_qp = (struct qat_qp *)qp;
 	register uint32_t nb_ops_sent = 0;
-	register int ret;
+	register int ret = -1;
 	uint16_t nb_ops_possible = nb_ops;
 	register uint8_t *base_addr;
 	register uint32_t tail;
-	int overflow;
 
 	if (unlikely(nb_ops == 0))
 		return 0;
@@ -590,26 +593,59 @@ qat_enqueue_op_burst(void *qp, void **ops, uint16_t nb_ops)
 	tail = queue->tail;
 
 	/* Find how many can actually fit on the ring */
-	tmp_qp->inflights16 += nb_ops;
-	overflow = tmp_qp->inflights16 - queue->max_inflights;
-	if (overflow > 0) {
-		tmp_qp->inflights16 -= overflow;
-		nb_ops_possible = nb_ops - overflow;
-		if (nb_ops_possible == 0)
+	{
+		/* dequeued can only be written by one thread, but it may not
+		 * be this thread. As it's 4-byte aligned it will be read
+		 * atomically here by any Intel CPU.
+		 * enqueued can wrap before dequeued, but cannot
+		 * lap it as var size of enq/deq (uint32_t) > var size of
+		 * max_inflights (uint16_t). In reality inflights is never
+		 * even as big as max uint16_t, as it's <= ADF_MAX_DESC.
+		 * On wrapping, the calculation still returns the correct
+		 * positive value as all three vars are unsigned.
+		 */
+		uint32_t inflights =
+			tmp_qp->enqueued - tmp_qp->dequeued;
+
+		if ((inflights + nb_ops) > tmp_qp->max_inflights) {
+			nb_ops_possible = tmp_qp->max_inflights - inflights;
+			if (nb_ops_possible == 0)
+				return 0;
+		}
+		/* QAT has plenty of work queued already, so don't waste cycles
+		 * enqueueing, wait til the application has gathered a bigger
+		 * burst or some completed ops have been dequeued
+		 */
+		if (tmp_qp->min_enq_burst_threshold && inflights >
+				QAT_QP_MIN_INFL_THRESHOLD && nb_ops_possible <
+				tmp_qp->min_enq_burst_threshold) {
+			tmp_qp->stats.threshold_hit_count++;
 			return 0;
+		}
 	}
 
 	while (nb_ops_sent != nb_ops_possible) {
-		ret = tmp_qp->build_request(*ops, base_addr + tail,
+		if (tmp_qp->service_type == QAT_SERVICE_SYMMETRIC) {
+#ifdef BUILD_QAT_SYM
+			ret = qat_sym_build_request(*ops, base_addr + tail,
+				tmp_qp->op_cookies[tail / queue->msg_size],
+				tmp_qp->qat_dev_gen);
+#endif
+		} else if (tmp_qp->service_type == QAT_SERVICE_COMPRESSION) {
+			ret = qat_comp_build_request(*ops, base_addr + tail,
+				tmp_qp->op_cookies[tail / queue->msg_size],
+				tmp_qp->qat_dev_gen);
+		} else if (tmp_qp->service_type == QAT_SERVICE_ASYMMETRIC) {
+#ifdef BUILD_QAT_ASYM
+			ret = qat_asym_build_request(*ops, base_addr + tail,
 				tmp_qp->op_cookies[tail / queue->msg_size],
 				tmp_qp->qat_dev_gen);
+#endif
+		}
+
 		if (ret != 0) {
 			tmp_qp->stats.enqueue_err_count++;
-			/*
-			 * This message cannot be enqueued,
-			 * decrease number of ops that wasn't sent
-			 */
-			tmp_qp->inflights16 -= nb_ops_possible - nb_ops_sent;
+			/* This message cannot be enqueued */
 			if (nb_ops_sent == 0)
 				return 0;
 			goto kick_tail;
@@ -621,26 +657,22 @@ qat_enqueue_op_burst(void *qp, void **ops, uint16_t nb_ops)
 	}
 kick_tail:
 	queue->tail = tail;
+	tmp_qp->enqueued += nb_ops_sent;
 	tmp_qp->stats.enqueued_count += nb_ops_sent;
-	queue->nb_pending_requests += nb_ops_sent;
-	if (tmp_qp->inflights16 < QAT_CSR_TAIL_FORCE_WRITE_THRESH ||
-		    queue->nb_pending_requests > QAT_CSR_TAIL_WRITE_THRESH) {
-		txq_write_tail(tmp_qp, queue);
-	}
+	txq_write_tail(tmp_qp, queue);
 	return nb_ops_sent;
 }
 
 uint16_t
 qat_dequeue_op_burst(void *qp, void **ops, uint16_t nb_ops)
 {
-	struct qat_queue *rx_queue, *tx_queue;
+	struct qat_queue *rx_queue;
 	struct qat_qp *tmp_qp = (struct qat_qp *)qp;
 	uint32_t head;
 	uint32_t resp_counter = 0;
 	uint8_t *resp_msg;
 
 	rx_queue = &(tmp_qp->rx_q);
-	tx_queue = &(tmp_qp->tx_q);
 	head = rx_queue->head;
 	resp_msg = (uint8_t *)rx_queue->base_addr + rx_queue->head;
 
@@ -669,22 +701,109 @@ qat_dequeue_op_burst(void *qp, void **ops, uint16_t nb_ops)
 	}
 	if (resp_counter > 0) {
 		rx_queue->head = head;
+		tmp_qp->dequeued += resp_counter;
 		tmp_qp->stats.dequeued_count += resp_counter;
 		rx_queue->nb_processed_responses += resp_counter;
-		tmp_qp->inflights16 -= resp_counter;
 
 		if (rx_queue->nb_processed_responses >
 						QAT_CSR_HEAD_WRITE_THRESH)
 			rxq_free_desc(tmp_qp, rx_queue);
 	}
-	/* also check if tail needs to be advanced */
-	if (tmp_qp->inflights16 <= QAT_CSR_TAIL_FORCE_WRITE_THRESH &&
-		tx_queue->tail != tx_queue->csr_tail) {
-		txq_write_tail(tmp_qp, tx_queue);
-	}
+
 	return resp_counter;
 }
 
+/* This is almost same as dequeue_op_burst, without the atomic, without stats
+ * and without the op. Dequeues one response.
+ */
+static uint8_t
+qat_cq_dequeue_response(struct qat_qp *qp, void *out_data)
+{
+	uint8_t result = 0;
+	uint8_t retries = 0;
+	struct qat_queue *queue = &(qp->rx_q);
+	struct icp_qat_fw_comn_resp *resp_msg = (struct icp_qat_fw_comn_resp *)
+			((uint8_t *)queue->base_addr + queue->head);
+
+	while (retries++ < QAT_CQ_MAX_DEQ_RETRIES &&
+			*(uint32_t *)resp_msg == ADF_RING_EMPTY_SIG) {
+		/* loop waiting for response until we reach the timeout */
+		rte_delay_ms(20);
+	}
+
+	if (*(uint32_t *)resp_msg != ADF_RING_EMPTY_SIG) {
+		/* response received */
+		result = 1;
+
+		/* check status flag */
+		if (ICP_QAT_FW_COMN_RESP_CRYPTO_STAT_GET(
+				resp_msg->comn_hdr.comn_status) ==
+				ICP_QAT_FW_COMN_STATUS_FLAG_OK) {
+			/* success */
+			memcpy(out_data, resp_msg, queue->msg_size);
+		} else {
+			memset(out_data, 0, queue->msg_size);
+		}
+
+		queue->head = adf_modulo(queue->head + queue->msg_size,
+				queue->modulo_mask);
+		rxq_free_desc(qp, queue);
+	}
+
+	return result;
+}
+
+/* Sends a NULL message and extracts QAT fw version from the response.
+ * Used to determine detailed capabilities based on the fw version number.
+ * This assumes that there are no inflight messages, i.e. assumes there's space
+ * on the qp, one message is sent and only one response collected.
+ * Returns fw version number or 0 for unknown version or a negative error code.
+ */
+int
+qat_cq_get_fw_version(struct qat_qp *qp)
+{
+	struct qat_queue *queue = &(qp->tx_q);
+	uint8_t *base_addr = (uint8_t *)queue->base_addr;
+	struct icp_qat_fw_comn_req null_msg;
+	struct icp_qat_fw_comn_resp response;
+
+	/* prepare the NULL request */
+	memset(&null_msg, 0, sizeof(null_msg));
+	null_msg.comn_hdr.hdr_flags =
+		ICP_QAT_FW_COMN_HDR_FLAGS_BUILD(ICP_QAT_FW_COMN_REQ_FLAG_SET);
+	null_msg.comn_hdr.service_type = ICP_QAT_FW_COMN_REQ_NULL;
+	null_msg.comn_hdr.service_cmd_id = ICP_QAT_FW_NULL_REQ_SERV_ID;
+
+#if RTE_LOG_DP_LEVEL >= RTE_LOG_DEBUG
+	QAT_DP_HEXDUMP_LOG(DEBUG, "NULL request", &null_msg, sizeof(null_msg));
+#endif
+
+	/* send the NULL request */
+	memcpy(base_addr + queue->tail, &null_msg, sizeof(null_msg));
+	queue->tail = adf_modulo(queue->tail + queue->msg_size,
+			queue->modulo_mask);
+	txq_write_tail(qp, queue);
+
+	/* receive a response */
+	if (qat_cq_dequeue_response(qp, &response)) {
+
+#if RTE_LOG_DP_LEVEL >= RTE_LOG_DEBUG
+		QAT_DP_HEXDUMP_LOG(DEBUG, "NULL response:", &response,
+				sizeof(response));
+#endif
+		/* if LW0 bit 24 is set - then the fw version was returned */
+		if (QAT_FIELD_GET(response.comn_hdr.hdr_flags,
+				ICP_QAT_FW_COMN_NULL_VERSION_FLAG_BITPOS,
+				ICP_QAT_FW_COMN_NULL_VERSION_FLAG_MASK))
+			return response.resrvd[0]; /* return LW4 */
+		else
+			return 0; /* not set - we don't know fw version */
+	}
+
+	QAT_LOG(ERR, "No response received");
+	return -EINVAL;
+}
+
 __rte_weak int
 qat_comp_process_response(void **op __rte_unused, uint8_t *resp __rte_unused,
 			  void *op_cookie __rte_unused,
diff --git a/dpdk/drivers/common/qat/qat_qp.h b/dpdk/drivers/common/qat/qat_qp.h
index 980c2ba323..47ad5dd203 100644
--- a/dpdk/drivers/common/qat/qat_qp.h
+++ b/dpdk/drivers/common/qat/qat_qp.h
@@ -11,10 +11,8 @@ struct qat_pci_device;
 
 #define QAT_CSR_HEAD_WRITE_THRESH 32U
 /* number of requests to accumulate before writing head CSR */
-#define QAT_CSR_TAIL_WRITE_THRESH 32U
-/* number of requests to accumulate before writing tail CSR */
-#define QAT_CSR_TAIL_FORCE_WRITE_THRESH 256U
-/* number of inflights below which no tail write coalescing should occur */
+
+#define QAT_QP_MIN_INFL_THRESHOLD	256
 
 typedef int (*build_request_t)(void *op,
 		uint8_t *req, void *op_cookie,
@@ -55,7 +53,6 @@ struct qat_queue {
 	uint32_t	tail;			/* Shadow copy of the tail */
 	uint32_t	modulo_mask;
 	uint32_t	msg_size;
-	uint16_t	max_inflights;
 	uint32_t	queue_size;
 	uint8_t		hw_bundle_number;
 	uint8_t		hw_queue_number;
@@ -64,13 +61,10 @@ struct qat_queue {
 	uint32_t	csr_tail;		/* last written tail value */
 	uint16_t	nb_processed_responses;
 	/* number of responses processed since last CSR head write */
-	uint16_t	nb_pending_requests;
-	/* number of requests pending since last CSR tail write */
 };
 
 struct qat_qp {
 	void			*mmap_bar_addr;
-	uint16_t		inflights16;
 	struct qat_queue	tx_q;
 	struct qat_queue	rx_q;
 	struct qat_common_stats stats;
@@ -82,6 +76,10 @@ struct qat_qp {
 	enum qat_service_type service_type;
 	struct qat_pci_device *qat_dev;
 	/**< qat device this qp is on */
+	uint32_t enqueued;
+	uint32_t dequeued __rte_aligned(4);
+	uint16_t max_inflights;
+	uint16_t min_enq_burst_threshold;
 } __rte_cache_aligned;
 
 extern const struct qat_qp_hw_data qat_gen1_qps[][ADF_MAX_QPS_ON_ANY_SERVICE];
@@ -105,6 +103,9 @@ int
 qat_qps_per_service(const struct qat_qp_hw_data *qp_hw_data,
 			enum qat_service_type service);
 
+int
+qat_cq_get_fw_version(struct qat_qp *qp);
+
 /* Needed for weak function*/
 int
 qat_comp_process_response(void **op __rte_unused, uint8_t *resp __rte_unused,
diff --git a/dpdk/drivers/compress/isal/isal_compress_pmd_ops.c b/dpdk/drivers/compress/isal/isal_compress_pmd_ops.c
Louis Abel's avatar
Louis Abel committed
18201 18202 18203 18204 18205 18206 18207 18208 18209 18210 18211 18212 18213 18214 18215 18216 18217 18218 18219 18220 18221 18222 18223 18224 18225 18226 18227 18228 18229 18230 18231 18232 18233 18234 18235 18236 18237 18238 18239 18240 18241 18242 18243 18244 18245 18246 18247 18248 18249 18250 18251 18252 18253 18254 18255 18256 18257 18258 18259 18260 18261 18262 18263 18264 18265 18266 18267 18268 18269 18270 18271 18272 18273 18274 18275 18276 18277 18278 18279 18280 18281 18282 18283 18284 18285 18286 18287 18288 18289 18290 18291 18292 18293 18294 18295 18296 18297 18298 18299 18300 18301 18302 18303 18304 18305 18306 18307 18308 18309 18310 18311 18312 18313 18314 18315 18316 18317 18318 18319 18320 18321 18322 18323 18324 18325 18326 18327 18328 18329 18330 18331 18332 18333 18334 18335 18336 18337 18338 18339 18340 18341 18342 18343 18344 18345 18346 18347 18348 18349 18350 18351 18352 18353 18354 18355 18356 18357 18358 18359 18360 18361 18362 18363 18364 18365 18366 18367 18368 18369 18370 18371 18372 18373 18374 18375 18376 18377 18378 18379 18380 18381 18382 18383 18384 18385 18386 18387 18388 18389 18390 18391 18392 18393 18394 18395 18396 18397 18398 18399 18400 18401 18402 18403 18404 18405 18406 18407 18408 18409 18410 18411 18412 18413 18414 18415 18416 18417 18418 18419 18420 18421 18422 18423 18424 18425 18426 18427 18428 18429 18430 18431 18432 18433 18434 18435 18436 18437 18438 18439 18440 18441 18442 18443 18444 18445 18446 18447 18448 18449 18450 18451 18452 18453 18454 18455 18456 18457 18458 18459 18460 18461 18462 18463 18464 18465 18466 18467 18468 18469 18470 18471 18472 18473 18474 18475 18476 18477 18478 18479 18480 18481 18482 18483 18484 18485 18486 18487 18488 18489 18490 18491 18492 18493 18494 18495 18496 18497 18498 18499 18500 18501 18502 18503 18504 18505 18506 18507 18508 18509 18510 18511 18512 18513 18514 18515 18516 18517 18518 18519 18520 18521 18522 18523 18524 18525 18526 18527 18528 18529 18530 18531 18532 18533 18534 18535 18536 18537 18538 18539 18540 18541 18542 18543 18544 18545 18546 18547 18548 18549 18550 18551 18552 18553 18554 18555 18556 18557 18558 18559 18560 18561 18562 18563 18564 18565 18566 18567 18568 18569 18570 18571 18572 18573 18574 18575 18576 18577 18578 18579 18580 18581 18582 18583 18584 18585 18586 18587 18588 18589 18590 18591 18592 18593 18594 18595 18596 18597 18598 18599 18600 18601 18602 18603 18604 18605 18606 18607 18608 18609 18610 18611 18612 18613 18614 18615 18616 18617 18618 18619 18620 18621 18622 18623 18624 18625 18626 18627 18628 18629 18630 18631 18632 18633 18634 18635 18636 18637 18638 18639 18640 18641 18642 18643 18644 18645 18646 18647 18648 18649 18650 18651 18652 18653 18654 18655 18656 18657 18658 18659 18660 18661 18662 18663 18664 18665 18666 18667 18668 18669 18670 18671 18672 18673 18674 18675 18676 18677 18678 18679 18680 18681 18682 18683 18684 18685 18686 18687 18688 18689 18690 18691 18692 18693 18694 18695 18696 18697 18698 18699 18700 18701 18702 18703 18704 18705 18706 18707 18708 18709 18710 18711 18712 18713 18714 18715 18716 18717 18718 18719 18720 18721 18722 18723 18724 18725 18726 18727 18728 18729 18730 18731 18732 18733 18734 18735 18736 18737 18738 18739 18740 18741 18742 18743 18744 18745 18746 18747 18748 18749 18750 18751 18752 18753 18754 18755 18756 18757 18758 18759 18760 18761 18762 18763 18764 18765 18766 18767 18768 18769 18770 18771 18772 18773 18774 18775 18776 18777 18778 18779 18780 18781 18782 18783 18784 18785 18786 18787 18788 18789 18790 18791 18792 18793 18794 18795 18796 18797 18798 18799 18800 18801 18802 18803 18804 18805 18806 18807 18808 18809 18810 18811 18812 18813 18814 18815 18816 18817 18818 18819 18820 18821 18822 18823 18824 18825 18826 18827 18828 18829 18830 18831 18832 18833 18834 18835 18836 18837 18838 18839 18840 18841 18842 18843 18844 18845 18846 18847 18848 18849 18850 18851 18852 18853 18854 18855 18856 18857 18858 18859 18860 18861 18862 18863 18864 18865 18866 18867 18868 18869 18870 18871 18872 18873 18874 18875 18876 18877 18878 18879 18880 18881 18882 18883 18884 18885 18886 18887 18888 18889 18890 18891 18892 18893 18894 18895 18896 18897 18898 18899 18900 18901 18902 18903 18904 18905 18906 18907 18908 18909 18910 18911 18912 18913 18914 18915 18916 18917 18918 18919 18920 18921 18922 18923 18924 18925 18926 18927 18928 18929 18930 18931 18932 18933 18934 18935 18936 18937 18938 18939 18940 18941 18942 18943 18944 18945 18946 18947 18948 18949 18950 18951 18952 18953 18954 18955 18956 18957 18958 18959 18960 18961 18962 18963 18964 18965 18966 18967 18968 18969 18970 18971 18972 18973 18974 18975 18976 18977 18978 18979 18980 18981 18982 18983 18984 18985 18986 18987 18988 18989 18990 18991 18992 18993 18994 18995 18996 18997 18998 18999 19000 19001 19002 19003 19004 19005 19006 19007 19008 19009 19010 19011 19012 19013 19014 19015 19016 19017 19018 19019 19020 19021 19022 19023 19024 19025 19026 19027 19028 19029 19030 19031 19032 19033 19034 19035 19036 19037 19038 19039 19040 19041 19042 19043 19044 19045 19046 19047 19048 19049 19050 19051 19052 19053 19054 19055 19056 19057 19058 19059 19060 19061 19062 19063 19064 19065 19066 19067 19068 19069 19070 19071 19072 19073 19074 19075 19076 19077 19078 19079 19080 19081 19082 19083 19084 19085 19086 19087 19088 19089 19090 19091 19092 19093 19094 19095 19096 19097 19098 19099 19100 19101 19102 19103 19104 19105 19106 19107 19108 19109 19110 19111 19112 19113 19114 19115 19116 19117 19118 19119 19120 19121 19122 19123 19124 19125 19126 19127 19128 19129 19130 19131 19132 19133 19134 19135 19136 19137 19138 19139 19140 19141 19142 19143 19144 19145 19146 19147 19148 19149 19150 19151 19152 19153 19154 19155 19156 19157 19158 19159 19160 19161 19162 19163 19164 19165 19166 19167 19168 19169 19170 19171 19172 19173 19174 19175 19176 19177 19178 19179 19180 19181 19182 19183 19184 19185 19186 19187 19188 19189 19190 19191 19192 19193 19194 19195 19196 19197 19198 19199 19200 19201 19202 19203 19204 19205 19206 19207 19208 19209 19210 19211 19212 19213 19214 19215 19216 19217 19218 19219 19220 19221 19222 19223 19224 19225 19226 19227 19228 19229 19230 19231 19232 19233 19234 19235 19236 19237 19238 19239 19240 19241 19242 19243 19244 19245 19246 19247 19248 19249 19250 19251 19252 19253 19254 19255 19256 19257 19258 19259 19260 19261 19262 19263 19264 19265 19266 19267 19268 19269 19270 19271 19272 19273 19274 19275 19276 19277 19278 19279 19280 19281 19282 19283 19284 19285 19286 19287 19288 19289 19290 19291 19292 19293 19294 19295 19296 19297 19298 19299 19300 19301 19302 19303 19304 19305 19306 19307 19308 19309 19310 19311 19312 19313 19314 19315 19316 19317 19318 19319 19320 19321 19322 19323 19324 19325 19326 19327 19328 19329 19330 19331 19332 19333 19334 19335 19336 19337 19338 19339 19340 19341 19342 19343 19344 19345 19346 19347 19348 19349 19350 19351 19352 19353 19354 19355 19356 19357 19358 19359 19360 19361 19362 19363 19364 19365 19366 19367 19368 19369 19370 19371 19372 19373 19374 19375 19376 19377 19378 19379 19380 19381 19382 19383 19384 19385 19386 19387 19388 19389 19390 19391 19392 19393 19394 19395 19396 19397 19398 19399 19400 19401 19402 19403 19404 19405 19406 19407 19408 19409 19410 19411 19412 19413 19414 19415 19416 19417 19418 19419 19420 19421 19422 19423 19424 19425 19426 19427 19428 19429 19430 19431 19432 19433 19434 19435 19436 19437 19438 19439 19440 19441 19442 19443 19444 19445 19446 19447 19448 19449 19450 19451 19452 19453 19454 19455 19456 19457 19458 19459 19460 19461 19462 19463 19464 19465 19466 19467 19468 19469 19470 19471 19472 19473 19474 19475 19476 19477 19478 19479 19480 19481 19482 19483 19484 19485 19486 19487 19488 19489 19490 19491 19492 19493 19494 19495 19496 19497 19498 19499 19500 19501 19502 19503 19504 19505 19506 19507 19508 19509 19510 19511 19512 19513 19514 19515 19516 19517 19518 19519 19520 19521 19522 19523 19524 19525 19526 19527 19528 19529 19530 19531 19532 19533 19534 19535 19536 19537 19538 19539 19540 19541 19542 19543 19544 19545 19546 19547 19548 19549 19550 19551 19552 19553 19554 19555 19556 19557 19558 19559 19560 19561 19562 19563 19564 19565 19566 19567 19568 19569 19570 19571 19572 19573 19574 19575 19576 19577 19578 19579 19580 19581 19582 19583 19584 19585 19586 19587 19588 19589 19590 19591 19592 19593 19594 19595 19596 19597 19598 19599 19600 19601 19602 19603 19604 19605 19606 19607 19608 19609 19610 19611 19612 19613 19614 19615 19616 19617 19618 19619 19620 19621 19622 19623 19624 19625 19626 19627 19628 19629 19630 19631 19632 19633 19634 19635 19636 19637 19638 19639 19640 19641 19642 19643 19644 19645 19646 19647 19648 19649 19650 19651 19652 19653 19654 19655 19656 19657 19658 19659 19660 19661 19662 19663 19664 19665 19666 19667 19668 19669 19670 19671 19672 19673 19674 19675 19676 19677 19678 19679 19680 19681 19682 19683 19684 19685 19686 19687 19688 19689 19690 19691 19692 19693 19694 19695 19696 19697 19698 19699 19700 19701 19702 19703 19704 19705 19706 19707 19708 19709 19710 19711 19712 19713 19714 19715 19716 19717 19718 19719 19720 19721 19722 19723 19724 19725 19726 19727 19728 19729 19730 19731 19732 19733 19734 19735 19736 19737 19738 19739 19740 19741 19742 19743 19744 19745 19746 19747 19748 19749 19750 19751 19752 19753 19754 19755 19756 19757 19758 19759 19760 19761 19762 19763 19764 19765 19766 19767 19768 19769 19770 19771 19772 19773 19774 19775 19776 19777 19778 19779 19780 19781 19782 19783 19784 19785 19786 19787 19788 19789 19790 19791 19792 19793 19794 19795 19796 19797 19798 19799 19800 19801 19802 19803 19804 19805 19806 19807 19808 19809 19810 19811 19812 19813 19814 19815 19816 19817 19818 19819 19820 19821 19822 19823 19824 19825 19826 19827 19828 19829 19830 19831 19832 19833 19834 19835 19836 19837 19838 19839 19840 19841 19842 19843 19844 19845 19846 19847 19848 19849 19850 19851 19852 19853 19854 19855 19856 19857 19858 19859 19860 19861 19862 19863 19864 19865 19866 19867 19868 19869 19870 19871 19872 19873 19874 19875 19876 19877 19878 19879 19880 19881 19882 19883 19884 19885 19886 19887 19888 19889 19890 19891 19892 19893 19894 19895 19896 19897 19898 19899 19900 19901 19902 19903 19904 19905 19906 19907 19908 19909 19910 19911 19912 19913 19914 19915 19916 19917 19918 19919 19920 19921 19922 19923 19924 19925 19926 19927 19928 19929 19930 19931 19932 19933 19934 19935 19936 19937 19938 19939 19940 19941 19942 19943 19944 19945 19946 19947 19948 19949 19950 19951 19952 19953 19954 19955 19956 19957 19958 19959 19960 19961 19962 19963 19964 19965 19966 19967 19968 19969 19970 19971 19972 19973 19974 19975 19976 19977 19978 19979 19980 19981 19982 19983 19984 19985 19986 19987 19988 19989 19990 19991 19992 19993 19994 19995 19996 19997 19998 19999 20000 20001 20002 20003 20004 20005 20006 20007 20008 20009 20010 20011 20012 20013 20014 20015 20016 20017 20018 20019 20020 20021 20022 20023 20024 20025 20026 20027 20028 20029 20030 20031 20032 20033 20034 20035 20036 20037 20038 20039 20040 20041 20042 20043 20044 20045 20046 20047 20048 20049 20050 20051 20052 20053 20054 20055 20056 20057 20058 20059 20060 20061 20062 20063 20064 20065 20066 20067 20068 20069 20070 20071 20072 20073 20074 20075 20076 20077 20078 20079 20080 20081 20082 20083 20084 20085 20086 20087 20088 20089 20090 20091 20092 20093 20094 20095 20096 20097 20098 20099 20100 20101 20102 20103 20104 20105 20106 20107 20108 20109 20110 20111 20112 20113 20114 20115 20116 20117 20118 20119 20120 20121 20122 20123 20124 20125 20126 20127 20128 20129 20130 20131 20132 20133 20134 20135 20136 20137 20138 20139 20140 20141 20142 20143 20144 20145 20146 20147 20148 20149 20150 20151 20152 20153 20154 20155 20156 20157 20158 20159 20160 20161 20162 20163 20164 20165 20166 20167 20168 20169 20170 20171 20172 20173 20174 20175 20176 20177 20178 20179 20180 20181 20182 20183 20184 20185 20186 20187 20188 20189 20190 20191 20192 20193 20194 20195 20196 20197 20198 20199 20200
index 31c4559915..7d03749da3 100644
--- a/dpdk/drivers/compress/isal/isal_compress_pmd_ops.c
+++ b/dpdk/drivers/compress/isal/isal_compress_pmd_ops.c
@@ -249,16 +249,27 @@ isal_comp_pmd_qp_setup(struct rte_compressdev *dev, uint16_t qp_id,
 	qp->stream = rte_zmalloc_socket("Isa-l compression stream ",
 			sizeof(struct isal_zstream),  RTE_CACHE_LINE_SIZE,
 			socket_id);
-
+	if (qp->stream == NULL) {
+		ISAL_PMD_LOG(ERR, "Failed to allocate compression stream memory");
+		goto qp_setup_cleanup;
+	}
 	/* Initialize memory for compression level buffer */
 	qp->stream->level_buf = rte_zmalloc_socket("Isa-l compression lev_buf",
 			ISAL_DEF_LVL3_DEFAULT, RTE_CACHE_LINE_SIZE,
 			socket_id);
+	if (qp->stream->level_buf == NULL) {
+		ISAL_PMD_LOG(ERR, "Failed to allocate compression level_buf memory");
+		goto qp_setup_cleanup;
+	}
 
 	/* Initialize memory for decompression state structure */
 	qp->state = rte_zmalloc_socket("Isa-l decompression state",
 			sizeof(struct inflate_state), RTE_CACHE_LINE_SIZE,
 			socket_id);
+	if (qp->state == NULL) {
+		ISAL_PMD_LOG(ERR, "Failed to allocate decompression state memory");
+		goto qp_setup_cleanup;
+	}
 
 	qp->id = qp_id;
 	dev->data->queue_pairs[qp_id] = qp;
@@ -284,8 +295,11 @@ isal_comp_pmd_qp_setup(struct rte_compressdev *dev, uint16_t qp_id,
 	return 0;
 
 qp_setup_cleanup:
-	if (qp)
-		rte_free(qp);
+	if (qp->stream)
+		rte_free(qp->stream->level_buf);
+	rte_free(qp->stream);
+	rte_free(qp->state);
+	rte_free(qp);
 
 	return -1;
 }
diff --git a/dpdk/drivers/compress/isal/meson.build b/dpdk/drivers/compress/isal/meson.build
index 25578880db..b039dfdfc5 100644
--- a/dpdk/drivers/compress/isal/meson.build
+++ b/dpdk/drivers/compress/isal/meson.build
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright 2018 Intel Corporation
 
-dep = dependency('libisal', required: false)
+dep = dependency('libisal', required: false, method: 'pkg-config')
 if not dep.found()
 	build = false
 	reason = 'missing dependency, "libisal"'
diff --git a/dpdk/drivers/compress/octeontx/otx_zip_pmd.c b/dpdk/drivers/compress/octeontx/otx_zip_pmd.c
index 9e00c86630..bff8ef035e 100644
--- a/dpdk/drivers/compress/octeontx/otx_zip_pmd.c
+++ b/dpdk/drivers/compress/octeontx/otx_zip_pmd.c
@@ -406,7 +406,7 @@ zip_pmd_qp_setup(struct rte_compressdev *dev, uint16_t qp_id,
 
 	qp->name = name;
 
-	/* Create completion queue upto max_inflight_ops */
+	/* Create completion queue up to max_inflight_ops */
 	qp->processed_pkts = zip_pmd_qp_create_processed_pkts_ring(qp,
 						max_inflight_ops, socket_id);
 	if (qp->processed_pkts == NULL)
diff --git a/dpdk/drivers/compress/qat/qat_comp_pmd.c b/dpdk/drivers/compress/qat/qat_comp_pmd.c
index 05b7dfe774..5cdabadef7 100644
--- a/dpdk/drivers/compress/qat/qat_comp_pmd.c
+++ b/dpdk/drivers/compress/qat/qat_comp_pmd.c
@@ -139,6 +139,7 @@ qat_comp_qp_setup(struct rte_compressdev *dev, uint16_t qp_id,
 								= *qp_addr;
 
 	qp = (struct qat_qp *)*qp_addr;
+	qp->min_enq_burst_threshold = qat_private->min_enq_burst_threshold;
 
 	for (i = 0; i < qp->nb_descriptors; i++) {
 
@@ -660,8 +661,12 @@ static const struct rte_driver compdev_qat_driver = {
 	.alias = qat_comp_drv_name
 };
 int
-qat_comp_dev_create(struct qat_pci_device *qat_pci_dev)
+qat_comp_dev_create(struct qat_pci_device *qat_pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param)
 {
+	int i = 0;
+	struct qat_device_info *qat_dev_instance =
+			&qat_pci_devs[qat_pci_dev->qat_dev_id];
 	if (qat_pci_dev->qat_dev_gen == QAT_GEN3) {
 		QAT_LOG(ERR, "Compression PMD not supported on QAT c4xxx");
 		return 0;
@@ -669,24 +674,27 @@ qat_comp_dev_create(struct qat_pci_device *qat_pci_dev)
 
 	struct rte_compressdev_pmd_init_params init_params = {
 		.name = "",
-		.socket_id = qat_pci_dev->pci_dev->device.numa_node,
+		.socket_id = qat_dev_instance->pci_dev->device.numa_node,
 	};
 	char name[RTE_COMPRESSDEV_NAME_MAX_LEN];
+	char capa_memz_name[RTE_COMPRESSDEV_NAME_MAX_LEN];
 	struct rte_compressdev *compressdev;
 	struct qat_comp_dev_private *comp_dev;
+	const struct rte_compressdev_capabilities *capabilities;
+	uint64_t capa_size;
 
 	snprintf(name, RTE_COMPRESSDEV_NAME_MAX_LEN, "%s_%s",
 			qat_pci_dev->name, "comp");
 	QAT_LOG(DEBUG, "Creating QAT COMP device %s", name);
 
 	/* Populate subset device to use in compressdev device creation */
-	qat_pci_dev->comp_rte_dev.driver = &compdev_qat_driver;
-	qat_pci_dev->comp_rte_dev.numa_node =
-					qat_pci_dev->pci_dev->device.numa_node;
-	qat_pci_dev->comp_rte_dev.devargs = NULL;
+	qat_dev_instance->comp_rte_dev.driver = &compdev_qat_driver;
+	qat_dev_instance->comp_rte_dev.numa_node =
+			qat_dev_instance->pci_dev->device.numa_node;
+	qat_dev_instance->comp_rte_dev.devargs = NULL;
 
 	compressdev = rte_compressdev_pmd_create(name,
-			&(qat_pci_dev->comp_rte_dev),
+			&(qat_dev_instance->comp_rte_dev),
 			sizeof(struct qat_comp_dev_private),
 			&init_params);
 
@@ -700,25 +708,62 @@ qat_comp_dev_create(struct qat_pci_device *qat_pci_dev)
 
 	compressdev->feature_flags = RTE_COMPDEV_FF_HW_ACCELERATED;
 
+	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
+		return 0;
+
+	snprintf(capa_memz_name, RTE_COMPRESSDEV_NAME_MAX_LEN,
+			"QAT_COMP_CAPA_GEN_%d",
+			qat_pci_dev->qat_dev_gen);
+
 	comp_dev = compressdev->data->dev_private;
 	comp_dev->qat_dev = qat_pci_dev;
 	comp_dev->compressdev = compressdev;
-	qat_pci_dev->comp_dev = comp_dev;
 
 	switch (qat_pci_dev->qat_dev_gen) {
 	case QAT_GEN1:
 	case QAT_GEN2:
 	case QAT_GEN3:
-		comp_dev->qat_dev_capabilities = qat_comp_gen_capabilities;
+		capabilities = qat_comp_gen_capabilities;
+		capa_size = sizeof(qat_comp_gen_capabilities);
 		break;
 	default:
-		comp_dev->qat_dev_capabilities = qat_comp_gen_capabilities;
+		capabilities = qat_comp_gen_capabilities;
+		capa_size = sizeof(qat_comp_gen_capabilities);
 		QAT_LOG(DEBUG,
 			"QAT gen %d capabilities unknown, default to GEN1",
 					qat_pci_dev->qat_dev_gen);
 		break;
 	}
 
+	comp_dev->capa_mz = rte_memzone_lookup(capa_memz_name);
+	if (comp_dev->capa_mz == NULL) {
+		comp_dev->capa_mz = rte_memzone_reserve(capa_memz_name,
+			capa_size,
+			rte_socket_id(), 0);
+	}
+	if (comp_dev->capa_mz == NULL) {
+		QAT_LOG(DEBUG,
+			"Error allocating memzone for capabilities, destroying PMD for %s",
+			name);
+		memset(&qat_dev_instance->comp_rte_dev, 0,
+			sizeof(qat_dev_instance->comp_rte_dev));
+		rte_compressdev_pmd_destroy(compressdev);
+		return -EFAULT;
+	}
+
+	memcpy(comp_dev->capa_mz->addr, capabilities, capa_size);
+	comp_dev->qat_dev_capabilities = comp_dev->capa_mz->addr;
+
+	while (1) {
+		if (qat_dev_cmd_param[i].name == NULL)
+			break;
+		if (!strcmp(qat_dev_cmd_param[i].name, COMP_ENQ_THRESHOLD_NAME))
+			comp_dev->min_enq_burst_threshold =
+					qat_dev_cmd_param[i].val;
+		i++;
+	}
+
+	qat_pci_dev->comp_dev = comp_dev;
 	QAT_LOG(DEBUG,
 		    "Created QAT COMP device %s as compressdev instance %d",
 			name, compressdev->data->dev_id);
@@ -737,6 +782,9 @@ qat_comp_dev_destroy(struct qat_pci_device *qat_pci_dev)
 	if (comp_dev == NULL)
 		return 0;
 
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY)
+		rte_memzone_free(qat_pci_dev->comp_dev->capa_mz);
+
 	/* clean up any resources used by the device */
 	qat_comp_dev_close(comp_dev->compressdev);
 
diff --git a/dpdk/drivers/compress/qat/qat_comp_pmd.h b/dpdk/drivers/compress/qat/qat_comp_pmd.h
index 6979de14d4..ed27120604 100644
--- a/dpdk/drivers/compress/qat/qat_comp_pmd.h
+++ b/dpdk/drivers/compress/qat/qat_comp_pmd.h
@@ -32,10 +32,14 @@ struct qat_comp_dev_private {
 	/**< The device's pool for qat_comp_xforms */
 	struct rte_mempool *streampool;
 	/**< The device's pool for qat_comp_streams */
+	const struct rte_memzone *capa_mz;
+	/* Shared memzone for storing capabilities */
+	uint16_t min_enq_burst_threshold;
 };
 
 int
-qat_comp_dev_create(struct qat_pci_device *qat_pci_dev);
+qat_comp_dev_create(struct qat_pci_device *qat_pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
 qat_comp_dev_destroy(struct qat_pci_device *qat_pci_dev);
diff --git a/dpdk/drivers/compress/zlib/meson.build b/dpdk/drivers/compress/zlib/meson.build
index b1328c535e..3bb7769494 100644
--- a/dpdk/drivers/compress/zlib/meson.build
+++ b/dpdk/drivers/compress/zlib/meson.build
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2018 Cavium Networks
 
-dep = dependency('zlib', required: false)
+dep = dependency('zlib', required: false, method: 'pkg-config')
 if not dep.found()
 	build = false
 	reason = 'missing dependency, "zlib"'
diff --git a/dpdk/drivers/compress/zlib/zlib_pmd.c b/dpdk/drivers/compress/zlib/zlib_pmd.c
index 19f9200c22..e39be2ed86 100644
--- a/dpdk/drivers/compress/zlib/zlib_pmd.c
+++ b/dpdk/drivers/compress/zlib/zlib_pmd.c
@@ -7,6 +7,8 @@
 
 #include "zlib_pmd_private.h"
 
+int zlib_logtype_driver;
+
 /** Compute next mbuf in the list, assign data buffer and length,
  *  returns 0 if mbuf is NULL
  */
diff --git a/dpdk/drivers/compress/zlib/zlib_pmd_private.h b/dpdk/drivers/compress/zlib/zlib_pmd_private.h
index bda49759dc..e36c5dc615 100644
--- a/dpdk/drivers/compress/zlib/zlib_pmd_private.h
+++ b/dpdk/drivers/compress/zlib/zlib_pmd_private.h
@@ -14,7 +14,7 @@
 
 #define DEF_MEM_LEVEL			8
 
-int zlib_logtype_driver;
+extern int zlib_logtype_driver;
 #define ZLIB_PMD_LOG(level, fmt, args...) \
 	rte_log(RTE_LOG_ ## level, zlib_logtype_driver, "%s(): "fmt "\n", \
 			__func__, ##args)
diff --git a/dpdk/drivers/crypto/aesni_gcm/Makefile b/dpdk/drivers/crypto/aesni_gcm/Makefile
index d8190a2ff4..b443167d51 100644
--- a/dpdk/drivers/crypto/aesni_gcm/Makefile
+++ b/dpdk/drivers/crypto/aesni_gcm/Makefile
@@ -20,7 +20,8 @@ LDLIBS += -lrte_eal -lrte_mbuf -lrte_mempool -lrte_ring
 LDLIBS += -lrte_cryptodev
 LDLIBS += -lrte_bus_vdev
 
-IMB_HDR = $(shell echo '\#include <intel-ipsec-mb.h>' | \
+H := \#
+IMB_HDR = $(shell echo '$Hinclude <intel-ipsec-mb.h>' | \
 	$(CC) -E $(EXTRA_CFLAGS) - | grep 'intel-ipsec-mb.h' | \
 	head -n1 | cut -d'"' -f2)
 
diff --git a/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c b/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c
index 1a03be31dc..c9c9eb8ca9 100644
--- a/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c
+++ b/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd.c
@@ -13,6 +13,8 @@
 
 #include "aesni_gcm_pmd_private.h"
 
+int aesni_gcm_logtype_driver;
+
 static uint8_t cryptodev_driver_id;
 
 /** Parse crypto xform chain and set private session parameters */
diff --git a/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd_private.h b/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd_private.h
index 2039adb533..7347c4769f 100644
--- a/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd_private.h
+++ b/dpdk/drivers/crypto/aesni_gcm/aesni_gcm_pmd_private.h
@@ -20,7 +20,7 @@
 /**< AES-NI GCM PMD device name */
 
 /** AES-NI GCM PMD  LOGTYPE DRIVER */
-int aesni_gcm_logtype_driver;
+extern int aesni_gcm_logtype_driver;
 #define AESNI_GCM_LOG(level, fmt, ...) \
 	rte_log(RTE_LOG_ ## level, aesni_gcm_logtype_driver,	\
 			"%s() line %u: "fmt "\n", __func__, __LINE__,	\
diff --git a/dpdk/drivers/crypto/aesni_mb/Makefile b/dpdk/drivers/crypto/aesni_mb/Makefile
index f1530e74c4..aa2e428106 100644
--- a/dpdk/drivers/crypto/aesni_mb/Makefile
+++ b/dpdk/drivers/crypto/aesni_mb/Makefile
@@ -20,7 +20,8 @@ LDLIBS += -lrte_eal -lrte_mbuf -lrte_mempool -lrte_ring
 LDLIBS += -lrte_cryptodev
 LDLIBS += -lrte_bus_vdev
 
-IMB_HDR = $(shell echo '\#include <intel-ipsec-mb.h>' | \
+H := \#
+IMB_HDR = $(shell echo '$Hinclude <intel-ipsec-mb.h>' | \
 	$(CC) -E $(EXTRA_CFLAGS) - | grep 'intel-ipsec-mb.h' | \
 	head -n1 | cut -d'"' -f2)
 
diff --git a/dpdk/drivers/crypto/aesni_mb/aesni_mb_pmd_private.h b/dpdk/drivers/crypto/aesni_mb/aesni_mb_pmd_private.h
index 3456693c25..03da3dc999 100644
--- a/dpdk/drivers/crypto/aesni_mb/aesni_mb_pmd_private.h
+++ b/dpdk/drivers/crypto/aesni_mb/aesni_mb_pmd_private.h
@@ -19,7 +19,7 @@ enum aesni_mb_vector_mode {
 /**< AES-NI Multi buffer PMD device name */
 
 /** AESNI_MB PMD LOGTYPE DRIVER */
-int aesni_mb_logtype_driver;
+extern int aesni_mb_logtype_driver;
 
 #define AESNI_MB_LOG(level, fmt, ...)  \
 	rte_log(RTE_LOG_ ## level, aesni_mb_logtype_driver,  \
@@ -74,7 +74,7 @@ static const unsigned auth_truncated_digest_byte_lengths[] = {
 		[AES_CMAC]	= 12,
 		[AES_CCM]	= 8,
 		[NULL_HASH]	= 0,
-		[AES_GMAC]	= 16,
+		[AES_GMAC]	= 12,
 		[PLAIN_SHA1]	= 20,
 		[PLAIN_SHA_224]	= 28,
 		[PLAIN_SHA_256]	= 32,
@@ -105,7 +105,7 @@ static const unsigned auth_digest_byte_lengths[] = {
 		[AES_XCBC]	= 16,
 		[AES_CMAC]	= 16,
 		[AES_CCM]	= 16,
-		[AES_GMAC]	= 12,
+		[AES_GMAC]	= 16,
 		[NULL_HASH]	= 0,
 		[PLAIN_SHA1]	= 20,
 		[PLAIN_SHA_224]	= 28,
diff --git a/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c b/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c
index 97d9f81766..d2fa0664e3 100644
--- a/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c
+++ b/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c
@@ -14,6 +14,8 @@
 
 #include "aesni_mb_pmd_private.h"
 
+int aesni_mb_logtype_driver;
+
 #define AES_CCM_DIGEST_MIN_LEN 4
 #define AES_CCM_DIGEST_MAX_LEN 16
 #define HMAC_MAX_BLOCK_SIZE 128
@@ -201,19 +203,11 @@ aesni_mb_set_session_auth_parameters(const MB_MGR *mb_mgr,
 			sess->cipher.direction = DECRYPT;
 
 		sess->auth.algo = AES_GMAC;
-		/*
-		 * Multi-buffer lib supports 8, 12 and 16 bytes of digest.
-		 * If size requested is different, generate the full digest
-		 * (16 bytes) in a temporary location and then memcpy
-		 * the requested number of bytes.
-		 */
-		if (sess->auth.req_digest_len != 16 &&
-				sess->auth.req_digest_len != 12 &&
-				sess->auth.req_digest_len != 8) {
-			sess->auth.gen_digest_len = 16;
-		} else {
-			sess->auth.gen_digest_len = sess->auth.req_digest_len;
+		if (sess->auth.req_digest_len > get_digest_byte_length(AES_GMAC)) {
+			AESNI_MB_LOG(ERR, "Invalid digest size\n");
+			return -EINVAL;
 		}
+		sess->auth.gen_digest_len = sess->auth.req_digest_len;
 		sess->iv.length = xform->auth.iv.length;
 		sess->iv.offset = xform->auth.iv.offset;
 
@@ -535,6 +529,14 @@ aesni_mb_set_session_aead_parameters(const MB_MGR *mb_mgr,
 		return -EINVAL;
 	}
 
+	/* Set IV parameters */
+	sess->iv.offset = xform->aead.iv.offset;
+	sess->iv.length = xform->aead.iv.length;
+
+	/* Set digest sizes */
+	sess->auth.req_digest_len = xform->aead.digest_length;
+	sess->auth.gen_digest_len = sess->auth.req_digest_len;
+
 	switch (xform->aead.algo) {
 	case RTE_CRYPTO_AEAD_AES_CCM:
 		sess->cipher.mode = CCM;
@@ -553,6 +555,13 @@ aesni_mb_set_session_aead_parameters(const MB_MGR *mb_mgr,
 			return -EINVAL;
 		}
 
+		/* CCM digests must be between 4 and 16 and an even number */
+		if (sess->auth.req_digest_len < AES_CCM_DIGEST_MIN_LEN ||
+				sess->auth.req_digest_len > AES_CCM_DIGEST_MAX_LEN ||
+				(sess->auth.req_digest_len & 1) == 1) {
+			AESNI_MB_LOG(ERR, "Invalid digest size\n");
+			return -EINVAL;
+		}
 		break;
 
 	case RTE_CRYPTO_AEAD_AES_GCM:
@@ -580,6 +589,12 @@ aesni_mb_set_session_aead_parameters(const MB_MGR *mb_mgr,
 			return -EINVAL;
 		}
 
+		/* GCM digest size must be between 1 and 16 */
+		if (sess->auth.req_digest_len == 0 ||
+				sess->auth.req_digest_len > 16) {
+			AESNI_MB_LOG(ERR, "Invalid digest size\n");
+			return -EINVAL;
+		}
 		break;
 
 	default:
@@ -587,20 +602,6 @@ aesni_mb_set_session_aead_parameters(const MB_MGR *mb_mgr,
 		return -ENOTSUP;
 	}
 
-	/* Set IV parameters */
-	sess->iv.offset = xform->aead.iv.offset;
-	sess->iv.length = xform->aead.iv.length;
-
-	sess->auth.req_digest_len = xform->aead.digest_length;
-	/* CCM digests must be between 4 and 16 and an even number */
-	if (sess->auth.req_digest_len < AES_CCM_DIGEST_MIN_LEN ||
-			sess->auth.req_digest_len > AES_CCM_DIGEST_MAX_LEN ||
-			(sess->auth.req_digest_len & 1) == 1) {
-		AESNI_MB_LOG(ERR, "Invalid digest size\n");
-		return -EINVAL;
-	}
-	sess->auth.gen_digest_len = sess->auth.req_digest_len;
-
 	return 0;
 }
 
@@ -729,10 +730,10 @@ get_session(struct aesni_mb_qp *qp, struct rte_crypto_op *op)
 					op->sym->session,
 					cryptodev_driver_id);
 	} else {
-		void *_sess = NULL;
+		void *_sess = rte_cryptodev_sym_session_create(qp->sess_mp);
 		void *_sess_private_data = NULL;
 
-		if (rte_mempool_get(qp->sess_mp, (void **)&_sess))
+		if (_sess == NULL)
 			return NULL;
 
 		if (rte_mempool_get(qp->sess_mp_priv,
diff --git a/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd_ops.c b/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd_ops.c
index d8609ad114..da614768b4 100644
--- a/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd_ops.c
+++ b/dpdk/drivers/crypto/aesni_mb/rte_aesni_mb_pmd_ops.c
@@ -449,9 +449,9 @@ static const struct rte_cryptodev_capabilities aesni_mb_pmd_capabilities[] = {
 					.increment = 8
 				},
 				.digest_size = {
-					.min = 8,
+					.min = 1,
 					.max = 16,
-					.increment = 4
+					.increment = 1
 				},
 				.aad_size = {
 					.min = 0,
@@ -479,9 +479,9 @@ static const struct rte_cryptodev_capabilities aesni_mb_pmd_capabilities[] = {
 					.increment = 8
 				},
 				.digest_size = {
-					.min = 8,
+					.min = 1,
 					.max = 16,
-					.increment = 4
+					.increment = 1
 				},
 				.iv_size = {
 					.min = 12,
diff --git a/dpdk/drivers/crypto/armv8/armv8_pmd_private.h b/dpdk/drivers/crypto/armv8/armv8_pmd_private.h
index 24040dda26..aeda47b1b9 100644
--- a/dpdk/drivers/crypto/armv8/armv8_pmd_private.h
+++ b/dpdk/drivers/crypto/armv8/armv8_pmd_private.h
@@ -8,36 +8,34 @@
 #define CRYPTODEV_NAME_ARMV8_PMD	crypto_armv8
 /**< ARMv8 Crypto PMD device name */
 
-#define ARMV8_CRYPTO_LOG_ERR(fmt, args...) \
-	RTE_LOG(ERR, CRYPTODEV, "[%s] %s() line %u: " fmt "\n",  \
-			RTE_STR(CRYPTODEV_NAME_ARMV8_CRYPTO_PMD), \
+extern int crypto_armv8_log_type;
+
+#define ARMV8_CRYPTO_LOG_ERR(fmt, args...)			\
+	rte_log(RTE_LOG_ERR, crypto_armv8_log_type,		\
+			"[%s] %s() line %u: " fmt "\n",		\
+			RTE_STR(CRYPTODEV_NAME_ARMV8_PMD),	\
 			__func__, __LINE__, ## args)
 
-#ifdef RTE_LIBRTE_ARMV8_CRYPTO_DEBUG
-#define ARMV8_CRYPTO_LOG_INFO(fmt, args...) \
-	RTE_LOG(INFO, CRYPTODEV, "[%s] %s() line %u: " fmt "\n", \
-			RTE_STR(CRYPTODEV_NAME_ARMV8_CRYPTO_PMD), \
+#define ARMV8_CRYPTO_LOG_INFO(fmt, args...)			\
+	rte_log(RTE_LOG_INFO, crypto_armv8_log_type,		\
+			"[%s] %s() line %u: " fmt "\n",		\
+			RTE_STR(CRYPTODEV_NAME_ARMV8_PMD),	\
 			__func__, __LINE__, ## args)
 
-#define ARMV8_CRYPTO_LOG_DBG(fmt, args...) \
-	RTE_LOG(DEBUG, CRYPTODEV, "[%s] %s() line %u: " fmt "\n", \
-			RTE_STR(CRYPTODEV_NAME_ARMV8_CRYPTO_PMD), \
+#define ARMV8_CRYPTO_LOG_DBG(fmt, args...)			\
+	rte_log(RTE_LOG_DEBUG, crypto_armv8_log_type,		\
+			"[%s] %s() line %u: " fmt "\n",		\
+			RTE_STR(CRYPTODEV_NAME_ARMV8_PMD),	\
 			__func__, __LINE__, ## args)
 
 #define ARMV8_CRYPTO_ASSERT(con)				\
 do {								\
 	if (!(con)) {						\
-		rte_panic("%s(): "				\
-		    con "condition failed, line %u", __func__);	\
+		rte_panic("condition failed, line %u",		\
+			__LINE__);				\
 	}							\
 } while (0)
 
-#else
-#define ARMV8_CRYPTO_LOG_INFO(fmt, args...)
-#define ARMV8_CRYPTO_LOG_DBG(fmt, args...)
-#define ARMV8_CRYPTO_ASSERT(con)
-#endif
-
 #define NBBY		8		/* Number of bits in a byte */
 #define BYTE_LENGTH(x)	((x) / NBBY)	/* Number of bytes in x (round down) */
 
diff --git a/dpdk/drivers/crypto/armv8/rte_armv8_pmd.c b/dpdk/drivers/crypto/armv8/rte_armv8_pmd.c
index 7dc83e69e1..3c5af17e68 100644
--- a/dpdk/drivers/crypto/armv8/rte_armv8_pmd.c
+++ b/dpdk/drivers/crypto/armv8/rte_armv8_pmd.c
@@ -84,12 +84,12 @@ crypto_op_ca_encrypt = {
 
 static const crypto_func_tbl_t
 crypto_op_ca_decrypt = {
-	NULL
+	{ {NULL} }
 };
 
 static const crypto_func_tbl_t
 crypto_op_ac_encrypt = {
-	NULL
+	{ {NULL} }
 };
 
 static const crypto_func_tbl_t
@@ -369,7 +369,16 @@ armv8_crypto_set_session_chained_parameters(struct armv8_crypto_session *sess,
 	/* Select cipher key */
 	sess->cipher.key.length = cipher_xform->cipher.key.length;
 	/* Set cipher direction */
-	cop = sess->cipher.direction;
+	switch (sess->cipher.direction) {
+	case RTE_CRYPTO_CIPHER_OP_ENCRYPT:
+		cop = ARMV8_CRYPTO_CIPHER_OP_ENCRYPT;
+		break;
+	case RTE_CRYPTO_CIPHER_OP_DECRYPT:
+		cop = ARMV8_CRYPTO_CIPHER_OP_DECRYPT;
+		break;
+	default:
+		return -ENOTSUP;
+	}
 	/* Set cipher algorithm */
 	calg = cipher_xform->cipher.algo;
 
@@ -657,8 +666,8 @@ process_op(struct armv8_crypto_qp *qp, struct rte_crypto_op *op,
 		memset(op->sym->session, 0,
 			rte_cryptodev_sym_get_existing_header_session_size(
 				op->sym->session));
-		rte_mempool_put(qp->sess_mp, sess);
-		rte_mempool_put(qp->sess_mp_priv, op->sym->session);
+		rte_mempool_put(qp->sess_mp_priv, sess);
+		rte_mempool_put(qp->sess_mp, op->sym->session);
 		op->sym->session = NULL;
 	}
 
@@ -843,6 +852,8 @@ static struct rte_vdev_driver armv8_crypto_pmd_drv = {
 
 static struct cryptodev_driver armv8_crypto_drv;
 
+RTE_LOG_REGISTER(crypto_armv8_log_type, pmd.crypto.armv8, ERR);
+
 RTE_PMD_REGISTER_VDEV(CRYPTODEV_NAME_ARMV8_PMD, armv8_crypto_pmd_drv);
 RTE_PMD_REGISTER_ALIAS(CRYPTODEV_NAME_ARMV8_PMD, cryptodev_armv8_pmd);
 RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_ARMV8_PMD,
diff --git a/dpdk/drivers/crypto/caam_jr/Makefile b/dpdk/drivers/crypto/caam_jr/Makefile
index 1b1f25a2a2..5b27b84c09 100644
--- a/dpdk/drivers/crypto/caam_jr/Makefile
+++ b/dpdk/drivers/crypto/caam_jr/Makefile
@@ -16,6 +16,13 @@ CFLAGS += -D _GNU_SOURCE
 CFLAGS += -O3
 CFLAGS += $(WERROR_FLAGS)
 
+# FIXME: temporary solution for Bugzilla 469
+ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)
+ifeq ($(shell test $(GCC_VERSION) -ge 100 && echo 1), 1)
+CFLAGS += -fcommon
+endif
+endif
+
 CFLAGS += -I$(RTE_SDK)/drivers/bus/dpaa/include
 CFLAGS += -I$(RTE_SDK)/drivers/common/dpaax
 CFLAGS += -I$(RTE_SDK)/drivers/common/dpaax/caamflib/
diff --git a/dpdk/drivers/crypto/caam_jr/caam_jr.c b/dpdk/drivers/crypto/caam_jr/caam_jr.c
index 8aaa3d45f6..d6fa8cf7e8 100644
--- a/dpdk/drivers/crypto/caam_jr/caam_jr.c
+++ b/dpdk/drivers/crypto/caam_jr/caam_jr.c
@@ -2084,7 +2084,7 @@ static struct rte_security_ops caam_jr_security_ops = {
 static void
 close_job_ring(struct sec_job_ring_t *job_ring)
 {
-	if (job_ring->irq_fd) {
+	if (job_ring->irq_fd != -1) {
 		/* Producer index is frozen. If consumer index is not equal
 		 * with producer index, then we have descs to flush.
 		 */
@@ -2093,7 +2093,7 @@ close_job_ring(struct sec_job_ring_t *job_ring)
 
 		/* free the uio job ring */
 		free_job_ring(job_ring->irq_fd);
-		job_ring->irq_fd = 0;
+		job_ring->irq_fd = -1;
 		caam_jr_dma_free(job_ring->input_ring);
 		caam_jr_dma_free(job_ring->output_ring);
 		g_job_rings_no--;
@@ -2197,7 +2197,7 @@ caam_jr_dev_uninit(struct rte_cryptodev *dev)
  *
  */
 static void *
-init_job_ring(void *reg_base_addr, uint32_t irq_id)
+init_job_ring(void *reg_base_addr, int irq_id)
 {
 	struct sec_job_ring_t *job_ring = NULL;
 	int i, ret = 0;
@@ -2207,7 +2207,7 @@ init_job_ring(void *reg_base_addr, uint32_t irq_id)
 	int irq_coalescing_count = 0;
 
 	for (i = 0; i < MAX_SEC_JOB_RINGS; i++) {
-		if (g_job_rings[i].irq_fd == 0) {
+		if (g_job_rings[i].irq_fd == -1) {
 			job_ring = &g_job_rings[i];
 			g_job_rings_no++;
 			break;
@@ -2398,6 +2398,8 @@ caam_jr_dev_init(const char *name,
 static int
 cryptodev_caam_jr_probe(struct rte_vdev_device *vdev)
 {
+	int ret;
+
 	struct rte_cryptodev_pmd_init_params init_params = {
 		"",
 		sizeof(struct sec_job_ring_t),
@@ -2414,6 +2416,12 @@ cryptodev_caam_jr_probe(struct rte_vdev_device *vdev)
 	input_args = rte_vdev_device_args(vdev);
 	rte_cryptodev_pmd_parse_input_args(&init_params, input_args);
 
+	ret = of_init();
+	if (ret) {
+		RTE_LOG(ERR, PMD,
+		"of_init failed\n");
+		return -EINVAL;
+	}
 	/* if sec device version is not configured */
 	if (!rta_get_sec_era()) {
 		const struct device_node *caam_node;
@@ -2424,7 +2432,7 @@ cryptodev_caam_jr_probe(struct rte_vdev_device *vdev)
 					NULL);
 			if (prop) {
 				rta_set_sec_era(
-					INTL_SEC_ERA(cpu_to_caam32(*prop)));
+					INTL_SEC_ERA(rte_be_to_cpu_32(*prop)));
 				break;
 			}
 		}
@@ -2460,6 +2468,15 @@ cryptodev_caam_jr_remove(struct rte_vdev_device *vdev)
 	return rte_cryptodev_pmd_destroy(cryptodev);
 }
 
+static void
+sec_job_rings_init(void)
+{
+	int i;
+
+	for (i = 0; i < MAX_SEC_JOB_RINGS; i++)
+		g_job_rings[i].irq_fd = -1;
+}
+
 static struct rte_vdev_driver cryptodev_caam_jr_drv = {
 	.probe = cryptodev_caam_jr_probe,
 	.remove = cryptodev_caam_jr_remove
@@ -2474,6 +2491,12 @@ RTE_PMD_REGISTER_PARAM_STRING(CRYPTODEV_NAME_CAAM_JR_PMD,
 RTE_PMD_REGISTER_CRYPTO_DRIVER(caam_jr_crypto_drv, cryptodev_caam_jr_drv.driver,
 		cryptodev_driver_id);
 
+RTE_INIT(caam_jr_init)
+{
+	sec_uio_job_rings_init();
+	sec_job_rings_init();
+}
+
 RTE_INIT(caam_jr_init_log)
 {
 	caam_jr_logtype = rte_log_register("pmd.crypto.caam");
diff --git a/dpdk/drivers/crypto/caam_jr/caam_jr_hw_specific.h b/dpdk/drivers/crypto/caam_jr/caam_jr_hw_specific.h
index 5f58a585d7..bbe8bc3f90 100644
--- a/dpdk/drivers/crypto/caam_jr/caam_jr_hw_specific.h
+++ b/dpdk/drivers/crypto/caam_jr/caam_jr_hw_specific.h
@@ -360,7 +360,7 @@ struct sec_job_ring_t {
 				 * bitwise operations.
 				 */
 
-	uint32_t irq_fd;	/* The file descriptor used for polling from
+	int irq_fd;		/* The file descriptor used for polling from
 				 * user space for interrupts notifications
 				 */
 	uint32_t jr_mode;	/* Model used by SEC Driver to receive
diff --git a/dpdk/drivers/crypto/caam_jr/caam_jr_pvt.h b/dpdk/drivers/crypto/caam_jr/caam_jr_pvt.h
index 98cd4438aa..552d6b9b1b 100644
--- a/dpdk/drivers/crypto/caam_jr/caam_jr_pvt.h
+++ b/dpdk/drivers/crypto/caam_jr/caam_jr_pvt.h
@@ -216,7 +216,7 @@ calc_chksum(void *buffer, int len)
 }
 struct uio_job_ring {
 	uint32_t jr_id;
-	uint32_t uio_fd;
+	int uio_fd;
 	void *register_base_addr;
 	int map_size;
 	int uio_minor_number;
@@ -224,8 +224,9 @@ struct uio_job_ring {
 
 int sec_cleanup(void);
 int sec_configure(void);
+void sec_uio_job_rings_init(void);
 struct uio_job_ring *config_job_ring(void);
-void free_job_ring(uint32_t uio_fd);
+void free_job_ring(int uio_fd);
 
 /* For Dma memory allocation of specified length and alignment */
 static inline void *
@@ -279,7 +280,7 @@ static inline rte_iova_t caam_jr_dma_vtop(void *ptr)
  * @retval 0 for success
  * @retval -1 value for error
  */
-uint32_t caam_jr_enable_irqs(uint32_t uio_fd);
+int caam_jr_enable_irqs(int uio_fd);
 
 /** @brief Request to SEC kernel driver to disable interrupts for descriptor
  *  finished processing
@@ -292,6 +293,6 @@ uint32_t caam_jr_enable_irqs(uint32_t uio_fd);
  * @retval -1 value for error
  *
  */
-uint32_t caam_jr_disable_irqs(uint32_t uio_fd);
+int caam_jr_disable_irqs(int uio_fd);
 
 #endif
diff --git a/dpdk/drivers/crypto/caam_jr/caam_jr_uio.c b/dpdk/drivers/crypto/caam_jr/caam_jr_uio.c
index b1bb44ca42..e4ee102344 100644
--- a/dpdk/drivers/crypto/caam_jr/caam_jr_uio.c
+++ b/dpdk/drivers/crypto/caam_jr/caam_jr_uio.c
@@ -145,7 +145,7 @@ file_read_first_line(const char root[], const char subdir[],
 		 "%s/%s/%s", root, subdir, filename);
 
 	fd = open(absolute_file_name, O_RDONLY);
-	SEC_ASSERT(fd > 0, fd, "Error opening file %s",
+	SEC_ASSERT(fd >= 0, fd, "Error opening file %s",
 			absolute_file_name);
 
 	/* read UIO device name from first line in file */
@@ -179,7 +179,7 @@ file_read_first_line(const char root[], const char subdir[],
  *         kernel driver as well. No special return values are used.
  */
 static int
-sec_uio_send_command(uint32_t uio_fd, int32_t uio_command)
+sec_uio_send_command(int uio_fd, int32_t uio_command)
 {
 	int ret;
 
@@ -201,8 +201,8 @@ sec_uio_send_command(uint32_t uio_fd, int32_t uio_command)
  * @retval 0 for success
  * @retval -1 value for error
  */
-uint32_t
-caam_jr_enable_irqs(uint32_t uio_fd)
+int
+caam_jr_enable_irqs(int uio_fd)
 {
 	int ret;
 
@@ -232,8 +232,8 @@ caam_jr_enable_irqs(uint32_t uio_fd)
  * @retval -1 value for error
  *
  */
-uint32_t
-caam_jr_disable_irqs(uint32_t uio_fd)
+int
+caam_jr_disable_irqs(int uio_fd)
 {
 	int ret;
 
@@ -322,12 +322,12 @@ uio_map_registers(int uio_device_fd, int uio_device_id,
 }
 
 void
-free_job_ring(uint32_t uio_fd)
+free_job_ring(int uio_fd)
 {
 	struct uio_job_ring *job_ring = NULL;
 	int i;
 
-	if (!uio_fd)
+	if (uio_fd == -1)
 		return;
 
 	for (i = 0; i < MAX_SEC_JOB_RINGS; i++) {
@@ -347,7 +347,7 @@ free_job_ring(uint32_t uio_fd)
 			job_ring->jr_id, job_ring->uio_fd);
 	close(job_ring->uio_fd);
 	g_uio_jr_num--;
-	job_ring->uio_fd = 0;
+	job_ring->uio_fd = -1;
 	if (job_ring->register_base_addr == NULL)
 		return;
 
@@ -370,7 +370,7 @@ uio_job_ring *config_job_ring(void)
 	int i;
 
 	for (i = 0; i < MAX_SEC_JOB_RINGS; i++) {
-		if (g_uio_job_ring[i].uio_fd == 0) {
+		if (g_uio_job_ring[i].uio_fd == -1) {
 			job_ring = &g_uio_job_ring[i];
 			g_uio_jr_num++;
 			break;
@@ -389,7 +389,7 @@ uio_job_ring *config_job_ring(void)
 
 	/* Open device file */
 	job_ring->uio_fd = open(uio_device_file_name, O_RDWR);
-	SEC_ASSERT(job_ring->uio_fd > 0, NULL,
+	SEC_ASSERT(job_ring->uio_fd >= 0, NULL,
 		"Failed to open UIO device file for job ring %d",
 		job_ring->jr_id);
 
@@ -488,12 +488,22 @@ sec_cleanup(void)
 		/* I need to close the fd after shutdown UIO commands need to be
 		 * sent using the fd
 		 */
-		if (job_ring->uio_fd != 0) {
+		if (job_ring->uio_fd != -1) {
 			CAAM_JR_INFO(
 			"Closed device file for job ring %d , fd = %d",
 			job_ring->jr_id, job_ring->uio_fd);
 			close(job_ring->uio_fd);
+			job_ring->uio_fd = -1;
 		}
 	}
 	return 0;
 }
+
+void
+sec_uio_job_rings_init(void)
+{
+	int i;
+
+	for (i = 0; i < MAX_SEC_JOB_RINGS; i++)
+		g_uio_job_ring[i].uio_fd = -1;
+}
diff --git a/dpdk/drivers/crypto/caam_jr/meson.build b/dpdk/drivers/crypto/caam_jr/meson.build
index 50132aebef..0dbfa2ee9c 100644
--- a/dpdk/drivers/crypto/caam_jr/meson.build
+++ b/dpdk/drivers/crypto/caam_jr/meson.build
@@ -14,6 +14,11 @@ sources = files('caam_jr_capabilities.c',
 
 allow_experimental_apis = true
 
+# FIXME: temporary solution for Bugzilla 469
+if (toolchain == 'gcc' and cc.version().version_compare('>=10.0.0'))
+	cflags += '-fcommon'
+endif
+
 includes += include_directories('../../bus/dpaa/include/')
 includes += include_directories('../../common/dpaax/')
 includes += include_directories('../../common/dpaax/caamflib/')
diff --git a/dpdk/drivers/crypto/ccp/ccp_dev.c b/dpdk/drivers/crypto/ccp/ccp_dev.c
index 80fe6a4533..7d98b2eb25 100644
--- a/dpdk/drivers/crypto/ccp/ccp_dev.c
+++ b/dpdk/drivers/crypto/ccp/ccp_dev.c
@@ -760,7 +760,7 @@ ccp_probe_device(const char *dirname, uint16_t domain,
 	return 0;
 fail:
 	CCP_LOG_ERR("CCP Device probe failed");
-	if (uio_fd > 0)
+	if (uio_fd >= 0)
 		close(uio_fd);
 	if (ccp_dev)
 		rte_free(ccp_dev);
diff --git a/dpdk/drivers/crypto/ccp/ccp_dev.h b/dpdk/drivers/crypto/ccp/ccp_dev.h
index f4ad9eafd5..37e04218ce 100644
--- a/dpdk/drivers/crypto/ccp/ccp_dev.h
+++ b/dpdk/drivers/crypto/ccp/ccp_dev.h
@@ -220,7 +220,7 @@ struct ccp_queue {
 	/**< lsb assigned for sha ctx */
 	uint32_t sb_hmac;
 	/**< lsb assigned for hmac ctx */
-} ____cacheline_aligned;
+} __rte_cache_aligned;
 
 /**
  * A structure describing a CCP device.
diff --git a/dpdk/drivers/crypto/ccp/meson.build b/dpdk/drivers/crypto/ccp/meson.build
index 6f7217adbf..99c7684e50 100644
--- a/dpdk/drivers/crypto/ccp/meson.build
+++ b/dpdk/drivers/crypto/ccp/meson.build
@@ -5,7 +5,7 @@ if not is_linux
 	build = false
 	reason = 'only supported on linux'
 endif
-dep = dependency('libcrypto', required: false)
+dep = dependency('libcrypto', required: false, method: 'pkg-config')
 if not dep.found()
 	build = false
 	reason = 'missing dependency, "libcrypto"'
diff --git a/dpdk/drivers/crypto/dpaa2_sec/Makefile b/dpdk/drivers/crypto/dpaa2_sec/Makefile
index 96b9c78435..183e9412ae 100644
--- a/dpdk/drivers/crypto/dpaa2_sec/Makefile
+++ b/dpdk/drivers/crypto/dpaa2_sec/Makefile
@@ -20,6 +20,13 @@ CFLAGS += -Wno-implicit-fallthrough
 endif
 endif
 
+# FIXME: temporary solution for Bugzilla 469
+ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)
+ifeq ($(shell test $(GCC_VERSION) -ge 100 && echo 1), 1)
+CFLAGS += -fcommon
+endif
+endif
+
 CFLAGS += -I$(RTE_SDK)/drivers/common/dpaax
 CFLAGS += -I$(RTE_SDK)/drivers/common/dpaax/caamflib
 CFLAGS += -I$(RTE_SDK)/drivers/crypto/dpaa2_sec/
diff --git a/dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c b/dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
index 6ed2701ab6..8df915e610 100644
--- a/dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
+++ b/dpdk/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
@@ -1,7 +1,7 @@
 /* SPDX-License-Identifier: BSD-3-Clause
  *
  *   Copyright (c) 2016 Freescale Semiconductor, Inc. All rights reserved.
- *   Copyright 2016-2019 NXP
+ *   Copyright 2016-2020 NXP
  *
  */
 
@@ -168,7 +168,8 @@ build_proto_compound_sg_fd(dpaa2_sec_session *sess,
 	 * mbuf priv after sym_op.
 	 */
 	if (sess->ctxt_type == DPAA2_SEC_PDCP && sess->pdcp.hfn_ovd) {
-		uint32_t hfn_ovd = *((uint8_t *)op + sess->pdcp.hfn_ovd_offset);
+		uint32_t hfn_ovd = *(uint32_t *)((uint8_t *)op +
+					sess->pdcp.hfn_ovd_offset);
 		/*enable HFN override override */
 		DPAA2_SET_FLE_INTERNAL_JD(ip_fle, hfn_ovd);
 		DPAA2_SET_FLE_INTERNAL_JD(op_fle, hfn_ovd);
@@ -243,7 +244,8 @@ build_proto_compound_fd(dpaa2_sec_session *sess,
 	 * mbuf priv after sym_op.
 	 */
 	if (sess->ctxt_type == DPAA2_SEC_PDCP && sess->pdcp.hfn_ovd) {
-		uint32_t hfn_ovd = *((uint8_t *)op + sess->pdcp.hfn_ovd_offset);
+		uint32_t hfn_ovd = *(uint32_t *)((uint8_t *)op +
+					sess->pdcp.hfn_ovd_offset);
 		/*enable HFN override override */
 		DPAA2_SET_FLE_INTERNAL_JD(ip_fle, hfn_ovd);
 		DPAA2_SET_FLE_INTERNAL_JD(op_fle, hfn_ovd);
@@ -1845,7 +1847,7 @@ dpaa2_sec_cipher_init(struct rte_cryptodev *dev,
 	session->ctxt_type = DPAA2_SEC_CIPHER;
 	session->cipher_key.data = rte_zmalloc(NULL, xform->cipher.key.length,
 			RTE_CACHE_LINE_SIZE);
-	if (session->cipher_key.data == NULL) {
+	if (session->cipher_key.data == NULL && xform->cipher.key.length > 0) {
 		DPAA2_SEC_ERR("No Memory for cipher key");
 		rte_free(priv);
 		return -1;
@@ -2192,7 +2194,7 @@ dpaa2_sec_aead_init(struct rte_cryptodev *dev,
 
 	priv->flc_desc[0].desc[0] = aeaddata.keylen;
 	err = rta_inline_query(IPSEC_AUTH_VAR_AES_DEC_BASE_DESC_LEN,
-			       MIN_JOB_DESC_SIZE,
+			       DESC_JOB_IO_LEN,
 			       (unsigned int *)priv->flc_desc[0].desc,
 			       &priv->flc_desc[0].desc[1], 1);
 
@@ -2410,7 +2412,7 @@ dpaa2_sec_aead_chain_init(struct rte_cryptodev *dev,
 	priv->flc_desc[0].desc[0] = cipherdata.keylen;
 	priv->flc_desc[0].desc[1] = authdata.keylen;
 	err = rta_inline_query(IPSEC_AUTH_VAR_AES_DEC_BASE_DESC_LEN,
-			       MIN_JOB_DESC_SIZE,
+			       DESC_JOB_IO_LEN,
 			       (unsigned int *)priv->flc_desc[0].desc,
 			       &priv->flc_desc[0].desc[2], 2);
 
@@ -2744,12 +2746,6 @@ dpaa2_sec_ipsec_proto_init(struct rte_crypto_cipher_xform *cipher_xform,
 	return 0;
 }
 
-#ifdef RTE_LIBRTE_SECURITY_TEST
-static uint8_t aes_cbc_iv[] = {
-	0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
-	0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f };
-#endif
-
 static int
 dpaa2_sec_set_ipsec_session(struct rte_cryptodev *dev,
 			    struct rte_security_session_conf *conf,
@@ -3145,6 +3141,14 @@ dpaa2_sec_set_pdcp_session(struct rte_cryptodev *dev,
 		goto out;
 	}
 
+	if (rta_inline_pdcp_query(authdata.algtype,
+				cipherdata.algtype,
+				session->pdcp.sn_size,
+				session->pdcp.hfn_ovd)) {
+		cipherdata.key = DPAA2_VADDR_TO_IOVA(cipherdata.key);
+		cipherdata.key_type = RTA_DATA_PTR;
+	}
+
 	if (pdcp_xform->domain == RTE_SECURITY_PDCP_MODE_CONTROL) {
 		if (session->dir == DIR_ENC)
 			bufsize = cnstr_shdsc_pdcp_c_plane_encap(
@@ -3482,7 +3486,7 @@ void dpaa2_sec_stats_get(struct rte_cryptodev *dev,
 		return;
 	}
 	for (i = 0; i < dev->data->nb_queue_pairs; i++) {
-		if (qp[i] == NULL) {
+		if (qp == NULL || qp[i] == NULL) {
 			DPAA2_SEC_DEBUG("Uninitialised queue pair");
 			continue;
 		}
diff --git a/dpdk/drivers/crypto/dpaa2_sec/meson.build b/dpdk/drivers/crypto/dpaa2_sec/meson.build
index ab9c8c8bf9..3f1dfd67da 100644
--- a/dpdk/drivers/crypto/dpaa2_sec/meson.build
+++ b/dpdk/drivers/crypto/dpaa2_sec/meson.build
@@ -12,4 +12,9 @@ sources = files('dpaa2_sec_dpseci.c',
 
 allow_experimental_apis = true
 
+# FIXME: temporary solution for Bugzilla 469
+if (toolchain == 'gcc' and cc.version().version_compare('>=10.0.0'))
+	cflags += '-fcommon'
+endif
+
 includes += include_directories('mc', '../../common/dpaax', '../../common/dpaax/caamflib')
diff --git a/dpdk/drivers/crypto/dpaa_sec/Makefile b/dpdk/drivers/crypto/dpaa_sec/Makefile
index fbfd775855..b5a97b9f6e 100644
--- a/dpdk/drivers/crypto/dpaa_sec/Makefile
+++ b/dpdk/drivers/crypto/dpaa_sec/Makefile
@@ -14,6 +14,13 @@ CFLAGS += -DALLOW_EXPERIMENTAL_API
 CFLAGS += -O3
 CFLAGS += $(WERROR_FLAGS)
 
+# FIXME: temporary solution for Bugzilla 469
+ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)
+ifeq ($(shell test $(GCC_VERSION) -ge 100 && echo 1), 1)
+CFLAGS += -fcommon
+endif
+endif
+
 CFLAGS += -I$(RTE_SDK)/drivers/bus/dpaa
 CFLAGS += -I$(RTE_SDK)/drivers/bus/dpaa/include
 CFLAGS += -I$(RTE_SDK)/drivers/bus/dpaa/base/qbman
diff --git a/dpdk/drivers/crypto/dpaa_sec/dpaa_sec.c b/dpdk/drivers/crypto/dpaa_sec/dpaa_sec.c
index e0b307cecd..a650313cdb 100644
--- a/dpdk/drivers/crypto/dpaa_sec/dpaa_sec.c
+++ b/dpdk/drivers/crypto/dpaa_sec/dpaa_sec.c
@@ -94,31 +94,6 @@ dpaa_sec_alloc_ctx(dpaa_sec_session *ses, int sg_count)
 	return ctx;
 }
 
-static inline rte_iova_t
-dpaa_mem_vtop(void *vaddr)
-{
-	const struct rte_memseg *ms;
-
-	ms = rte_mem_virt2memseg(vaddr, NULL);
-	if (ms) {
-		dpaax_iova_table_update(ms->iova, ms->addr, ms->len);
-		return ms->iova + RTE_PTR_DIFF(vaddr, ms->addr);
-	}
-	return (size_t)NULL;
-}
-
-static inline void *
-dpaa_mem_ptov(rte_iova_t paddr)
-{
-	void *va;
-
-	va = (void *)dpaax_iova_table_get_va(paddr);
-	if (likely(va))
-		return va;
-
-	return rte_mem_iova2virt(paddr);
-}
-
 static void
 ern_sec_fq_handler(struct qman_portal *qm __rte_unused,
 		   struct qman_fq *fq,
@@ -183,7 +158,7 @@ dqrr_out_fq_cb_rx(struct qman_portal *qm __always_unused,
 	 * sg[0] is for output
 	 * sg[1] for input
 	 */
-	job = dpaa_mem_ptov(qm_fd_addr_get64(fd));
+	job = rte_dpaa_mem_ptov(qm_fd_addr_get64(fd));
 
 	ctx = container_of(job, struct dpaa_sec_op_ctx, job);
 	ctx->fd_status = fd->status;
@@ -262,7 +237,6 @@ dpaa_sec_prep_pdcp_cdb(dpaa_sec_session *ses)
 	struct sec_cdb *cdb = &ses->cdb;
 	struct alginfo *p_authdata = NULL;
 	int32_t shared_desc_len = 0;
-	int err;
 #if RTE_BYTE_ORDER == RTE_BIG_ENDIAN
 	int swap = false;
 #else
@@ -276,10 +250,6 @@ dpaa_sec_prep_pdcp_cdb(dpaa_sec_session *ses)
 	cipherdata.algtype = ses->cipher_key.alg;
 	cipherdata.algmode = ses->cipher_key.algmode;
 
-	cdb->sh_desc[0] = cipherdata.keylen;
-	cdb->sh_desc[1] = 0;
-	cdb->sh_desc[2] = 0;
-
 	if (ses->auth_alg) {
 		authdata.key = (size_t)ses->auth_key.data;
 		authdata.keylen = ses->auth_key.length;
@@ -289,33 +259,17 @@ dpaa_sec_prep_pdcp_cdb(dpaa_sec_session *ses)
 		authdata.algmode = ses->auth_key.algmode;
 
 		p_authdata = &authdata;
-
-		cdb->sh_desc[1] = authdata.keylen;
 	}
 
-	err = rta_inline_query(IPSEC_AUTH_VAR_AES_DEC_BASE_DESC_LEN,
-			       MIN_JOB_DESC_SIZE,
-			       (unsigned int *)cdb->sh_desc,
-			       &cdb->sh_desc[2], 2);
-	if (err < 0) {
-		DPAA_SEC_ERR("Crypto: Incorrect key lengths");
-		return err;
-	}
-
-	if (!(cdb->sh_desc[2] & 1) && cipherdata.keylen) {
+	if (rta_inline_pdcp_query(authdata.algtype,
+				cipherdata.algtype,
+				ses->pdcp.sn_size,
+				ses->pdcp.hfn_ovd)) {
 		cipherdata.key =
-			(size_t)dpaa_mem_vtop((void *)(size_t)cipherdata.key);
+			(size_t)rte_dpaa_mem_vtop((void *)
+					(size_t)cipherdata.key);
 		cipherdata.key_type = RTA_DATA_PTR;
 	}
-	if (!(cdb->sh_desc[2] & (1 << 1)) &&  authdata.keylen) {
-		authdata.key =
-			(size_t)dpaa_mem_vtop((void *)(size_t)authdata.key);
-		authdata.key_type = RTA_DATA_PTR;
-	}
-
-	cdb->sh_desc[0] = 0;
-	cdb->sh_desc[1] = 0;
-	cdb->sh_desc[2] = 0;
 
 	if (ses->pdcp.domain == RTE_SECURITY_PDCP_MODE_CONTROL) {
 		if (ses->dir == DIR_ENC)
@@ -394,7 +348,7 @@ dpaa_sec_prep_ipsec_cdb(dpaa_sec_session *ses)
 	cdb->sh_desc[0] = cipherdata.keylen;
 	cdb->sh_desc[1] = authdata.keylen;
 	err = rta_inline_query(IPSEC_AUTH_VAR_AES_DEC_BASE_DESC_LEN,
-			       MIN_JOB_DESC_SIZE,
+			       DESC_JOB_IO_LEN,
 			       (unsigned int *)cdb->sh_desc,
 			       &cdb->sh_desc[2], 2);
 
@@ -405,14 +359,14 @@ dpaa_sec_prep_ipsec_cdb(dpaa_sec_session *ses)
 	if (cdb->sh_desc[2] & 1)
 		cipherdata.key_type = RTA_DATA_IMM;
 	else {
-		cipherdata.key = (size_t)dpaa_mem_vtop(
+		cipherdata.key = (size_t)rte_dpaa_mem_vtop(
 					(void *)(size_t)cipherdata.key);
 		cipherdata.key_type = RTA_DATA_PTR;
 	}
 	if (cdb->sh_desc[2] & (1<<1))
 		authdata.key_type = RTA_DATA_IMM;
 	else {
-		authdata.key = (size_t)dpaa_mem_vtop(
+		authdata.key = (size_t)rte_dpaa_mem_vtop(
 					(void *)(size_t)authdata.key);
 		authdata.key_type = RTA_DATA_PTR;
 	}
@@ -580,7 +534,7 @@ dpaa_sec_prep_cdb(dpaa_sec_session *ses)
 		cdb->sh_desc[0] = alginfo_c.keylen;
 		cdb->sh_desc[1] = alginfo_a.keylen;
 		err = rta_inline_query(IPSEC_AUTH_VAR_AES_DEC_BASE_DESC_LEN,
-				       MIN_JOB_DESC_SIZE,
+				       DESC_JOB_IO_LEN,
 				       (unsigned int *)cdb->sh_desc,
 				       &cdb->sh_desc[2], 2);
 
@@ -591,14 +545,14 @@ dpaa_sec_prep_cdb(dpaa_sec_session *ses)
 		if (cdb->sh_desc[2] & 1)
 			alginfo_c.key_type = RTA_DATA_IMM;
 		else {
-			alginfo_c.key = (size_t)dpaa_mem_vtop(
+			alginfo_c.key = (size_t)rte_dpaa_mem_vtop(
 						(void *)(size_t)alginfo_c.key);
 			alginfo_c.key_type = RTA_DATA_PTR;
 		}
 		if (cdb->sh_desc[2] & (1<<1))
 			alginfo_a.key_type = RTA_DATA_IMM;
 		else {
-			alginfo_a.key = (size_t)dpaa_mem_vtop(
+			alginfo_a.key = (size_t)rte_dpaa_mem_vtop(
 						(void *)(size_t)alginfo_a.key);
 			alginfo_a.key_type = RTA_DATA_PTR;
 		}
@@ -674,7 +628,7 @@ dpaa_sec_deq(struct dpaa_sec_qp *qp, struct rte_crypto_op **ops, int nb_ops)
 		 * sg[0] is for output
 		 * sg[1] for input
 		 */
-		job = dpaa_mem_ptov(qm_fd_addr_get64(fd));
+		job = rte_dpaa_mem_ptov(qm_fd_addr_get64(fd));
 
 		ctx = container_of(job, struct dpaa_sec_op_ctx, job);
 		ctx->fd_status = fd->status;
@@ -768,7 +722,7 @@ build_auth_only_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	in_sg->extension = 1;
 	in_sg->final = 1;
 	in_sg->length = data_len;
-	qm_sg_entry_set64(in_sg, dpaa_mem_vtop(&cf->sg[2]));
+	qm_sg_entry_set64(in_sg, rte_dpaa_mem_vtop(&cf->sg[2]));
 
 	/* 1st seg */
 	sg = in_sg + 1;
@@ -788,7 +742,7 @@ build_auth_only_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		} else {
 			sg->length = ses->iv.length;
 		}
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(iv_ptr));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(iv_ptr));
 		in_sg->length += sg->length;
 		cpu_to_hw_sg(sg);
 		sg++;
@@ -821,7 +775,7 @@ build_auth_only_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg++;
 		rte_memcpy(old_digest, sym->auth.digest.data,
 				ses->digest_length);
-		start_addr = dpaa_mem_vtop(old_digest);
+		start_addr = rte_dpaa_mem_vtop(old_digest);
 		qm_sg_entry_set64(sg, start_addr);
 		sg->length = ses->digest_length;
 		in_sg->length += ses->digest_length;
@@ -888,7 +842,7 @@ build_auth_only(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	in_sg->extension = 1;
 	in_sg->final = 1;
 	in_sg->length = data_len;
-	qm_sg_entry_set64(in_sg, dpaa_mem_vtop(&cf->sg[2]));
+	qm_sg_entry_set64(in_sg, rte_dpaa_mem_vtop(&cf->sg[2]));
 	sg = &cf->sg[2];
 
 	if (ses->iv.length) {
@@ -906,7 +860,7 @@ build_auth_only(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		} else {
 			sg->length = ses->iv.length;
 		}
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(iv_ptr));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(iv_ptr));
 		in_sg->length += sg->length;
 		cpu_to_hw_sg(sg);
 		sg++;
@@ -923,7 +877,7 @@ build_auth_only(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		rte_memcpy(old_digest, sym->auth.digest.data,
 				ses->digest_length);
 		/* let's check digest by hw */
-		start_addr = dpaa_mem_vtop(old_digest);
+		start_addr = rte_dpaa_mem_vtop(old_digest);
 		sg++;
 		qm_sg_entry_set64(sg, start_addr);
 		sg->length = ses->digest_length;
@@ -987,7 +941,7 @@ build_cipher_only_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	out_sg = &cf->sg[0];
 	out_sg->extension = 1;
 	out_sg->length = data_len;
-	qm_sg_entry_set64(out_sg, dpaa_mem_vtop(&cf->sg[2]));
+	qm_sg_entry_set64(out_sg, rte_dpaa_mem_vtop(&cf->sg[2]));
 	cpu_to_hw_sg(out_sg);
 
 	/* 1st seg */
@@ -1016,11 +970,11 @@ build_cipher_only_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	in_sg->length = data_len + ses->iv.length;
 
 	sg++;
-	qm_sg_entry_set64(in_sg, dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(in_sg, rte_dpaa_mem_vtop(sg));
 	cpu_to_hw_sg(in_sg);
 
 	/* IV */
-	qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+	qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 	sg->length = ses->iv.length;
 	cpu_to_hw_sg(sg);
 
@@ -1098,11 +1052,11 @@ build_cipher_only(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	sg->extension = 1;
 	sg->final = 1;
 	sg->length = data_len + ses->iv.length;
-	qm_sg_entry_set64(sg, dpaa_mem_vtop(&cf->sg[2]));
+	qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(&cf->sg[2]));
 	cpu_to_hw_sg(sg);
 
 	sg = &cf->sg[2];
-	qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+	qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 	sg->length = ses->iv.length;
 	cpu_to_hw_sg(sg);
 
@@ -1163,7 +1117,7 @@ build_cipher_auth_gcm_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 
 	/* output sg entries */
 	sg = &cf->sg[2];
-	qm_sg_entry_set64(out_sg, dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(out_sg, rte_dpaa_mem_vtop(sg));
 	cpu_to_hw_sg(out_sg);
 
 	/* 1st seg */
@@ -1206,18 +1160,18 @@ build_cipher_auth_gcm_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 
 	/* input sg entries */
 	sg++;
-	qm_sg_entry_set64(in_sg, dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(in_sg, rte_dpaa_mem_vtop(sg));
 	cpu_to_hw_sg(in_sg);
 
 	/* 1st seg IV */
-	qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+	qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 	sg->length = ses->iv.length;
 	cpu_to_hw_sg(sg);
 
 	/* 2nd seg auth only */
 	if (ses->auth_only_len) {
 		sg++;
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(sym->aead.aad.data));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(sym->aead.aad.data));
 		sg->length = ses->auth_only_len;
 		cpu_to_hw_sg(sg);
 	}
@@ -1243,7 +1197,7 @@ build_cipher_auth_gcm_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg++;
 		memcpy(ctx->digest, sym->aead.digest.data,
 			ses->digest_length);
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(ctx->digest));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(ctx->digest));
 		sg->length = ses->digest_length;
 	}
 	sg->final = 1;
@@ -1281,9 +1235,9 @@ build_cipher_auth_gcm(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	/* input */
 	rte_prefetch0(cf->sg);
 	sg = &cf->sg[2];
-	qm_sg_entry_set64(&cf->sg[1], dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(&cf->sg[1], rte_dpaa_mem_vtop(sg));
 	if (is_encode(ses)) {
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 		sg->length = ses->iv.length;
 		length += sg->length;
 		cpu_to_hw_sg(sg);
@@ -1291,7 +1245,7 @@ build_cipher_auth_gcm(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg++;
 		if (ses->auth_only_len) {
 			qm_sg_entry_set64(sg,
-					  dpaa_mem_vtop(sym->aead.aad.data));
+					  rte_dpaa_mem_vtop(sym->aead.aad.data));
 			sg->length = ses->auth_only_len;
 			length += sg->length;
 			cpu_to_hw_sg(sg);
@@ -1303,7 +1257,7 @@ build_cipher_auth_gcm(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg->final = 1;
 		cpu_to_hw_sg(sg);
 	} else {
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 		sg->length = ses->iv.length;
 		length += sg->length;
 		cpu_to_hw_sg(sg);
@@ -1311,7 +1265,7 @@ build_cipher_auth_gcm(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg++;
 		if (ses->auth_only_len) {
 			qm_sg_entry_set64(sg,
-					  dpaa_mem_vtop(sym->aead.aad.data));
+					  rte_dpaa_mem_vtop(sym->aead.aad.data));
 			sg->length = ses->auth_only_len;
 			length += sg->length;
 			cpu_to_hw_sg(sg);
@@ -1326,7 +1280,7 @@ build_cipher_auth_gcm(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		       ses->digest_length);
 		sg++;
 
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(ctx->digest));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(ctx->digest));
 		sg->length = ses->digest_length;
 		length += sg->length;
 		sg->final = 1;
@@ -1340,7 +1294,7 @@ build_cipher_auth_gcm(struct rte_crypto_op *op, dpaa_sec_session *ses)
 
 	/* output */
 	sg++;
-	qm_sg_entry_set64(&cf->sg[0], dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(&cf->sg[0], rte_dpaa_mem_vtop(sg));
 	qm_sg_entry_set64(sg,
 		dst_start_addr + sym->aead.data.offset);
 	sg->length = sym->aead.data.length;
@@ -1409,7 +1363,7 @@ build_cipher_auth_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 
 	/* output sg entries */
 	sg = &cf->sg[2];
-	qm_sg_entry_set64(out_sg, dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(out_sg, rte_dpaa_mem_vtop(sg));
 	cpu_to_hw_sg(out_sg);
 
 	/* 1st seg */
@@ -1451,11 +1405,11 @@ build_cipher_auth_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 
 	/* input sg entries */
 	sg++;
-	qm_sg_entry_set64(in_sg, dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(in_sg, rte_dpaa_mem_vtop(sg));
 	cpu_to_hw_sg(in_sg);
 
 	/* 1st seg IV */
-	qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+	qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 	sg->length = ses->iv.length;
 	cpu_to_hw_sg(sg);
 
@@ -1481,7 +1435,7 @@ build_cipher_auth_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg++;
 		memcpy(ctx->digest, sym->auth.digest.data,
 			ses->digest_length);
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(ctx->digest));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(ctx->digest));
 		sg->length = ses->digest_length;
 	}
 	sg->final = 1;
@@ -1518,9 +1472,9 @@ build_cipher_auth(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	/* input */
 	rte_prefetch0(cf->sg);
 	sg = &cf->sg[2];
-	qm_sg_entry_set64(&cf->sg[1], dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(&cf->sg[1], rte_dpaa_mem_vtop(sg));
 	if (is_encode(ses)) {
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 		sg->length = ses->iv.length;
 		length += sg->length;
 		cpu_to_hw_sg(sg);
@@ -1532,7 +1486,7 @@ build_cipher_auth(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		sg->final = 1;
 		cpu_to_hw_sg(sg);
 	} else {
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(IV_ptr));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(IV_ptr));
 		sg->length = ses->iv.length;
 		length += sg->length;
 		cpu_to_hw_sg(sg);
@@ -1548,7 +1502,7 @@ build_cipher_auth(struct rte_crypto_op *op, dpaa_sec_session *ses)
 		       ses->digest_length);
 		sg++;
 
-		qm_sg_entry_set64(sg, dpaa_mem_vtop(ctx->digest));
+		qm_sg_entry_set64(sg, rte_dpaa_mem_vtop(ctx->digest));
 		sg->length = ses->digest_length;
 		length += sg->length;
 		sg->final = 1;
@@ -1562,7 +1516,7 @@ build_cipher_auth(struct rte_crypto_op *op, dpaa_sec_session *ses)
 
 	/* output */
 	sg++;
-	qm_sg_entry_set64(&cf->sg[0], dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(&cf->sg[0], rte_dpaa_mem_vtop(sg));
 	qm_sg_entry_set64(sg, dst_start_addr + sym->cipher.data.offset);
 	sg->length = sym->cipher.data.length;
 	length = sg->length;
@@ -1656,7 +1610,7 @@ build_proto_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	/* output */
 	out_sg = &cf->sg[0];
 	out_sg->extension = 1;
-	qm_sg_entry_set64(out_sg, dpaa_mem_vtop(&cf->sg[2]));
+	qm_sg_entry_set64(out_sg, rte_dpaa_mem_vtop(&cf->sg[2]));
 
 	/* 1st seg */
 	sg = &cf->sg[2];
@@ -1689,7 +1643,7 @@ build_proto_sg(struct rte_crypto_op *op, dpaa_sec_session *ses)
 	in_len = mbuf->data_len;
 
 	sg++;
-	qm_sg_entry_set64(in_sg, dpaa_mem_vtop(sg));
+	qm_sg_entry_set64(in_sg, rte_dpaa_mem_vtop(sg));
 
 	/* 1st seg */
 	qm_sg_entry_set64(sg, rte_pktmbuf_mtophys(mbuf));
@@ -1884,7 +1838,7 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
 			inq[loop] = ses->inq[rte_lcore_id() % MAX_DPAA_CORES];
 			fd->opaque_addr = 0;
 			fd->cmd = 0;
-			qm_fd_addr_set64(fd, dpaa_mem_vtop(cf->sg));
+			qm_fd_addr_set64(fd, rte_dpaa_mem_vtop(cf->sg));
 			fd->_format1 = qm_fd_compound;
 			fd->length29 = 2 * sizeof(struct qm_sg_entry);
 
@@ -2349,7 +2303,7 @@ dpaa_sec_attach_sess_q(struct dpaa_sec_qp *qp, dpaa_sec_session *sess)
 		}
 	}
 	ret = dpaa_sec_init_rx(sess->inq[rte_lcore_id() % MAX_DPAA_CORES],
-			       dpaa_mem_vtop(&sess->cdb),
+			       rte_dpaa_mem_vtop(&sess->cdb),
 			       qman_fq_fqid(&qp->outq));
 	if (ret)
 		DPAA_SEC_ERR("Unable to init sec queue");
@@ -3005,7 +2959,8 @@ dpaa_sec_set_pdcp_session(struct rte_cryptodev *dev,
 	session->pdcp.hfn = pdcp_xform->hfn;
 	session->pdcp.hfn_threshold = pdcp_xform->hfn_threshold;
 	session->pdcp.hfn_ovd = pdcp_xform->hfn_ovrd;
-	session->pdcp.hfn_ovd_offset = cipher_xform->iv.offset;
+	if (cipher_xform)
+		session->pdcp.hfn_ovd_offset = cipher_xform->iv.offset;
 
 	rte_spinlock_lock(&dev_priv->lock);
 	for (i = 0; i < MAX_DPAA_CORES; i++) {
@@ -3149,7 +3104,7 @@ dpaa_sec_process_parallel_event(void *event,
 	 * sg[0] is for output
 	 * sg[1] for input
 	 */
-	job = dpaa_mem_ptov(qm_fd_addr_get64(fd));
+	job = rte_dpaa_mem_ptov(qm_fd_addr_get64(fd));
 
 	ctx = container_of(job, struct dpaa_sec_op_ctx, job);
 	ctx->fd_status = fd->status;
@@ -3204,7 +3159,7 @@ dpaa_sec_process_atomic_event(void *event,
 	 * sg[0] is for output
 	 * sg[1] for input
 	 */
-	job = dpaa_mem_ptov(qm_fd_addr_get64(fd));
+	job = rte_dpaa_mem_ptov(qm_fd_addr_get64(fd));
 
 	ctx = container_of(job, struct dpaa_sec_op_ctx, job);
 	ctx->fd_status = fd->status;
diff --git a/dpdk/drivers/crypto/dpaa_sec/meson.build b/dpdk/drivers/crypto/dpaa_sec/meson.build
index 9f17d3a43e..e819f9cf1b 100644
--- a/dpdk/drivers/crypto/dpaa_sec/meson.build
+++ b/dpdk/drivers/crypto/dpaa_sec/meson.build
@@ -6,11 +6,16 @@ if not is_linux
 	reason = 'only supported on linux'
 endif
 
-deps += ['bus_dpaa', 'security']
+deps += ['bus_dpaa', 'mempool_dpaa', 'security']
 sources = files('dpaa_sec.c')
 
 allow_experimental_apis = true
 
+# FIXME: temporary solution for Bugzilla 469
+if (toolchain == 'gcc' and cc.version().version_compare('>=10.0.0'))
+	cflags += '-fcommon'
+endif
+
 includes += include_directories('../../bus/dpaa/include')
 includes += include_directories('../../common/dpaax')
 includes += include_directories('../../common/dpaax/caamflib/')
diff --git a/dpdk/drivers/crypto/kasumi/kasumi_pmd_private.h b/dpdk/drivers/crypto/kasumi/kasumi_pmd_private.h
index 7ac19c5735..f0b83f2272 100644
--- a/dpdk/drivers/crypto/kasumi/kasumi_pmd_private.h
+++ b/dpdk/drivers/crypto/kasumi/kasumi_pmd_private.h
@@ -11,7 +11,7 @@
 /**< KASUMI PMD device name */
 
 /** KASUMI PMD LOGTYPE DRIVER */
-int kasumi_logtype_driver;
+extern int kasumi_logtype_driver;
 
 #define KASUMI_LOG(level, fmt, ...)  \
 	rte_log(RTE_LOG_ ## level, kasumi_logtype_driver,  \
@@ -72,6 +72,6 @@ kasumi_set_session_parameters(struct kasumi_session *sess,
 
 
 /** device specific operations function pointer structure */
-struct rte_cryptodev_ops *rte_kasumi_pmd_ops;
+extern struct rte_cryptodev_ops *rte_kasumi_pmd_ops;
 
 #endif /* _KASUMI_PMD_PRIVATE_H_ */
diff --git a/dpdk/drivers/crypto/kasumi/rte_kasumi_pmd.c b/dpdk/drivers/crypto/kasumi/rte_kasumi_pmd.c
index d0583ef073..dd85928c52 100644
--- a/dpdk/drivers/crypto/kasumi/rte_kasumi_pmd.c
+++ b/dpdk/drivers/crypto/kasumi/rte_kasumi_pmd.c
@@ -17,6 +17,7 @@
 #define KASUMI_MAX_BURST 4
 #define BYTE_LEN 8
 
+int kasumi_logtype_driver;
 static uint8_t cryptodev_driver_id;
 
 /** Get xform chain order. */
@@ -556,6 +557,7 @@ cryptodev_kasumi_create(const char *name,
 
 	dev->feature_flags = RTE_CRYPTODEV_FF_SYMMETRIC_CRYPTO |
 			RTE_CRYPTODEV_FF_SYM_OPERATION_CHAINING |
+			RTE_CRYPTODEV_FF_OOP_LB_IN_LB_OUT |
 			cpu_flags;
 
 	internals = dev->data->dev_private;
diff --git a/dpdk/drivers/crypto/mvsam/mrvl_pmd_private.h b/dpdk/drivers/crypto/mvsam/mrvl_pmd_private.h
index 09702b9e3e..e575330ef5 100644
--- a/dpdk/drivers/crypto/mvsam/mrvl_pmd_private.h
+++ b/dpdk/drivers/crypto/mvsam/mrvl_pmd_private.h
@@ -13,7 +13,7 @@
 /**< Marvell PMD device name */
 
 /** MRVL PMD LOGTYPE DRIVER */
-int mrvl_logtype_driver;
+extern int mrvl_logtype_driver;
 
 #define MRVL_LOG(level, fmt, ...) \
 	rte_log(RTE_LOG_ ## level, mrvl_logtype_driver, \
diff --git a/dpdk/drivers/crypto/mvsam/rte_mrvl_pmd.c b/dpdk/drivers/crypto/mvsam/rte_mrvl_pmd.c
index 3c0fe216f0..63782ce974 100644
--- a/dpdk/drivers/crypto/mvsam/rte_mrvl_pmd.c
+++ b/dpdk/drivers/crypto/mvsam/rte_mrvl_pmd.c
@@ -19,6 +19,7 @@
 #define MRVL_PMD_MAX_NB_SESS_ARG		("max_nb_sessions")
 #define MRVL_PMD_DEFAULT_MAX_NB_SESSIONS	2048
 
+int mrvl_logtype_driver;
 static uint8_t cryptodev_driver_id;
 
 struct mrvl_pmd_init_params {
diff --git a/dpdk/drivers/crypto/nitrox/nitrox_csr.h b/dpdk/drivers/crypto/nitrox/nitrox_csr.h
index 8cd92e38be..de7a3c6713 100644
--- a/dpdk/drivers/crypto/nitrox/nitrox_csr.h
+++ b/dpdk/drivers/crypto/nitrox/nitrox_csr.h
@@ -12,18 +12,18 @@
 #define NITROX_CSR_ADDR(bar_addr, offset) (bar_addr + (offset))
 
 /* NPS packet registers */
-#define NPS_PKT_IN_INSTR_CTLX(_i)	(0x10060 + ((_i) * 0x40000))
-#define NPS_PKT_IN_INSTR_BADDRX(_i)	(0x10068 + ((_i) * 0x40000))
-#define NPS_PKT_IN_INSTR_RSIZEX(_i)	(0x10070 + ((_i) * 0x40000))
-#define NPS_PKT_IN_DONE_CNTSX(_i)	(0x10080 + ((_i) * 0x40000))
-#define NPS_PKT_IN_INSTR_BAOFF_DBELLX(_i)	(0x10078 + ((_i) * 0x40000))
-#define NPS_PKT_IN_INT_LEVELSX(_i)		(0x10088 + ((_i) * 0x40000))
-#define NPS_PKT_SLC_CTLX(_i)		(0x10000 + ((_i) * 0x40000))
-#define NPS_PKT_SLC_CNTSX(_i)		(0x10008 + ((_i) * 0x40000))
-#define NPS_PKT_SLC_INT_LEVELSX(_i)	(0x10010 + ((_i) * 0x40000))
+#define NPS_PKT_IN_INSTR_CTLX(_i)	(0x10060UL + ((_i) * 0x40000UL))
+#define NPS_PKT_IN_INSTR_BADDRX(_i)	(0x10068UL + ((_i) * 0x40000UL))
+#define NPS_PKT_IN_INSTR_RSIZEX(_i)	(0x10070UL + ((_i) * 0x40000UL))
+#define NPS_PKT_IN_DONE_CNTSX(_i)	(0x10080UL + ((_i) * 0x40000UL))
+#define NPS_PKT_IN_INSTR_BAOFF_DBELLX(_i)	(0x10078UL + ((_i) * 0x40000UL))
+#define NPS_PKT_IN_INT_LEVELSX(_i)		(0x10088UL + ((_i) * 0x40000UL))
+#define NPS_PKT_SLC_CTLX(_i)		(0x10000UL + ((_i) * 0x40000UL))
+#define NPS_PKT_SLC_CNTSX(_i)		(0x10008UL + ((_i) * 0x40000UL))
+#define NPS_PKT_SLC_INT_LEVELSX(_i)	(0x10010UL + ((_i) * 0x40000UL))
 
 /* AQM Virtual Function Registers */
-#define AQMQ_QSZX(_i)			(0x20008 + ((_i)*0x40000))
+#define AQMQ_QSZX(_i)			(0x20008UL + ((_i) * 0x40000UL))
 
 static inline uint64_t
 nitrox_read_csr(uint8_t *bar_addr, uint64_t offset)
diff --git a/dpdk/drivers/crypto/nitrox/nitrox_sym.c b/dpdk/drivers/crypto/nitrox/nitrox_sym.c
index 56410c44d7..d1b32fec92 100644
--- a/dpdk/drivers/crypto/nitrox/nitrox_sym.c
+++ b/dpdk/drivers/crypto/nitrox/nitrox_sym.c
@@ -683,7 +683,8 @@ nitrox_sym_pmd_create(struct nitrox_device *ndev)
 	struct rte_cryptodev *cdev;
 
 	rte_pci_device_name(&ndev->pdev->addr, name, sizeof(name));
-	snprintf(name + strlen(name), RTE_CRYPTODEV_NAME_MAX_LEN, "_n5sym");
+	snprintf(name + strlen(name), RTE_CRYPTODEV_NAME_MAX_LEN - strlen(name),
+		 "_n5sym");
 	ndev->rte_sym_dev.driver = &nitrox_rte_sym_drv;
 	ndev->rte_sym_dev.numa_node = ndev->pdev->device.numa_node;
 	ndev->rte_sym_dev.devargs = NULL;
diff --git a/dpdk/drivers/crypto/octeontx/otx_cryptodev_ops.c b/dpdk/drivers/crypto/octeontx/otx_cryptodev_ops.c
index ba56b212b9..4eadb773ef 100644
--- a/dpdk/drivers/crypto/octeontx/otx_cryptodev_ops.c
+++ b/dpdk/drivers/crypto/octeontx/otx_cryptodev_ops.c
@@ -905,6 +905,7 @@ otx_cpt_dev_create(struct rte_cryptodev *c_dev)
 				RTE_CRYPTODEV_FF_HW_ACCELERATED |
 				RTE_CRYPTODEV_FF_SYM_OPERATION_CHAINING |
 				RTE_CRYPTODEV_FF_IN_PLACE_SGL |
+				RTE_CRYPTODEV_FF_OOP_LB_IN_LB_OUT |
 				RTE_CRYPTODEV_FF_OOP_SGL_IN_LB_OUT |
 				RTE_CRYPTODEV_FF_OOP_SGL_IN_SGL_OUT;
 		break;
diff --git a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.c b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.c
index 7fd216bb39..8523817847 100644
--- a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.c
+++ b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.c
@@ -24,6 +24,8 @@
 
 int otx2_cpt_logtype;
 
+uint8_t otx2_cryptodev_driver_id;
+
 static struct rte_pci_id pci_id_cpt_table[] = {
 	{
 		RTE_PCI_DEVICE(PCI_VENDOR_ID_CAVIUM,
@@ -68,45 +70,53 @@ otx2_cpt_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
 
 	otx2_dev = &vf->otx2_dev;
 
-	/* Initialize the base otx2_dev object */
-	ret = otx2_dev_init(pci_dev, otx2_dev);
-	if (ret) {
-		CPT_LOG_ERR("Could not initialize otx2_dev");
-		goto pmd_destroy;
-	}
-
-	/* Get number of queues available on the device */
-	ret = otx2_cpt_available_queues_get(dev, &nb_queues);
-	if (ret) {
-		CPT_LOG_ERR("Could not determine the number of queues available");
-		goto otx2_dev_fini;
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
+		/* Initialize the base otx2_dev object */
+		ret = otx2_dev_init(pci_dev, otx2_dev);
+		if (ret) {
+			CPT_LOG_ERR("Could not initialize otx2_dev");
+			goto pmd_destroy;
+		}
+
+		/* Get number of queues available on the device */
+		ret = otx2_cpt_available_queues_get(dev, &nb_queues);
+		if (ret) {
+			CPT_LOG_ERR("Could not determine the number of queues available");
+			goto otx2_dev_fini;
+		}
+
+		/* Don't exceed the limits set per VF */
+		nb_queues = RTE_MIN(nb_queues, OTX2_CPT_MAX_QUEUES_PER_VF);
+
+		if (nb_queues == 0) {
+			CPT_LOG_ERR("No free queues available on the device");
+			goto otx2_dev_fini;
+		}
+
+		vf->max_queues = nb_queues;
+
+		CPT_LOG_INFO("Max queues supported by device: %d",
+				vf->max_queues);
 	}
 
-	/* Don't exceed the limits set per VF */
-	nb_queues = RTE_MIN(nb_queues, OTX2_CPT_MAX_QUEUES_PER_VF);
-
-	if (nb_queues == 0) {
-		CPT_LOG_ERR("No free queues available on the device");
-		goto otx2_dev_fini;
-	}
-
-	vf->max_queues = nb_queues;
-
-	CPT_LOG_INFO("Max queues supported by device: %d", vf->max_queues);
-
 	dev->feature_flags = RTE_CRYPTODEV_FF_SYMMETRIC_CRYPTO |
 			     RTE_CRYPTODEV_FF_HW_ACCELERATED |
 			     RTE_CRYPTODEV_FF_SYM_OPERATION_CHAINING |
 			     RTE_CRYPTODEV_FF_IN_PLACE_SGL |
+			     RTE_CRYPTODEV_FF_OOP_LB_IN_LB_OUT |
 			     RTE_CRYPTODEV_FF_OOP_SGL_IN_LB_OUT |
 			     RTE_CRYPTODEV_FF_OOP_SGL_IN_SGL_OUT |
 			     RTE_CRYPTODEV_FF_ASYMMETRIC_CRYPTO |
 			     RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_QT;
 
+	if (rte_eal_process_type() == RTE_PROC_SECONDARY)
+		otx2_cpt_set_enqdeq_fns(dev);
+
 	return 0;
 
 otx2_dev_fini:
-	otx2_dev_fini(pci_dev, otx2_dev);
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY)
+		otx2_dev_fini(pci_dev, otx2_dev);
 pmd_destroy:
 	rte_cryptodev_pmd_destroy(dev);
 exit:
@@ -145,6 +155,7 @@ static struct cryptodev_driver otx2_cryptodev_drv;
 RTE_INIT(otx2_cpt_init_log);
 RTE_PMD_REGISTER_PCI(CRYPTODEV_NAME_OCTEONTX2_PMD, otx2_cryptodev_pmd);
 RTE_PMD_REGISTER_PCI_TABLE(CRYPTODEV_NAME_OCTEONTX2_PMD, pci_id_cpt_table);
+RTE_PMD_REGISTER_KMOD_DEP(CRYPTODEV_NAME_OCTEONTX2_PMD, "vfio-pci");
 RTE_PMD_REGISTER_CRYPTO_DRIVER(otx2_cryptodev_drv, otx2_cryptodev_pmd.driver,
 		otx2_cryptodev_driver_id);
 
diff --git a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.h b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.h
index 8e0ebc292a..17c0bee661 100644
--- a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.h
+++ b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev.h
@@ -38,6 +38,8 @@ extern int otx2_cpt_logtype;
 /*
  * Crypto device driver ID
  */
-uint8_t otx2_cryptodev_driver_id;
+extern uint8_t otx2_cryptodev_driver_id;
+
+void otx2_cpt_set_enqdeq_fns(struct rte_cryptodev *dev);
 
 #endif /* _OTX2_CRYPTODEV_H_ */
diff --git a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.c b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.c
index 65101b0d2f..292aff1928 100644
--- a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.c
+++ b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.c
@@ -518,8 +518,8 @@ otx2_cpt_enqueue_sym_sessless(struct otx2_cpt_qp *qp, struct rte_crypto_op *op,
 	int ret;
 
 	/* Create temporary session */
-
-	if (rte_mempool_get(qp->sess_mp, (void **)&sess))
+	sess = rte_cryptodev_sym_session_create(qp->sess_mp);
+	if (sess == NULL)
 		return -ENOMEM;
 
 	ret = sym_session_configure(driver_id, sym_op->xform, sess,
@@ -671,6 +671,8 @@ static inline void
 otx2_cpt_dequeue_post_process(struct otx2_cpt_qp *qp, struct rte_crypto_op *cop,
 			      uintptr_t *rsp, uint8_t cc)
 {
+	unsigned int sz;
+
 	if (cop->type == RTE_CRYPTO_OP_TYPE_SYMMETRIC) {
 		if (likely(cc == NO_ERR)) {
 			/* Verify authentication data if required */
@@ -689,6 +691,9 @@ otx2_cpt_dequeue_post_process(struct otx2_cpt_qp *qp, struct rte_crypto_op *cop,
 		if (unlikely(cop->sess_type == RTE_CRYPTO_OP_SESSIONLESS)) {
 			sym_session_clear(otx2_cryptodev_driver_id,
 					  cop->sym->session);
+			sz = rte_cryptodev_sym_get_existing_header_session_size(
+					cop->sym->session);
+			memset(cop->sym->session, 0, sz);
 			rte_mempool_put(qp->sess_mp, cop->sym->session);
 			cop->sym->session = NULL;
 		}
@@ -808,6 +813,15 @@ otx2_cpt_dequeue_burst(void *qptr, struct rte_crypto_op **ops, uint16_t nb_ops)
 	return nb_completed;
 }
 
+void
+otx2_cpt_set_enqdeq_fns(struct rte_cryptodev *dev)
+{
+	dev->enqueue_burst = otx2_cpt_enqueue_burst;
+	dev->dequeue_burst = otx2_cpt_dequeue_burst;
+
+	rte_mb();
+}
+
 /* PMD ops */
 
 static int
@@ -857,10 +871,8 @@ otx2_cpt_dev_config(struct rte_cryptodev *dev,
 		goto queues_detach;
 	}
 
-	dev->enqueue_burst = otx2_cpt_enqueue_burst;
-	dev->dequeue_burst = otx2_cpt_dequeue_burst;
+	otx2_cpt_set_enqdeq_fns(dev);
 
-	rte_mb();
 	return 0;
 
 queues_detach:
diff --git a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.h b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.h
index a2724f7227..f83e36b486 100644
--- a/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.h
+++ b/dpdk/drivers/crypto/octeontx2/otx2_cryptodev_ops.h
@@ -16,6 +16,6 @@ enum otx2_cpt_egrp {
 	OTX2_CPT_EGRP_AE = 2
 };
 
-struct rte_cryptodev_ops otx2_cpt_ops;
+extern struct rte_cryptodev_ops otx2_cpt_ops;
 
 #endif /* _OTX2_CRYPTODEV_OPS_H_ */
diff --git a/dpdk/drivers/crypto/openssl/meson.build b/dpdk/drivers/crypto/openssl/meson.build
index 394e74c9eb..cd05f1dbaf 100644
--- a/dpdk/drivers/crypto/openssl/meson.build
+++ b/dpdk/drivers/crypto/openssl/meson.build
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-dep = dependency('libcrypto', required: false)
+dep = dependency('libcrypto', required: false, method: 'pkg-config')
 if not dep.found()
 	build = false
 	reason = 'missing dependency, "libcrypto"'
diff --git a/dpdk/drivers/crypto/openssl/openssl_pmd_private.h b/dpdk/drivers/crypto/openssl/openssl_pmd_private.h
index 43ac3813df..b2054b3754 100644
--- a/dpdk/drivers/crypto/openssl/openssl_pmd_private.h
+++ b/dpdk/drivers/crypto/openssl/openssl_pmd_private.h
@@ -16,7 +16,7 @@
 /**< Open SSL Crypto PMD device name */
 
 /** OPENSSL PMD LOGTYPE DRIVER */
-int openssl_logtype_driver;
+extern int openssl_logtype_driver;
 #define OPENSSL_LOG(level, fmt, ...)  \
 	rte_log(RTE_LOG_ ## level, openssl_logtype_driver,  \
 			"%s() line %u: " fmt "\n", __func__, __LINE__,  \
diff --git a/dpdk/drivers/crypto/openssl/rte_openssl_pmd.c b/dpdk/drivers/crypto/openssl/rte_openssl_pmd.c
index 91f028308c..c294f60b7d 100644
--- a/dpdk/drivers/crypto/openssl/rte_openssl_pmd.c
+++ b/dpdk/drivers/crypto/openssl/rte_openssl_pmd.c
@@ -18,6 +18,7 @@
 
 #define DES_BLOCK_SIZE 8
 
+int openssl_logtype_driver;
 static uint8_t cryptodev_driver_id;
 
 #if (OPENSSL_VERSION_NUMBER < 0x10100000L)
@@ -762,10 +763,10 @@ get_session(struct openssl_qp *qp, struct rte_crypto_op *op)
 			return NULL;
 
 		/* provide internal session */
-		void *_sess = NULL;
+		void *_sess = rte_cryptodev_sym_session_create(qp->sess_mp);
 		void *_sess_private_data = NULL;
 
-		if (rte_mempool_get(qp->sess_mp, (void **)&_sess))
+		if (_sess == NULL)
 			return NULL;
 
 		if (rte_mempool_get(qp->sess_mp_priv,
@@ -2037,6 +2038,26 @@ process_asym_op(struct openssl_qp *qp, struct rte_crypto_op *op,
 	return retval;
 }
 
+static void
+copy_plaintext(struct rte_mbuf *m_src, struct rte_mbuf *m_dst,
+		struct rte_crypto_op *op)
+{
+	uint8_t *p_src, *p_dst;
+
+	p_src = rte_pktmbuf_mtod(m_src, uint8_t *);
+	p_dst = rte_pktmbuf_mtod(m_dst, uint8_t *);
+
+	/**
+	 * Copy the content between cipher offset and auth offset
+	 * for generating correct digest.
+	 */
+	if (op->sym->cipher.data.offset > op->sym->auth.data.offset)
+		memcpy(p_dst + op->sym->auth.data.offset,
+				p_src + op->sym->auth.data.offset,
+				op->sym->cipher.data.offset -
+				op->sym->auth.data.offset);
+}
+
 /** Process crypto operation for mbuf */
 static int
 process_op(struct openssl_qp *qp, struct rte_crypto_op *op,
@@ -2059,6 +2080,9 @@ process_op(struct openssl_qp *qp, struct rte_crypto_op *op,
 		break;
 	case OPENSSL_CHAIN_CIPHER_AUTH:
 		process_openssl_cipher_op(op, sess, msrc, mdst);
+		/* OOP */
+		if (msrc != mdst)
+			copy_plaintext(msrc, mdst, op);
 		process_openssl_auth_op(qp, op, sess, mdst, mdst);
Louis Abel's avatar
Louis Abel committed
20201 20202 20203 20204 20205 20206 20207 20208 20209 20210 20211 20212 20213 20214 20215 20216 20217 20218 20219 20220 20221 20222 20223 20224 20225 20226 20227 20228 20229 20230 20231 20232 20233 20234 20235 20236 20237 20238 20239 20240 20241 20242 20243 20244 20245 20246 20247 20248 20249 20250 20251 20252 20253 20254 20255 20256 20257 20258 20259 20260 20261 20262 20263 20264 20265 20266 20267 20268 20269 20270 20271 20272 20273 20274 20275 20276 20277 20278 20279 20280 20281 20282 20283 20284 20285 20286 20287 20288 20289 20290 20291 20292 20293 20294 20295 20296 20297 20298 20299 20300 20301 20302 20303 20304 20305 20306 20307 20308 20309 20310 20311 20312 20313 20314 20315 20316 20317 20318 20319 20320 20321 20322 20323 20324 20325 20326 20327 20328 20329 20330 20331 20332 20333 20334 20335 20336 20337 20338 20339 20340 20341 20342 20343 20344 20345 20346 20347 20348 20349 20350 20351 20352 20353 20354 20355 20356 20357 20358 20359 20360 20361 20362 20363 20364 20365 20366 20367 20368 20369 20370 20371 20372 20373 20374 20375 20376 20377 20378 20379 20380 20381 20382 20383 20384 20385 20386 20387 20388 20389 20390 20391 20392 20393 20394 20395 20396 20397 20398 20399 20400 20401 20402 20403 20404 20405 20406 20407 20408 20409 20410 20411 20412 20413 20414 20415 20416 20417 20418 20419 20420 20421 20422 20423 20424 20425 20426 20427 20428 20429 20430 20431 20432 20433 20434 20435 20436 20437 20438 20439 20440 20441 20442 20443 20444 20445 20446 20447 20448 20449 20450 20451 20452 20453 20454 20455 20456 20457 20458 20459 20460 20461 20462 20463 20464 20465 20466 20467 20468 20469 20470 20471 20472 20473 20474 20475 20476 20477 20478 20479 20480 20481 20482 20483 20484 20485 20486 20487 20488 20489 20490 20491 20492 20493 20494 20495 20496 20497 20498 20499 20500 20501 20502 20503 20504 20505 20506 20507 20508 20509 20510 20511 20512 20513 20514 20515 20516 20517 20518 20519 20520 20521 20522 20523 20524 20525 20526 20527 20528 20529 20530 20531 20532 20533 20534 20535 20536 20537 20538 20539 20540 20541 20542 20543 20544 20545 20546 20547 20548 20549 20550 20551 20552 20553 20554 20555 20556 20557 20558 20559 20560 20561 20562 20563 20564 20565 20566 20567 20568 20569 20570 20571 20572 20573 20574 20575 20576 20577 20578 20579 20580 20581 20582 20583 20584 20585 20586 20587 20588 20589 20590 20591 20592 20593 20594 20595 20596 20597 20598 20599 20600 20601 20602 20603 20604 20605 20606 20607 20608 20609 20610 20611 20612 20613 20614 20615 20616 20617 20618 20619 20620 20621 20622 20623 20624 20625 20626 20627 20628 20629 20630 20631 20632 20633 20634 20635 20636 20637 20638 20639 20640 20641 20642 20643 20644 20645 20646 20647 20648 20649 20650 20651 20652 20653 20654 20655 20656 20657 20658 20659 20660 20661 20662 20663 20664 20665 20666 20667 20668 20669 20670 20671 20672 20673 20674 20675 20676 20677 20678 20679 20680 20681 20682 20683 20684 20685 20686 20687 20688 20689 20690 20691 20692 20693 20694 20695 20696 20697 20698 20699 20700 20701 20702 20703 20704 20705 20706 20707 20708 20709 20710 20711 20712 20713 20714 20715 20716 20717 20718 20719 20720 20721 20722 20723 20724 20725 20726 20727 20728 20729 20730 20731 20732 20733 20734 20735 20736 20737 20738 20739 20740 20741 20742 20743 20744 20745 20746 20747 20748 20749 20750 20751 20752 20753 20754 20755 20756 20757 20758 20759 20760 20761 20762 20763 20764 20765 20766 20767 20768 20769 20770 20771 20772 20773 20774 20775 20776 20777 20778 20779 20780 20781 20782 20783 20784 20785 20786 20787 20788 20789 20790 20791 20792 20793 20794 20795 20796 20797 20798 20799 20800 20801 20802 20803 20804 20805 20806 20807 20808 20809 20810 20811 20812 20813 20814 20815 20816 20817 20818 20819 20820 20821 20822 20823 20824 20825 20826 20827 20828 20829 20830 20831 20832 20833 20834 20835 20836 20837 20838 20839 20840 20841 20842 20843 20844 20845 20846 20847 20848 20849 20850 20851 20852 20853 20854 20855 20856 20857 20858 20859 20860 20861 20862 20863 20864 20865 20866 20867 20868 20869 20870 20871 20872 20873 20874 20875 20876 20877 20878 20879 20880 20881 20882 20883 20884 20885 20886 20887 20888 20889 20890 20891 20892 20893 20894 20895 20896 20897 20898 20899 20900 20901 20902 20903 20904 20905 20906 20907 20908 20909 20910 20911 20912 20913 20914 20915 20916 20917 20918 20919 20920 20921 20922 20923 20924 20925 20926 20927 20928 20929 20930 20931 20932 20933 20934 20935 20936 20937 20938 20939 20940 20941 20942 20943 20944 20945 20946 20947 20948 20949 20950 20951 20952 20953 20954 20955 20956 20957 20958 20959 20960 20961 20962 20963 20964 20965 20966 20967 20968 20969 20970 20971 20972 20973 20974 20975 20976 20977 20978 20979 20980 20981 20982 20983 20984 20985 20986 20987 20988 20989 20990 20991 20992 20993 20994 20995 20996 20997 20998 20999 21000 21001 21002 21003 21004 21005 21006 21007 21008 21009 21010 21011 21012 21013 21014 21015 21016 21017 21018 21019 21020 21021 21022 21023 21024 21025 21026 21027 21028 21029 21030 21031 21032 21033 21034 21035 21036 21037 21038 21039 21040 21041 21042 21043 21044 21045 21046 21047 21048 21049 21050 21051 21052 21053 21054 21055 21056 21057 21058 21059 21060 21061 21062 21063 21064 21065 21066 21067 21068 21069 21070 21071 21072 21073 21074 21075 21076 21077 21078 21079 21080 21081 21082 21083 21084 21085 21086 21087 21088 21089 21090 21091 21092 21093 21094 21095 21096 21097 21098 21099 21100 21101 21102 21103 21104 21105 21106 21107 21108 21109 21110 21111 21112 21113 21114 21115 21116 21117 21118 21119 21120 21121 21122 21123 21124 21125 21126 21127 21128 21129 21130 21131 21132 21133 21134 21135 21136 21137 21138 21139 21140 21141 21142 21143 21144 21145 21146 21147 21148 21149 21150 21151 21152 21153 21154 21155 21156 21157 21158 21159 21160 21161 21162 21163 21164 21165 21166 21167 21168 21169 21170 21171 21172 21173 21174 21175 21176 21177 21178 21179 21180 21181 21182 21183 21184 21185 21186 21187 21188 21189 21190 21191 21192 21193 21194 21195 21196 21197 21198 21199 21200 21201 21202 21203 21204 21205 21206 21207 21208 21209 21210 21211 21212 21213 21214 21215 21216 21217 21218 21219 21220 21221 21222 21223 21224 21225 21226 21227 21228 21229 21230 21231 21232 21233 21234 21235 21236 21237 21238 21239 21240 21241 21242 21243 21244 21245 21246 21247 21248 21249 21250 21251 21252 21253 21254 21255 21256 21257 21258 21259 21260 21261 21262 21263 21264 21265 21266 21267 21268 21269 21270 21271 21272 21273 21274 21275 21276 21277 21278 21279 21280 21281 21282 21283 21284 21285 21286 21287 21288 21289 21290 21291 21292 21293 21294 21295 21296 21297 21298 21299 21300 21301 21302 21303 21304 21305 21306 21307 21308 21309 21310 21311 21312 21313 21314 21315 21316 21317 21318 21319 21320 21321 21322 21323 21324 21325 21326 21327 21328 21329 21330 21331 21332 21333 21334 21335 21336 21337 21338 21339 21340 21341 21342 21343 21344 21345 21346 21347 21348 21349 21350 21351 21352 21353 21354 21355 21356 21357 21358 21359 21360 21361 21362 21363 21364 21365 21366 21367 21368 21369 21370 21371 21372 21373 21374 21375 21376 21377 21378 21379 21380 21381 21382 21383 21384 21385 21386 21387 21388 21389 21390 21391 21392 21393 21394 21395 21396 21397 21398 21399 21400 21401 21402 21403 21404 21405 21406 21407 21408 21409 21410 21411 21412 21413 21414 21415 21416 21417 21418 21419 21420 21421 21422 21423 21424 21425 21426 21427 21428 21429 21430 21431 21432 21433 21434 21435 21436 21437 21438 21439 21440 21441 21442 21443 21444 21445 21446 21447 21448 21449 21450 21451 21452 21453 21454 21455 21456 21457 21458 21459 21460 21461 21462 21463 21464 21465 21466 21467 21468 21469 21470 21471 21472 21473 21474 21475 21476 21477 21478 21479 21480 21481 21482 21483 21484 21485 21486 21487 21488 21489 21490 21491 21492 21493 21494 21495 21496 21497 21498 21499 21500 21501 21502 21503 21504 21505 21506 21507 21508 21509 21510 21511 21512 21513 21514 21515 21516 21517 21518 21519 21520 21521 21522 21523 21524 21525 21526 21527 21528 21529 21530 21531 21532 21533 21534 21535 21536 21537 21538 21539 21540 21541 21542 21543 21544 21545 21546 21547 21548 21549 21550 21551 21552 21553 21554 21555 21556 21557 21558 21559 21560 21561 21562 21563 21564 21565 21566 21567 21568 21569 21570 21571 21572 21573 21574 21575 21576 21577 21578 21579 21580 21581 21582 21583 21584 21585 21586 21587 21588 21589 21590 21591 21592 21593 21594 21595 21596 21597 21598 21599 21600 21601 21602 21603 21604 21605 21606 21607 21608 21609 21610 21611 21612 21613 21614 21615 21616 21617 21618 21619 21620 21621 21622 21623 21624 21625 21626 21627 21628 21629 21630 21631 21632 21633 21634 21635 21636 21637 21638 21639 21640 21641 21642 21643 21644 21645 21646 21647 21648 21649 21650 21651 21652 21653 21654 21655 21656 21657 21658 21659 21660 21661 21662 21663 21664 21665 21666 21667 21668 21669 21670 21671 21672 21673 21674 21675 21676 21677 21678 21679 21680 21681 21682 21683 21684 21685 21686 21687 21688 21689 21690 21691 21692 21693 21694 21695 21696 21697 21698 21699 21700 21701 21702 21703 21704 21705 21706 21707 21708 21709 21710 21711 21712 21713 21714 21715 21716 21717 21718 21719 21720 21721 21722 21723 21724 21725 21726 21727 21728 21729 21730 21731 21732 21733 21734 21735 21736 21737 21738 21739 21740 21741 21742 21743 21744 21745 21746 21747 21748 21749 21750 21751 21752 21753 21754 21755 21756 21757 21758 21759 21760 21761 21762 21763 21764 21765 21766 21767 21768 21769 21770 21771 21772 21773 21774 21775 21776 21777 21778 21779 21780 21781 21782 21783 21784 21785 21786 21787 21788 21789 21790 21791 21792 21793 21794 21795 21796 21797 21798 21799 21800 21801 21802 21803 21804 21805 21806 21807 21808 21809 21810 21811 21812 21813 21814 21815 21816 21817 21818 21819 21820 21821 21822 21823 21824 21825 21826 21827 21828 21829 21830 21831 21832 21833 21834 21835 21836 21837 21838 21839 21840 21841 21842 21843 21844 21845 21846 21847 21848 21849 21850 21851 21852 21853 21854 21855 21856 21857 21858 21859 21860 21861 21862 21863 21864 21865 21866 21867 21868 21869 21870 21871 21872 21873 21874 21875 21876 21877 21878 21879 21880 21881 21882 21883 21884 21885 21886 21887 21888 21889 21890 21891 21892 21893 21894 21895 21896 21897 21898 21899 21900 21901 21902 21903 21904 21905 21906 21907 21908 21909 21910 21911 21912 21913 21914 21915 21916 21917 21918 21919 21920 21921 21922 21923 21924 21925 21926 21927 21928 21929 21930 21931 21932 21933 21934 21935 21936 21937 21938 21939 21940 21941 21942 21943 21944 21945 21946 21947 21948 21949 21950 21951 21952 21953 21954 21955 21956 21957 21958 21959 21960 21961 21962 21963 21964 21965 21966 21967 21968 21969 21970 21971 21972 21973 21974 21975 21976 21977 21978 21979 21980 21981 21982 21983 21984 21985 21986 21987 21988 21989 21990 21991 21992 21993 21994 21995 21996 21997 21998 21999 22000 22001 22002 22003 22004 22005 22006 22007 22008 22009 22010 22011 22012 22013 22014 22015 22016 22017 22018 22019 22020 22021 22022 22023 22024 22025 22026 22027 22028 22029 22030 22031 22032 22033 22034 22035 22036 22037 22038 22039 22040 22041 22042 22043 22044 22045 22046 22047 22048 22049 22050 22051 22052 22053 22054 22055 22056 22057 22058 22059 22060 22061 22062 22063 22064 22065 22066 22067 22068 22069 22070 22071 22072 22073 22074 22075 22076 22077 22078 22079 22080 22081 22082 22083 22084 22085 22086 22087 22088 22089 22090 22091 22092 22093 22094 22095 22096 22097 22098 22099 22100 22101 22102 22103 22104 22105 22106 22107 22108 22109 22110 22111 22112 22113 22114 22115 22116 22117 22118 22119 22120 22121 22122 22123 22124 22125 22126 22127 22128 22129 22130 22131 22132 22133 22134 22135 22136 22137 22138 22139 22140 22141 22142 22143 22144 22145 22146 22147 22148 22149 22150 22151 22152 22153 22154 22155 22156 22157 22158 22159 22160 22161 22162 22163 22164 22165 22166 22167 22168 22169 22170 22171 22172 22173 22174 22175 22176 22177 22178 22179 22180 22181 22182 22183 22184 22185 22186 22187 22188 22189 22190 22191 22192 22193 22194 22195 22196 22197 22198 22199 22200
 		break;
 	case OPENSSL_CHAIN_AUTH_CIPHER:
diff --git a/dpdk/drivers/crypto/qat/meson.build b/dpdk/drivers/crypto/qat/meson.build
index fc65923a76..8d1e25a845 100644
--- a/dpdk/drivers/crypto/qat/meson.build
+++ b/dpdk/drivers/crypto/qat/meson.build
@@ -5,7 +5,7 @@
 # driver which comes later. Here we just add our sources files to the list
 build = false
 reason = '' # sentinal value to suppress printout
-dep = dependency('libcrypto', required: false)
+dep = dependency('libcrypto', required: false, method: 'pkg-config')
 qat_includes += include_directories('.')
 qat_deps += 'cryptodev'
 if dep.found()
diff --git a/dpdk/drivers/crypto/qat/qat_asym.c b/dpdk/drivers/crypto/qat/qat_asym.c
index ae0dd79562..85973812a8 100644
--- a/dpdk/drivers/crypto/qat/qat_asym.c
+++ b/dpdk/drivers/crypto/qat/qat_asym.c
@@ -475,7 +475,7 @@ qat_asym_build_request(void *in_op,
 	if (op->sess_type == RTE_CRYPTO_OP_WITH_SESSION) {
 		ctx = (struct qat_asym_session *)
 			get_asym_session_private_data(
-			op->asym->session, cryptodev_qat_asym_driver_id);
+			op->asym->session, qat_asym_driver_id);
 		if (unlikely(ctx == NULL)) {
 			QAT_LOG(ERR, "Session has not been created for this device");
 			goto error;
@@ -693,7 +693,7 @@ qat_asym_process_response(void **op, uint8_t *resp,
 
 	if (rx_op->sess_type == RTE_CRYPTO_OP_WITH_SESSION) {
 		ctx = (struct qat_asym_session *)get_asym_session_private_data(
-			rx_op->asym->session, cryptodev_qat_asym_driver_id);
+			rx_op->asym->session, qat_asym_driver_id);
 		qat_asym_collect_response(rx_op, cookie, ctx->xform);
 	} else if (rx_op->sess_type == RTE_CRYPTO_OP_SESSIONLESS) {
 		qat_asym_collect_response(rx_op, cookie, rx_op->asym->xform);
diff --git a/dpdk/drivers/crypto/qat/qat_asym_pmd.c b/dpdk/drivers/crypto/qat/qat_asym_pmd.c
index c8a52b669b..2b69b8ecf9 100644
--- a/dpdk/drivers/crypto/qat/qat_asym_pmd.c
+++ b/dpdk/drivers/crypto/qat/qat_asym_pmd.c
@@ -11,7 +11,7 @@
 #include "qat_sym_capabilities.h"
 #include "qat_asym_capabilities.h"
 
-uint8_t cryptodev_qat_asym_driver_id;
+uint8_t qat_asym_driver_id;
 
 static const struct rte_cryptodev_capabilities qat_gen1_asym_capabilities[] = {
 	QAT_BASE_GEN1_ASYM_CAPABILITIES,
@@ -63,7 +63,7 @@ static void qat_asym_dev_info_get(struct rte_cryptodev *dev,
 							QAT_SERVICE_ASYMMETRIC);
 		info->feature_flags = dev->feature_flags;
 		info->capabilities = internals->qat_dev_capabilities;
-		info->driver_id = cryptodev_qat_asym_driver_id;
+		info->driver_id = qat_asym_driver_id;
 		/* No limit of number of sessions */
 		info->sym.max_nb_sessions = 0;
 	}
@@ -160,6 +160,7 @@ static int qat_asym_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
 							= *qp_addr;
 
 	qp = (struct qat_qp *)*qp_addr;
+	qp->min_enq_burst_threshold = qat_private->min_enq_burst_threshold;
 
 	for (i = 0; i < qp->nb_descriptors; i++) {
 		int j;
@@ -235,35 +236,55 @@ static const struct rte_driver cryptodev_qat_asym_driver = {
 };
 
 int
-qat_asym_dev_create(struct qat_pci_device *qat_pci_dev)
+qat_asym_dev_create(struct qat_pci_device *qat_pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param)
 {
+	int i = 0;
+	struct qat_device_info *qat_dev_instance =
+			&qat_pci_devs[qat_pci_dev->qat_dev_id];
+
 	struct rte_cryptodev_pmd_init_params init_params = {
 			.name = "",
-			.socket_id = qat_pci_dev->pci_dev->device.numa_node,
+			.socket_id =
+				qat_dev_instance->pci_dev->device.numa_node,
 			.private_data_size = sizeof(struct qat_asym_dev_private)
 	};
 	char name[RTE_CRYPTODEV_NAME_MAX_LEN];
+	char capa_memz_name[RTE_CRYPTODEV_NAME_MAX_LEN];
 	struct rte_cryptodev *cryptodev;
 	struct qat_asym_dev_private *internals;
 
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
+		qat_pci_dev->qat_asym_driver_id =
+				qat_asym_driver_id;
+	} else if (rte_eal_process_type() == RTE_PROC_SECONDARY) {
+		if (qat_pci_dev->qat_asym_driver_id !=
+				qat_asym_driver_id) {
+			QAT_LOG(ERR,
+				"Device %s have different driver id than corresponding device in primary process",
+				name);
+			return -(EFAULT);
+		}
+	}
+
 	snprintf(name, RTE_CRYPTODEV_NAME_MAX_LEN, "%s_%s",
 			qat_pci_dev->name, "asym");
 	QAT_LOG(DEBUG, "Creating QAT ASYM device %s\n", name);
 
 	/* Populate subset device to use in cryptodev device creation */
-	qat_pci_dev->asym_rte_dev.driver = &cryptodev_qat_asym_driver;
-	qat_pci_dev->asym_rte_dev.numa_node =
-				qat_pci_dev->pci_dev->device.numa_node;
-	qat_pci_dev->asym_rte_dev.devargs = NULL;
+	qat_dev_instance->asym_rte_dev.driver = &cryptodev_qat_asym_driver;
+	qat_dev_instance->asym_rte_dev.numa_node =
+			qat_dev_instance->pci_dev->device.numa_node;
+	qat_dev_instance->asym_rte_dev.devargs = NULL;
 
 	cryptodev = rte_cryptodev_pmd_create(name,
-			&(qat_pci_dev->asym_rte_dev), &init_params);
+			&(qat_dev_instance->asym_rte_dev), &init_params);
 
 	if (cryptodev == NULL)
 		return -ENODEV;
 
-	qat_pci_dev->asym_rte_dev.name = cryptodev->data->name;
-	cryptodev->driver_id = cryptodev_qat_asym_driver_id;
+	qat_dev_instance->asym_rte_dev.name = cryptodev->data->name;
+	cryptodev->driver_id = qat_asym_driver_id;
 	cryptodev->dev_ops = &crypto_qat_ops;
 
 	cryptodev->enqueue_burst = qat_asym_pmd_enqueue_op_burst;
@@ -274,13 +295,49 @@ qat_asym_dev_create(struct qat_pci_device *qat_pci_dev)
 			RTE_CRYPTODEV_FF_ASYM_SESSIONLESS |
 			RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_EXP |
 			RTE_CRYPTODEV_FF_RSA_PRIV_OP_KEY_QT;
+
+	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
+		return 0;
+
+	snprintf(capa_memz_name, RTE_CRYPTODEV_NAME_MAX_LEN,
+			"QAT_ASYM_CAPA_GEN_%d",
+			qat_pci_dev->qat_dev_gen);
+
 	internals = cryptodev->data->dev_private;
 	internals->qat_dev = qat_pci_dev;
-	qat_pci_dev->asym_dev = internals;
-
 	internals->asym_dev_id = cryptodev->data->dev_id;
 	internals->qat_dev_capabilities = qat_gen1_asym_capabilities;
 
+	internals->capa_mz = rte_memzone_lookup(capa_memz_name);
+	if (internals->capa_mz == NULL) {
+		internals->capa_mz = rte_memzone_reserve(capa_memz_name,
+			sizeof(qat_gen1_asym_capabilities),
+			rte_socket_id(), 0);
+	}
+	if (internals->capa_mz == NULL) {
+		QAT_LOG(DEBUG,
+			"Error allocating memzone for capabilities, destroying PMD for %s",
+			name);
+		rte_cryptodev_pmd_destroy(cryptodev);
+		memset(&qat_dev_instance->asym_rte_dev, 0,
+			sizeof(qat_dev_instance->asym_rte_dev));
+		return -EFAULT;
+	}
+
+	memcpy(internals->capa_mz->addr, qat_gen1_asym_capabilities,
+			sizeof(qat_gen1_asym_capabilities));
+	internals->qat_dev_capabilities = internals->capa_mz->addr;
+
+	while (1) {
+		if (qat_dev_cmd_param[i].name == NULL)
+			break;
+		if (!strcmp(qat_dev_cmd_param[i].name, ASYM_ENQ_THRESHOLD_NAME))
+			internals->min_enq_burst_threshold =
+					qat_dev_cmd_param[i].val;
+		i++;
+	}
+
+	qat_pci_dev->asym_dev = internals;
 	QAT_LOG(DEBUG, "Created QAT ASYM device %s as cryptodev instance %d",
 			cryptodev->data->name, internals->asym_dev_id);
 	return 0;
@@ -295,12 +352,14 @@ qat_asym_dev_destroy(struct qat_pci_device *qat_pci_dev)
 		return -ENODEV;
 	if (qat_pci_dev->asym_dev == NULL)
 		return 0;
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY)
+		rte_memzone_free(qat_pci_dev->asym_dev->capa_mz);
 
 	/* free crypto device */
 	cryptodev = rte_cryptodev_pmd_get_dev(
 			qat_pci_dev->asym_dev->asym_dev_id);
 	rte_cryptodev_pmd_destroy(cryptodev);
-	qat_pci_dev->asym_rte_dev.name = NULL;
+	qat_pci_devs[qat_pci_dev->qat_dev_id].asym_rte_dev.name = NULL;
 	qat_pci_dev->asym_dev = NULL;
 
 	return 0;
@@ -309,4 +368,4 @@ qat_asym_dev_destroy(struct qat_pci_device *qat_pci_dev)
 static struct cryptodev_driver qat_crypto_drv;
 RTE_PMD_REGISTER_CRYPTO_DRIVER(qat_crypto_drv,
 		cryptodev_qat_asym_driver,
-		cryptodev_qat_asym_driver_id);
+		qat_asym_driver_id);
diff --git a/dpdk/drivers/crypto/qat/qat_asym_pmd.h b/dpdk/drivers/crypto/qat/qat_asym_pmd.h
index 895d0f6d6a..3b5abddec8 100644
--- a/dpdk/drivers/crypto/qat/qat_asym_pmd.h
+++ b/dpdk/drivers/crypto/qat/qat_asym_pmd.h
@@ -13,7 +13,7 @@
 #define CRYPTODEV_NAME_QAT_ASYM_PMD	crypto_qat_asym
 
 
-extern uint8_t cryptodev_qat_asym_driver_id;
+extern uint8_t qat_asym_driver_id;
 
 /** private data structure for a QAT device.
  * This QAT device is a device offering only asymmetric crypto service,
@@ -26,6 +26,9 @@ struct qat_asym_dev_private {
 	/**< Device instance for this rte_cryptodev */
 	const struct rte_cryptodev_capabilities *qat_dev_capabilities;
 	/* QAT device asymmetric crypto capabilities */
+	const struct rte_memzone *capa_mz;
+	/* Shared memzone for storing capabilities */
+	uint16_t min_enq_burst_threshold;
 };
 
 uint16_t
@@ -42,7 +45,8 @@ int qat_asym_session_configure(struct rte_cryptodev *dev,
 		struct rte_mempool *mempool);
 
 int
-qat_asym_dev_create(struct qat_pci_device *qat_pci_dev);
+qat_asym_dev_create(struct qat_pci_device *qat_pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
 qat_asym_dev_destroy(struct qat_pci_device *qat_pci_dev);
diff --git a/dpdk/drivers/crypto/qat/qat_sym.c b/dpdk/drivers/crypto/qat/qat_sym.c
index 5c9904cbf9..fda20ad26d 100644
--- a/dpdk/drivers/crypto/qat/qat_sym.c
+++ b/dpdk/drivers/crypto/qat/qat_sym.c
@@ -179,7 +179,7 @@ qat_sym_build_request(void *in_op, uint8_t *out_msg,
 	}
 
 	ctx = (struct qat_sym_session *)get_sym_session_private_data(
-			op->sym->session, cryptodev_qat_driver_id);
+				op->sym->session, qat_sym_driver_id);
 
 	if (unlikely(ctx == NULL)) {
 		QAT_DP_LOG(ERR, "Session was not created for this device");
diff --git a/dpdk/drivers/crypto/qat/qat_sym.h b/dpdk/drivers/crypto/qat/qat_sym.h
index bc6426c327..758b06d865 100644
--- a/dpdk/drivers/crypto/qat/qat_sym.h
+++ b/dpdk/drivers/crypto/qat/qat_sym.h
@@ -155,7 +155,7 @@ qat_sym_process_response(void **op, uint8_t *resp)
 		struct qat_sym_session *sess = (struct qat_sym_session *)
 						get_sym_session_private_data(
 						rx_op->sym->session,
-						cryptodev_qat_driver_id);
+						qat_sym_driver_id);
 
 
 		if (sess->bpi_ctx)
diff --git a/dpdk/drivers/crypto/qat/qat_sym_capabilities.h b/dpdk/drivers/crypto/qat/qat_sym_capabilities.h
index 028a56c568..8591795aa0 100644
--- a/dpdk/drivers/crypto/qat/qat_sym_capabilities.h
+++ b/dpdk/drivers/crypto/qat/qat_sym_capabilities.h
@@ -6,6 +6,111 @@
 #define _QAT_SYM_CAPABILITIES_H_
 
 #define QAT_BASE_GEN1_SYM_CAPABILITIES					\
+	{	/* SHA1 */						\
+		.op = RTE_CRYPTO_OP_TYPE_SYMMETRIC,			\
+		{.sym = {						\
+			.xform_type = RTE_CRYPTO_SYM_XFORM_AUTH,	\
+			{.auth = {					\
+				.algo = RTE_CRYPTO_AUTH_SHA1,		\
+				.block_size = 64,			\
+				.key_size = {				\
+					.min = 0,			\
+					.max = 0,			\
+					.increment = 0			\
+				},					\
+				.digest_size = {			\
+					.min = 1,			\
+					.max = 20,			\
+					.increment = 1			\
+				},					\
+				.iv_size = { 0 }			\
+			}, }						\
+		}, }							\
+	},								\
+	{	/* SHA224 */						\
+		.op = RTE_CRYPTO_OP_TYPE_SYMMETRIC,			\
+		{.sym = {						\
+			.xform_type = RTE_CRYPTO_SYM_XFORM_AUTH,	\
+			{.auth = {					\
+				.algo = RTE_CRYPTO_AUTH_SHA224,		\
+				.block_size = 64,			\
+				.key_size = {				\
+					.min = 0,			\
+					.max = 0,			\
+					.increment = 0			\
+				},					\
+				.digest_size = {			\
+					.min = 1,			\
+					.max = 28,			\
+					.increment = 1			\
+				},					\
+				.iv_size = { 0 }			\
+			}, }						\
+		}, }							\
+	},								\
+	{	/* SHA256 */						\
+		.op = RTE_CRYPTO_OP_TYPE_SYMMETRIC,			\
+		{.sym = {						\
+			.xform_type = RTE_CRYPTO_SYM_XFORM_AUTH,	\
+			{.auth = {					\
+				.algo = RTE_CRYPTO_AUTH_SHA256,		\
+				.block_size = 64,			\
+				.key_size = {				\
+					.min = 0,			\
+					.max = 0,			\
+					.increment = 0			\
+				},					\
+				.digest_size = {			\
+					.min = 1,			\
+					.max = 32,			\
+					.increment = 1			\
+				},					\
+				.iv_size = { 0 }			\
+			}, }						\
+		}, }							\
+	},								\
+	{	/* SHA384 */						\
+		.op = RTE_CRYPTO_OP_TYPE_SYMMETRIC,			\
+		{.sym = {						\
+			.xform_type = RTE_CRYPTO_SYM_XFORM_AUTH,	\
+			{.auth = {					\
+				.algo = RTE_CRYPTO_AUTH_SHA384,		\
+				.block_size = 128,			\
+				.key_size = {				\
+					.min = 0,			\
+					.max = 0,			\
+					.increment = 0			\
+				},					\
+				.digest_size = {			\
+					.min = 1,			\
+					.max = 48,			\
+					.increment = 1			\
+				},					\
+				.iv_size = { 0 }			\
+			}, }						\
+		}, }							\
+	},								\
+	{	/* SHA512 */						\
+		.op = RTE_CRYPTO_OP_TYPE_SYMMETRIC,			\
+		{.sym = {						\
+			.xform_type = RTE_CRYPTO_SYM_XFORM_AUTH,	\
+			{.auth = {					\
+				.algo = RTE_CRYPTO_AUTH_SHA512,		\
+				.block_size = 128,			\
+				.key_size = {				\
+					.min = 0,			\
+					.max = 0,			\
+					.increment = 0			\
+				},					\
+				.digest_size = {			\
+					.min = 1,			\
+					.max = 64,			\
+					.increment = 1			\
+				},					\
+				.iv_size = { 0 }			\
+			}, }						\
+		}, }							\
+	},								\
 	{	/* SHA1 HMAC */						\
 		.op = RTE_CRYPTO_OP_TYPE_SYMMETRIC,			\
 		{.sym = {						\
@@ -314,7 +419,7 @@
 				.key_size = {				\
 					.min = 32,			\
 					.max = 64,			\
-					.increment = 0			\
+					.increment = 32			\
 				},					\
 				.iv_size = {				\
 					.min = 16,			\
diff --git a/dpdk/drivers/crypto/qat/qat_sym_pmd.c b/dpdk/drivers/crypto/qat/qat_sym_pmd.c
index 71f21ceb25..31ed6a99aa 100644
--- a/dpdk/drivers/crypto/qat/qat_sym_pmd.c
+++ b/dpdk/drivers/crypto/qat/qat_sym_pmd.c
@@ -14,7 +14,9 @@
 #include "qat_sym_session.h"
 #include "qat_sym_pmd.h"
 
-uint8_t cryptodev_qat_driver_id;
+#define MIXED_CRYPTO_MIN_FW_VER 0x04090000
+
+uint8_t qat_sym_driver_id;
 
 static const struct rte_cryptodev_capabilities qat_gen1_sym_capabilities[] = {
 	QAT_BASE_GEN1_SYM_CAPABILITIES,
@@ -27,6 +29,12 @@ static const struct rte_cryptodev_capabilities qat_gen2_sym_capabilities[] = {
 	RTE_CRYPTODEV_END_OF_CAPABILITIES_LIST()
 };
 
+static const struct rte_cryptodev_capabilities qat_gen3_sym_capabilities[] = {
+	QAT_BASE_GEN1_SYM_CAPABILITIES,
+	QAT_EXTRA_GEN2_SYM_CAPABILITIES,
+	RTE_CRYPTODEV_END_OF_CAPABILITIES_LIST()
+};
+
 static int qat_sym_qp_release(struct rte_cryptodev *dev,
 	uint16_t queue_pair_id);
 
@@ -72,7 +80,7 @@ static void qat_sym_dev_info_get(struct rte_cryptodev *dev,
 			qat_qps_per_service(sym_hw_qps, QAT_SERVICE_SYMMETRIC);
 		info->feature_flags = dev->feature_flags;
 		info->capabilities = internals->qat_dev_capabilities;
-		info->driver_id = cryptodev_qat_driver_id;
+		info->driver_id = qat_sym_driver_id;
 		/* No limit of number of sessions */
 		info->sym.max_nb_sessions = 0;
 	}
@@ -169,6 +177,7 @@ static int qat_sym_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
 							= *qp_addr;
 
 	qp = (struct qat_qp *)*qp_addr;
+	qp->min_enq_burst_threshold = qat_private->min_enq_burst_threshold;
 
 	for (i = 0; i < qp->nb_descriptors; i++) {
 
@@ -186,6 +195,31 @@ static int qat_sym_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
 				qat_sgl_dst);
 	}
 
+	/* Get fw version from QAT (GEN2), skip if we've got it already */
+	if (qp->qat_dev_gen == QAT_GEN2 && !(qat_private->internal_capabilities
+			& QAT_SYM_CAP_VALID)) {
+		ret = qat_cq_get_fw_version(qp);
+
+		if (ret < 0) {
+			qat_sym_qp_release(dev, qp_id);
+			return ret;
+		}
+
+		if (ret != 0)
+			QAT_LOG(DEBUG, "QAT firmware version: %d.%d.%d",
+					(ret >> 24) & 0xff,
+					(ret >> 16) & 0xff,
+					(ret >> 8) & 0xff);
+		else
+			QAT_LOG(DEBUG, "unknown QAT firmware version");
+
+		/* set capabilities based on the fw version */
+		qat_private->internal_capabilities = QAT_SYM_CAP_VALID |
+				((ret >= MIXED_CRYPTO_MIN_FW_VER) ?
+						QAT_SYM_CAP_MIXED_CRYPTO : 0);
+		ret = 0;
+	}
+
 	return ret;
 }
 
@@ -237,35 +271,63 @@ static const struct rte_driver cryptodev_qat_sym_driver = {
 };
 
 int
-qat_sym_dev_create(struct qat_pci_device *qat_pci_dev)
+qat_sym_dev_create(struct qat_pci_device *qat_pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param __rte_unused)
 {
+	int i = 0;
+	struct qat_device_info *qat_dev_instance =
+			&qat_pci_devs[qat_pci_dev->qat_dev_id];
+
 	struct rte_cryptodev_pmd_init_params init_params = {
 			.name = "",
-			.socket_id = qat_pci_dev->pci_dev->device.numa_node,
+			.socket_id =
+				qat_dev_instance->pci_dev->device.numa_node,
 			.private_data_size = sizeof(struct qat_sym_dev_private)
 	};
 	char name[RTE_CRYPTODEV_NAME_MAX_LEN];
+	char capa_memz_name[RTE_CRYPTODEV_NAME_MAX_LEN];
 	struct rte_cryptodev *cryptodev;
 	struct qat_sym_dev_private *internals;
+	const struct rte_cryptodev_capabilities *capabilities;
+	uint64_t capa_size;
+
+	/*
+	 * All processes must use same driver id so they can share sessions.
+	 * Store driver_id so we can validate that all processes have the same
+	 * value, typically they have, but could differ if binaries built
+	 * separately.
+	 */
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
+		qat_pci_dev->qat_sym_driver_id =
+				qat_sym_driver_id;
+	} else if (rte_eal_process_type() == RTE_PROC_SECONDARY) {
+		if (qat_pci_dev->qat_sym_driver_id !=
+				qat_sym_driver_id) {
+			QAT_LOG(ERR,
+				"Device %s have different driver id than corresponding device in primary process",
+				name);
+			return -(EFAULT);
+		}
+	}
 
 	snprintf(name, RTE_CRYPTODEV_NAME_MAX_LEN, "%s_%s",
 			qat_pci_dev->name, "sym");
 	QAT_LOG(DEBUG, "Creating QAT SYM device %s", name);
 
 	/* Populate subset device to use in cryptodev device creation */
-	qat_pci_dev->sym_rte_dev.driver = &cryptodev_qat_sym_driver;
-	qat_pci_dev->sym_rte_dev.numa_node =
-				qat_pci_dev->pci_dev->device.numa_node;
-	qat_pci_dev->sym_rte_dev.devargs = NULL;
+	qat_dev_instance->sym_rte_dev.driver = &cryptodev_qat_sym_driver;
+	qat_dev_instance->sym_rte_dev.numa_node =
+			qat_dev_instance->pci_dev->device.numa_node;
+	qat_dev_instance->sym_rte_dev.devargs = NULL;
 
 	cryptodev = rte_cryptodev_pmd_create(name,
-			&(qat_pci_dev->sym_rte_dev), &init_params);
+			&(qat_dev_instance->sym_rte_dev), &init_params);
 
 	if (cryptodev == NULL)
 		return -ENODEV;
 
-	qat_pci_dev->sym_rte_dev.name = cryptodev->data->name;
-	cryptodev->driver_id = cryptodev_qat_driver_id;
+	qat_dev_instance->sym_rte_dev.name = cryptodev->data->name;
+	cryptodev->driver_id = qat_sym_driver_id;
 	cryptodev->dev_ops = &crypto_qat_ops;
 
 	cryptodev->enqueue_burst = qat_sym_pmd_enqueue_op_burst;
@@ -281,27 +343,68 @@ qat_sym_dev_create(struct qat_pci_device *qat_pci_dev)
 			RTE_CRYPTODEV_FF_OOP_LB_IN_LB_OUT |
 			RTE_CRYPTODEV_FF_DIGEST_ENCRYPTED;
 
+	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
+		return 0;
+
+	snprintf(capa_memz_name, RTE_CRYPTODEV_NAME_MAX_LEN,
+			"QAT_SYM_CAPA_GEN_%d",
+			qat_pci_dev->qat_dev_gen);
+
 	internals = cryptodev->data->dev_private;
 	internals->qat_dev = qat_pci_dev;
-	qat_pci_dev->sym_dev = internals;
 
 	internals->sym_dev_id = cryptodev->data->dev_id;
 	switch (qat_pci_dev->qat_dev_gen) {
 	case QAT_GEN1:
-		internals->qat_dev_capabilities = qat_gen1_sym_capabilities;
+		capabilities = qat_gen1_sym_capabilities;
+		capa_size = sizeof(qat_gen1_sym_capabilities);
 		break;
 	case QAT_GEN2:
+		capabilities = qat_gen2_sym_capabilities;
+		capa_size = sizeof(qat_gen2_sym_capabilities);
+		break;
 	case QAT_GEN3:
-		internals->qat_dev_capabilities = qat_gen2_sym_capabilities;
+		capabilities = qat_gen3_sym_capabilities;
+		capa_size = sizeof(qat_gen3_sym_capabilities);
 		break;
 	default:
-		internals->qat_dev_capabilities = qat_gen2_sym_capabilities;
 		QAT_LOG(DEBUG,
-			"QAT gen %d capabilities unknown, default to GEN2",
-					qat_pci_dev->qat_dev_gen);
-		break;
+			"QAT gen %d capabilities unknown",
+			qat_pci_dev->qat_dev_gen);
+		rte_cryptodev_pmd_destroy(cryptodev);
+		memset(&qat_dev_instance->sym_rte_dev, 0,
+			sizeof(qat_dev_instance->sym_rte_dev));
+		return -(EINVAL);
+	}
+	internals->capa_mz = rte_memzone_lookup(capa_memz_name);
+	if (internals->capa_mz == NULL) {
+	internals->capa_mz = rte_memzone_reserve(capa_memz_name,
+		capa_size,
+		rte_socket_id(), 0);
 	}
+	if (internals->capa_mz == NULL) {
+	QAT_LOG(DEBUG,
+		"Error allocating memzone for capabilities, destroying PMD for %s",
+		name);
+	rte_cryptodev_pmd_destroy(cryptodev);
+	memset(&qat_dev_instance->sym_rte_dev, 0,
+		sizeof(qat_dev_instance->sym_rte_dev));
+	return -EFAULT;
+	}
+
+	memcpy(internals->capa_mz->addr, capabilities, capa_size);
+	internals->qat_dev_capabilities = internals->capa_mz->addr;
 
+	while (1) {
+		if (qat_dev_cmd_param[i].name == NULL)
+			break;
+		if (!strcmp(qat_dev_cmd_param[i].name, SYM_ENQ_THRESHOLD_NAME))
+			internals->min_enq_burst_threshold =
+					qat_dev_cmd_param[i].val;
+		i++;
+	}
+
+	qat_pci_dev->sym_dev = internals;
 	QAT_LOG(DEBUG, "Created QAT SYM device %s as cryptodev instance %d",
 			cryptodev->data->name, internals->sym_dev_id);
 	return 0;
@@ -316,11 +419,13 @@ qat_sym_dev_destroy(struct qat_pci_device *qat_pci_dev)
 		return -ENODEV;
 	if (qat_pci_dev->sym_dev == NULL)
 		return 0;
+	if (rte_eal_process_type() == RTE_PROC_PRIMARY)
+		rte_memzone_free(qat_pci_dev->sym_dev->capa_mz);
 
 	/* free crypto device */
 	cryptodev = rte_cryptodev_pmd_get_dev(qat_pci_dev->sym_dev->sym_dev_id);
 	rte_cryptodev_pmd_destroy(cryptodev);
-	qat_pci_dev->sym_rte_dev.name = NULL;
+	qat_pci_devs[qat_pci_dev->qat_dev_id].sym_rte_dev.name = NULL;
 	qat_pci_dev->sym_dev = NULL;
 
 	return 0;
@@ -329,4 +434,4 @@ qat_sym_dev_destroy(struct qat_pci_device *qat_pci_dev)
 static struct cryptodev_driver qat_crypto_drv;
 RTE_PMD_REGISTER_CRYPTO_DRIVER(qat_crypto_drv,
 		cryptodev_qat_sym_driver,
-		cryptodev_qat_driver_id);
+		qat_sym_driver_id);
diff --git a/dpdk/drivers/crypto/qat/qat_sym_pmd.h b/dpdk/drivers/crypto/qat/qat_sym_pmd.h
index 7ddaf453e9..e2ed112cb1 100644
--- a/dpdk/drivers/crypto/qat/qat_sym_pmd.h
+++ b/dpdk/drivers/crypto/qat/qat_sym_pmd.h
@@ -15,7 +15,11 @@
 /** Intel(R) QAT Symmetric Crypto PMD driver name */
 #define CRYPTODEV_NAME_QAT_SYM_PMD	crypto_qat
 
-extern uint8_t cryptodev_qat_driver_id;
+/* Internal capabilities */
+#define QAT_SYM_CAP_MIXED_CRYPTO	(1 << 0)
+#define QAT_SYM_CAP_VALID		(1 << 31)
+
+extern uint8_t qat_sym_driver_id;
 
 /** private data structure for a QAT device.
  * This QAT device is a device offering only symmetric crypto service,
@@ -27,11 +31,16 @@ struct qat_sym_dev_private {
 	uint8_t sym_dev_id;
 	/**< Device instance for this rte_cryptodev */
 	const struct rte_cryptodev_capabilities *qat_dev_capabilities;
-	/* QAT device symmetric crypto capabilities */
+	/**< QAT device symmetric crypto capabilities */
+	uint32_t internal_capabilities; /* see flags QAT_SYM_CAP_xxx */
+	const struct rte_memzone *capa_mz;
+	/* Shared memzone for storing capabilities */
+	uint16_t min_enq_burst_threshold;
 };
 
 int
-qat_sym_dev_create(struct qat_pci_device *qat_pci_dev);
+qat_sym_dev_create(struct qat_pci_device *qat_pci_dev,
+		struct qat_dev_cmd_param *qat_dev_cmd_param);
 
 int
 qat_sym_dev_destroy(struct qat_pci_device *qat_pci_dev);
diff --git a/dpdk/drivers/crypto/qat/qat_sym_session.c b/dpdk/drivers/crypto/qat/qat_sym_session.c
index 72290ba480..8545be2791 100644
--- a/dpdk/drivers/crypto/qat/qat_sym_session.c
+++ b/dpdk/drivers/crypto/qat/qat_sym_session.c
@@ -19,6 +19,41 @@
 #include "qat_sym_session.h"
 #include "qat_sym_pmd.h"
 
+/* SHA1 - 20 bytes - Initialiser state can be found in FIPS stds 180-2 */
+static const uint8_t sha1InitialState[] = {
+	0x67, 0x45, 0x23, 0x01, 0xef, 0xcd, 0xab, 0x89, 0x98, 0xba,
+	0xdc, 0xfe, 0x10, 0x32, 0x54, 0x76, 0xc3, 0xd2, 0xe1, 0xf0};
+
+/* SHA 224 - 32 bytes - Initialiser state can be found in FIPS stds 180-2 */
+static const uint8_t sha224InitialState[] = {
+	0xc1, 0x05, 0x9e, 0xd8, 0x36, 0x7c, 0xd5, 0x07, 0x30, 0x70, 0xdd,
+	0x17, 0xf7, 0x0e, 0x59, 0x39, 0xff, 0xc0, 0x0b, 0x31, 0x68, 0x58,
+	0x15, 0x11, 0x64, 0xf9, 0x8f, 0xa7, 0xbe, 0xfa, 0x4f, 0xa4};
+
+/* SHA 256 - 32 bytes - Initialiser state can be found in FIPS stds 180-2 */
+static const uint8_t sha256InitialState[] = {
+	0x6a, 0x09, 0xe6, 0x67, 0xbb, 0x67, 0xae, 0x85, 0x3c, 0x6e, 0xf3,
+	0x72, 0xa5, 0x4f, 0xf5, 0x3a, 0x51, 0x0e, 0x52, 0x7f, 0x9b, 0x05,
+	0x68, 0x8c, 0x1f, 0x83, 0xd9, 0xab, 0x5b, 0xe0, 0xcd, 0x19};
+
+/* SHA 384 - 64 bytes - Initialiser state can be found in FIPS stds 180-2 */
+static const uint8_t sha384InitialState[] = {
+	0xcb, 0xbb, 0x9d, 0x5d, 0xc1, 0x05, 0x9e, 0xd8, 0x62, 0x9a, 0x29,
+	0x2a, 0x36, 0x7c, 0xd5, 0x07, 0x91, 0x59, 0x01, 0x5a, 0x30, 0x70,
+	0xdd, 0x17, 0x15, 0x2f, 0xec, 0xd8, 0xf7, 0x0e, 0x59, 0x39, 0x67,
+	0x33, 0x26, 0x67, 0xff, 0xc0, 0x0b, 0x31, 0x8e, 0xb4, 0x4a, 0x87,
+	0x68, 0x58, 0x15, 0x11, 0xdb, 0x0c, 0x2e, 0x0d, 0x64, 0xf9, 0x8f,
+	0xa7, 0x47, 0xb5, 0x48, 0x1d, 0xbe, 0xfa, 0x4f, 0xa4};
+
+/* SHA 512 - 64 bytes - Initialiser state can be found in FIPS stds 180-2 */
+static const uint8_t sha512InitialState[] = {
+	0x6a, 0x09, 0xe6, 0x67, 0xf3, 0xbc, 0xc9, 0x08, 0xbb, 0x67, 0xae,
+	0x85, 0x84, 0xca, 0xa7, 0x3b, 0x3c, 0x6e, 0xf3, 0x72, 0xfe, 0x94,
+	0xf8, 0x2b, 0xa5, 0x4f, 0xf5, 0x3a, 0x5f, 0x1d, 0x36, 0xf1, 0x51,
+	0x0e, 0x52, 0x7f, 0xad, 0xe6, 0x82, 0xd1, 0x9b, 0x05, 0x68, 0x8c,
+	0x2b, 0x3e, 0x6c, 0x1f, 0x1f, 0x83, 0xd9, 0xab, 0xfb, 0x41, 0xbd,
+	0x6b, 0x5b, 0xe0, 0xcd, 0x19, 0x13, 0x7e, 0x21, 0x79};
+
 /** Frees a context previously created
  *  Depends on openssl libcrypto
  */
@@ -416,6 +451,79 @@ qat_sym_session_configure(struct rte_cryptodev *dev,
 	return 0;
 }
 
+static void
+qat_sym_session_set_ext_hash_flags(struct qat_sym_session *session,
+		uint8_t hash_flag)
+{
+	struct icp_qat_fw_comn_req_hdr *header = &session->fw_req.comn_hdr;
+	struct icp_qat_fw_cipher_auth_cd_ctrl_hdr *cd_ctrl =
+			(struct icp_qat_fw_cipher_auth_cd_ctrl_hdr *)
+			session->fw_req.cd_ctrl.content_desc_ctrl_lw;
+
+	/* Set the Use Extended Protocol Flags bit in LW 1 */
+	QAT_FIELD_SET(header->comn_req_flags,
+			QAT_COMN_EXT_FLAGS_USED,
+			QAT_COMN_EXT_FLAGS_BITPOS,
+			QAT_COMN_EXT_FLAGS_MASK);
+
+	/* Set Hash Flags in LW 28 */
+	cd_ctrl->hash_flags |= hash_flag;
+
+	/* Set proto flags in LW 1 */
+	switch (session->qat_cipher_alg) {
+	case ICP_QAT_HW_CIPHER_ALGO_SNOW_3G_UEA2:
+		ICP_QAT_FW_LA_PROTO_SET(header->serv_specif_flags,
+				ICP_QAT_FW_LA_SNOW_3G_PROTO);
+		ICP_QAT_FW_LA_ZUC_3G_PROTO_FLAG_SET(
+				header->serv_specif_flags, 0);
+		break;
+	case ICP_QAT_HW_CIPHER_ALGO_ZUC_3G_128_EEA3:
+		ICP_QAT_FW_LA_PROTO_SET(header->serv_specif_flags,
+				ICP_QAT_FW_LA_NO_PROTO);
+		ICP_QAT_FW_LA_ZUC_3G_PROTO_FLAG_SET(
+				header->serv_specif_flags,
+				ICP_QAT_FW_LA_ZUC_3G_PROTO);
+		break;
+	default:
+		ICP_QAT_FW_LA_PROTO_SET(header->serv_specif_flags,
+				ICP_QAT_FW_LA_NO_PROTO);
+		ICP_QAT_FW_LA_ZUC_3G_PROTO_FLAG_SET(
+				header->serv_specif_flags, 0);
+		break;
+	}
+}
+
+static void
+qat_sym_session_handle_mixed(const struct rte_cryptodev *dev,
+		struct qat_sym_session *session)
+{
+	const struct qat_sym_dev_private *qat_private = dev->data->dev_private;
+	enum qat_device_gen min_dev_gen = (qat_private->internal_capabilities &
+			QAT_SYM_CAP_MIXED_CRYPTO) ? QAT_GEN2 : QAT_GEN3;
+
+	if (session->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_ZUC_3G_128_EIA3 &&
+			session->qat_cipher_alg !=
+			ICP_QAT_HW_CIPHER_ALGO_ZUC_3G_128_EEA3) {
+		session->min_qat_dev_gen = min_dev_gen;
+		qat_sym_session_set_ext_hash_flags(session,
+			1 << ICP_QAT_FW_AUTH_HDR_FLAG_ZUC_EIA3_BITPOS);
+	} else if (session->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_SNOW_3G_UIA2 &&
+			session->qat_cipher_alg !=
+			ICP_QAT_HW_CIPHER_ALGO_SNOW_3G_UEA2) {
+		session->min_qat_dev_gen = min_dev_gen;
+		qat_sym_session_set_ext_hash_flags(session,
+			1 << ICP_QAT_FW_AUTH_HDR_FLAG_SNOW3G_UIA2_BITPOS);
+	} else if ((session->aes_cmac ||
+			session->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_NULL) &&
+			(session->qat_cipher_alg ==
+			ICP_QAT_HW_CIPHER_ALGO_SNOW_3G_UEA2 ||
+			session->qat_cipher_alg ==
+			ICP_QAT_HW_CIPHER_ALGO_ZUC_3G_128_EEA3)) {
+		session->min_qat_dev_gen = min_dev_gen;
+		qat_sym_session_set_ext_hash_flags(session, 0);
+	}
+}
+
 int
 qat_sym_session_set_parameters(struct rte_cryptodev *dev,
 		struct rte_crypto_sym_xform *xform, void *session_private)
@@ -463,6 +571,8 @@ qat_sym_session_set_parameters(struct rte_cryptodev *dev,
 					xform, session);
 			if (ret < 0)
 				return ret;
+			/* Special handling of mixed hash+cipher algorithms */
+			qat_sym_session_handle_mixed(dev, session);
 		}
 		break;
 	case ICP_QAT_FW_LA_CMD_HASH_CIPHER:
@@ -480,6 +590,8 @@ qat_sym_session_set_parameters(struct rte_cryptodev *dev,
 					xform, session);
 			if (ret < 0)
 				return ret;
+			/* Special handling of mixed hash+cipher algorithms */
+			qat_sym_session_handle_mixed(dev, session);
 		}
 		break;
 	case ICP_QAT_FW_LA_CMD_TRNG_GET_RANDOM:
@@ -580,8 +692,29 @@ qat_sym_session_configure_auth(struct rte_cryptodev *dev,
 	const uint8_t *key_data = auth_xform->key.data;
 	uint8_t key_length = auth_xform->key.length;
 	session->aes_cmac = 0;
+	session->auth_mode = ICP_QAT_HW_AUTH_MODE1;
 
 	switch (auth_xform->algo) {
+	case RTE_CRYPTO_AUTH_SHA1:
+		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_SHA1;
+		session->auth_mode = ICP_QAT_HW_AUTH_MODE0;
+		break;
+	case RTE_CRYPTO_AUTH_SHA224:
+		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_SHA224;
+		session->auth_mode = ICP_QAT_HW_AUTH_MODE0;
+		break;
+	case RTE_CRYPTO_AUTH_SHA256:
+		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_SHA256;
+		session->auth_mode = ICP_QAT_HW_AUTH_MODE0;
+		break;
+	case RTE_CRYPTO_AUTH_SHA384:
+		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_SHA384;
+		session->auth_mode = ICP_QAT_HW_AUTH_MODE0;
+		break;
+	case RTE_CRYPTO_AUTH_SHA512:
+		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_SHA512;
+		session->auth_mode = ICP_QAT_HW_AUTH_MODE0;
+		break;
 	case RTE_CRYPTO_AUTH_SHA1_HMAC:
 		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_SHA1;
 		break;
@@ -635,11 +768,6 @@ qat_sym_session_configure_auth(struct rte_cryptodev *dev,
 		}
 		session->qat_hash_alg = ICP_QAT_HW_AUTH_ALGO_ZUC_3G_128_EIA3;
 		break;
-	case RTE_CRYPTO_AUTH_SHA1:
-	case RTE_CRYPTO_AUTH_SHA256:
-	case RTE_CRYPTO_AUTH_SHA512:
-	case RTE_CRYPTO_AUTH_SHA224:
-	case RTE_CRYPTO_AUTH_SHA384:
 	case RTE_CRYPTO_AUTH_MD5:
 	case RTE_CRYPTO_AUTH_AES_CBC_MAC:
 		QAT_LOG(ERR, "Crypto: Unsupported hash alg %u",
@@ -727,6 +855,8 @@ qat_sym_session_configure_aead(struct rte_cryptodev *dev,
 	session->cipher_iv.offset = xform->aead.iv.offset;
 	session->cipher_iv.length = xform->aead.iv.length;
 
+	session->auth_mode = ICP_QAT_HW_AUTH_MODE1;
+
 	switch (aead_xform->algo) {
 	case RTE_CRYPTO_AEAD_AES_GCM:
 		if (qat_sym_validate_aes_key(aead_xform->key.length,
@@ -1524,7 +1654,7 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 		(struct icp_qat_fw_la_auth_req_params *)
 		((char *)&req_tmpl->serv_specif_rqpars +
 		ICP_QAT_FW_HASH_REQUEST_PARAMETERS_OFFSET);
-	uint16_t state1_size = 0, state2_size = 0;
+	uint16_t state1_size = 0, state2_size = 0, cd_extra_size = 0;
 	uint16_t hash_offset, cd_size;
 	uint32_t *aad_len = NULL;
 	uint32_t wordIndex  = 0;
@@ -1574,10 +1704,11 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 	hash = (struct icp_qat_hw_auth_setup *)cdesc->cd_cur_ptr;
 	hash->auth_config.reserved = 0;
 	hash->auth_config.config =
-			ICP_QAT_HW_AUTH_CONFIG_BUILD(ICP_QAT_HW_AUTH_MODE1,
+			ICP_QAT_HW_AUTH_CONFIG_BUILD(cdesc->auth_mode,
 				cdesc->qat_hash_alg, digestsize);
 
-	if (cdesc->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_SNOW_3G_UIA2
+	if (cdesc->auth_mode == ICP_QAT_HW_AUTH_MODE0
+		|| cdesc->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_SNOW_3G_UIA2
 		|| cdesc->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_KASUMI_F9
 		|| cdesc->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_ZUC_3G_128_EIA3
 		|| cdesc->qat_hash_alg == ICP_QAT_HW_AUTH_ALGO_AES_XCBC_MAC
@@ -1600,6 +1731,15 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 	 */
 	switch (cdesc->qat_hash_alg) {
 	case ICP_QAT_HW_AUTH_ALGO_SHA1:
+		if (cdesc->auth_mode == ICP_QAT_HW_AUTH_MODE0) {
+			/* Plain SHA-1 */
+			rte_memcpy(cdesc->cd_cur_ptr, sha1InitialState,
+					sizeof(sha1InitialState));
+			state1_size = qat_hash_get_state1_size(
+					cdesc->qat_hash_alg);
+			break;
+		}
+		/* SHA-1 HMAC */
 		if (qat_sym_do_precomputes(ICP_QAT_HW_AUTH_ALGO_SHA1, authkey,
 			authkeylen, cdesc->cd_cur_ptr, &state1_size,
 			cdesc->aes_cmac)) {
@@ -1609,6 +1749,15 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 		state2_size = RTE_ALIGN_CEIL(ICP_QAT_HW_SHA1_STATE2_SZ, 8);
 		break;
 	case ICP_QAT_HW_AUTH_ALGO_SHA224:
+		if (cdesc->auth_mode == ICP_QAT_HW_AUTH_MODE0) {
+			/* Plain SHA-224 */
+			rte_memcpy(cdesc->cd_cur_ptr, sha224InitialState,
+					sizeof(sha224InitialState));
+			state1_size = qat_hash_get_state1_size(
+					cdesc->qat_hash_alg);
+			break;
+		}
+		/* SHA-224 HMAC */
 		if (qat_sym_do_precomputes(ICP_QAT_HW_AUTH_ALGO_SHA224, authkey,
 			authkeylen, cdesc->cd_cur_ptr, &state1_size,
 			cdesc->aes_cmac)) {
@@ -1618,6 +1767,15 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 		state2_size = ICP_QAT_HW_SHA224_STATE2_SZ;
 		break;
 	case ICP_QAT_HW_AUTH_ALGO_SHA256:
+		if (cdesc->auth_mode == ICP_QAT_HW_AUTH_MODE0) {
+			/* Plain SHA-256 */
+			rte_memcpy(cdesc->cd_cur_ptr, sha256InitialState,
+					sizeof(sha256InitialState));
+			state1_size = qat_hash_get_state1_size(
+					cdesc->qat_hash_alg);
+			break;
+		}
+		/* SHA-256 HMAC */
 		if (qat_sym_do_precomputes(ICP_QAT_HW_AUTH_ALGO_SHA256, authkey,
 			authkeylen, cdesc->cd_cur_ptr,	&state1_size,
 			cdesc->aes_cmac)) {
@@ -1627,6 +1785,15 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 		state2_size = ICP_QAT_HW_SHA256_STATE2_SZ;
 		break;
 	case ICP_QAT_HW_AUTH_ALGO_SHA384:
+		if (cdesc->auth_mode == ICP_QAT_HW_AUTH_MODE0) {
+			/* Plain SHA-384 */
+			rte_memcpy(cdesc->cd_cur_ptr, sha384InitialState,
+					sizeof(sha384InitialState));
+			state1_size = qat_hash_get_state1_size(
+					cdesc->qat_hash_alg);
+			break;
+		}
+		/* SHA-384 HMAC */
 		if (qat_sym_do_precomputes(ICP_QAT_HW_AUTH_ALGO_SHA384, authkey,
 			authkeylen, cdesc->cd_cur_ptr, &state1_size,
 			cdesc->aes_cmac)) {
@@ -1636,6 +1803,15 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 		state2_size = ICP_QAT_HW_SHA384_STATE2_SZ;
 		break;
 	case ICP_QAT_HW_AUTH_ALGO_SHA512:
+		if (cdesc->auth_mode == ICP_QAT_HW_AUTH_MODE0) {
+			/* Plain SHA-512 */
+			rte_memcpy(cdesc->cd_cur_ptr, sha512InitialState,
+					sizeof(sha512InitialState));
+			state1_size = qat_hash_get_state1_size(
+					cdesc->qat_hash_alg);
+			break;
+		}
+		/* SHA-512 HMAC */
 		if (qat_sym_do_precomputes(ICP_QAT_HW_AUTH_ALGO_SHA512, authkey,
 			authkeylen, cdesc->cd_cur_ptr,	&state1_size,
 			cdesc->aes_cmac)) {
@@ -1700,7 +1876,7 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 		memcpy(cipherconfig->key, authkey, authkeylen);
 		memset(cipherconfig->key + authkeylen,
 				0, ICP_QAT_HW_SNOW_3G_UEA2_IV_SZ);
-		cdesc->cd_cur_ptr += sizeof(struct icp_qat_hw_cipher_config) +
+		cd_extra_size += sizeof(struct icp_qat_hw_cipher_config) +
 				authkeylen + ICP_QAT_HW_SNOW_3G_UEA2_IV_SZ;
 		auth_param->hash_state_sz = ICP_QAT_HW_SNOW_3G_UEA2_IV_SZ >> 3;
 		break;
@@ -1716,8 +1892,7 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 			+ ICP_QAT_HW_ZUC_3G_EEA3_IV_SZ);
 
 		memcpy(cdesc->cd_cur_ptr + state1_size, authkey, authkeylen);
-		cdesc->cd_cur_ptr += state1_size + state2_size
-			+ ICP_QAT_HW_ZUC_3G_EEA3_IV_SZ;
+		cd_extra_size += ICP_QAT_HW_ZUC_3G_EEA3_IV_SZ;
 		auth_param->hash_state_sz = ICP_QAT_HW_ZUC_3G_EEA3_IV_SZ >> 3;
 		cdesc->min_qat_dev_gen = QAT_GEN2;
 
@@ -1803,7 +1978,7 @@ int qat_sym_session_aead_create_cd_auth(struct qat_sym_session *cdesc,
 			 RTE_ALIGN_CEIL(hash_cd_ctrl->inner_state1_sz, 8))
 					>> 3);
 
-	cdesc->cd_cur_ptr += state1_size + state2_size;
+	cdesc->cd_cur_ptr += state1_size + state2_size + cd_extra_size;
 	cd_size = cdesc->cd_cur_ptr-(uint8_t *)&cdesc->cd;
 
 	cd_pars->u.s.content_desc_addr = cdesc->cd_paddr;
diff --git a/dpdk/drivers/crypto/qat/qat_sym_session.h b/dpdk/drivers/crypto/qat/qat_sym_session.h
index 98985d6867..bcab5b2b60 100644
--- a/dpdk/drivers/crypto/qat/qat_sym_session.h
+++ b/dpdk/drivers/crypto/qat/qat_sym_session.h
@@ -62,6 +62,7 @@ struct qat_sym_session {
 	enum icp_qat_hw_cipher_mode qat_mode;
 	enum icp_qat_hw_auth_algo qat_hash_alg;
 	enum icp_qat_hw_auth_op auth_op;
+	enum icp_qat_hw_auth_mode auth_mode;
 	void *bpi_ctx;
 	struct qat_sym_cd cd;
 	uint8_t *cd_cur_ptr;
diff --git a/dpdk/drivers/crypto/scheduler/meson.build b/dpdk/drivers/crypto/scheduler/meson.build
index c5ba2d6804..cb0f3a8ba9 100644
--- a/dpdk/drivers/crypto/scheduler/meson.build
+++ b/dpdk/drivers/crypto/scheduler/meson.build
@@ -13,7 +13,7 @@ sources = files(
 	'scheduler_roundrobin.c',
 )
 
-headers = files(
+install_headers(
 	'rte_cryptodev_scheduler.h',
 	'rte_cryptodev_scheduler_operations.h',
 )
diff --git a/dpdk/drivers/crypto/scheduler/scheduler_pmd_private.h b/dpdk/drivers/crypto/scheduler/scheduler_pmd_private.h
index 3ed480c183..d6870177b1 100644
--- a/dpdk/drivers/crypto/scheduler/scheduler_pmd_private.h
+++ b/dpdk/drivers/crypto/scheduler/scheduler_pmd_private.h
@@ -59,7 +59,6 @@ struct scheduler_qp_ctx {
 	uint32_t max_nb_objs;
 
 	struct rte_ring *order_ring;
-	uint32_t seqn;
 } __rte_cache_aligned;
 
 
diff --git a/dpdk/drivers/crypto/snow3g/rte_snow3g_pmd.c b/dpdk/drivers/crypto/snow3g/rte_snow3g_pmd.c
index 9d07e1ab2c..32d94c5ab5 100644
--- a/dpdk/drivers/crypto/snow3g/rte_snow3g_pmd.c
+++ b/dpdk/drivers/crypto/snow3g/rte_snow3g_pmd.c
@@ -16,6 +16,7 @@
 #define SNOW3G_MAX_BURST 8
 #define BYTE_LEN 8
 
+int snow3g_logtype_driver;
 static uint8_t cryptodev_driver_id;
 
 /** Get xform chain order. */
@@ -567,6 +568,7 @@ cryptodev_snow3g_create(const char *name,
 
 	dev->feature_flags = RTE_CRYPTODEV_FF_SYMMETRIC_CRYPTO |
 			RTE_CRYPTODEV_FF_SYM_OPERATION_CHAINING |
+			RTE_CRYPTODEV_FF_OOP_LB_IN_LB_OUT |
 			cpu_flags;
 
 	internals = dev->data->dev_private;
diff --git a/dpdk/drivers/crypto/snow3g/snow3g_pmd_private.h b/dpdk/drivers/crypto/snow3g/snow3g_pmd_private.h
index 1fe05eb567..1070800960 100644
--- a/dpdk/drivers/crypto/snow3g/snow3g_pmd_private.h
+++ b/dpdk/drivers/crypto/snow3g/snow3g_pmd_private.h
@@ -11,7 +11,7 @@
 /**< SNOW 3G PMD device name */
 
 /** SNOW 3G PMD LOGTYPE DRIVER */
-int snow3g_logtype_driver;
+extern int snow3g_logtype_driver;
 
 #define SNOW3G_LOG(level, fmt, ...)  \
 	rte_log(RTE_LOG_ ## level, snow3g_logtype_driver,  \
diff --git a/dpdk/drivers/crypto/zuc/rte_zuc_pmd.c b/dpdk/drivers/crypto/zuc/rte_zuc_pmd.c
index 8e214cd50e..bc02d9d4af 100644
--- a/dpdk/drivers/crypto/zuc/rte_zuc_pmd.c
+++ b/dpdk/drivers/crypto/zuc/rte_zuc_pmd.c
@@ -14,6 +14,7 @@
 #define ZUC_MAX_BURST 4
 #define BYTE_LEN 8
 
+int zuc_logtype_driver;
 static uint8_t cryptodev_driver_id;
 
 /** Get xform chain order. */
@@ -475,6 +476,7 @@ cryptodev_zuc_create(const char *name,
 
 	dev->feature_flags = RTE_CRYPTODEV_FF_SYMMETRIC_CRYPTO |
 			RTE_CRYPTODEV_FF_SYM_OPERATION_CHAINING |
+			RTE_CRYPTODEV_FF_OOP_LB_IN_LB_OUT |
 			cpu_flags;
 
 	internals = dev->data->dev_private;
diff --git a/dpdk/drivers/crypto/zuc/zuc_pmd_private.h b/dpdk/drivers/crypto/zuc/zuc_pmd_private.h
index 428efd4bb5..dc492b1710 100644
--- a/dpdk/drivers/crypto/zuc/zuc_pmd_private.h
+++ b/dpdk/drivers/crypto/zuc/zuc_pmd_private.h
@@ -8,10 +8,10 @@
 #include <sso_zuc.h>
 
 #define CRYPTODEV_NAME_ZUC_PMD		crypto_zuc
-/**< KASUMI PMD device name */
+/**< ZUC PMD device name */
 
 /** ZUC PMD LOGTYPE DRIVER */
-int zuc_logtype_driver;
+extern int zuc_logtype_driver;
 #define ZUC_LOG(level, fmt, ...)  \
 	rte_log(RTE_LOG_ ## level, zuc_logtype_driver,  \
 			"%s()... line %u: " fmt "\n", __func__, __LINE__,  \
diff --git a/dpdk/drivers/event/dpaa/dpaa_eventdev.c b/dpdk/drivers/event/dpaa/dpaa_eventdev.c
index a7d57edce7..29b18fe62b 100644
--- a/dpdk/drivers/event/dpaa/dpaa_eventdev.c
+++ b/dpdk/drivers/event/dpaa/dpaa_eventdev.c
@@ -173,7 +173,7 @@ dpaa_event_dequeue_burst(void *port, struct rte_event ev[],
 	int ret;
 	u16 ch_id;
 	void *buffers[8];
-	u32 num_frames, i, irq = 0;
+	u32 num_frames, i;
 	uint64_t cur_ticks = 0, wait_time_ticks = 0;
 	struct dpaa_port *portal = (struct dpaa_port *)port;
 	struct rte_mbuf *mbuf;
@@ -222,8 +222,6 @@ dpaa_event_dequeue_burst(void *port, struct rte_event ev[],
 	do {
 		/* Lets dequeue the frames */
 		num_frames = qman_portal_dequeue(ev, nb_events, buffers);
-		if (irq)
-			irq = 0;
 		if (num_frames)
 			break;
 		cur_ticks = rte_get_timer_cycles();
diff --git a/dpdk/drivers/event/dpaa2/dpaa2_eventdev.c b/dpdk/drivers/event/dpaa2/dpaa2_eventdev.c
index d71361666c..5ae76d4d9d 100644
--- a/dpdk/drivers/event/dpaa2/dpaa2_eventdev.c
+++ b/dpdk/drivers/event/dpaa2/dpaa2_eventdev.c
@@ -391,7 +391,7 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,
 	dev_info->max_event_priority_levels =
 		DPAA2_EVENT_MAX_EVENT_PRIORITY_LEVELS;
 	dev_info->max_event_ports = rte_fslmc_get_device_count(DPAA2_IO);
-	/* we only support dpio upto number of cores*/
+	/* we only support dpio up to number of cores */
 	if (dev_info->max_event_ports > rte_lcore_count())
 		dev_info->max_event_ports = rte_lcore_count();
 	dev_info->max_event_port_dequeue_depth =
@@ -403,7 +403,8 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,
 		RTE_EVENT_DEV_CAP_BURST_MODE|
 		RTE_EVENT_DEV_CAP_RUNTIME_PORT_LINK |
 		RTE_EVENT_DEV_CAP_MULTIPLE_QUEUE_PORT |
-		RTE_EVENT_DEV_CAP_NONSEQ_MODE;
+		RTE_EVENT_DEV_CAP_NONSEQ_MODE |
+		RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES;
 
 }
 
@@ -479,6 +480,8 @@ dpaa2_eventdev_queue_def_conf(struct rte_eventdev *dev, uint8_t queue_id,
 	RTE_SET_USED(queue_id);
 
 	queue_conf->nb_atomic_flows = DPAA2_EVENT_QUEUE_ATOMIC_FLOWS;
+	queue_conf->nb_atomic_order_sequences =
+				DPAA2_EVENT_QUEUE_ORDER_SEQUENCES;
 	queue_conf->schedule_type = RTE_SCHED_TYPE_PARALLEL;
 	queue_conf->priority = RTE_EVENT_DEV_PRIORITY_NORMAL;
 }
@@ -564,14 +567,14 @@ dpaa2_eventdev_port_release(void *port)
 
 	EVENTDEV_INIT_FUNC_TRACE();
 
+	if (portal == NULL)
+		return;
+
 	/* TODO: Cleanup is required when ports are in linked state. */
 	if (portal->is_port_linked)
 		DPAA2_EVENTDEV_WARN("Event port must be unlinked before release");
 
-	if (portal)
-		rte_free(portal);
-
-	portal = NULL;
+	rte_free(portal);
 }
 
 static int
diff --git a/dpdk/drivers/event/dpaa2/dpaa2_eventdev_selftest.c b/dpdk/drivers/event/dpaa2/dpaa2_eventdev_selftest.c
index ba4f4bd234..1f35807b21 100644
--- a/dpdk/drivers/event/dpaa2/dpaa2_eventdev_selftest.c
+++ b/dpdk/drivers/event/dpaa2/dpaa2_eventdev_selftest.c
@@ -47,17 +47,6 @@ struct event_attr {
 	uint8_t seq;
 };
 
-static uint32_t seqn_list_index;
-static int seqn_list[NUM_PACKETS];
-
-static void
-seqn_list_init(void)
-{
-	RTE_BUILD_BUG_ON(NUM_PACKETS < MAX_EVENTS);
-	memset(seqn_list, 0, sizeof(seqn_list));
-	seqn_list_index = 0;
-}
-
 struct test_core_param {
 	rte_atomic32_t *total_events;
 	uint64_t dequeue_tmo_ticks;
@@ -516,7 +505,7 @@ launch_workers_and_wait(int (*master_worker)(void *),
 		return 0;
 
 	rte_atomic32_set(&atomic_total_events, total_events);
-	seqn_list_init();
+	RTE_BUILD_BUG_ON(NUM_PACKETS < MAX_EVENTS);
 
 	param = malloc(sizeof(struct test_core_param) * nb_workers);
 	if (!param)
diff --git a/dpdk/drivers/event/dsw/dsw_event.c b/dpdk/drivers/event/dsw/dsw_event.c
index 61a66fabf3..0df9209e4f 100644
--- a/dpdk/drivers/event/dsw/dsw_event.c
+++ b/dpdk/drivers/event/dsw/dsw_event.c
@@ -658,6 +658,9 @@ dsw_port_consider_migration(struct dsw_evdev *dsw,
 	if (dsw->num_ports == 1)
 		return;
 
+	if (seen_events_len < DSW_MAX_EVENTS_RECORDED)
+		return;
+
 	DSW_LOG_DP_PORT(DEBUG, source_port->id, "Considering migration.\n");
 
 	/* Randomize interval to avoid having all threads considering
@@ -930,11 +933,6 @@ dsw_port_ctl_process(struct dsw_evdev *dsw, struct dsw_port *port)
 {
 	struct dsw_ctl_msg msg;
 
-	/* So any table loads happens before the ring dequeue, in the
-	 * case of a 'paus' message.
-	 */
-	rte_smp_rmb();
-
 	if (dsw_port_ctl_dequeue(port, &msg) == 0) {
 		switch (msg.type) {
 		case DSW_CTL_PAUS_REQ:
@@ -1018,12 +1016,12 @@ dsw_event_enqueue(void *port, const struct rte_event *ev)
 }
 
 static __rte_always_inline uint16_t
-dsw_event_enqueue_burst_generic(void *port, const struct rte_event events[],
+dsw_event_enqueue_burst_generic(struct dsw_port *source_port,
+				const struct rte_event events[],
 				uint16_t events_len, bool op_types_known,
 				uint16_t num_new, uint16_t num_release,
 				uint16_t num_non_release)
 {
-	struct dsw_port *source_port = port;
 	struct dsw_evdev *dsw = source_port->dsw;
 	bool enough_credits;
 	uint16_t i;
@@ -1047,12 +1045,10 @@ dsw_event_enqueue_burst_generic(void *port, const struct rte_event events[],
 	 */
 	if (unlikely(events_len == 0)) {
 		dsw_port_note_op(source_port, DSW_MAX_PORT_OPS_PER_BG_TASK);
+		dsw_port_flush_out_buffers(dsw, source_port);
 		return 0;
 	}
 
-	if (unlikely(events_len > source_port->enqueue_depth))
-		events_len = source_port->enqueue_depth;
-
 	dsw_port_note_op(source_port, events_len);
 
 	if (!op_types_known)
@@ -1101,31 +1097,48 @@ dsw_event_enqueue_burst_generic(void *port, const struct rte_event events[],
 	DSW_LOG_DP_PORT(DEBUG, source_port->id, "%d non-release events "
 			"accepted.\n", num_non_release);
 
-	return num_non_release;
+	return (num_non_release + num_release);
 }
 
 uint16_t
 dsw_event_enqueue_burst(void *port, const struct rte_event events[],
 			uint16_t events_len)
 {
-	return dsw_event_enqueue_burst_generic(port, events, events_len, false,
-					       0, 0, 0);
+	struct dsw_port *source_port = port;
+
+	if (unlikely(events_len > source_port->enqueue_depth))
+		events_len = source_port->enqueue_depth;
+
+	return dsw_event_enqueue_burst_generic(source_port, events,
+					       events_len, false, 0, 0, 0);
 }
 
 uint16_t
 dsw_event_enqueue_new_burst(void *port, const struct rte_event events[],
 			    uint16_t events_len)
 {
-	return dsw_event_enqueue_burst_generic(port, events, events_len, true,
-					       events_len, 0, events_len);
+	struct dsw_port *source_port = port;
+
+	if (unlikely(events_len > source_port->enqueue_depth))
+		events_len = source_port->enqueue_depth;
+
+	return dsw_event_enqueue_burst_generic(source_port, events,
+					       events_len, true, events_len,
+					       0, events_len);
 }
 
 uint16_t
 dsw_event_enqueue_forward_burst(void *port, const struct rte_event events[],
 				uint16_t events_len)
 {
-	return dsw_event_enqueue_burst_generic(port, events, events_len, true,
-					       0, 0, events_len);
+	struct dsw_port *source_port = port;
+
+	if (unlikely(events_len > source_port->enqueue_depth))
+		events_len = source_port->enqueue_depth;
+
+	return dsw_event_enqueue_burst_generic(source_port, events,
+					       events_len, true, 0, 0,
+					       events_len);
 }
 
 uint16_t
@@ -1179,11 +1192,6 @@ static uint16_t
 dsw_port_dequeue_burst(struct dsw_port *port, struct rte_event *events,
 		       uint16_t num)
 {
-	struct dsw_port *source_port = port;
-	struct dsw_evdev *dsw = source_port->dsw;
-
-	dsw_port_ctl_process(dsw, source_port);
-
 	if (unlikely(port->in_buffer_len > 0)) {
 		uint16_t dequeued = RTE_MIN(num, port->in_buffer_len);
 
diff --git a/dpdk/drivers/event/octeontx2/otx2_evdev.c b/dpdk/drivers/event/octeontx2/otx2_evdev.c
index 2daeba42c7..5bdf23c362 100644
--- a/dpdk/drivers/event/octeontx2/otx2_evdev.c
+++ b/dpdk/drivers/event/octeontx2/otx2_evdev.c
@@ -648,7 +648,36 @@ sso_lf_cfg(struct otx2_sso_evdev *dev, struct otx2_mbox *mbox,
 static void
 otx2_sso_port_release(void *port)
 {
-	rte_free(port);
+	struct otx2_ssogws_cookie *gws_cookie = ssogws_get_cookie(port);
+	struct otx2_sso_evdev *dev;
+	int i;
+
+	if (!gws_cookie->configured)
+		goto free;
+
+	dev = sso_pmd_priv(gws_cookie->event_dev);
+	if (dev->dual_ws) {
+		struct otx2_ssogws_dual *ws = port;
+
+		for (i = 0; i < dev->nb_event_queues; i++) {
+			sso_port_link_modify((struct otx2_ssogws *)
+					     &ws->ws_state[0], i, false);
+			sso_port_link_modify((struct otx2_ssogws *)
+					     &ws->ws_state[1], i, false);
+		}
+		memset(ws, 0, sizeof(*ws));
+	} else {
+		struct otx2_ssogws *ws = port;
+
+		for (i = 0; i < dev->nb_event_queues; i++)
+			sso_port_link_modify(ws, i, false);
+		memset(ws, 0, sizeof(*ws));
+	}
+
+	memset(gws_cookie, 0, sizeof(*gws_cookie));
+
+free:
+	rte_free(gws_cookie);
 }
 
 static void
@@ -659,28 +688,41 @@ otx2_sso_queue_release(struct rte_eventdev *event_dev, uint8_t queue_id)
 }
 
 static void
-sso_clr_links(const struct rte_eventdev *event_dev)
+sso_restore_links(const struct rte_eventdev *event_dev)
 {
 	struct otx2_sso_evdev *dev = sso_pmd_priv(event_dev);
+	uint16_t *links_map;
 	int i, j;
 
 	for (i = 0; i < dev->nb_event_ports; i++) {
+		links_map = event_dev->data->links_map;
+		/* Point links_map to this port specific area */
+		links_map += (i * RTE_EVENT_MAX_QUEUES_PER_DEV);
 		if (dev->dual_ws) {
 			struct otx2_ssogws_dual *ws;
 
 			ws = event_dev->data->ports[i];
 			for (j = 0; j < dev->nb_event_queues; j++) {
+				if (links_map[j] == 0xdead)
+					continue;
 				sso_port_link_modify((struct otx2_ssogws *)
-						&ws->ws_state[0], j, false);
+						&ws->ws_state[0], j, true);
 				sso_port_link_modify((struct otx2_ssogws *)
-						&ws->ws_state[1], j, false);
+						&ws->ws_state[1], j, true);
+				sso_func_trace("Restoring port %d queue %d "
+						"link", i, j);
 			}
 		} else {
 			struct otx2_ssogws *ws;
 
 			ws = event_dev->data->ports[i];
-			for (j = 0; j < dev->nb_event_queues; j++)
-				sso_port_link_modify(ws, j, false);
+			for (j = 0; j < dev->nb_event_queues; j++) {
+				if (links_map[j] == 0xdead)
+					continue;
+				sso_port_link_modify(ws, j, true);
+				sso_func_trace("Restoring port %d queue %d "
+						"link", i, j);
+			}
 		}
 	}
 }
@@ -722,25 +764,29 @@ sso_configure_dual_ports(const struct rte_eventdev *event_dev)
 	}
 
 	for (i = 0; i < dev->nb_event_ports; i++) {
+		struct otx2_ssogws_cookie *gws_cookie;
 		struct otx2_ssogws_dual *ws;
 		uintptr_t base;
 
-		/* Free memory prior to re-allocation if needed */
 		if (event_dev->data->ports[i] != NULL) {
 			ws = event_dev->data->ports[i];
-			rte_free(ws);
-			ws = NULL;
-		}
-
-		/* Allocate event port memory */
-		ws = rte_zmalloc_socket("otx2_sso_ws",
-					sizeof(struct otx2_ssogws_dual),
+		} else {
+			/* Allocate event port memory */
+			ws = rte_zmalloc_socket("otx2_sso_ws",
+					sizeof(struct otx2_ssogws_dual) +
+					RTE_CACHE_LINE_SIZE,
 					RTE_CACHE_LINE_SIZE,
 					event_dev->data->socket_id);
-		if (ws == NULL) {
-			otx2_err("Failed to alloc memory for port=%d", i);
-			rc = -ENOMEM;
-			break;
+			if (ws == NULL) {
+				otx2_err("Failed to alloc memory for port=%d",
+					 i);
+				rc = -ENOMEM;
+				break;
+			}
+
+			/* First cache line is reserved for cookie */
+			ws = (struct otx2_ssogws_dual *)
+				((uint8_t *)ws + RTE_CACHE_LINE_SIZE);
 		}
 
 		ws->port = i;
@@ -752,6 +798,10 @@ sso_configure_dual_ports(const struct rte_eventdev *event_dev)
 		sso_set_port_ops((struct otx2_ssogws *)&ws->ws_state[1], base);
 		vws++;
 
+		gws_cookie = ssogws_get_cookie(ws);
+		gws_cookie->event_dev = event_dev;
+		gws_cookie->configured = 1;
+
 		event_dev->data->ports[i] = ws;
 	}
 
@@ -788,19 +838,21 @@ sso_configure_ports(const struct rte_eventdev *event_dev)
 	}
 
 	for (i = 0; i < nb_lf; i++) {
+		struct otx2_ssogws_cookie *gws_cookie;
 		struct otx2_ssogws *ws;
 		uintptr_t base;
 
 		/* Free memory prior to re-allocation if needed */
 		if (event_dev->data->ports[i] != NULL) {
 			ws = event_dev->data->ports[i];
-			rte_free(ws);
+			rte_free(ssogws_get_cookie(ws));
 			ws = NULL;
 		}
 
 		/* Allocate event port memory */
 		ws = rte_zmalloc_socket("otx2_sso_ws",
-					sizeof(struct otx2_ssogws),
+					sizeof(struct otx2_ssogws) +
+					RTE_CACHE_LINE_SIZE,
 					RTE_CACHE_LINE_SIZE,
 					event_dev->data->socket_id);
 		if (ws == NULL) {
@@ -809,10 +861,18 @@ sso_configure_ports(const struct rte_eventdev *event_dev)
 			break;
 		}
 
+		/* First cache line is reserved for cookie */
+		ws = (struct otx2_ssogws *)
+			((uint8_t *)ws + RTE_CACHE_LINE_SIZE);
+
 		ws->port = i;
 		base = dev->bar2 + (RVU_BLOCK_ADDR_SSOW << 20 | i << 12);
 		sso_set_port_ops(ws, base);
 
+		gws_cookie = ssogws_get_cookie(ws);
+		gws_cookie->event_dev = event_dev;
+		gws_cookie->configured = 1;
+
 		event_dev->data->ports[i] = ws;
 	}
 
@@ -1057,8 +1117,8 @@ otx2_sso_configure(const struct rte_eventdev *event_dev)
 		goto teardown_hwggrp;
 	}
 
-	/* Clear any prior port-queue mapping. */
-	sso_clr_links(event_dev);
+	/* Restore any prior port-queue mapping. */
+	sso_restore_links(event_dev);
 	rc = sso_ggrp_alloc_xaq(dev);
 	if (rc < 0) {
 		otx2_err("Failed to alloc xaq to ggrp %d", rc);
diff --git a/dpdk/drivers/event/octeontx2/otx2_evdev.h b/dpdk/drivers/event/octeontx2/otx2_evdev.h
index 231a12a52b..e134ea5ea3 100644
--- a/dpdk/drivers/event/octeontx2/otx2_evdev.h
+++ b/dpdk/drivers/event/octeontx2/otx2_evdev.h
@@ -16,7 +16,7 @@
 #include "otx2_mempool.h"
 #include "otx2_tim_evdev.h"
 
-#define EVENTDEV_NAME_OCTEONTX2_PMD otx2_eventdev
+#define EVENTDEV_NAME_OCTEONTX2_PMD event_octeontx2
 
 #define sso_func_trace otx2_sso_dbg
 
@@ -212,6 +212,18 @@ sso_pmd_priv(const struct rte_eventdev *event_dev)
 	return event_dev->data->dev_private;
 }
 
+struct otx2_ssogws_cookie {
+	const struct rte_eventdev *event_dev;
+	bool configured;
+};
+
+static inline struct otx2_ssogws_cookie *
+ssogws_get_cookie(void *ws)
+{
+	return (struct otx2_ssogws_cookie *)
+		((uint8_t *)ws - RTE_CACHE_LINE_SIZE);
+}
+
 static const union mbuf_initializer mbuf_init = {
 	.fields = {
 		.data_off = RTE_PKTMBUF_HEADROOM,
diff --git a/dpdk/drivers/event/octeontx2/otx2_evdev_adptr.c b/dpdk/drivers/event/octeontx2/otx2_evdev_adptr.c
index 233cba2aa3..8bdcfa3ea5 100644
--- a/dpdk/drivers/event/octeontx2/otx2_evdev_adptr.c
+++ b/dpdk/drivers/event/octeontx2/otx2_evdev_adptr.c
@@ -133,7 +133,7 @@ sso_rxq_disable(struct otx2_eth_dev *dev, uint16_t qid)
 	aq = otx2_mbox_alloc_msg_nix_aq_enq(mbox);
 	aq->qidx = qid;
 	aq->ctype = NIX_AQ_CTYPE_CQ;
-	aq->op = NIX_AQ_INSTOP_INIT;
+	aq->op = NIX_AQ_INSTOP_WRITE;
 
 	aq->cq.ena = 1;
 	aq->cq.caching = 1;
@@ -144,7 +144,7 @@ sso_rxq_disable(struct otx2_eth_dev *dev, uint16_t qid)
 
 	rc = otx2_mbox_process(mbox);
 	if (rc < 0) {
-		otx2_err("Failed to init cq context");
+		otx2_err("Failed to enable cq context");
 		goto fail;
 	}
 
diff --git a/dpdk/drivers/event/octeontx2/otx2_evdev_stats.h b/dpdk/drivers/event/octeontx2/otx2_evdev_stats.h
index 9d7c694ee6..74fcec8a07 100644
--- a/dpdk/drivers/event/octeontx2/otx2_evdev_stats.h
+++ b/dpdk/drivers/event/octeontx2/otx2_evdev_stats.h
@@ -67,7 +67,7 @@ otx2_sso_xstats_get(const struct rte_eventdev *event_dev,
 
 	switch (mode) {
 	case RTE_EVENT_DEV_XSTATS_DEVICE:
-		break;
+		return 0;
 	case RTE_EVENT_DEV_XSTATS_PORT:
 		if (queue_port_id >= (signed int)dev->nb_event_ports)
 			goto invalid_value;
diff --git a/dpdk/drivers/event/octeontx2/otx2_worker_dual.h b/dpdk/drivers/event/octeontx2/otx2_worker_dual.h
index 5134e3d525..fb6a8cd0d5 100644
--- a/dpdk/drivers/event/octeontx2/otx2_worker_dual.h
+++ b/dpdk/drivers/event/octeontx2/otx2_worker_dual.h
@@ -69,8 +69,11 @@ otx2_ssogws_dual_get_work(struct otx2_ssogws_state *ws,
 
 	if (event.sched_type != SSO_TT_EMPTY &&
 	    event.event_type == RTE_EVENT_TYPE_ETHDEV) {
-		otx2_wqe_to_mbuf(get_work1, mbuf, event.sub_event_type,
-				 (uint32_t) event.get_work0, flags, lookup_mem);
+		uint8_t port = event.sub_event_type;
+
+		event.sub_event_type = 0;
+		otx2_wqe_to_mbuf(get_work1, mbuf, port,
+				 event.flow_id, flags, lookup_mem);
 		/* Extracting tstamp, if PTP enabled. CGX will prepend the
 		 * timestamp at starting of packet data and it can be derieved
 		 * from WQE 9 dword which corresponds to SG iova.
diff --git a/dpdk/drivers/mempool/dpaa2/meson.build b/dpdk/drivers/mempool/dpaa2/meson.build
index d79fc31644..a4fe684fc4 100644
--- a/dpdk/drivers/mempool/dpaa2/meson.build
+++ b/dpdk/drivers/mempool/dpaa2/meson.build
@@ -9,5 +9,7 @@ endif
 deps += ['bus_fslmc']
 sources = files('dpaa2_hw_mempool.c')
 
+install_headers('rte_dpaa2_mempool.h')
+
 # depends on fslmc bus which uses experimental API
 allow_experimental_apis = true
diff --git a/dpdk/drivers/mempool/octeontx/octeontx_fpavf.c b/dpdk/drivers/mempool/octeontx/octeontx_fpavf.c
index c97267db3c..e37b844842 100644
--- a/dpdk/drivers/mempool/octeontx/octeontx_fpavf.c
+++ b/dpdk/drivers/mempool/octeontx/octeontx_fpavf.c
@@ -267,7 +267,7 @@ octeontx_fpapf_pool_setup(unsigned int gpool, unsigned int buf_size,
 		POOL_LTYPE(0x2) | POOL_STYPE(0) | POOL_SET_NAT_ALIGN |
 		POOL_ENA;
 
-	cfg.aid = FPA_AURA_IDX(gpool);
+	cfg.aid = 0;
 	cfg.pool_cfg = reg;
 	cfg.pool_stack_base = phys_addr;
 	cfg.pool_stack_end = phys_addr + memsz;
@@ -305,10 +305,8 @@ octeontx_fpapf_pool_destroy(unsigned int gpool_index)
 	int ret = -1;
 
 	fpa = octeontx_get_fpavf(gpool_index);
-	if (fpa == NULL) {
-		ret = -EINVAL;
-		goto err;
-	}
+	if (fpa == NULL)
+		return -EINVAL;
 
 	hdr.coproc = FPA_COPROC;
 	hdr.msg = FPA_CONFIGSET;
@@ -355,7 +353,7 @@ octeontx_fpapf_aura_attach(unsigned int gpool_index)
 	hdr.vfid = gpool_index;
 	hdr.res_code = 0;
 	memset(&cfg, 0x0, sizeof(struct octeontx_mbox_fpa_cfg));
-	cfg.aid = FPA_AURA_IDX(gpool_index);
+	cfg.aid = 0;
 
 	ret = octeontx_mbox_send(&hdr, &cfg,
 					sizeof(struct octeontx_mbox_fpa_cfg),
@@ -384,7 +382,7 @@ octeontx_fpapf_aura_detach(unsigned int gpool_index)
 		goto err;
 	}
 
-	cfg.aid = FPA_AURA_IDX(gpool_index);
+	cfg.aid = 0;
 	hdr.coproc = FPA_COPROC;
 	hdr.msg = FPA_DETACHAURA;
 	hdr.vfid = gpool_index;
diff --git a/dpdk/drivers/mempool/octeontx2/otx2_mempool_ops.c b/dpdk/drivers/mempool/octeontx2/otx2_mempool_ops.c
index ea4b1c45d2..18bdb0b4c4 100644
--- a/dpdk/drivers/mempool/octeontx2/otx2_mempool_ops.c
+++ b/dpdk/drivers/mempool/octeontx2/otx2_mempool_ops.c
@@ -637,10 +637,10 @@ static int
 otx2_npa_alloc(struct rte_mempool *mp)
 {
 	uint32_t block_size, block_count;
+	uint64_t aura_handle = 0;
 	struct otx2_npa_lf *lf;
 	struct npa_aura_s aura;
 	struct npa_pool_s pool;
-	uint64_t aura_handle;
 	int rc;
 
 	lf = otx2_npa_lf_obj_get();
diff --git a/dpdk/drivers/meson.build b/dpdk/drivers/meson.build
index 72eec46088..696079680b 100644
--- a/dpdk/drivers/meson.build
+++ b/dpdk/drivers/meson.build
@@ -9,8 +9,8 @@ endif
 dpdk_driver_classes = ['common',
 	       'bus',
 	       'mempool', # depends on common and bus.
-	       'raw',     # depends on common and bus.
-	       'net',     # depends on common, bus, mempool and raw.
+	       'net',     # depends on common, bus, mempool
+	       'raw',     # depends on common, bus and net.
 	       'crypto',  # depends on common, bus and mempool (net in future).
 	       'compress', # depends on common, bus, mempool.
 	       'event',   # depends on common, bus, mempool and net.
@@ -151,7 +151,7 @@ foreach class:dpdk_driver_classes
 			version_map = '@0@/@1@/@2@_version.map'.format(
 					meson.current_source_dir(),
 					drv_path, lib_name)
-			implib = dir_name + '.dll.a'
+			implib = 'lib' + lib_name + '.dll.a'
 
 			def_file = custom_target(lib_name + '_def',
 				command: [map_to_def_cmd, '@INPUT@', '@OUTPUT@'],
@@ -159,8 +159,14 @@ foreach class:dpdk_driver_classes
 				output: '@0@_exports.def'.format(lib_name))
 			lk_deps = [version_map, def_file]
 			if is_windows
-				lk_args = ['-Wl,/def:' + def_file.full_path(),
-					'-Wl,/implib:lib\\' + implib]
+				if is_ms_linker
+					lk_args = ['-Wl,/def:' + def_file.full_path()]
+					if meson.version().version_compare('<0.54.0')
+						lk_args += ['-Wl,/implib:drivers\\' + implib]
+					endif
+				else
+					lk_args = []
+				endif
 			else
 				lk_args = ['-Wl,--version-script=' + version_map]
 				# on unix systems check the output of the
@@ -192,7 +198,7 @@ foreach class:dpdk_driver_classes
 			shared_dep = declare_dependency(link_with: shared_lib,
 					include_directories: includes,
 					dependencies: shared_deps)
-			static_dep = declare_dependency(link_with: static_lib,
+			static_dep = declare_dependency(
 					include_directories: includes,
 					dependencies: static_deps)
 
diff --git a/dpdk/drivers/net/af_packet/rte_eth_af_packet.c b/dpdk/drivers/net/af_packet/rte_eth_af_packet.c
index f5806bf42c..00387ed0ac 100644
--- a/dpdk/drivers/net/af_packet/rte_eth_af_packet.c
+++ b/dpdk/drivers/net/af_packet/rte_eth_af_packet.c
@@ -604,6 +604,8 @@ rte_pmd_init_internals(struct rte_vdev_device *dev,
 	for (q = 0; q < nb_queues; q++) {
 		(*internals)->rx_queue[q].map = MAP_FAILED;
 		(*internals)->tx_queue[q].map = MAP_FAILED;
+		(*internals)->rx_queue[q].sockfd = -1;
+		(*internals)->tx_queue[q].sockfd = -1;
 	}
 
 	req = &((*internals)->req);
@@ -621,20 +623,20 @@ rte_pmd_init_internals(struct rte_vdev_device *dev,
 		PMD_LOG(ERR,
 			"%s: I/F name too long (%s)",
 			name, pair->value);
-		return -1;
+		goto free_internals;
 	}
 	if (ioctl(sockfd, SIOCGIFINDEX, &ifr) == -1) {
 		PMD_LOG_ERRNO(ERR, "%s: ioctl failed (SIOCGIFINDEX)", name);
-		return -1;
+		goto free_internals;
 	}
 	(*internals)->if_name = strdup(pair->value);
 	if ((*internals)->if_name == NULL)
-		return -1;
+		goto free_internals;
 	(*internals)->if_index = ifr.ifr_ifindex;
 
 	if (ioctl(sockfd, SIOCGIFHWADDR, &ifr) == -1) {
 		PMD_LOG_ERRNO(ERR, "%s: ioctl failed (SIOCGIFHWADDR)", name);
-		return -1;
+		goto free_internals;
 	}
 	memcpy(&(*internals)->eth_addr, ifr.ifr_hwaddr.sa_data, ETH_ALEN);
 
@@ -658,7 +660,7 @@ rte_pmd_init_internals(struct rte_vdev_device *dev,
 			PMD_LOG_ERRNO(ERR,
 				"%s: could not open AF_PACKET socket",
 				name);
-			return -1;
+			goto error;
 		}
 
 		tpver = TPACKET_V2;
@@ -802,15 +804,19 @@ rte_pmd_init_internals(struct rte_vdev_device *dev,
 	if (qsockfd != -1)
 		close(qsockfd);
 	for (q = 0; q < nb_queues; q++) {
-		munmap((*internals)->rx_queue[q].map,
-		       2 * req->tp_block_size * req->tp_block_nr);
+		if ((*internals)->rx_queue[q].map != MAP_FAILED)
+			munmap((*internals)->rx_queue[q].map,
+			       2 * req->tp_block_size * req->tp_block_nr);
 
 		rte_free((*internals)->rx_queue[q].rd);
 		rte_free((*internals)->tx_queue[q].rd);
-		if (((*internals)->rx_queue[q].sockfd != 0) &&
+		if (((*internals)->rx_queue[q].sockfd >= 0) &&
 			((*internals)->rx_queue[q].sockfd != qsockfd))
 			close((*internals)->rx_queue[q].sockfd);
 	}
+free_internals:
+	rte_free((*internals)->rx_queue);
+	rte_free((*internals)->tx_queue);
 	free((*internals)->if_name);
 	rte_free(*internals);
 	return -1;
diff --git a/dpdk/drivers/net/af_xdp/meson.build b/dpdk/drivers/net/af_xdp/meson.build
index 307aa0e388..a9007439fe 100644
--- a/dpdk/drivers/net/af_xdp/meson.build
+++ b/dpdk/drivers/net/af_xdp/meson.build
@@ -3,7 +3,7 @@
 
 sources = files('rte_eth_af_xdp.c')
 
-bpf_dep = dependency('libbpf', required: false)
+bpf_dep = dependency('libbpf', required: false, method: 'pkg-config')
 if not bpf_dep.found()
 	bpf_dep = cc.find_library('bpf', required: false)
 endif
diff --git a/dpdk/drivers/net/af_xdp/rte_eth_af_xdp.c b/dpdk/drivers/net/af_xdp/rte_eth_af_xdp.c
index 2b1245ee4f..ac253b1d81 100644
--- a/dpdk/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/dpdk/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -34,6 +34,7 @@
 #include <rte_log.h>
 #include <rte_memory.h>
 #include <rte_memzone.h>
+#include <rte_mempool.h>
 #include <rte_mbuf.h>
 #include <rte_malloc.h>
 #include <rte_ring.h>
@@ -58,13 +59,6 @@ static int af_xdp_logtype;
 
 #define ETH_AF_XDP_FRAME_SIZE		2048
 #define ETH_AF_XDP_NUM_BUFFERS		4096
-#ifdef XDP_UMEM_UNALIGNED_CHUNK_FLAG
-#define ETH_AF_XDP_MBUF_OVERHEAD	128 /* sizeof(struct rte_mbuf) */
-#define ETH_AF_XDP_DATA_HEADROOM \
-	(ETH_AF_XDP_MBUF_OVERHEAD + RTE_PKTMBUF_HEADROOM)
-#else
-#define ETH_AF_XDP_DATA_HEADROOM	0
-#endif
 #define ETH_AF_XDP_DFLT_NUM_DESCS	XSK_RING_CONS__DEFAULT_NUM_DESCS
 #define ETH_AF_XDP_DFLT_START_QUEUE_IDX	0
 #define ETH_AF_XDP_DFLT_QUEUE_COUNT	1
@@ -171,7 +165,8 @@ reserve_fill_queue_zc(struct xsk_umem_info *umem, uint16_t reserve_size,
 		uint64_t addr;
 
 		fq_addr = xsk_ring_prod__fill_addr(fq, idx++);
-		addr = (uint64_t)bufs[i] - (uint64_t)umem->buffer;
+		addr = (uint64_t)bufs[i] - (uint64_t)umem->buffer -
+				umem->mb_pool->header_size;
 		*fq_addr = addr;
 	}
 
@@ -242,7 +237,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	if (rte_pktmbuf_alloc_bulk(umem->mb_pool, fq_bufs, nb_pkts)) {
 		AF_XDP_LOG(DEBUG,
 			"Failed to get enough buffers for fq.\n");
-		return -1;
+		return 0;
 	}
 
 	rcvd = xsk_ring_cons__peek(rx, nb_pkts, &idx_rx);
@@ -270,8 +265,11 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		addr = xsk_umem__extract_addr(addr);
 
 		bufs[i] = (struct rte_mbuf *)
-				xsk_umem__get_data(umem->buffer, addr);
-		bufs[i]->data_off = offset - sizeof(struct rte_mbuf);
+				xsk_umem__get_data(umem->buffer, addr +
+					umem->mb_pool->header_size);
+		bufs[i]->data_off = offset - sizeof(struct rte_mbuf) -
+			rte_pktmbuf_priv_size(umem->mb_pool) -
+			umem->mb_pool->header_size;
 
 		rte_pktmbuf_pkt_len(bufs[i]) = len;
 		rte_pktmbuf_data_len(bufs[i]) = len;
@@ -307,6 +305,10 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	uint32_t free_thresh = fq->size >> 1;
 	struct rte_mbuf *mbufs[ETH_AF_XDP_RX_BATCH_SIZE];
 
+	if (xsk_prod_nb_free(fq, free_thresh) >= free_thresh)
+		(void)reserve_fill_queue(umem, ETH_AF_XDP_RX_BATCH_SIZE, NULL);
+
+
 	if (unlikely(rte_pktmbuf_alloc_bulk(rxq->mb_pool, mbufs, nb_pkts) != 0))
 		return 0;
 
@@ -320,9 +322,6 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		goto out;
 	}
 
-	if (xsk_prod_nb_free(fq, free_thresh) >= free_thresh)
-		(void)reserve_fill_queue(umem, ETH_AF_XDP_RX_BATCH_SIZE, NULL);
-
 	for (i = 0; i < rcvd; i++) {
 		const struct xdp_desc *desc;
 		uint64_t addr;
@@ -384,7 +383,8 @@ pull_umem_cq(struct xsk_umem_info *umem, int size)
 #if defined(XDP_UMEM_UNALIGNED_CHUNK_FLAG)
 		addr = xsk_umem__extract_addr(addr);
 		rte_pktmbuf_free((struct rte_mbuf *)
-					xsk_umem__get_data(umem->buffer, addr));
+					xsk_umem__get_data(umem->buffer,
+					addr + umem->mb_pool->header_size));
 #else
 		rte_ring_enqueue(umem->buf_ring, (void *)addr);
 #endif
@@ -442,9 +442,11 @@ af_xdp_tx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 			}
 			desc = xsk_ring_prod__tx_desc(&txq->tx, idx_tx);
 			desc->len = mbuf->pkt_len;
-			addr = (uint64_t)mbuf - (uint64_t)umem->buffer;
+			addr = (uint64_t)mbuf - (uint64_t)umem->buffer -
+					umem->mb_pool->header_size;
 			offset = rte_pktmbuf_mtod(mbuf, uint64_t) -
-					(uint64_t)mbuf;
+					(uint64_t)mbuf +
+					umem->mb_pool->header_size;
 			offset = offset << XSK_UNALIGNED_BUF_OFFSET_SHIFT;
 			desc->addr = addr | offset;
 			count++;
@@ -465,9 +467,11 @@ af_xdp_tx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 			desc = xsk_ring_prod__tx_desc(&txq->tx, idx_tx);
 			desc->len = mbuf->pkt_len;
 
-			addr = (uint64_t)local_mbuf - (uint64_t)umem->buffer;
+			addr = (uint64_t)local_mbuf - (uint64_t)umem->buffer -
+					umem->mb_pool->header_size;
 			offset = rte_pktmbuf_mtod(local_mbuf, uint64_t) -
-					(uint64_t)local_mbuf;
+					(uint64_t)local_mbuf +
+					umem->mb_pool->header_size;
 			pkt = xsk_umem__get_data(umem->buffer, addr + offset);
 			offset = offset << XSK_UNALIGNED_BUF_OFFSET_SHIFT;
 			desc->addr = addr | offset;
@@ -480,10 +484,7 @@ af_xdp_tx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		tx_bytes += mbuf->pkt_len;
 	}
 
-#if defined(XDP_USE_NEED_WAKEUP)
-	if (xsk_ring_prod__needs_wakeup(&txq->tx))
-#endif
-		kick_tx(txq);
+	kick_tx(txq);
 
 out:
 	xsk_ring_prod__submit(&txq->tx, count);
@@ -595,7 +596,14 @@ eth_dev_info(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
 	dev_info->max_tx_queues = internals->queue_cnt;
 
 	dev_info->min_mtu = RTE_ETHER_MIN_MTU;
-	dev_info->max_mtu = ETH_AF_XDP_FRAME_SIZE - ETH_AF_XDP_DATA_HEADROOM;
+#if defined(XDP_UMEM_UNALIGNED_CHUNK_FLAG)
+	dev_info->max_mtu = getpagesize() -
+				sizeof(struct rte_mempool_objhdr) -
+				sizeof(struct rte_mbuf) -
+				RTE_PKTMBUF_HEADROOM - XDP_PACKET_HEADROOM;
+#else
+	dev_info->max_mtu = ETH_AF_XDP_FRAME_SIZE - XDP_PACKET_HEADROOM;
+#endif
 
 	dev_info->default_rxportconf.nb_queues = 1;
 	dev_info->default_txportconf.nb_queues = 1;
@@ -678,7 +686,6 @@ static void
 xdp_umem_destroy(struct xsk_umem_info *umem)
 {
 #if defined(XDP_UMEM_UNALIGNED_CHUNK_FLAG)
-	rte_mempool_free(umem->mb_pool);
 	umem->mb_pool = NULL;
 #else
 	rte_memzone_free(umem->mz);
@@ -689,7 +696,6 @@ xdp_umem_destroy(struct xsk_umem_info *umem)
 #endif
 
 	rte_free(umem);
-	umem = NULL;
 }
 
 static void
@@ -737,12 +743,17 @@ eth_link_update(struct rte_eth_dev *dev __rte_unused,
 }
 
 #if defined(XDP_UMEM_UNALIGNED_CHUNK_FLAG)
-static inline uint64_t get_base_addr(struct rte_mempool *mp)
+static inline uintptr_t get_base_addr(struct rte_mempool *mp, uint64_t *align)
 {
 	struct rte_mempool_memhdr *memhdr;
+	uintptr_t memhdr_addr, aligned_addr;
 
 	memhdr = STAILQ_FIRST(&mp->mem_list);
-	return (uint64_t)memhdr->addr & ~(getpagesize() - 1);
+	memhdr_addr = (uintptr_t)memhdr->addr;
+	aligned_addr = memhdr_addr & ~(getpagesize() - 1);
+	*align = memhdr_addr - aligned_addr;
+
+	return aligned_addr;
 }
 
Louis Abel's avatar
Louis Abel committed
22201 22202 22203 22204 22205 22206 22207 22208 22209 22210 22211 22212 22213 22214 22215 22216 22217 22218 22219 22220 22221 22222 22223 22224 22225 22226 22227 22228 22229 22230 22231 22232 22233 22234 22235 22236 22237 22238 22239 22240 22241 22242 22243 22244 22245 22246 22247 22248 22249 22250 22251 22252 22253 22254 22255 22256 22257 22258 22259 22260 22261 22262 22263 22264 22265 22266 22267 22268 22269 22270 22271 22272 22273 22274 22275 22276 22277 22278 22279 22280 22281 22282 22283 22284 22285 22286 22287 22288 22289 22290 22291 22292 22293 22294 22295 22296 22297 22298 22299 22300 22301 22302 22303 22304 22305 22306 22307 22308 22309 22310 22311 22312 22313 22314 22315 22316 22317 22318 22319 22320 22321 22322 22323 22324 22325 22326 22327 22328 22329 22330 22331 22332 22333 22334 22335 22336 22337 22338 22339 22340 22341 22342 22343 22344 22345 22346 22347 22348 22349 22350 22351 22352 22353 22354 22355 22356 22357 22358 22359 22360 22361 22362 22363 22364 22365 22366 22367 22368 22369 22370 22371 22372 22373 22374 22375 22376 22377 22378 22379 22380 22381 22382 22383 22384 22385 22386 22387 22388 22389 22390 22391 22392 22393 22394 22395 22396 22397 22398 22399 22400 22401 22402 22403 22404 22405 22406 22407 22408 22409 22410 22411 22412 22413 22414 22415 22416 22417 22418 22419 22420 22421 22422 22423 22424 22425 22426 22427 22428 22429 22430 22431 22432 22433 22434 22435 22436 22437 22438 22439 22440 22441 22442 22443 22444 22445 22446 22447 22448 22449 22450 22451 22452 22453 22454 22455 22456 22457 22458 22459 22460 22461 22462 22463 22464 22465 22466 22467 22468 22469 22470 22471 22472 22473 22474 22475 22476 22477 22478 22479 22480 22481 22482 22483 22484 22485 22486 22487 22488 22489 22490 22491 22492 22493 22494 22495 22496 22497 22498 22499 22500 22501 22502 22503 22504 22505 22506 22507 22508 22509 22510 22511 22512 22513 22514 22515 22516 22517 22518 22519 22520 22521 22522 22523 22524 22525 22526 22527 22528 22529 22530 22531 22532 22533 22534 22535 22536 22537 22538 22539 22540 22541 22542 22543 22544 22545 22546 22547 22548 22549 22550 22551 22552 22553 22554 22555 22556 22557 22558 22559 22560 22561 22562 22563 22564 22565 22566 22567 22568 22569 22570 22571 22572 22573 22574 22575 22576 22577 22578 22579 22580 22581 22582 22583 22584 22585 22586 22587 22588 22589 22590 22591 22592 22593 22594 22595 22596 22597 22598 22599 22600 22601 22602 22603 22604 22605 22606 22607 22608 22609 22610 22611 22612 22613 22614 22615 22616 22617 22618 22619 22620 22621 22622 22623 22624 22625 22626 22627 22628 22629 22630 22631 22632 22633 22634 22635 22636 22637 22638 22639 22640 22641 22642 22643 22644 22645 22646 22647 22648 22649 22650 22651 22652 22653 22654 22655 22656 22657 22658 22659 22660 22661 22662 22663 22664 22665 22666 22667 22668 22669 22670 22671 22672 22673 22674 22675 22676 22677 22678 22679 22680 22681 22682 22683 22684 22685 22686 22687 22688 22689 22690 22691 22692 22693 22694 22695 22696 22697 22698 22699 22700 22701 22702 22703 22704 22705 22706 22707 22708 22709 22710 22711 22712 22713 22714 22715 22716 22717 22718 22719 22720 22721 22722 22723 22724 22725 22726 22727 22728 22729 22730 22731 22732 22733 22734 22735 22736 22737 22738 22739 22740 22741 22742 22743 22744 22745 22746 22747 22748 22749 22750 22751 22752 22753 22754 22755 22756 22757 22758 22759 22760 22761 22762 22763 22764 22765 22766 22767 22768 22769 22770 22771 22772 22773 22774 22775 22776 22777 22778 22779 22780 22781 22782 22783 22784 22785 22786 22787 22788 22789 22790 22791 22792 22793 22794 22795 22796 22797 22798 22799 22800 22801 22802 22803 22804 22805 22806 22807 22808 22809 22810 22811 22812 22813 22814 22815 22816 22817 22818 22819 22820 22821 22822 22823 22824 22825 22826 22827 22828 22829 22830 22831 22832 22833 22834 22835 22836 22837 22838 22839 22840 22841 22842 22843 22844 22845 22846 22847 22848 22849 22850 22851 22852 22853 22854 22855 22856 22857 22858 22859 22860 22861 22862 22863 22864 22865 22866 22867 22868 22869 22870 22871 22872 22873 22874 22875 22876 22877 22878 22879 22880 22881 22882 22883 22884 22885 22886 22887 22888 22889 22890 22891 22892 22893 22894 22895 22896 22897 22898 22899 22900 22901 22902 22903 22904 22905 22906 22907 22908 22909 22910 22911 22912 22913 22914 22915 22916 22917 22918 22919 22920 22921 22922 22923 22924 22925 22926 22927 22928 22929 22930 22931 22932 22933 22934 22935 22936 22937 22938 22939 22940 22941 22942 22943 22944 22945 22946 22947 22948 22949 22950 22951 22952 22953 22954 22955 22956 22957 22958 22959 22960 22961 22962 22963 22964 22965 22966 22967 22968 22969 22970 22971 22972 22973 22974 22975 22976 22977 22978 22979 22980 22981 22982 22983 22984 22985 22986 22987 22988 22989 22990 22991 22992 22993 22994 22995 22996 22997 22998 22999 23000 23001 23002 23003 23004 23005 23006 23007 23008 23009 23010 23011 23012 23013 23014 23015 23016 23017 23018 23019 23020 23021 23022 23023 23024 23025 23026 23027 23028 23029 23030 23031 23032 23033 23034 23035 23036 23037 23038 23039 23040 23041 23042 23043 23044 23045 23046 23047 23048 23049 23050 23051 23052 23053 23054 23055 23056 23057 23058 23059 23060 23061 23062 23063 23064 23065 23066 23067 23068 23069 23070 23071 23072 23073 23074 23075 23076 23077 23078 23079 23080 23081 23082 23083 23084 23085 23086 23087 23088 23089 23090 23091 23092 23093 23094 23095 23096 23097 23098 23099 23100 23101 23102 23103 23104 23105 23106 23107 23108 23109 23110 23111 23112 23113 23114 23115 23116 23117 23118 23119 23120 23121 23122 23123 23124 23125 23126 23127 23128 23129 23130 23131 23132 23133 23134 23135 23136 23137 23138 23139 23140 23141 23142 23143 23144 23145 23146 23147 23148 23149 23150 23151 23152 23153 23154 23155 23156 23157 23158 23159 23160 23161 23162 23163 23164 23165 23166 23167 23168 23169 23170 23171 23172 23173 23174 23175 23176 23177 23178 23179 23180 23181 23182 23183 23184 23185 23186 23187 23188 23189 23190 23191 23192 23193 23194 23195 23196 23197 23198 23199 23200 23201 23202 23203 23204 23205 23206 23207 23208 23209 23210 23211 23212 23213 23214 23215 23216 23217 23218 23219 23220 23221 23222 23223 23224 23225 23226 23227 23228 23229 23230 23231 23232 23233 23234 23235 23236 23237 23238 23239 23240 23241 23242 23243 23244 23245 23246 23247 23248 23249 23250 23251 23252 23253 23254 23255 23256 23257 23258 23259 23260 23261 23262 23263 23264 23265 23266 23267 23268 23269 23270 23271 23272 23273 23274 23275 23276 23277 23278 23279 23280 23281 23282 23283 23284 23285 23286 23287 23288 23289 23290 23291 23292 23293 23294 23295 23296 23297 23298 23299 23300 23301 23302 23303 23304 23305 23306 23307 23308 23309 23310 23311 23312 23313 23314 23315 23316 23317 23318 23319 23320 23321 23322 23323 23324 23325 23326 23327 23328 23329 23330 23331 23332 23333 23334 23335 23336 23337 23338 23339 23340 23341 23342 23343 23344 23345 23346 23347 23348 23349 23350 23351 23352 23353 23354 23355 23356 23357 23358 23359 23360 23361 23362 23363 23364 23365 23366 23367 23368 23369 23370 23371 23372 23373 23374 23375 23376 23377 23378 23379 23380 23381 23382 23383 23384 23385 23386 23387 23388 23389 23390 23391 23392 23393 23394 23395 23396 23397 23398 23399 23400 23401 23402 23403 23404 23405 23406 23407 23408 23409 23410 23411 23412 23413 23414 23415 23416 23417 23418 23419 23420 23421 23422 23423 23424 23425 23426 23427 23428 23429 23430 23431 23432 23433 23434 23435 23436 23437 23438 23439 23440 23441 23442 23443 23444 23445 23446 23447 23448 23449 23450 23451 23452 23453 23454 23455 23456 23457 23458 23459 23460 23461 23462 23463 23464 23465 23466 23467 23468 23469 23470 23471 23472 23473 23474 23475 23476 23477 23478 23479 23480 23481 23482 23483 23484 23485 23486 23487 23488 23489 23490 23491 23492 23493 23494 23495 23496 23497 23498 23499 23500 23501 23502 23503 23504 23505 23506 23507 23508 23509 23510 23511 23512 23513 23514 23515 23516 23517 23518 23519 23520 23521 23522 23523 23524 23525 23526 23527 23528 23529 23530 23531 23532 23533 23534 23535 23536 23537 23538 23539 23540 23541 23542 23543 23544 23545 23546 23547 23548 23549 23550 23551 23552 23553 23554 23555 23556 23557 23558 23559 23560 23561 23562 23563 23564 23565 23566 23567 23568 23569 23570 23571 23572 23573 23574 23575 23576 23577 23578 23579 23580 23581 23582 23583 23584 23585 23586 23587 23588 23589 23590 23591 23592 23593 23594 23595 23596 23597 23598 23599 23600 23601 23602 23603 23604 23605 23606 23607 23608 23609 23610 23611 23612 23613 23614 23615 23616 23617 23618 23619 23620 23621 23622 23623 23624 23625 23626 23627 23628 23629 23630 23631 23632 23633 23634 23635 23636 23637 23638 23639 23640 23641 23642 23643 23644 23645 23646 23647 23648 23649 23650 23651 23652 23653 23654 23655 23656 23657 23658 23659 23660 23661 23662 23663 23664 23665 23666 23667 23668 23669 23670 23671 23672 23673 23674 23675 23676 23677 23678 23679 23680 23681 23682 23683 23684 23685 23686 23687 23688 23689 23690 23691 23692 23693 23694 23695 23696 23697 23698 23699 23700 23701 23702 23703 23704 23705 23706 23707 23708 23709 23710 23711 23712 23713 23714 23715 23716 23717 23718 23719 23720 23721 23722 23723 23724 23725 23726 23727 23728 23729 23730 23731 23732 23733 23734 23735 23736 23737 23738 23739 23740 23741 23742 23743 23744 23745 23746 23747 23748 23749 23750 23751 23752 23753 23754 23755 23756 23757 23758 23759 23760 23761 23762 23763 23764 23765 23766 23767 23768 23769 23770 23771 23772 23773 23774 23775 23776 23777 23778 23779 23780 23781 23782 23783 23784 23785 23786 23787 23788 23789 23790 23791 23792 23793 23794 23795 23796 23797 23798 23799 23800 23801 23802 23803 23804 23805 23806 23807 23808 23809 23810 23811 23812 23813 23814 23815 23816 23817 23818 23819 23820 23821 23822 23823 23824 23825 23826 23827 23828 23829 23830 23831 23832 23833 23834 23835 23836 23837 23838 23839 23840 23841 23842 23843 23844 23845 23846 23847 23848 23849 23850 23851 23852 23853 23854 23855 23856 23857 23858 23859 23860 23861 23862 23863 23864 23865 23866 23867 23868 23869 23870 23871 23872 23873 23874 23875 23876 23877 23878 23879 23880 23881 23882 23883 23884 23885 23886 23887 23888 23889 23890 23891 23892 23893 23894 23895 23896 23897 23898 23899 23900 23901 23902 23903 23904 23905 23906 23907 23908 23909 23910 23911 23912 23913 23914 23915 23916 23917 23918 23919 23920 23921 23922 23923 23924 23925 23926 23927 23928 23929 23930 23931 23932 23933 23934 23935 23936 23937 23938 23939 23940 23941 23942 23943 23944 23945 23946 23947 23948 23949 23950 23951 23952 23953 23954 23955 23956 23957 23958 23959 23960 23961 23962 23963 23964 23965 23966 23967 23968 23969 23970 23971 23972 23973 23974 23975 23976 23977 23978 23979 23980 23981 23982 23983 23984 23985 23986 23987 23988 23989 23990 23991 23992 23993 23994 23995 23996 23997 23998 23999 24000 24001 24002 24003 24004 24005 24006 24007 24008 24009 24010 24011 24012 24013 24014 24015 24016 24017 24018 24019 24020 24021 24022 24023 24024 24025 24026 24027 24028 24029 24030 24031 24032 24033 24034 24035 24036 24037 24038 24039 24040 24041 24042 24043 24044 24045 24046 24047 24048 24049 24050 24051 24052 24053 24054 24055 24056 24057 24058 24059 24060 24061 24062 24063 24064 24065 24066 24067 24068 24069 24070 24071 24072 24073 24074 24075 24076 24077 24078 24079 24080 24081 24082 24083 24084 24085 24086 24087 24088 24089 24090 24091 24092 24093 24094 24095 24096 24097 24098 24099 24100 24101 24102 24103 24104 24105 24106 24107 24108 24109 24110 24111 24112 24113 24114 24115 24116 24117 24118 24119 24120 24121 24122 24123 24124 24125 24126 24127 24128 24129 24130 24131 24132 24133 24134 24135 24136 24137 24138 24139 24140 24141 24142 24143 24144 24145 24146 24147 24148 24149 24150 24151 24152 24153 24154 24155 24156 24157 24158 24159 24160 24161 24162 24163 24164 24165 24166 24167 24168 24169 24170 24171 24172 24173 24174 24175 24176 24177 24178 24179 24180 24181 24182 24183 24184 24185 24186 24187 24188 24189 24190 24191 24192 24193 24194 24195 24196 24197 24198 24199 24200
 static struct
@@ -757,12 +768,15 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals __rte_unused,
 		.flags = XDP_UMEM_UNALIGNED_CHUNK_FLAG};
 	void *base_addr = NULL;
 	struct rte_mempool *mb_pool = rxq->mb_pool;
+	uint64_t umem_size, align = 0;
 
-	usr_config.frame_size = rte_pktmbuf_data_room_size(mb_pool) +
-					ETH_AF_XDP_MBUF_OVERHEAD +
-					mb_pool->private_data_size;
-	usr_config.frame_headroom = ETH_AF_XDP_DATA_HEADROOM +
-					mb_pool->private_data_size;
+	usr_config.frame_size = rte_mempool_calc_obj_size(mb_pool->elt_size,
+								mb_pool->flags,
+								NULL);
+	usr_config.frame_headroom = mb_pool->header_size +
+					sizeof(struct rte_mbuf) +
+					rte_pktmbuf_priv_size(mb_pool) +
+					RTE_PKTMBUF_HEADROOM;
 
 	umem = rte_zmalloc_socket("umem", sizeof(*umem), 0, rte_socket_id());
 	if (umem == NULL) {
@@ -771,12 +785,11 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals __rte_unused,
 	}
 
 	umem->mb_pool = mb_pool;
-	base_addr = (void *)get_base_addr(mb_pool);
+	base_addr = (void *)get_base_addr(mb_pool, &align);
+	umem_size = mb_pool->populated_size * usr_config.frame_size + align;
 
-	ret = xsk_umem__create(&umem->umem, base_addr,
-			       mb_pool->populated_size * usr_config.frame_size,
-			       &umem->fq, &umem->cq,
-			       &usr_config);
+	ret = xsk_umem__create(&umem->umem, base_addr, umem_size,
+			       &umem->fq, &umem->cq, &usr_config);
 
 	if (ret) {
 		AF_XDP_LOG(ERR, "Failed to create umem");
@@ -795,7 +808,7 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
 		.fill_size = ETH_AF_XDP_DFLT_NUM_DESCS,
 		.comp_size = ETH_AF_XDP_DFLT_NUM_DESCS,
 		.frame_size = ETH_AF_XDP_FRAME_SIZE,
-		.frame_headroom = ETH_AF_XDP_DATA_HEADROOM };
+		.frame_headroom = 0 };
 	char ring_name[RTE_RING_NAMESIZE];
 	char mz_name[RTE_MEMZONE_NAMESIZE];
 	int ret;
@@ -820,8 +833,7 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
 
 	for (i = 0; i < ETH_AF_XDP_NUM_BUFFERS; i++)
 		rte_ring_enqueue(umem->buf_ring,
-				 (void *)(i * ETH_AF_XDP_FRAME_SIZE +
-					  ETH_AF_XDP_DATA_HEADROOM));
+				 (void *)(i * ETH_AF_XDP_FRAME_SIZE));
 
 	snprintf(mz_name, sizeof(mz_name), "af_xdp_umem_%s_%u",
 		       internals->if_name, rxq->xsk_queue_idx);
@@ -930,7 +942,7 @@ eth_rx_queue_setup(struct rte_eth_dev *dev,
 	/* Now get the space available for data in the mbuf */
 	buf_size = rte_pktmbuf_data_room_size(mb_pool) -
 		RTE_PKTMBUF_HEADROOM;
-	data_size = ETH_AF_XDP_FRAME_SIZE - ETH_AF_XDP_DATA_HEADROOM;
+	data_size = ETH_AF_XDP_FRAME_SIZE;
 
 	if (data_size > buf_size) {
 		AF_XDP_LOG(ERR, "%s: %d bytes will not fit in mbuf (%d bytes)\n",
@@ -1103,7 +1115,7 @@ xdp_get_channels_info(const char *if_name, int *max_queues,
 
 	channels.cmd = ETHTOOL_GCHANNELS;
 	ifr.ifr_data = (void *)&channels;
-	strncpy(ifr.ifr_name, if_name, IFNAMSIZ);
+	strlcpy(ifr.ifr_name, if_name, IFNAMSIZ);
 	ret = ioctl(fd, SIOCETHTOOL, &ifr);
 	if (ret) {
 		if (errno == EOPNOTSUPP) {
diff --git a/dpdk/drivers/net/atlantic/rte_pmd_atlantic.h b/dpdk/drivers/net/atlantic/rte_pmd_atlantic.h
index c0208569b6..0100fc16e5 100644
--- a/dpdk/drivers/net/atlantic/rte_pmd_atlantic.h
+++ b/dpdk/drivers/net/atlantic/rte_pmd_atlantic.h
@@ -11,7 +11,7 @@
 #ifndef _PMD_ATLANTIC_H_
 #define _PMD_ATLANTIC_H_
 
-#include <rte_ethdev_driver.h>
+#include <rte_compat.h>
 
 /**
  * @warning
diff --git a/dpdk/drivers/net/avp/avp_ethdev.c b/dpdk/drivers/net/avp/avp_ethdev.c
index cd747b6beb..8de05ec16f 100644
--- a/dpdk/drivers/net/avp/avp_ethdev.c
+++ b/dpdk/drivers/net/avp/avp_ethdev.c
@@ -269,7 +269,7 @@ avp_dev_process_request(struct avp_dev *avp, struct rte_avp_request *request)
 			break;
 		}
 
-		if ((count < 1) && (retry == 0)) {
+		if (retry == 0) {
 			PMD_DRV_LOG(ERR, "Timeout while waiting for a response for %u\n",
 				    request->req_id);
 			ret = -ETIME;
@@ -1694,7 +1694,7 @@ avp_xmit_scattered_pkts(void *tx_queue,
 			uint16_t nb_pkts)
 {
 	struct rte_avp_desc *avp_bufs[(AVP_MAX_TX_BURST *
-				       RTE_AVP_MAX_MBUF_SEGMENTS)];
+				       RTE_AVP_MAX_MBUF_SEGMENTS)] = {};
 	struct avp_queue *txq = (struct avp_queue *)tx_queue;
 	struct rte_avp_desc *tx_bufs[AVP_MAX_TX_BURST];
 	struct avp_dev *avp = txq->avp;
diff --git a/dpdk/drivers/net/bnx2x/bnx2x.c b/dpdk/drivers/net/bnx2x/bnx2x.c
index ed31335ac5..0b4030e2b9 100644
--- a/dpdk/drivers/net/bnx2x/bnx2x.c
+++ b/dpdk/drivers/net/bnx2x/bnx2x.c
@@ -1167,6 +1167,10 @@ static int bnx2x_has_rx_work(struct bnx2x_fastpath *fp)
 	if (unlikely((rx_cq_cons_sb & MAX_RCQ_ENTRIES(rxq)) ==
 		     MAX_RCQ_ENTRIES(rxq)))
 		rx_cq_cons_sb++;
+
+	PMD_RX_LOG(DEBUG, "hw CQ cons = %d, sw CQ cons = %d",
+		   rx_cq_cons_sb, rxq->rx_cq_head);
+
 	return rxq->rx_cq_head != rx_cq_cons_sb;
 }
 
@@ -1249,9 +1253,12 @@ static uint8_t bnx2x_rxeof(struct bnx2x_softc *sc, struct bnx2x_fastpath *fp)
 	uint16_t bd_cons, bd_prod, bd_prod_fw, comp_ring_cons;
 	uint16_t hw_cq_cons, sw_cq_cons, sw_cq_prod;
 
+	rte_spinlock_lock(&(fp)->rx_mtx);
+
 	rxq = sc->rx_queues[fp->index];
 	if (!rxq) {
 		PMD_RX_LOG(ERR, "RX queue %d is NULL", fp->index);
+		rte_spinlock_unlock(&(fp)->rx_mtx);
 		return 0;
 	}
 
@@ -1321,9 +1328,14 @@ static uint8_t bnx2x_rxeof(struct bnx2x_softc *sc, struct bnx2x_fastpath *fp)
 	rxq->rx_cq_head = sw_cq_cons;
 	rxq->rx_cq_tail = sw_cq_prod;
 
+	PMD_RX_LOG(DEBUG, "BD prod = %d, sw CQ prod = %d",
+		   bd_prod_fw, sw_cq_prod);
+
 	/* Update producers */
 	bnx2x_update_rx_prod(sc, fp, bd_prod_fw, sw_cq_prod);
 
+	rte_spinlock_unlock(&(fp)->rx_mtx);
+
 	return sw_cq_cons != hw_cq_cons;
 }
 
@@ -4577,10 +4589,10 @@ static void bnx2x_handle_fp_tq(struct bnx2x_fastpath *fp)
 			bnx2x_handle_fp_tq(fp);
 			return;
 		}
+		/* We have completed slow path completion, clear the flag */
+		rte_atomic32_set(&sc->scan_fp, 0);
 	}
 
-	/* Assuming we have completed slow path completion, clear the flag */
-	rte_atomic32_set(&sc->scan_fp, 0);
 	bnx2x_ack_sb(sc, fp->igu_sb_id, USTORM_ID,
 		   le16toh(fp->fp_hc_idx), IGU_INT_ENABLE, 1);
 }
diff --git a/dpdk/drivers/net/bnx2x/bnx2x.h b/dpdk/drivers/net/bnx2x/bnx2x.h
index 3383c76759..1dbc98197d 100644
--- a/dpdk/drivers/net/bnx2x/bnx2x.h
+++ b/dpdk/drivers/net/bnx2x/bnx2x.h
@@ -360,6 +360,9 @@ struct bnx2x_fastpath {
 	/* pointer back to parent structure */
 	struct bnx2x_softc *sc;
 
+	/* Used to synchronize fastpath Rx access */
+	rte_spinlock_t rx_mtx;
+
 	/* status block */
 	struct bnx2x_dma                 sb_dma;
 	union bnx2x_host_hc_status_block status_block;
diff --git a/dpdk/drivers/net/bnx2x/bnx2x_ethdev.c b/dpdk/drivers/net/bnx2x/bnx2x_ethdev.c
index 20b045ff87..8a1a3fc7f9 100644
--- a/dpdk/drivers/net/bnx2x/bnx2x_ethdev.c
+++ b/dpdk/drivers/net/bnx2x/bnx2x_ethdev.c
@@ -20,6 +20,7 @@ int bnx2x_logtype_driver;
  * The set of PCI devices this driver supports
  */
 #define BROADCOM_PCI_VENDOR_ID 0x14E4
+#define QLOGIC_PCI_VENDOR_ID 0x1077
 static const struct rte_pci_id pci_id_bnx2x_map[] = {
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57800) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57711) },
@@ -27,11 +28,13 @@ static const struct rte_pci_id pci_id_bnx2x_map[] = {
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57811) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57840_OBS) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57840_4_10) },
+	{ RTE_PCI_DEVICE(QLOGIC_PCI_VENDOR_ID, CHIP_NUM_57840_4_10) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57840_2_20) },
 #ifdef RTE_LIBRTE_BNX2X_MF_SUPPORT
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57810_MF) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57811_MF) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57840_MF) },
+	{ RTE_PCI_DEVICE(QLOGIC_PCI_VENDOR_ID, CHIP_NUM_57840_MF) },
 #endif
 	{ .vendor_id = 0, }
 };
@@ -41,6 +44,7 @@ static const struct rte_pci_id pci_id_bnx2xvf_map[] = {
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57810_VF) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57811_VF) },
 	{ RTE_PCI_DEVICE(BROADCOM_PCI_VENDOR_ID, CHIP_NUM_57840_VF) },
+	{ RTE_PCI_DEVICE(QLOGIC_PCI_VENDOR_ID, CHIP_NUM_57840_VF) },
 	{ .vendor_id = 0, }
 };
 
@@ -598,6 +602,11 @@ bnx2x_common_dev_init(struct rte_eth_dev *eth_dev, int is_vf)
 
 	eth_dev->dev_ops = is_vf ? &bnx2xvf_eth_dev_ops : &bnx2x_eth_dev_ops;
 
+	if (rte_eal_process_type() != RTE_PROC_PRIMARY) {
+		PMD_DRV_LOG(ERR, sc, "Skipping device init from secondary process");
+		return 0;
+	}
+
 	rte_eth_copy_pci_info(eth_dev, pci_dev);
 
 	sc->pcie_bus    = pci_dev->addr.bus;
diff --git a/dpdk/drivers/net/bnx2x/bnx2x_rxtx.c b/dpdk/drivers/net/bnx2x/bnx2x_rxtx.c
index ae97dfee36..e201b68db8 100644
--- a/dpdk/drivers/net/bnx2x/bnx2x_rxtx.c
+++ b/dpdk/drivers/net/bnx2x/bnx2x_rxtx.c
@@ -346,6 +346,8 @@ bnx2x_recv_pkts(void *p_rxq, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 	uint16_t len, pad;
 	struct rte_mbuf *rx_mb = NULL;
 
+	rte_spinlock_lock(&(fp)->rx_mtx);
+
 	hw_cq_cons = le16toh(*fp->rx_cq_cons_sb);
 	if ((hw_cq_cons & USABLE_RCQ_ENTRIES_PER_PAGE) ==
 			USABLE_RCQ_ENTRIES_PER_PAGE) {
@@ -357,8 +359,10 @@ bnx2x_recv_pkts(void *p_rxq, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 	sw_cq_cons = rxq->rx_cq_head;
 	sw_cq_prod = rxq->rx_cq_tail;
 
-	if (sw_cq_cons == hw_cq_cons)
+	if (sw_cq_cons == hw_cq_cons) {
+		rte_spinlock_unlock(&(fp)->rx_mtx);
 		return 0;
+	}
 
 	while (nb_rx < nb_pkts && sw_cq_cons != hw_cq_cons) {
 
@@ -414,7 +418,7 @@ bnx2x_recv_pkts(void *p_rxq, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 		 */
 		if (cqe_fp->pars_flags.flags & PARSING_FLAGS_VLAN) {
 			rx_mb->vlan_tci = cqe_fp->vlan_tag;
-			rx_mb->ol_flags |= PKT_RX_VLAN;
+			rx_mb->ol_flags |= PKT_RX_VLAN | PKT_RX_VLAN_STRIPPED;
 		}
 
 		rx_pkts[nb_rx] = rx_mb;
@@ -439,6 +443,8 @@ bnx2x_recv_pkts(void *p_rxq, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 
 	bnx2x_upd_rx_prod_fast(sc, fp, bd_prod, sw_cq_prod);
 
+	rte_spinlock_unlock(&(fp)->rx_mtx);
+
 	return nb_rx;
 }
 
diff --git a/dpdk/drivers/net/bnx2x/meson.build b/dpdk/drivers/net/bnx2x/meson.build
index 678708905e..f9749d3132 100644
--- a/dpdk/drivers/net/bnx2x/meson.build
+++ b/dpdk/drivers/net/bnx2x/meson.build
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2018 Intel Corporation
 
-dep = dependency('zlib', required: false)
+dep = dependency('zlib', required: false, method: 'pkg-config')
 build = dep.found()
 reason = 'missing dependency, "zlib"'
 ext_deps += dep
diff --git a/dpdk/drivers/net/bnxt/bnxt.h b/dpdk/drivers/net/bnxt/bnxt.h
index e259c8239d..0a0ecaafa8 100644
--- a/dpdk/drivers/net/bnxt/bnxt.h
+++ b/dpdk/drivers/net/bnxt/bnxt.h
@@ -117,6 +117,14 @@
 #define BNXT_NUM_ASYNC_CPR(bp) 1
 #endif
 
+/* In FreeBSD OS, nic_uio driver does not support interrupts */
+#ifdef RTE_EXEC_ENV_FREEBSD
+#ifdef BNXT_NUM_ASYNC_CPR
+#undef BNXT_NUM_ASYNC_CPR
+#endif
+#define BNXT_NUM_ASYNC_CPR(bp)	0
+#endif
+
 #define BNXT_MISC_VEC_ID               RTE_INTR_VEC_ZERO_OFFSET
 #define BNXT_RX_VEC_START              RTE_INTR_VEC_RXTX_OFFSET
 
@@ -170,13 +178,6 @@ struct bnxt_led_cfg {
 #define BNXT_LED_DFLT_ENABLES(x)                        \
 	rte_cpu_to_le_32(BNXT_LED_DFLT_ENA << (BNXT_LED_DFLT_ENA_SHIFT * (x)))
 
-enum bnxt_hw_context {
-	HW_CONTEXT_NONE     = 0,
-	HW_CONTEXT_IS_RSS   = 1,
-	HW_CONTEXT_IS_COS   = 2,
-	HW_CONTEXT_IS_LB    = 3,
-};
-
 struct bnxt_vlan_table_entry {
 	uint16_t		tpid;
 	uint16_t		vid;
@@ -231,9 +232,10 @@ struct bnxt_pf_info {
 	uint8_t			evb_mode;
 };
 
-/* Max wait time is 10 * 100ms = 1s */
-#define BNXT_LINK_WAIT_CNT	10
-#define BNXT_LINK_WAIT_INTERVAL	100
+/* Max wait time for link up is 10s and link down is 500ms */
+#define BNXT_MAX_LINK_WAIT_CNT	200
+#define BNXT_MIN_LINK_WAIT_CNT	10
+#define BNXT_LINK_WAIT_INTERVAL	50
 struct bnxt_link_info {
 	uint32_t		phy_flags;
 	uint8_t			mac_type;
@@ -342,7 +344,7 @@ struct bnxt_coal {
 #define DBR_TYPE_NQ				(0xaULL << 60)
 #define DBR_TYPE_NQ_ARM				(0xbULL << 60)
 
-#define BNXT_RSS_TBL_SIZE_THOR		512
+#define BNXT_RSS_TBL_SIZE_THOR		512U
 #define BNXT_RSS_ENTRIES_PER_CTX_THOR	64
 #define BNXT_MAX_RSS_CTXTS_THOR \
 	(BNXT_RSS_TBL_SIZE_THOR / BNXT_RSS_ENTRIES_PER_CTX_THOR)
@@ -461,6 +463,11 @@ struct bnxt_error_recovery_info {
 	uint32_t        last_reset_counter;
 };
 
+/* Frequency for the FUNC_DRV_IF_CHANGE retry in milliseconds */
+#define BNXT_IF_CHANGE_RETRY_INTERVAL	50
+/* Maximum retry count for FUNC_DRV_IF_CHANGE */
+#define BNXT_IF_CHANGE_RETRY_COUNT	40
+
 /* address space location of register */
 #define BNXT_FW_STATUS_REG_TYPE_MASK	3
 /* register is located in PCIe config space */
@@ -485,7 +492,6 @@ struct bnxt {
 	void				*bar0;
 
 	struct rte_eth_dev		*eth_dev;
-	struct rte_eth_rss_conf		rss_conf;
 	struct rte_pci_device		*pdev;
 	void				*doorbell_base;
 
@@ -507,19 +513,17 @@ struct bnxt {
 #define BNXT_FLAG_STINGRAY		BIT(14)
 #define BNXT_FLAG_FW_RESET		BIT(15)
 #define BNXT_FLAG_FATAL_ERROR		BIT(16)
-#define BNXT_FLAG_FW_CAP_IF_CHANGE		BIT(17)
-#define BNXT_FLAG_IF_CHANGE_HOT_FW_RESET_DONE	BIT(18)
-#define BNXT_FLAG_FW_CAP_ERROR_RECOVERY		BIT(19)
-#define BNXT_FLAG_FW_HEALTH_CHECK_SCHEDULED	BIT(20)
-#define BNXT_FLAG_FW_CAP_ERR_RECOVER_RELOAD	BIT(21)
-#define BNXT_FLAG_EXT_STATS_SUPPORTED		BIT(22)
-#define BNXT_FLAG_NEW_RM			BIT(23)
-#define BNXT_FLAG_INIT_DONE			BIT(24)
-#define BNXT_FLAG_FW_CAP_ONE_STEP_TX_TS		BIT(25)
-#define BNXT_FLAG_ADV_FLOW_MGMT			BIT(26)
+#define BNXT_FLAG_IF_CHANGE_HOT_FW_RESET_DONE	BIT(17)
+#define BNXT_FLAG_FW_HEALTH_CHECK_SCHEDULED	BIT(18)
+#define BNXT_FLAG_EXT_STATS_SUPPORTED		BIT(19)
+#define BNXT_FLAG_NEW_RM			BIT(20)
+#define BNXT_FLAG_FW_CAP_ONE_STEP_TX_TS		BIT(22)
+#define BNXT_FLAG_ADV_FLOW_MGMT			BIT(23)
+#define BNXT_FLAG_NPAR_PF                      BIT(24)
+#define BNXT_FLAG_DFLT_MAC_SET			BIT(26)
 #define BNXT_PF(bp)		(!((bp)->flags & BNXT_FLAG_VF))
 #define BNXT_VF(bp)		((bp)->flags & BNXT_FLAG_VF)
-#define BNXT_NPAR(bp)		((bp)->port_partition_type)
+#define BNXT_NPAR(bp)		((bp)->flags & BNXT_FLAG_NPAR_PF)
 #define BNXT_MH(bp)             ((bp)->flags & BNXT_FLAG_MULTI_HOST)
 #define BNXT_SINGLE_PF(bp)      (BNXT_PF(bp) && !BNXT_NPAR(bp) && !BNXT_MH(bp))
 #define BNXT_USE_CHIMP_MB	0 //For non-CFA commands, everything uses Chimp.
@@ -529,9 +533,14 @@ struct bnxt {
 #define BNXT_STINGRAY(bp)	((bp)->flags & BNXT_FLAG_STINGRAY)
 #define BNXT_HAS_NQ(bp)		BNXT_CHIP_THOR(bp)
 #define BNXT_HAS_RING_GRPS(bp)	(!BNXT_CHIP_THOR(bp))
+#define BNXT_HAS_DFLT_MAC_SET(bp)      ((bp)->flags & BNXT_FLAG_DFLT_MAC_SET)
+
+	uint32_t		fw_cap;
+#define BNXT_FW_CAP_HOT_RESET		BIT(0)
+#define BNXT_FW_CAP_IF_CHANGE		BIT(1)
+#define BNXT_FW_CAP_ERROR_RECOVERY	BIT(2)
+#define BNXT_FW_CAP_ERR_RECOVER_RELOAD	BIT(3)
 
-	uint32_t		flow_flags;
-#define BNXT_FLOW_FLAG_L2_HDR_SRC_FILTER_EN	BIT(0)
 	pthread_mutex_t         flow_lock;
 
 	uint32_t		vnic_cap_flags;
@@ -584,12 +593,15 @@ struct bnxt {
 	rte_iova_t			hwrm_short_cmd_req_dma_addr;
 	rte_spinlock_t			hwrm_lock;
 	pthread_mutex_t			def_cp_lock;
+	pthread_mutex_t			health_check_lock;
 	uint16_t			max_req_len;
 	uint16_t			max_resp_len;
 	uint16_t                        hwrm_max_ext_req_len;
 
-	 /* default command timeout value of 50ms */
-#define HWRM_CMD_TIMEOUT		50000
+	 /* default command timeout value of 500ms */
+#define DFLT_HWRM_CMD_TIMEOUT		500000
+	 /* short command timeout value of 50ms */
+#define SHORT_HWRM_CMD_TIMEOUT		50000
 	/* default HWRM request timeout value */
 	uint32_t			hwrm_cmd_timeout;
 
@@ -603,18 +615,11 @@ struct bnxt {
 	uint8_t                 max_q;
 
 	uint16_t		fw_fid;
-	uint8_t			dflt_mac_addr[RTE_ETHER_ADDR_LEN];
 	uint16_t		max_rsscos_ctx;
 	uint16_t		max_cp_rings;
 	uint16_t		max_tx_rings;
 	uint16_t		max_rx_rings;
 #define MAX_STINGRAY_RINGS		128U
-#define BNXT_MAX_RINGS(bp) \
-	(BNXT_STINGRAY(bp) ? RTE_MIN(RTE_MIN(bp->max_rx_rings, \
-					     MAX_STINGRAY_RINGS), \
-				     bp->max_stat_ctx) : \
-				RTE_MIN(bp->max_rx_rings, bp->max_stat_ctx))
-
 	uint16_t		max_nq_rings;
 	uint16_t		max_l2_ctx;
 	uint16_t		max_rx_em_flows;
@@ -628,8 +633,6 @@ struct bnxt {
 #define BNXT_OUTER_TPID_BD_SHFT	16
 	uint32_t		outer_tpid_bd;
 	struct bnxt_pf_info	pf;
-	uint8_t			port_partition_type;
-	uint8_t			dev_stopped;
 	uint8_t			vxlan_port_cnt;
 	uint8_t			geneve_port_cnt;
 	uint16_t		vxlan_port;
@@ -652,8 +655,37 @@ struct bnxt {
 	struct bnxt_error_recovery_info *recovery_info;
 };
 
+static
+inline uint16_t bnxt_max_rings(struct bnxt *bp)
+{
+	uint16_t max_tx_rings = bp->max_tx_rings;
+	uint16_t max_rx_rings = bp->max_rx_rings;
+	uint16_t max_cp_rings = bp->max_cp_rings;
+	uint16_t max_rings;
+
+	/* For the sake of symmetry:
+	 * max Tx rings == max Rx rings, one stat ctx for each.
+	 */
+	if (BNXT_STINGRAY(bp)) {
+		max_rx_rings = RTE_MIN(RTE_MIN(max_rx_rings / 2U,
+					       MAX_STINGRAY_RINGS),
+				       bp->max_stat_ctx / 2U);
+	} else {
+		max_rx_rings = RTE_MIN(max_rx_rings / 2U,
+				       bp->max_stat_ctx / 2U);
+	}
+
+	max_tx_rings = RTE_MIN(max_tx_rings, max_rx_rings);
+	if (max_cp_rings > BNXT_NUM_ASYNC_CPR(bp))
+		max_cp_rings -= BNXT_NUM_ASYNC_CPR(bp);
+	max_rings = RTE_MIN(max_cp_rings / 2U, max_tx_rings);
+
+	return max_rings;
+}
+
 int bnxt_mtu_set_op(struct rte_eth_dev *eth_dev, uint16_t new_mtu);
-int bnxt_link_update_op(struct rte_eth_dev *eth_dev, int wait_to_complete);
+int bnxt_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete,
+		     bool exp_link_status);
 int bnxt_rcv_msg_from_vf(struct bnxt *bp, uint16_t vf_id, void *msg);
 int is_bnxt_in_error(struct bnxt *bp);
 uint16_t bnxt_rss_ctxts(const struct bnxt *bp);
@@ -664,6 +696,13 @@ void bnxt_schedule_fw_health_check(struct bnxt *bp);
 
 bool is_bnxt_supported(struct rte_eth_dev *dev);
 bool bnxt_stratus_device(struct bnxt *bp);
+int bnxt_link_update_op(struct rte_eth_dev *eth_dev,
+			int wait_to_complete);
+uint16_t bnxt_dummy_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
+			      uint16_t nb_pkts);
+uint16_t bnxt_dummy_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,
+			      uint16_t nb_pkts);
+
 extern const struct rte_flow_ops bnxt_flow_ops;
 #define bnxt_acquire_flow_lock(bp) \
 	pthread_mutex_lock(&(bp)->flow_lock)
@@ -671,11 +710,23 @@ extern const struct rte_flow_ops bnxt_flow_ops;
 #define bnxt_release_flow_lock(bp) \
 	pthread_mutex_unlock(&(bp)->flow_lock)
 
+#define BNXT_VALID_VNIC_OR_RET(bp, vnic_id) do { \
+	if ((vnic_id) >= (bp)->max_vnics) { \
+		rte_flow_error_set(error, \
+				EINVAL, \
+				RTE_FLOW_ERROR_TYPE_ATTR_GROUP, \
+				NULL, \
+				"Group id is invalid!"); \
+		rc = -rte_errno; \
+		goto ret; \
+	} \
+} while (0)
+
 extern int bnxt_logtype_driver;
 #define PMD_DRV_LOG_RAW(level, fmt, args...) \
 	rte_log(RTE_LOG_ ## level, bnxt_logtype_driver, "%s(): " fmt, \
 		__func__, ## args)
 
 #define PMD_DRV_LOG(level, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, fmt, ## args)
+	  PMD_DRV_LOG_RAW(level, fmt, ## args)
 #endif
diff --git a/dpdk/drivers/net/bnxt/bnxt_cpr.c b/dpdk/drivers/net/bnxt/bnxt_cpr.c
index e6f30fecbf..26c7dae88f 100644
--- a/dpdk/drivers/net/bnxt/bnxt_cpr.c
+++ b/dpdk/drivers/net/bnxt/bnxt_cpr.c
@@ -21,7 +21,7 @@ void bnxt_wait_for_device_shutdown(struct bnxt *bp)
 	 * the SHUTDOWN bit in health register
 	 */
 	if (!(bp->recovery_info &&
-	      (bp->flags & BNXT_FLAG_FW_CAP_ERR_RECOVER_RELOAD)))
+	      (bp->fw_cap & BNXT_FW_CAP_ERR_RECOVER_RELOAD)))
 		return;
 
 	/* Driver has to wait for fw_reset_max_msecs or shutdown bit which comes
@@ -76,6 +76,18 @@ void bnxt_handle_async_event(struct bnxt *bp,
 		PMD_DRV_LOG(INFO, "Port conn async event\n");
 		break;
 	case HWRM_ASYNC_EVENT_CMPL_EVENT_ID_RESET_NOTIFY:
+		/*
+		 * Avoid any rx/tx packet processing during firmware reset
+		 * operation.
+		 */
+		bnxt_stop_rxtx(bp);
+
+		/* Ignore reset notify async events when stopping the port */
+		if (!bp->eth_dev->data->dev_started) {
+			bp->flags |= BNXT_FLAG_FATAL_ERROR;
+			return;
+		}
+
 		event_data = rte_le_to_cpu_32(async_cmp->event_data1);
 		/* timestamp_lo/hi values are in units of 100ms */
 		bp->fw_reset_max_msecs = async_cmp->timestamp_hi ?
@@ -276,3 +288,9 @@ bool bnxt_is_recovery_enabled(struct bnxt *bp)
 
 	return false;
 }
+
+void bnxt_stop_rxtx(struct bnxt *bp)
+{
+	bp->eth_dev->rx_pkt_burst = &bnxt_dummy_recv_pkts;
+	bp->eth_dev->tx_pkt_burst = &bnxt_dummy_xmit_pkts;
+}
diff --git a/dpdk/drivers/net/bnxt/bnxt_cpr.h b/dpdk/drivers/net/bnxt/bnxt_cpr.h
index c2880783f6..ff9697f4c8 100644
--- a/dpdk/drivers/net/bnxt/bnxt_cpr.h
+++ b/dpdk/drivers/net/bnxt/bnxt_cpr.h
@@ -64,9 +64,9 @@ struct bnxt_db_info;
 				(cons));				\
 } while (0)
 #define B_CP_DIS_DB(cpr, raw_cons)					\
-	rte_write32((DB_CP_FLAGS |					\
-		    RING_CMP(((cpr)->cp_ring_struct), raw_cons)),	\
-		    ((cpr)->cp_db.doorbell))
+	rte_write32_relaxed((DB_CP_FLAGS |				\
+			    RING_CMP(((cpr)->cp_ring_struct), raw_cons)), \
+			    ((cpr)->cp_db.doorbell))
 
 #define B_CP_DB(cpr, raw_cons, ring_mask)				\
 	rte_write32((DB_CP_FLAGS |					\
@@ -126,4 +126,5 @@ void bnxt_wait_for_device_shutdown(struct bnxt *bp);
 bool bnxt_is_recovery_enabled(struct bnxt *bp);
 bool bnxt_is_master_func(struct bnxt *bp);
 
+void bnxt_stop_rxtx(struct bnxt *bp);
 #endif
diff --git a/dpdk/drivers/net/bnxt/bnxt_ethdev.c b/dpdk/drivers/net/bnxt/bnxt_ethdev.c
index 41848f36f8..06843d8ddb 100644
--- a/dpdk/drivers/net/bnxt/bnxt_ethdev.c
+++ b/dpdk/drivers/net/bnxt/bnxt_ethdev.c
@@ -119,6 +119,7 @@ static const struct rte_pci_id bnxt_pci_id_map[] = {
 				     DEV_RX_OFFLOAD_UDP_CKSUM | \
 				     DEV_RX_OFFLOAD_TCP_CKSUM | \
 				     DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM | \
+				     DEV_RX_OFFLOAD_OUTER_UDP_CKSUM | \
 				     DEV_RX_OFFLOAD_JUMBO_FRAME | \
 				     DEV_RX_OFFLOAD_KEEP_CRC | \
 				     DEV_RX_OFFLOAD_VLAN_EXTEND | \
@@ -132,6 +133,8 @@ static int bnxt_dev_uninit(struct rte_eth_dev *eth_dev);
 static int bnxt_init_resources(struct bnxt *bp, bool reconfig_dev);
 static int bnxt_uninit_resources(struct bnxt *bp, bool reconfig_dev);
 static void bnxt_cancel_fw_health_check(struct bnxt *bp);
+static int bnxt_restore_vlan_filters(struct bnxt *bp);
+static void bnxt_dev_recover(void *arg);
 
 int is_bnxt_in_error(struct bnxt *bp)
 {
@@ -151,12 +154,15 @@ int is_bnxt_in_error(struct bnxt *bp)
 
 uint16_t bnxt_rss_ctxts(const struct bnxt *bp)
 {
+	unsigned int num_rss_rings = RTE_MIN(bp->rx_nr_rings,
+					     BNXT_RSS_TBL_SIZE_THOR);
+
 	if (!BNXT_CHIP_THOR(bp))
 		return 1;
 
-	return RTE_ALIGN_MUL_CEIL(bp->rx_nr_rings,
+	return RTE_ALIGN_MUL_CEIL(num_rss_rings,
 				  BNXT_RSS_ENTRIES_PER_CTX_THOR) /
-				    BNXT_RSS_ENTRIES_PER_CTX_THOR;
+				  BNXT_RSS_ENTRIES_PER_CTX_THOR;
 }
 
 static uint16_t  bnxt_rss_hash_tbl_size(const struct bnxt *bp)
@@ -228,14 +234,109 @@ static int bnxt_alloc_mem(struct bnxt *bp, bool reconfig)
 	return rc;
 }
 
-static int bnxt_init_chip(struct bnxt *bp)
+static int bnxt_setup_one_vnic(struct bnxt *bp, uint16_t vnic_id)
 {
+	struct rte_eth_conf *dev_conf = &bp->eth_dev->data->dev_conf;
+	struct bnxt_vnic_info *vnic = &bp->vnic_info[vnic_id];
+	uint64_t rx_offloads = dev_conf->rxmode.offloads;
 	struct bnxt_rx_queue *rxq;
+	unsigned int j;
+	int rc;
+
+	rc = bnxt_vnic_grp_alloc(bp, vnic);
+	if (rc)
+		goto err_out;
+
+	PMD_DRV_LOG(DEBUG, "vnic[%d] = %p vnic->fw_grp_ids = %p\n",
+		    vnic_id, vnic, vnic->fw_grp_ids);
+
+	rc = bnxt_hwrm_vnic_alloc(bp, vnic);
+	if (rc)
+		goto err_out;
+
+	/* Alloc RSS context only if RSS mode is enabled */
+	if (dev_conf->rxmode.mq_mode & ETH_MQ_RX_RSS) {
+		int j, nr_ctxs = bnxt_rss_ctxts(bp);
+
+		if (bp->rx_nr_rings > BNXT_RSS_TBL_SIZE_THOR) {
+			PMD_DRV_LOG(ERR, "RxQ cnt %d > reta_size %d\n",
+				    bp->rx_nr_rings, BNXT_RSS_TBL_SIZE_THOR);
+			PMD_DRV_LOG(ERR,
+				    "Only queues 0-%d will be in RSS table\n",
+				    BNXT_RSS_TBL_SIZE_THOR - 1);
+		}
+
+		rc = 0;
+		for (j = 0; j < nr_ctxs; j++) {
+			rc = bnxt_hwrm_vnic_ctx_alloc(bp, vnic, j);
+			if (rc)
+				break;
+		}
+		if (rc) {
+			PMD_DRV_LOG(ERR,
+				    "HWRM vnic %d ctx %d alloc failure rc: %x\n",
+				    vnic_id, j, rc);
+			goto err_out;
+		}
+		vnic->num_lb_ctxts = nr_ctxs;
+	}
+
+	/*
+	 * Firmware sets pf pair in default vnic cfg. If the VLAN strip
+	 * setting is not available at this time, it will not be
+	 * configured correctly in the CFA.
+	 */
+	if (rx_offloads & DEV_RX_OFFLOAD_VLAN_STRIP)
+		vnic->vlan_strip = true;
+	else
+		vnic->vlan_strip = false;
+
+	rc = bnxt_hwrm_vnic_cfg(bp, vnic);
+	if (rc)
+		goto err_out;
+
+	rc = bnxt_set_hwrm_vnic_filters(bp, vnic);
+	if (rc)
+		goto err_out;
+
+	for (j = 0; j < bp->rx_num_qs_per_vnic; j++) {
+		rxq = bp->eth_dev->data->rx_queues[j];
+
+		PMD_DRV_LOG(DEBUG,
+			    "rxq[%d]->vnic=%p vnic->fw_grp_ids=%p\n",
+			    j, rxq->vnic, rxq->vnic->fw_grp_ids);
+
+		if (BNXT_HAS_RING_GRPS(bp) && rxq->rx_deferred_start)
+			rxq->vnic->fw_grp_ids[j] = INVALID_HW_RING_ID;
+		else
+			vnic->rx_queue_cnt++;
+	}
+
+	PMD_DRV_LOG(DEBUG, "vnic->rx_queue_cnt = %d\n", vnic->rx_queue_cnt);
+
+	rc = bnxt_vnic_rss_configure(bp, vnic);
+	if (rc)
+		goto err_out;
+
+	bnxt_hwrm_vnic_plcmode_cfg(bp, vnic);
+
+	if (rx_offloads & DEV_RX_OFFLOAD_TCP_LRO)
+		bnxt_hwrm_vnic_tpa_cfg(bp, vnic, 1);
+	else
+		bnxt_hwrm_vnic_tpa_cfg(bp, vnic, 0);
+
+	return 0;
+err_out:
+	PMD_DRV_LOG(ERR, "HWRM vnic %d cfg failure rc: %x\n",
+		    vnic_id, rc);
+	return rc;
+}
+
+static int bnxt_init_chip(struct bnxt *bp)
+{
 	struct rte_eth_link new;
 	struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(bp->eth_dev);
-	struct rte_eth_conf *dev_conf = &bp->eth_dev->data->dev_conf;
 	struct rte_intr_handle *intr_handle = &pci_dev->intr_handle;
-	uint64_t rx_offloads = dev_conf->rxmode.offloads;
 	uint32_t intr_vector = 0;
 	uint32_t queue_id, base = BNXT_MISC_VEC_ID;
 	uint32_t vec = BNXT_MISC_VEC_ID;
@@ -303,93 +404,11 @@ static int bnxt_init_chip(struct bnxt *bp)
 
 	/* VNIC configuration */
 	for (i = 0; i < bp->nr_vnics; i++) {
-		struct rte_eth_conf *dev_conf = &bp->eth_dev->data->dev_conf;
-		struct bnxt_vnic_info *vnic = &bp->vnic_info[i];
-
-		rc = bnxt_vnic_grp_alloc(bp, vnic);
+		rc = bnxt_setup_one_vnic(bp, i);
 		if (rc)
 			goto err_out;
-
-		PMD_DRV_LOG(DEBUG, "vnic[%d] = %p vnic->fw_grp_ids = %p\n",
-			    i, vnic, vnic->fw_grp_ids);
-
-		rc = bnxt_hwrm_vnic_alloc(bp, vnic);
-		if (rc) {
-			PMD_DRV_LOG(ERR, "HWRM vnic %d alloc failure rc: %x\n",
-				i, rc);
-			goto err_out;
-		}
-
-		/* Alloc RSS context only if RSS mode is enabled */
-		if (dev_conf->rxmode.mq_mode & ETH_MQ_RX_RSS) {
-			int j, nr_ctxs = bnxt_rss_ctxts(bp);
-
-			rc = 0;
-			for (j = 0; j < nr_ctxs; j++) {
-				rc = bnxt_hwrm_vnic_ctx_alloc(bp, vnic, j);
-				if (rc)
-					break;
-			}
-			if (rc) {
-				PMD_DRV_LOG(ERR,
-				  "HWRM vnic %d ctx %d alloc failure rc: %x\n",
-				  i, j, rc);
-				goto err_out;
-			}
-			vnic->num_lb_ctxts = nr_ctxs;
-		}
-
-		/*
-		 * Firmware sets pf pair in default vnic cfg. If the VLAN strip
-		 * setting is not available at this time, it will not be
-		 * configured correctly in the CFA.
-		 */
-		if (rx_offloads & DEV_RX_OFFLOAD_VLAN_STRIP)
-			vnic->vlan_strip = true;
-		else
-			vnic->vlan_strip = false;
-
-		rc = bnxt_hwrm_vnic_cfg(bp, vnic);
-		if (rc) {
-			PMD_DRV_LOG(ERR, "HWRM vnic %d cfg failure rc: %x\n",
-				i, rc);
-			goto err_out;
-		}
-
-		rc = bnxt_set_hwrm_vnic_filters(bp, vnic);
-		if (rc) {
-			PMD_DRV_LOG(ERR,
-				"HWRM vnic %d filter failure rc: %x\n",
-				i, rc);
-			goto err_out;
-		}
-
-		for (j = 0; j < bp->rx_num_qs_per_vnic; j++) {
-			rxq = bp->eth_dev->data->rx_queues[j];
-
-			PMD_DRV_LOG(DEBUG,
-				    "rxq[%d]->vnic=%p vnic->fw_grp_ids=%p\n",
-				    j, rxq->vnic, rxq->vnic->fw_grp_ids);
-
-			if (BNXT_HAS_RING_GRPS(bp) && rxq->rx_deferred_start)
-				rxq->vnic->fw_grp_ids[j] = INVALID_HW_RING_ID;
-		}
-
-		rc = bnxt_vnic_rss_configure(bp, vnic);
-		if (rc) {
-			PMD_DRV_LOG(ERR,
-				    "HWRM vnic set RSS failure rc: %x\n", rc);
-			goto err_out;
-		}
-
-		bnxt_hwrm_vnic_plcmode_cfg(bp, vnic);
-
-		if (bp->eth_dev->data->dev_conf.rxmode.offloads &
-		    DEV_RX_OFFLOAD_TCP_LRO)
-			bnxt_hwrm_vnic_tpa_cfg(bp, vnic, 1);
-		else
-			bnxt_hwrm_vnic_tpa_cfg(bp, vnic, 0);
 	}
+
 	rc = bnxt_hwrm_cfa_l2_set_rx_mask(bp, &bp->vnic_info[0], 0, NULL);
 	if (rc) {
 		PMD_DRV_LOG(ERR,
@@ -439,8 +458,11 @@ static int bnxt_init_chip(struct bnxt *bp)
 
 	/* enable uio/vfio intr/eventfd mapping */
 	rc = rte_intr_enable(intr_handle);
+#ifndef RTE_EXEC_ENV_FREEBSD
+	/* In FreeBSD OS, nic_uio driver does not support interrupts */
 	if (rc)
 		goto err_free;
+#endif
 
 	rc = bnxt_get_hwrm_link_config(bp, &new);
 	if (rc) {
@@ -505,7 +527,7 @@ static int bnxt_dev_info_get_op(struct rte_eth_dev *eth_dev,
 	if (BNXT_PF(bp))
 		dev_info->max_vfs = pdev->max_vfs;
 
-	max_rx_rings = BNXT_MAX_RINGS(bp);
+	max_rx_rings = bnxt_max_rings(bp);
 	/* For the sake of symmetry, max_rx_queues = max_tx_queues */
 	dev_info->max_rx_queues = max_rx_rings;
 	dev_info->max_tx_queues = max_rx_rings;
@@ -535,8 +557,7 @@ static int bnxt_dev_info_get_op(struct rte_eth_dev *eth_dev,
 			.wthresh = 0,
 		},
 		.rx_free_thresh = 32,
-		/* If no descriptors available, pkts are dropped by default */
-		.rx_drop_en = 1,
+		.rx_drop_en = BNXT_DEFAULT_RX_DROP_EN,
 	};
 
 	dev_info->default_txconf = (struct rte_eth_txconf) {
@@ -758,6 +779,7 @@ bnxt_receive_function(__rte_unused struct rte_eth_dev *eth_dev)
 		DEV_RX_OFFLOAD_UDP_CKSUM |
 		DEV_RX_OFFLOAD_TCP_CKSUM |
 		DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM |
+		DEV_RX_OFFLOAD_OUTER_UDP_CKSUM |
 		DEV_RX_OFFLOAD_RSS_HASH |
 		DEV_RX_OFFLOAD_VLAN_FILTER))) {
 		PMD_DRV_LOG(INFO, "Using vector mode receive for port %d\n",
@@ -827,7 +849,7 @@ static int bnxt_dev_start_op(struct rte_eth_dev *eth_dev)
 	struct bnxt *bp = eth_dev->data->dev_private;
 	uint64_t rx_offloads = eth_dev->data->dev_conf.rxmode.offloads;
 	int vlan_mask = 0;
-	int rc;
+	int rc, retry_cnt = BNXT_IF_CHANGE_RETRY_COUNT;
 
 	if (!eth_dev->data->nb_tx_queues || !eth_dev->data->nb_rx_queues) {
 		PMD_DRV_LOG(ERR, "Queues are not configured yet!\n");
@@ -840,14 +862,23 @@ static int bnxt_dev_start_op(struct rte_eth_dev *eth_dev)
 			bp->rx_cp_nr_rings, RTE_ETHDEV_QUEUE_STAT_CNTRS);
 	}
 
-	rc = bnxt_hwrm_if_change(bp, 1);
-	if (!rc) {
-		if (bp->flags & BNXT_FLAG_IF_CHANGE_HOT_FW_RESET_DONE) {
-			rc = bnxt_handle_if_change_status(bp);
-			if (rc)
-				return rc;
-		}
+	do {
+		rc = bnxt_hwrm_if_change(bp, true);
+		if (rc == 0 || rc != -EAGAIN)
+			break;
+
+		rte_delay_ms(BNXT_IF_CHANGE_RETRY_INTERVAL);
+	} while (retry_cnt--);
+
+	if (rc)
+		return rc;
+
+	if (bp->flags & BNXT_FLAG_IF_CHANGE_HOT_FW_RESET_DONE) {
+		rc = bnxt_handle_if_change_status(bp);
+		if (rc)
+			return rc;
 	}
+
 	bnxt_enable_int(bp);
 
 	rc = bnxt_init_chip(bp);
@@ -855,6 +886,7 @@ static int bnxt_dev_start_op(struct rte_eth_dev *eth_dev)
 		goto error;
 
 	eth_dev->data->scattered_rx = bnxt_scattered_rx(eth_dev);
+	eth_dev->data->dev_started = 1;
 
 	bnxt_link_update_op(eth_dev, 1);
 
@@ -869,19 +901,16 @@ static int bnxt_dev_start_op(struct rte_eth_dev *eth_dev)
 	eth_dev->rx_pkt_burst = bnxt_receive_function(eth_dev);
 	eth_dev->tx_pkt_burst = bnxt_transmit_function(eth_dev);
 
-	bp->flags |= BNXT_FLAG_INIT_DONE;
-	eth_dev->data->dev_started = 1;
-	bp->dev_stopped = 0;
-	pthread_mutex_lock(&bp->def_cp_lock);
 	bnxt_schedule_fw_health_check(bp);
-	pthread_mutex_unlock(&bp->def_cp_lock);
+
 	return 0;
 
 error:
-	bnxt_hwrm_if_change(bp, 0);
 	bnxt_shutdown_nic(bp);
 	bnxt_free_tx_mbufs(bp);
 	bnxt_free_rx_mbufs(bp);
+	bnxt_hwrm_if_change(bp, false);
+	eth_dev->data->dev_started = 0;
 	return rc;
 }
 
@@ -916,6 +945,7 @@ static void bnxt_dev_stop_op(struct rte_eth_dev *eth_dev)
 	struct bnxt *bp = eth_dev->data->dev_private;
 	struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(eth_dev);
 	struct rte_intr_handle *intr_handle = &pci_dev->intr_handle;
+	struct rte_eth_link link;
 
 	eth_dev->data->dev_started = 0;
 	/* Prevent crashes when queues are still in use */
@@ -929,18 +959,16 @@ static void bnxt_dev_stop_op(struct rte_eth_dev *eth_dev)
 
 	bnxt_cancel_fw_health_check(bp);
 
-	bp->flags &= ~BNXT_FLAG_INIT_DONE;
-	if (bp->eth_dev->data->dev_started) {
-		/* TBD: STOP HW queues DMA */
-		eth_dev->data->dev_link.link_status = 0;
+	/* Do not bring link down during reset recovery */
+	if (!is_bnxt_in_error(bp)) {
+		bnxt_dev_set_link_down_op(eth_dev);
+		/* Wait for link to be reset */
+		if (BNXT_SINGLE_PF(bp))
+			rte_delay_ms(500);
+		/* clear the recorded link status */
+		memset(&link, 0, sizeof(link));
+		rte_eth_linkstatus_set(eth_dev, &link);
 	}
-	bnxt_dev_set_link_down_op(eth_dev);
-
-	/* Wait for link to be reset and the async notification to process.
-	 * During reset recovery, there is no need to wait
-	 */
-	if (!is_bnxt_in_error(bp))
-		rte_delay_ms(BNXT_LINK_WAIT_INTERVAL * 2);
 
 	/* Clean queue intr-vector mapping */
 	rte_intr_efd_disable(intr_handle);
@@ -955,8 +983,7 @@ static void bnxt_dev_stop_op(struct rte_eth_dev *eth_dev)
 	/* Process any remaining notifications in default completion queue */
 	bnxt_int_handler(eth_dev);
 	bnxt_shutdown_nic(bp);
-	bnxt_hwrm_if_change(bp, 0);
-	bp->dev_stopped = 1;
+	bnxt_hwrm_if_change(bp, false);
 	bp->rx_cosq_cnt = 0;
 }
 
@@ -964,7 +991,11 @@ static void bnxt_dev_close_op(struct rte_eth_dev *eth_dev)
 {
 	struct bnxt *bp = eth_dev->data->dev_private;
 
-	if (bp->dev_stopped == 0)
+	/* cancel the recovery handler before remove dev */
+	rte_eal_alarm_cancel(bnxt_dev_reset_and_resume, (void *)bp);
+	rte_eal_alarm_cancel(bnxt_dev_recover, (void *)bp);
+
+	if (eth_dev->data->dev_started)
 		bnxt_dev_stop_op(eth_dev);
 
 	if (eth_dev->data->mac_addrs != NULL) {
@@ -1074,7 +1105,7 @@ static int bnxt_mac_addr_add_op(struct rte_eth_dev *eth_dev,
 	if (rc)
 		return rc;
 
-	if (BNXT_VF(bp) & !BNXT_VF_IS_TRUSTED(bp)) {
+	if (BNXT_VF(bp) && !BNXT_VF_IS_TRUSTED(bp)) {
 		PMD_DRV_LOG(ERR, "Cannot add MAC address to a VF interface\n");
 		return -ENOTSUP;
 	}
@@ -1084,6 +1115,10 @@ static int bnxt_mac_addr_add_op(struct rte_eth_dev *eth_dev,
 		return -EINVAL;
 	}
 
+	/* Filter settings will get applied when port is started */
+	if (!eth_dev->data->dev_started)
+		return 0;
+
 	rc = bnxt_add_mac_filter(bp, vnic, mac_addr, index, pool);
 
 	return rc;
@@ -1094,7 +1129,8 @@ int bnxt_link_update_op(struct rte_eth_dev *eth_dev, int wait_to_complete)
 	int rc = 0;
 	struct bnxt *bp = eth_dev->data->dev_private;
 	struct rte_eth_link new;
-	unsigned int cnt = BNXT_LINK_WAIT_CNT;
+	int cnt = wait_to_complete ? BNXT_MAX_LINK_WAIT_CNT :
+			BNXT_MIN_LINK_WAIT_CNT;
 
 	rc = is_bnxt_in_error(bp);
 	if (rc)
@@ -1118,6 +1154,12 @@ int bnxt_link_update_op(struct rte_eth_dev *eth_dev, int wait_to_complete)
 		rte_delay_ms(BNXT_LINK_WAIT_INTERVAL);
 	} while (cnt--);
 
+	/* Only single function PF can bring phy down.
+	 * When port is stopped, report link down for VF/MH/NPAR functions.
+	 */
+	if (!BNXT_SINGLE_PF(bp) && !eth_dev->data->dev_started)
+		memset(&new, 0, sizeof(new));
+
 out:
 	/* Timed out or success */
 	if (new.link_status != eth_dev->data->dev_link.link_status ||
@@ -1145,6 +1187,10 @@ static int bnxt_promiscuous_enable_op(struct rte_eth_dev *eth_dev)
 	if (rc)
 		return rc;
 
+	/* Filter settings will get applied when port is started */
+	if (!eth_dev->data->dev_started)
+		return 0;
+
 	if (bp->vnic_info == NULL)
 		return 0;
 
@@ -1170,6 +1216,10 @@ static int bnxt_promiscuous_disable_op(struct rte_eth_dev *eth_dev)
 	if (rc)
 		return rc;
 
+	/* Filter settings will get applied when port is started */
+	if (!eth_dev->data->dev_started)
+		return 0;
+
 	if (bp->vnic_info == NULL)
 		return 0;
 
@@ -1195,6 +1245,10 @@ static int bnxt_allmulticast_enable_op(struct rte_eth_dev *eth_dev)
 	if (rc)
 		return rc;
 
+	/* Filter settings will get applied when port is started */
+	if (!eth_dev->data->dev_started)
+		return 0;
+
 	if (bp->vnic_info == NULL)
 		return 0;
 
@@ -1220,6 +1274,10 @@ static int bnxt_allmulticast_disable_op(struct rte_eth_dev *eth_dev)
 	if (rc)
 		return rc;
 
+	/* Filter settings will get applied when port is started */
+	if (!eth_dev->data->dev_started)
+		return 0;
+
 	if (bp->vnic_info == NULL)
 		return 0;
 
@@ -1319,8 +1377,8 @@ static int bnxt_reta_update_op(struct rte_eth_dev *eth_dev,
 		}
 	}
 
-	bnxt_hwrm_vnic_rss_cfg(bp, vnic);
-	return 0;
+	rc = bnxt_hwrm_vnic_rss_cfg(bp, vnic);
+	return rc;
 }
 
 static int bnxt_reta_query_op(struct rte_eth_dev *eth_dev,
@@ -1399,7 +1457,9 @@ static int bnxt_rss_hash_update_op(struct rte_eth_dev *eth_dev,
 	}
 
 	bp->flags |= BNXT_FLAG_UPDATE_HASH;
-	memcpy(&bp->rss_conf, rss_conf, sizeof(*rss_conf));
+	memcpy(&eth_dev->data->dev_conf.rx_adv_conf.rss_conf,
+	       rss_conf,
+	       sizeof(*rss_conf));
 
 	/* Update the default RSS VNIC(s) */
 	vnic = &bp->vnic_info[0];
@@ -1420,8 +1480,8 @@ static int bnxt_rss_hash_update_op(struct rte_eth_dev *eth_dev,
 	memcpy(vnic->rss_hash_key, rss_conf->rss_key, rss_conf->rss_key_len);
 
 rss_config:
-	bnxt_hwrm_vnic_rss_cfg(bp, vnic);
-	return 0;
+	rc = bnxt_hwrm_vnic_rss_cfg(bp, vnic);
+	return rc;
 }
 
 static int bnxt_rss_hash_conf_get_op(struct rte_eth_dev *eth_dev,
@@ -1476,7 +1536,7 @@ static int bnxt_rss_hash_conf_get_op(struct rte_eth_dev *eth_dev,
 		}
 		if (hash_types) {
 			PMD_DRV_LOG(ERR,
-				"Unknwon RSS config from firmware (%08x), RSS disabled",
+				"Unknown RSS config from firmware (%08x), RSS disabled",
 				vnic->hash_type);
 			return -ENOTSUP;
 		}
@@ -1808,6 +1868,11 @@ static int bnxt_vlan_filter_set_op(struct rte_eth_dev *eth_dev,
 	if (rc)
 		return rc;
 
+	if (!eth_dev->data->dev_started) {
+		PMD_DRV_LOG(ERR, "port must be started before setting vlan\n");
+		return -EINVAL;
+	}
+
 	/* These operations apply to ALL existing MAC/VLAN filters */
 	if (on)
 		return bnxt_add_vlan_filter(bp, vlan_id);
@@ -1841,18 +1906,12 @@ static int bnxt_del_dflt_mac_filter(struct bnxt *bp,
 }
 
 static int
-bnxt_vlan_offload_set_op(struct rte_eth_dev *dev, int mask)
+bnxt_config_vlan_hw_filter(struct bnxt *bp, uint64_t rx_offloads)
 {
-	struct bnxt *bp = dev->data->dev_private;
-	uint64_t rx_offloads = dev->data->dev_conf.rxmode.offloads;
 	struct bnxt_vnic_info *vnic;
 	unsigned int i;
 	int rc;
 
-	rc = is_bnxt_in_error(bp);
-	if (rc)
-		return rc;
-
 	vnic = BNXT_GET_DEFAULT_VNIC(bp);
 	if (!(rx_offloads & DEV_RX_OFFLOAD_VLAN_FILTER)) {
 		/* Remove any VLAN filters programmed */
@@ -1876,18 +1935,102 @@ bnxt_vlan_offload_set_op(struct rte_eth_dev *dev, int mask)
 	PMD_DRV_LOG(DEBUG, "VLAN Filtering: %d\n",
 		    !!(rx_offloads & DEV_RX_OFFLOAD_VLAN_FILTER));
 
+	return 0;
+}
+
+static int bnxt_free_one_vnic(struct bnxt *bp, uint16_t vnic_id)
+{
+	struct bnxt_vnic_info *vnic = &bp->vnic_info[vnic_id];
+	unsigned int i;
+	int rc;
+
+	/* Destroy vnic filters and vnic */
+	if (bp->eth_dev->data->dev_conf.rxmode.offloads &
+	    DEV_RX_OFFLOAD_VLAN_FILTER) {
+		for (i = 0; i < RTE_ETHER_MAX_VLAN_ID; i++)
+			bnxt_del_vlan_filter(bp, i);
+	}
+	bnxt_del_dflt_mac_filter(bp, vnic);
+
+	rc = bnxt_hwrm_vnic_free(bp, vnic);
+	if (rc)
+		return rc;
+
+	rte_free(vnic->fw_grp_ids);
+	vnic->fw_grp_ids = NULL;
+
+	vnic->rx_queue_cnt = 0;
+
+	return 0;
+}
+
+static int
+bnxt_config_vlan_hw_stripping(struct bnxt *bp, uint64_t rx_offloads)
+{
+	struct bnxt_vnic_info *vnic = BNXT_GET_DEFAULT_VNIC(bp);
+	int rc;
+
+	/* Destroy, recreate and reconfigure the default vnic */
+	rc = bnxt_free_one_vnic(bp, 0);
+	if (rc)
+		return rc;
+
+	/* default vnic 0 */
+	rc = bnxt_setup_one_vnic(bp, 0);
+	if (rc)
+		return rc;
+
+	if (bp->eth_dev->data->dev_conf.rxmode.offloads &
+	    DEV_RX_OFFLOAD_VLAN_FILTER) {
+		rc = bnxt_add_vlan_filter(bp, 0);
+		if (rc)
+			return rc;
+		rc = bnxt_restore_vlan_filters(bp);
+		if (rc)
+			return rc;
+	} else {
+		rc = bnxt_add_mac_filter(bp, vnic, NULL, 0, 0);
+		if (rc)
+			return rc;
+	}
+
+	rc = bnxt_hwrm_cfa_l2_set_rx_mask(bp, vnic, 0, NULL);
+	if (rc)
+		return rc;
+
+	PMD_DRV_LOG(DEBUG, "VLAN Strip Offload: %d\n",
+		    !!(rx_offloads & DEV_RX_OFFLOAD_VLAN_STRIP));
+
+	return rc;
+}
+
+static int
+bnxt_vlan_offload_set_op(struct rte_eth_dev *dev, int mask)
+{
+	uint64_t rx_offloads = dev->data->dev_conf.rxmode.offloads;
+	struct bnxt *bp = dev->data->dev_private;
+	int rc;
+
+	rc = is_bnxt_in_error(bp);
+	if (rc)
+		return rc;
+
+	/* Filter settings will get applied when port is started */
+	if (!dev->data->dev_started)
+		return 0;
+
+	if (mask & ETH_VLAN_FILTER_MASK) {
+		/* Enable or disable VLAN filtering */
+		rc = bnxt_config_vlan_hw_filter(bp, rx_offloads);
+		if (rc)
+			return rc;
+	}
+
 	if (mask & ETH_VLAN_STRIP_MASK) {
 		/* Enable or disable VLAN stripping */
-		for (i = 0; i < bp->nr_vnics; i++) {
-			struct bnxt_vnic_info *vnic = &bp->vnic_info[i];
-			if (rx_offloads & DEV_RX_OFFLOAD_VLAN_STRIP)
-				vnic->vlan_strip = true;
-			else
-				vnic->vlan_strip = false;
-			bnxt_hwrm_vnic_cfg(bp, vnic);
-		}
-		PMD_DRV_LOG(DEBUG, "VLAN Strip Offload: %d\n",
-			!!(rx_offloads & DEV_RX_OFFLOAD_VLAN_STRIP));
+		rc = bnxt_config_vlan_hw_stripping(bp, rx_offloads);
+		if (rc)
+			return rc;
 	}
 
 	if (mask & ETH_VLAN_EXTEND_MASK) {
@@ -1965,7 +2108,6 @@ bnxt_set_default_mac_addr_op(struct rte_eth_dev *dev,
 	struct bnxt *bp = dev->data->dev_private;
 	/* Default Filter is tied to VNIC 0 */
 	struct bnxt_vnic_info *vnic = &bp->vnic_info[0];
-	struct bnxt_filter_info *filter;
 	int rc;
 
 	rc = is_bnxt_in_error(bp);
@@ -1978,32 +2120,27 @@ bnxt_set_default_mac_addr_op(struct rte_eth_dev *dev,
 	if (rte_is_zero_ether_addr(addr))
 		return -EINVAL;
 
-	STAILQ_FOREACH(filter, &vnic->filter, next) {
-		/* Default Filter is at Index 0 */
-		if (filter->mac_index != 0)
-			continue;
+	/* Filter settings will get applied when port is started */
+	if (!dev->data->dev_started)
+		return 0;
 
-		memcpy(filter->l2_addr, addr, RTE_ETHER_ADDR_LEN);
-		memset(filter->l2_addr_mask, 0xff, RTE_ETHER_ADDR_LEN);
-		filter->flags |= HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX |
-			HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_OUTERMOST;
-		filter->enables |=
-			HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR |
-			HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR_MASK;
+	/* Check if the requested MAC is already added */
+	if (memcmp(addr, bp->mac_addr, RTE_ETHER_ADDR_LEN) == 0)
+		return 0;
 
-		rc = bnxt_hwrm_set_l2_filter(bp, vnic->fw_vnic_id, filter);
-		if (rc) {
-			memcpy(filter->l2_addr, bp->mac_addr,
-			       RTE_ETHER_ADDR_LEN);
-			return rc;
-		}
+	/* Destroy filter and re-create it */
+	bnxt_del_dflt_mac_filter(bp, vnic);
 
-		memcpy(bp->mac_addr, addr, RTE_ETHER_ADDR_LEN);
-		PMD_DRV_LOG(DEBUG, "Set MAC addr\n");
-		return 0;
+	memcpy(bp->mac_addr, addr, RTE_ETHER_ADDR_LEN);
+	if (dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_VLAN_FILTER) {
+		/* This filter will allow only untagged packets */
+		rc = bnxt_add_vlan_filter(bp, 0);
+	} else {
+		rc = bnxt_add_mac_filter(bp, vnic, addr, 0, 0);
 	}
 
-	return 0;
+	PMD_DRV_LOG(DEBUG, "Set MAC addr\n");
+	return rc;
 }
 
 static int
@@ -2053,10 +2190,11 @@ bnxt_fw_version_get(struct rte_eth_dev *dev, char *fw_version, size_t fw_size)
 	uint8_t fw_major = (bp->fw_ver >> 24) & 0xff;
 	uint8_t fw_minor = (bp->fw_ver >> 16) & 0xff;
 	uint8_t fw_updt = (bp->fw_ver >> 8) & 0xff;
+	uint8_t fw_rsvd = bp->fw_ver & 0xff;
 	int ret;
 
-	ret = snprintf(fw_version, fw_size, "%d.%d.%d",
-			fw_major, fw_minor, fw_updt);
+	ret = snprintf(fw_version, fw_size, "%d.%d.%d.%d",
+			fw_major, fw_minor, fw_updt, fw_rsvd);
 
 	ret += 1; /* add the size of '\0' */
 	if (fw_size < (uint32_t)ret)
@@ -2082,8 +2220,9 @@ bnxt_rxq_info_get_op(struct rte_eth_dev *dev, uint16_t queue_id,
 	qinfo->nb_desc = rxq->nb_rx_desc;
 
 	qinfo->conf.rx_free_thresh = rxq->rx_free_thresh;
-	qinfo->conf.rx_drop_en = 0;
+	qinfo->conf.rx_drop_en = rxq->drop_en;
 	qinfo->conf.rx_deferred_start = rxq->rx_deferred_start;
+	qinfo->conf.offloads = dev->data->dev_conf.rxmode.offloads;
 }
 
 static void
@@ -2107,6 +2246,7 @@ bnxt_txq_info_get_op(struct rte_eth_dev *dev, uint16_t queue_id,
 	qinfo->conf.tx_free_thresh = txq->tx_free_thresh;
 	qinfo->conf.tx_rs_thresh = 0;
 	qinfo->conf.tx_deferred_start = txq->tx_deferred_start;
+	qinfo->conf.offloads = dev->data->dev_conf.txmode.offloads;
 }
 
 int bnxt_mtu_set_op(struct rte_eth_dev *eth_dev, uint16_t new_mtu)
@@ -3500,9 +3640,9 @@ bnxt_get_eeprom_length_op(struct rte_eth_dev *dev)
 	if (rc)
 		return rc;
 
-	PMD_DRV_LOG(INFO, "%04x:%02x:%02x:%02x\n",
-		bp->pdev->addr.domain, bp->pdev->addr.bus,
-		bp->pdev->addr.devid, bp->pdev->addr.function);
+	PMD_DRV_LOG(INFO, PCI_PRI_FMT "\n",
+		    bp->pdev->addr.domain, bp->pdev->addr.bus,
+		    bp->pdev->addr.devid, bp->pdev->addr.function);
 
 	rc = bnxt_hwrm_nvm_get_dir_info(bp, &dir_entries, &entry_length);
 	if (rc != 0)
@@ -3524,10 +3664,10 @@ bnxt_get_eeprom_op(struct rte_eth_dev *dev,
 	if (rc)
 		return rc;
 
-	PMD_DRV_LOG(INFO, "%04x:%02x:%02x:%02x in_eeprom->offset = %d "
-		"len = %d\n", bp->pdev->addr.domain,
-		bp->pdev->addr.bus, bp->pdev->addr.devid,
-		bp->pdev->addr.function, in_eeprom->offset, in_eeprom->length);
+	PMD_DRV_LOG(INFO, PCI_PRI_FMT " in_eeprom->offset = %d len = %d\n",
+		    bp->pdev->addr.domain, bp->pdev->addr.bus,
+		    bp->pdev->addr.devid, bp->pdev->addr.function,
+		    in_eeprom->offset, in_eeprom->length);
 
 	if (in_eeprom->offset == 0) /* special offset value to get directory */
 		return bnxt_get_nvram_directory(bp, in_eeprom->length,
@@ -3600,10 +3740,10 @@ bnxt_set_eeprom_op(struct rte_eth_dev *dev,
 	if (rc)
 		return rc;
 
-	PMD_DRV_LOG(INFO, "%04x:%02x:%02x:%02x in_eeprom->offset = %d "
-		"len = %d\n", bp->pdev->addr.domain,
-		bp->pdev->addr.bus, bp->pdev->addr.devid,
-		bp->pdev->addr.function, in_eeprom->offset, in_eeprom->length);
+	PMD_DRV_LOG(INFO, PCI_PRI_FMT " in_eeprom->offset = %d len = %d\n",
+		    bp->pdev->addr.domain, bp->pdev->addr.bus,
+		    bp->pdev->addr.devid, bp->pdev->addr.function,
+		    in_eeprom->offset, in_eeprom->length);
 
 	if (!BNXT_PF(bp)) {
 		PMD_DRV_LOG(ERR, "NVM write not supported from a VF\n");
@@ -3688,8 +3828,6 @@ static const struct eth_dev_ops bnxt_dev_ops = {
 	.txq_info_get = bnxt_txq_info_get_op,
 	.dev_led_on = bnxt_dev_led_on_op,
 	.dev_led_off = bnxt_dev_led_off_op,
-	.xstats_get_by_id = bnxt_dev_xstats_get_by_id_op,
-	.xstats_get_names_by_id = bnxt_dev_xstats_get_names_by_id_op,
 	.rx_queue_count = bnxt_rx_queue_count_op,
 	.rx_descriptor_status = bnxt_rx_descriptor_status_op,
 	.tx_descriptor_status = bnxt_tx_descriptor_status_op,
@@ -3788,24 +3926,100 @@ static void bnxt_write_fw_reset_reg(struct bnxt *bp, uint32_t index)
 
 static void bnxt_dev_cleanup(struct bnxt *bp)
 {
-	bnxt_set_hwrm_link_config(bp, false);
+	bp->eth_dev->data->dev_link.link_status = 0;
 	bp->link_info.link_up = 0;
-	if (bp->dev_stopped == 0)
+	if (bp->eth_dev->data->dev_started)
 		bnxt_dev_stop_op(bp->eth_dev);
 
 	bnxt_uninit_resources(bp, true);
 }
 
+static int bnxt_restore_vlan_filters(struct bnxt *bp)
+{
+	struct rte_eth_dev *dev = bp->eth_dev;
+	struct rte_vlan_filter_conf *vfc;
+	int vidx, vbit, rc;
+	uint16_t vlan_id;
+
+	for (vlan_id = 1; vlan_id <= RTE_ETHER_MAX_VLAN_ID; vlan_id++) {
+		vfc = &dev->data->vlan_filter_conf;
+		vidx = vlan_id / 64;
+		vbit = vlan_id % 64;
+
+		/* Each bit corresponds to a VLAN id */
+		if (vfc->ids[vidx] & (UINT64_C(1) << vbit)) {
+			rc = bnxt_add_vlan_filter(bp, vlan_id);
+			if (rc)
+				return rc;
+		}
+	}
+
+	return 0;
+}
+
+static int bnxt_restore_mac_filters(struct bnxt *bp)
+{
+	struct rte_eth_dev *dev = bp->eth_dev;
+	struct rte_eth_dev_info dev_info;
+	struct rte_ether_addr *addr;
+	uint64_t pool_mask;
+	uint32_t pool = 0;
+	uint16_t i;
+	int rc;
+
+	if (BNXT_VF(bp) && !BNXT_VF_IS_TRUSTED(bp))
+		return 0;
+
+	rc = bnxt_dev_info_get_op(dev, &dev_info);
+	if (rc)
+		return rc;
+
+	/* replay MAC address configuration */
+	for (i = 1; i < dev_info.max_mac_addrs; i++) {
+		addr = &dev->data->mac_addrs[i];
+
+		/* skip zero address */
+		if (rte_is_zero_ether_addr(addr))
+			continue;
+
+		pool = 0;
+		pool_mask = dev->data->mac_pool_sel[i];
+
+		do {
+			if (pool_mask & 1ULL) {
+				rc = bnxt_mac_addr_add_op(dev, addr, i, pool);
+				if (rc)
+					return rc;
+			}
+			pool_mask >>= 1;
+			pool++;
+		} while (pool_mask);
+	}
+
+	return 0;
+}
+
 static int bnxt_restore_filters(struct bnxt *bp)
 {
 	struct rte_eth_dev *dev = bp->eth_dev;
 	int ret = 0;
 
-	if (dev->data->all_multicast)
+	if (dev->data->all_multicast) {
 		ret = bnxt_allmulticast_enable_op(dev);
-	if (dev->data->promiscuous)
+		if (ret)
+			return ret;
+	}
+	if (dev->data->promiscuous) {
 		ret = bnxt_promiscuous_enable_op(dev);
+		if (ret)
+			return ret;
+	}
 
+	ret = bnxt_restore_mac_filters(bp);
+	if (ret)
+		return ret;
+
+	ret = bnxt_restore_vlan_filters(bp);
 	/* TODO restore other filters as well */
 	return ret;
 }
@@ -3820,7 +4034,7 @@ static void bnxt_dev_recover(void *arg)
 	bp->flags &= ~BNXT_FLAG_FATAL_ERROR;
 
 	do {
-		rc = bnxt_hwrm_ver_get(bp);
+		rc = bnxt_hwrm_ver_get(bp, SHORT_HWRM_CMD_TIMEOUT);
 		if (rc == 0)
 			break;
 		rte_delay_ms(BNXT_FW_READY_WAIT_INTERVAL);
@@ -3844,15 +4058,17 @@ static void bnxt_dev_recover(void *arg)
 	rc = bnxt_dev_start_op(bp->eth_dev);
 	if (rc) {
 		PMD_DRV_LOG(ERR, "Failed to start port after reset\n");
-		goto err;
+		goto err_start;
 	}
 
 	rc = bnxt_restore_filters(bp);
 	if (rc)
-		goto err;
+		goto err_start;
 
 	PMD_DRV_LOG(INFO, "Recovered from FW reset\n");
 	return;
+err_start:
+	bnxt_dev_stop_op(bp->eth_dev);
 err:
 	bp->flags |= BNXT_FLAG_FATAL_ERROR;
 	bnxt_uninit_resources(bp, false);
@@ -4006,17 +4222,22 @@ void bnxt_schedule_fw_health_check(struct bnxt *bp)
 {
 	uint32_t polling_freq;
 
+	pthread_mutex_lock(&bp->health_check_lock);
+
 	if (!bnxt_is_recovery_enabled(bp))
-		return;
+		goto done;
 
 	if (bp->flags & BNXT_FLAG_FW_HEALTH_CHECK_SCHEDULED)
-		return;
+		goto done;
 
 	polling_freq = bp->recovery_info->driver_polling_freq;
 
 	rte_eal_alarm_set(US_PER_MS * polling_freq,
 			  bnxt_check_fw_health, (void *)bp);
 	bp->flags |= BNXT_FLAG_FW_HEALTH_CHECK_SCHEDULED;
+
+done:
+	pthread_mutex_unlock(&bp->health_check_lock);
 }
 
 static void bnxt_cancel_fw_health_check(struct bnxt *bp)
@@ -4138,18 +4359,6 @@ static int bnxt_alloc_ctx_mem_blk(__rte_unused struct bnxt *bp,
 
 		memset(mz->addr, 0, mz->len);
 		mz_phys_addr = mz->iova;
-		if ((unsigned long)mz->addr == mz_phys_addr) {
-			PMD_DRV_LOG(DEBUG,
-				    "physical address same as virtual\n");
-			PMD_DRV_LOG(DEBUG, "Using rte_mem_virt2iova()\n");
-			mz_phys_addr = rte_mem_virt2iova(mz->addr);
-			if (mz_phys_addr == RTE_BAD_IOVA) {
-				PMD_DRV_LOG(ERR,
-					"unable to map addr to phys memory\n");
-				return -ENOMEM;
-			}
-		}
-		rte_mem_lock_page(((char *)mz->addr));
 
 		rmem->pg_tbl = mz->addr;
 		rmem->pg_tbl_map = mz_phys_addr;
@@ -4173,22 +4382,8 @@ static int bnxt_alloc_ctx_mem_blk(__rte_unused struct bnxt *bp,
 
 	memset(mz->addr, 0, mz->len);
 	mz_phys_addr = mz->iova;
-	if ((unsigned long)mz->addr == mz_phys_addr) {
-		PMD_DRV_LOG(DEBUG,
-			    "Memzone physical address same as virtual.\n");
-		PMD_DRV_LOG(DEBUG, "Using rte_mem_virt2iova()\n");
-		for (sz = 0; sz < mem_size; sz += BNXT_PAGE_SIZE)
-			rte_mem_lock_page(((char *)mz->addr) + sz);
-		mz_phys_addr = rte_mem_virt2iova(mz->addr);
-		if (mz_phys_addr == RTE_BAD_IOVA) {
-			PMD_DRV_LOG(ERR,
-				    "unable to map addr to phys memory\n");
-			return -ENOMEM;
-		}
-	}
 
 	for (sz = 0, i = 0; sz < mem_size; sz += BNXT_PAGE_SIZE, i++) {
-		rte_mem_lock_page(((char *)mz->addr) + sz);
 		rmem->pg_arr[i] = ((char *)mz->addr) + sz;
 		rmem->dma_arr[i] = mz_phys_addr + sz;
 
@@ -4365,18 +4560,6 @@ static int bnxt_alloc_stats_mem(struct bnxt *bp)
 	}
 	memset(mz->addr, 0, mz->len);
 	mz_phys_addr = mz->iova;
-	if ((unsigned long)mz->addr == mz_phys_addr) {
-		PMD_DRV_LOG(DEBUG,
-			    "Memzone physical address same as virtual.\n");
-		PMD_DRV_LOG(DEBUG,
-			    "Using rte_mem_virt2iova()\n");
-		mz_phys_addr = rte_mem_virt2iova(mz->addr);
-		if (mz_phys_addr == RTE_BAD_IOVA) {
-			PMD_DRV_LOG(ERR,
-				    "Can't map address to physical memory\n");
-			return -ENOMEM;
-		}
-	}
 
 	bp->rx_mem_zone = (const void *)mz;
 	bp->hw_rx_port_stats = mz->addr;
@@ -4403,17 +4586,6 @@ static int bnxt_alloc_stats_mem(struct bnxt *bp)
 	}
 	memset(mz->addr, 0, mz->len);
 	mz_phys_addr = mz->iova;
-	if ((unsigned long)mz->addr == mz_phys_addr) {
-		PMD_DRV_LOG(DEBUG,
-			    "Memzone physical address same as virtual\n");
-		PMD_DRV_LOG(DEBUG, "Using rte_mem_virt2iova()\n");
-		mz_phys_addr = rte_mem_virt2iova(mz->addr);
-		if (mz_phys_addr == RTE_BAD_IOVA) {
-			PMD_DRV_LOG(ERR,
-				    "Can't map address to physical memory\n");
-			return -ENOMEM;
-		}
-	}
 
 	bp->tx_mem_zone = (const void *)mz;
 	bp->hw_tx_port_stats = mz->addr;
@@ -4461,7 +4633,7 @@ static int bnxt_setup_mac_addr(struct rte_eth_dev *eth_dev)
 		return -ENOMEM;
 	}
 
-	if (bnxt_check_zero_bytes(bp->dflt_mac_addr, RTE_ETHER_ADDR_LEN)) {
+	if (!BNXT_HAS_DFLT_MAC_SET(bp)) {
 		if (BNXT_PF(bp))
 			return -EINVAL;
 
@@ -4474,14 +4646,11 @@ static int bnxt_setup_mac_addr(struct rte_eth_dev *eth_dev)
 			    bp->mac_addr[3], bp->mac_addr[4], bp->mac_addr[5]);
 
 		rc = bnxt_hwrm_set_mac(bp);
-		if (!rc)
-			memcpy(&bp->eth_dev->data->mac_addrs[0], bp->mac_addr,
-			       RTE_ETHER_ADDR_LEN);
-		return rc;
+		if (rc)
+			return rc;
 	}
 
 	/* Copy the permanent MAC from the FUNC_QCAPS response */
-	memcpy(bp->mac_addr, bp->dflt_mac_addr, RTE_ETHER_ADDR_LEN);
 	memcpy(&eth_dev->data->mac_addrs[0], bp->mac_addr, RTE_ETHER_ADDR_LEN);
 
 	return rc;
@@ -4492,7 +4661,7 @@ static int bnxt_restore_dflt_mac(struct bnxt *bp)
 	int rc = 0;
 
 	/* MAC is already configured in FW */
-	if (!bnxt_check_zero_bytes(bp->dflt_mac_addr, RTE_ETHER_ADDR_LEN))
+	if (BNXT_HAS_DFLT_MAC_SET(bp))
 		return 0;
 
 	/* Restore the old MAC configured */
@@ -4546,7 +4715,9 @@ static int bnxt_init_fw(struct bnxt *bp)
 	uint16_t mtu;
 	int rc = 0;
 
-	rc = bnxt_hwrm_ver_get(bp);
+	bp->fw_cap = 0;
+
+	rc = bnxt_hwrm_ver_get(bp, DFLT_HWRM_CMD_TIMEOUT);
 	if (rc)
 		return rc;
 
@@ -4574,14 +4745,10 @@ static int bnxt_init_fw(struct bnxt *bp)
 	if (rc)
 		return rc;
 
-	rc = bnxt_hwrm_cfa_adv_flow_mgmt_qcaps(bp);
-	if (rc)
-		return rc;
-
 	/* Get the adapter error recovery support info */
 	rc = bnxt_hwrm_error_recovery_qcfg(bp);
 	if (rc)
-		bp->flags &= ~BNXT_FLAG_FW_CAP_ERROR_RECOVERY;
+		bp->fw_cap &= ~BNXT_FW_CAP_ERROR_RECOVERY;
 
 	bnxt_hwrm_port_led_qcaps(bp);
 
@@ -4600,8 +4767,14 @@ bnxt_init_locks(struct bnxt *bp)
 	}
 
 	err = pthread_mutex_init(&bp->def_cp_lock, NULL);
-	if (err)
+	if (err) {
 		PMD_DRV_LOG(ERR, "Unable to initialize def_cp_lock\n");
+		return err;
+	}
+
+	err = pthread_mutex_init(&bp->health_check_lock, NULL);
+	if (err)
+		PMD_DRV_LOG(ERR, "Unable to initialize health_check_lock\n");
 	return err;
 }
 
@@ -4693,8 +4866,6 @@ bnxt_dev_init(struct rte_eth_dev *eth_dev)
 
 	bp = eth_dev->data->dev_private;
 
-	bp->dev_stopped = 1;
-
 	if (bnxt_vf_pciid(pci_dev->id.device_id))
 		bp->flags |= BNXT_FLAG_VF;
 
@@ -4745,6 +4916,7 @@ bnxt_uninit_locks(struct bnxt *bp)
 {
 	pthread_mutex_destroy(&bp->flow_lock);
 	pthread_mutex_destroy(&bp->def_cp_lock);
+	pthread_mutex_destroy(&bp->health_check_lock);
 }
 
 static int
@@ -4796,10 +4968,9 @@ bnxt_dev_uninit(struct rte_eth_dev *eth_dev)
 		bp->rx_mem_zone = NULL;
 	}
 
-	if (bp->dev_stopped == 0)
+	if (eth_dev->data->dev_started)
 		bnxt_dev_close_op(eth_dev);
-	if (bp->pf.vf_info)
-		rte_free(bp->pf.vf_info);
+	bnxt_hwrm_free_vf_info(bp);
 	eth_dev->dev_ops = NULL;
 	eth_dev->rx_pkt_burst = NULL;
 	eth_dev->tx_pkt_burst = NULL;
diff --git a/dpdk/drivers/net/bnxt/bnxt_filter.c b/dpdk/drivers/net/bnxt/bnxt_filter.c
index da1a6c24a9..f4b18d5b84 100644
--- a/dpdk/drivers/net/bnxt/bnxt_filter.c
+++ b/dpdk/drivers/net/bnxt/bnxt_filter.c
@@ -26,22 +26,20 @@ struct bnxt_filter_info *bnxt_alloc_filter(struct bnxt *bp)
 {
 	struct bnxt_filter_info *filter;
 
-	/* Find the 1st unused filter from the free_filter_list pool*/
-	filter = STAILQ_FIRST(&bp->free_filter_list);
+	filter = bnxt_get_unused_filter(bp);
 	if (!filter) {
 		PMD_DRV_LOG(ERR, "No more free filter resources\n");
 		return NULL;
 	}
-	STAILQ_REMOVE_HEAD(&bp->free_filter_list, next);
 
 	filter->mac_index = INVALID_MAC_INDEX;
 	/* Default to L2 MAC Addr filter */
 	filter->flags = HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX;
 	filter->enables = HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR |
 			HWRM_CFA_L2_FILTER_ALLOC_INPUT_ENABLES_L2_ADDR_MASK;
-	memcpy(filter->l2_addr, bp->eth_dev->data->mac_addrs->addr_bytes,
-	       RTE_ETHER_ADDR_LEN);
+	memcpy(filter->l2_addr, bp->mac_addr, RTE_ETHER_ADDR_LEN);
 	memset(filter->l2_addr_mask, 0xff, RTE_ETHER_ADDR_LEN);
+
 	return filter;
 }
 
@@ -83,6 +81,15 @@ void bnxt_free_all_filters(struct bnxt *bp)
 	struct bnxt_filter_info *filter, *temp_filter;
 	unsigned int i;
 
+	for (i = 0; i < bp->pf.max_vfs; i++) {
+		STAILQ_FOREACH(filter, &bp->pf.vf_info[i].filter, next) {
+			bnxt_hwrm_clear_l2_filter(bp, filter);
+		}
+	}
+
+	if (bp->vnic_info == NULL)
+		return;
+
 	for (i = 0; i < bp->nr_vnics; i++) {
 		vnic = &bp->vnic_info[i];
 		filter = STAILQ_FIRST(&vnic->filter);
@@ -96,12 +103,6 @@ void bnxt_free_all_filters(struct bnxt *bp)
 		}
 		STAILQ_INIT(&vnic->filter);
 	}
-
-	for (i = 0; i < bp->pf.max_vfs; i++) {
-		STAILQ_FOREACH(filter, &bp->pf.vf_info[i].filter, next) {
-			bnxt_hwrm_clear_l2_filter(bp, filter);
-		}
-	}
 }
 
 void bnxt_free_filter_mem(struct bnxt *bp)
diff --git a/dpdk/drivers/net/bnxt/bnxt_filter.h b/dpdk/drivers/net/bnxt/bnxt_filter.h
index 9db3e74877..fc40f112ba 100644
--- a/dpdk/drivers/net/bnxt/bnxt_filter.h
+++ b/dpdk/drivers/net/bnxt/bnxt_filter.h
@@ -77,6 +77,10 @@ struct bnxt_filter_info {
 	uint16_t                ip_addr_type;
 	uint16_t                ethertype;
 	uint32_t		priority;
+	/* Backptr to vnic. As of now, used only by an L2 filter
+	 * to remember which vnic it was created on
+	 */
+	struct			bnxt_vnic_info *vnic;
 };
 
 struct bnxt_filter_info *bnxt_alloc_filter(struct bnxt *bp);
diff --git a/dpdk/drivers/net/bnxt/bnxt_flow.c b/dpdk/drivers/net/bnxt/bnxt_flow.c
index 76e9584da7..f069e5f56a 100644
--- a/dpdk/drivers/net/bnxt/bnxt_flow.c
+++ b/dpdk/drivers/net/bnxt/bnxt_flow.c
@@ -746,10 +746,9 @@ bnxt_find_matching_l2_filter(struct bnxt *bp, struct bnxt_filter_info *nf)
 {
 	struct bnxt_filter_info *mf, *f0;
 	struct bnxt_vnic_info *vnic0;
-	struct rte_flow *flow;
 	int i;
 
-	vnic0 = &bp->vnic_info[0];
+	vnic0 = BNXT_GET_DEFAULT_VNIC(bp);
 	f0 = STAILQ_FIRST(&vnic0->filter);
 
 	/* This flow has same DST MAC as the port/l2 filter. */
@@ -762,8 +761,7 @@ bnxt_find_matching_l2_filter(struct bnxt *bp, struct bnxt_filter_info *nf)
 		if (vnic->fw_vnic_id == INVALID_VNIC_ID)
 			continue;
 
-		STAILQ_FOREACH(flow, &vnic->flow_list, next) {
-			mf = flow->filter;
+		STAILQ_FOREACH(mf, &vnic->filter, next) {
 
 			if (mf->matching_l2_fltr_ptr)
 				continue;
@@ -798,6 +796,8 @@ bnxt_create_l2_filter(struct bnxt *bp, struct bnxt_filter_info *nf,
 	if (filter1 == NULL)
 		return NULL;
 
+	memcpy(filter1, nf, sizeof(*filter1));
+
 	filter1->flags = HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_XDP_DISABLE;
 	filter1->flags |= HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_PATH_RX;
 	if (nf->valid_flags & BNXT_FLOW_L2_SRC_VALID_FLAG ||
@@ -867,7 +867,6 @@ bnxt_create_l2_filter(struct bnxt *bp, struct bnxt_filter_info *nf,
 		bnxt_free_filter(bp, filter1);
 		return NULL;
 	}
-	filter1->l2_ref_cnt++;
 	return filter1;
 }
 
@@ -880,11 +879,14 @@ bnxt_get_l2_filter(struct bnxt *bp, struct bnxt_filter_info *nf,
 	l2_filter = bnxt_find_matching_l2_filter(bp, nf);
 	if (l2_filter) {
 		l2_filter->l2_ref_cnt++;
-		nf->matching_l2_fltr_ptr = l2_filter;
 	} else {
 		l2_filter = bnxt_create_l2_filter(bp, nf, vnic);
-		nf->matching_l2_fltr_ptr = NULL;
+		if (l2_filter) {
+			STAILQ_INSERT_TAIL(&vnic->filter, l2_filter, next);
+			l2_filter->vnic = vnic;
+		}
 	}
+	nf->matching_l2_fltr_ptr = l2_filter;
 
 	return l2_filter;
 }
@@ -1054,16 +1056,9 @@ bnxt_validate_and_parse_flow(struct rte_eth_dev *dev,
 			vnic_id = act_q->index;
 		}
 
+		BNXT_VALID_VNIC_OR_RET(bp, vnic_id);
+
 		vnic = &bp->vnic_info[vnic_id];
-		if (vnic == NULL) {
-			rte_flow_error_set(error,
-					   EINVAL,
-					   RTE_FLOW_ERROR_TYPE_ACTION,
-					   act,
-					   "No matching VNIC found.");
-			rc = -rte_errno;
-			goto ret;
-		}
 		if (vnic->rx_queue_cnt) {
 			if (vnic->start_grp_id != act_q->index) {
 				PMD_DRV_LOG(ERR,
@@ -1126,7 +1121,16 @@ bnxt_validate_and_parse_flow(struct rte_eth_dev *dev,
 		PMD_DRV_LOG(DEBUG,
 			    "Setting vnic ff_idx %d\n", vnic->ff_pool_idx);
 		filter->dst_id = vnic->fw_vnic_id;
-		filter1 = bnxt_get_l2_filter(bp, filter, vnic);
+
+		/* For ntuple filter, create the L2 filter with default VNIC.
+		 * The user specified redirect queue will be set while creating
+		 * the ntuple filter in hardware.
+		 */
+		vnic0 = BNXT_GET_DEFAULT_VNIC(bp);
+		if (use_ntuple)
+			filter1 = bnxt_get_l2_filter(bp, filter, vnic0);
+		else
+			filter1 = bnxt_get_l2_filter(bp, filter, vnic);
 		if (filter1 == NULL) {
 			rte_flow_error_set(error,
 					   ENOSPC,
@@ -1252,28 +1256,10 @@ bnxt_validate_and_parse_flow(struct rte_eth_dev *dev,
 		rss = (const struct rte_flow_action_rss *)act->conf;
 
 		vnic_id = attr->group;
-		if (!vnic_id) {
-			PMD_DRV_LOG(ERR, "Group id cannot be 0\n");
-			rte_flow_error_set(error,
-					   EINVAL,
-					   RTE_FLOW_ERROR_TYPE_ATTR,
-					   NULL,
-					   "Group id cannot be 0");
-			rc = -rte_errno;
-			goto ret;
-		}
+
+		BNXT_VALID_VNIC_OR_RET(bp, vnic_id);
 
 		vnic = &bp->vnic_info[vnic_id];
-		if (vnic == NULL) {
-			rte_flow_error_set(error,
-					   EINVAL,
-					   RTE_FLOW_ERROR_TYPE_ACTION,
-					   act,
-					   "No matching VNIC for RSS group.");
-			rc = -rte_errno;
-			goto ret;
-		}
-		PMD_DRV_LOG(DEBUG, "VNIC found\n");
 
 		/* Check if requested RSS config matches RSS config of VNIC
 		 * only if it is not a fresh VNIC configuration.
@@ -1420,11 +1406,6 @@ bnxt_validate_and_parse_flow(struct rte_eth_dev *dev,
 		goto ret;
 	}
 
-	if (filter1 && !filter->matching_l2_fltr_ptr) {
-		bnxt_free_filter(bp, filter1);
-		filter1->fw_l2_filter_id = -1;
-	}
-
 done:
 	act = bnxt_flow_non_void_action(++act);
 	if (act->type != RTE_FLOW_ACTION_TYPE_END) {
@@ -1448,7 +1429,7 @@ bnxt_validate_and_parse_flow(struct rte_eth_dev *dev,
 		if (rxq && !vnic->rx_queue_cnt)
 			rxq->vnic = &bp->vnic_info[0];
 	}
-	return rc;
+	return -rte_errno;
 }
 
 static
@@ -1537,10 +1518,13 @@ bnxt_update_filter(struct bnxt *bp, struct bnxt_filter_info *old_filter,
 	 * filter which points to the new destination queue and so we clear
 	 * the previous L2 filter. For ntuple filters, we are going to reuse
 	 * the old L2 filter and create new NTUPLE filter with this new
Louis Abel's avatar
Louis Abel committed
24201 24202 24203 24204 24205 24206 24207 24208 24209 24210 24211 24212 24213 24214 24215 24216 24217 24218 24219 24220 24221 24222 24223 24224 24225 24226 24227 24228 24229 24230 24231 24232 24233 24234 24235 24236 24237 24238 24239 24240 24241 24242 24243 24244 24245 24246 24247 24248 24249 24250 24251 24252 24253 24254 24255 24256 24257 24258 24259 24260 24261 24262 24263 24264 24265 24266 24267 24268 24269 24270 24271 24272 24273 24274 24275 24276 24277 24278 24279 24280 24281 24282 24283 24284 24285 24286 24287 24288 24289 24290 24291 24292 24293 24294 24295 24296 24297 24298 24299 24300 24301 24302 24303 24304 24305 24306 24307 24308 24309 24310 24311 24312 24313 24314 24315 24316 24317 24318 24319 24320 24321 24322 24323 24324 24325 24326 24327 24328 24329 24330 24331 24332 24333 24334 24335 24336 24337 24338 24339 24340 24341 24342 24343 24344 24345 24346 24347 24348 24349 24350 24351 24352 24353 24354 24355 24356 24357 24358 24359 24360 24361 24362 24363 24364 24365 24366 24367 24368 24369 24370 24371 24372 24373 24374 24375 24376 24377 24378 24379 24380 24381 24382 24383 24384 24385 24386 24387 24388 24389 24390 24391 24392 24393 24394 24395 24396 24397 24398 24399 24400 24401 24402 24403 24404 24405 24406 24407 24408 24409 24410 24411 24412 24413 24414 24415 24416 24417 24418 24419 24420 24421 24422 24423 24424 24425 24426 24427 24428 24429 24430 24431 24432 24433 24434 24435 24436 24437 24438 24439 24440 24441 24442 24443 24444 24445 24446 24447 24448 24449 24450 24451 24452 24453 24454 24455 24456 24457 24458 24459 24460 24461 24462 24463 24464 24465 24466 24467 24468 24469 24470 24471 24472 24473 24474 24475 24476 24477 24478 24479 24480 24481 24482 24483 24484 24485 24486 24487 24488 24489 24490 24491 24492 24493 24494 24495 24496 24497 24498 24499 24500 24501 24502 24503 24504 24505 24506 24507 24508 24509 24510 24511 24512 24513 24514 24515 24516 24517 24518 24519 24520 24521 24522 24523 24524 24525 24526 24527 24528 24529 24530 24531 24532 24533 24534 24535 24536 24537 24538 24539 24540 24541 24542 24543 24544 24545 24546 24547 24548 24549 24550 24551 24552 24553 24554 24555 24556 24557 24558 24559 24560 24561 24562 24563 24564 24565 24566 24567 24568 24569 24570 24571 24572 24573 24574 24575 24576 24577 24578 24579 24580 24581 24582 24583 24584 24585 24586 24587 24588 24589 24590 24591 24592 24593 24594 24595 24596 24597 24598 24599 24600 24601 24602 24603 24604 24605 24606 24607 24608 24609 24610 24611 24612 24613 24614 24615 24616 24617 24618 24619 24620 24621 24622 24623 24624 24625 24626 24627 24628 24629 24630 24631 24632 24633 24634 24635 24636 24637 24638 24639 24640 24641 24642 24643 24644 24645 24646 24647 24648 24649 24650 24651 24652 24653 24654 24655 24656 24657 24658 24659 24660 24661 24662 24663 24664 24665 24666 24667 24668 24669 24670 24671 24672 24673 24674 24675 24676 24677 24678 24679 24680 24681 24682 24683 24684 24685 24686 24687 24688 24689 24690 24691 24692 24693 24694 24695 24696 24697 24698 24699 24700 24701 24702 24703 24704 24705 24706 24707 24708 24709 24710 24711 24712 24713 24714 24715 24716 24717 24718 24719 24720 24721 24722 24723 24724 24725 24726 24727 24728 24729 24730 24731 24732 24733 24734 24735 24736 24737 24738 24739 24740 24741 24742 24743 24744 24745 24746 24747 24748 24749 24750 24751 24752 24753 24754 24755 24756 24757 24758 24759 24760 24761 24762 24763 24764 24765 24766 24767 24768 24769 24770 24771 24772 24773 24774 24775 24776 24777 24778 24779 24780 24781 24782 24783 24784 24785 24786 24787 24788 24789 24790 24791 24792 24793 24794 24795 24796 24797 24798 24799 24800 24801 24802 24803 24804 24805 24806 24807 24808 24809 24810 24811 24812 24813 24814 24815 24816 24817 24818 24819 24820 24821 24822 24823 24824 24825 24826 24827 24828 24829 24830 24831 24832 24833 24834 24835 24836 24837 24838 24839 24840 24841 24842 24843 24844 24845 24846 24847 24848 24849 24850 24851 24852 24853 24854 24855 24856 24857 24858 24859 24860 24861 24862 24863 24864 24865 24866 24867 24868 24869 24870 24871 24872 24873 24874 24875 24876 24877 24878 24879 24880 24881 24882 24883 24884 24885 24886 24887 24888 24889 24890 24891 24892 24893 24894 24895 24896 24897 24898 24899 24900 24901 24902 24903 24904 24905 24906 24907 24908 24909 24910 24911 24912 24913 24914 24915 24916 24917 24918 24919 24920 24921 24922 24923 24924 24925 24926 24927 24928 24929 24930 24931 24932 24933 24934 24935 24936 24937 24938 24939 24940 24941 24942 24943 24944 24945 24946 24947 24948 24949 24950 24951 24952 24953 24954 24955 24956 24957 24958 24959 24960 24961 24962 24963 24964 24965 24966 24967 24968 24969 24970 24971 24972 24973 24974 24975 24976 24977 24978 24979 24980 24981 24982 24983 24984 24985 24986 24987 24988 24989 24990 24991 24992 24993 24994 24995 24996 24997 24998 24999 25000 25001 25002 25003 25004 25005 25006 25007 25008 25009 25010 25011 25012 25013 25014 25015 25016 25017 25018 25019 25020 25021 25022 25023 25024 25025 25026 25027 25028 25029 25030 25031 25032 25033 25034 25035 25036 25037 25038 25039 25040 25041 25042 25043 25044 25045 25046 25047 25048 25049 25050 25051 25052 25053 25054 25055 25056 25057 25058 25059 25060 25061 25062 25063 25064 25065 25066 25067 25068 25069 25070 25071 25072 25073 25074 25075 25076 25077 25078 25079 25080 25081 25082 25083 25084 25085 25086 25087 25088 25089 25090 25091 25092 25093 25094 25095 25096 25097 25098 25099 25100 25101 25102 25103 25104 25105 25106 25107 25108 25109 25110 25111 25112 25113 25114 25115 25116 25117 25118 25119 25120 25121 25122 25123 25124 25125 25126 25127 25128 25129 25130 25131 25132 25133 25134 25135 25136 25137 25138 25139 25140 25141 25142 25143 25144 25145 25146 25147 25148 25149 25150 25151 25152 25153 25154 25155 25156 25157 25158 25159 25160 25161 25162 25163 25164 25165 25166 25167 25168 25169 25170 25171 25172 25173 25174 25175 25176 25177 25178 25179 25180 25181 25182 25183 25184 25185 25186 25187 25188 25189 25190 25191 25192 25193 25194 25195 25196 25197 25198 25199 25200 25201 25202 25203 25204 25205 25206 25207 25208 25209 25210 25211 25212 25213 25214 25215 25216 25217 25218 25219 25220 25221 25222 25223 25224 25225 25226 25227 25228 25229 25230 25231 25232 25233 25234 25235 25236 25237 25238 25239 25240 25241 25242 25243 25244 25245 25246 25247 25248 25249 25250 25251 25252 25253 25254 25255 25256 25257 25258 25259 25260 25261 25262 25263 25264 25265 25266 25267 25268 25269 25270 25271 25272 25273 25274 25275 25276 25277 25278 25279 25280 25281 25282 25283 25284 25285 25286 25287 25288 25289 25290 25291 25292 25293 25294 25295 25296 25297 25298 25299 25300 25301 25302 25303 25304 25305 25306 25307 25308 25309 25310 25311 25312 25313 25314 25315 25316 25317 25318 25319 25320 25321 25322 25323 25324 25325 25326 25327 25328 25329 25330 25331 25332 25333 25334 25335 25336 25337 25338 25339 25340 25341 25342 25343 25344 25345 25346 25347 25348 25349 25350 25351 25352 25353 25354 25355 25356 25357 25358 25359 25360 25361 25362 25363 25364 25365 25366 25367 25368 25369 25370 25371 25372 25373 25374 25375 25376 25377 25378 25379 25380 25381 25382 25383 25384 25385 25386 25387 25388 25389 25390 25391 25392 25393 25394 25395 25396 25397 25398 25399 25400 25401 25402 25403 25404 25405 25406 25407 25408 25409 25410 25411 25412 25413 25414 25415 25416 25417 25418 25419 25420 25421 25422 25423 25424 25425 25426 25427 25428 25429 25430 25431 25432 25433 25434 25435 25436 25437 25438 25439 25440 25441 25442 25443 25444 25445 25446 25447 25448 25449 25450 25451 25452 25453 25454 25455 25456 25457 25458 25459 25460 25461 25462 25463 25464 25465 25466 25467 25468 25469 25470 25471 25472 25473 25474 25475 25476 25477 25478 25479 25480 25481 25482 25483 25484 25485 25486 25487 25488 25489 25490 25491 25492 25493 25494 25495 25496 25497 25498 25499 25500 25501 25502 25503 25504 25505 25506 25507 25508 25509 25510 25511 25512 25513 25514 25515 25516 25517 25518 25519 25520 25521 25522 25523 25524 25525 25526 25527 25528 25529 25530 25531 25532 25533 25534 25535 25536 25537 25538 25539 25540 25541 25542 25543 25544 25545 25546 25547 25548 25549 25550 25551 25552 25553 25554 25555 25556 25557 25558 25559 25560 25561 25562 25563 25564 25565 25566 25567 25568 25569 25570 25571 25572 25573 25574 25575 25576 25577 25578 25579 25580 25581 25582 25583 25584 25585 25586 25587 25588 25589 25590 25591 25592 25593 25594 25595 25596 25597 25598 25599 25600 25601 25602 25603 25604 25605 25606 25607 25608 25609 25610 25611 25612 25613 25614 25615 25616 25617 25618 25619 25620 25621 25622 25623 25624 25625 25626 25627 25628 25629 25630 25631 25632 25633 25634 25635 25636 25637 25638 25639 25640 25641 25642 25643 25644 25645 25646 25647 25648 25649 25650 25651 25652 25653 25654 25655 25656 25657 25658 25659 25660 25661 25662 25663 25664 25665 25666 25667 25668 25669 25670 25671 25672 25673 25674 25675 25676 25677 25678 25679 25680 25681 25682 25683 25684 25685 25686 25687 25688 25689 25690 25691 25692 25693 25694 25695 25696 25697 25698 25699 25700 25701 25702 25703 25704 25705 25706 25707 25708 25709 25710 25711 25712 25713 25714 25715 25716 25717 25718 25719 25720 25721 25722 25723 25724 25725 25726 25727 25728 25729 25730 25731 25732 25733 25734 25735 25736 25737 25738 25739 25740 25741 25742 25743 25744 25745 25746 25747 25748 25749 25750 25751 25752 25753 25754 25755 25756 25757 25758 25759 25760 25761 25762 25763 25764 25765 25766 25767 25768 25769 25770 25771 25772 25773 25774 25775 25776 25777 25778 25779 25780 25781 25782 25783 25784 25785 25786 25787 25788 25789 25790 25791 25792 25793 25794 25795 25796 25797 25798 25799 25800 25801 25802 25803 25804 25805 25806 25807 25808 25809 25810 25811 25812 25813 25814 25815 25816 25817 25818 25819 25820 25821 25822 25823 25824 25825 25826 25827 25828 25829 25830 25831 25832 25833 25834 25835 25836 25837 25838 25839 25840 25841 25842 25843 25844 25845 25846 25847 25848 25849 25850 25851 25852 25853 25854 25855 25856 25857 25858 25859 25860 25861 25862 25863 25864 25865 25866 25867 25868 25869 25870 25871 25872 25873 25874 25875 25876 25877 25878 25879 25880 25881 25882 25883 25884 25885 25886 25887 25888 25889 25890 25891 25892 25893 25894 25895 25896 25897 25898 25899 25900 25901 25902 25903 25904 25905 25906 25907 25908 25909 25910 25911 25912 25913 25914 25915 25916 25917 25918 25919 25920 25921 25922 25923 25924 25925 25926 25927 25928 25929 25930 25931 25932 25933 25934 25935 25936 25937 25938 25939 25940 25941 25942 25943 25944 25945 25946 25947 25948 25949 25950 25951 25952 25953 25954 25955 25956 25957 25958 25959 25960 25961 25962 25963 25964 25965 25966 25967 25968 25969 25970 25971 25972 25973 25974 25975 25976 25977 25978 25979 25980 25981 25982 25983 25984 25985 25986 25987 25988 25989 25990 25991 25992 25993 25994 25995 25996 25997 25998 25999 26000 26001 26002 26003 26004 26005 26006 26007 26008 26009 26010 26011 26012 26013 26014 26015 26016 26017 26018 26019 26020 26021 26022 26023 26024 26025 26026 26027 26028 26029 26030 26031 26032 26033 26034 26035 26036 26037 26038 26039 26040 26041 26042 26043 26044 26045 26046 26047 26048 26049 26050 26051 26052 26053 26054 26055 26056 26057 26058 26059 26060 26061 26062 26063 26064 26065 26066 26067 26068 26069 26070 26071 26072 26073 26074 26075 26076 26077 26078 26079 26080 26081 26082 26083 26084 26085 26086 26087 26088 26089 26090 26091 26092 26093 26094 26095 26096 26097 26098 26099 26100 26101 26102 26103 26104 26105 26106 26107 26108 26109 26110 26111 26112 26113 26114 26115 26116 26117 26118 26119 26120 26121 26122 26123 26124 26125 26126 26127 26128 26129 26130 26131 26132 26133 26134 26135 26136 26137 26138 26139 26140 26141 26142 26143 26144 26145 26146 26147 26148 26149 26150 26151 26152 26153 26154 26155 26156 26157 26158 26159 26160 26161 26162 26163 26164 26165 26166 26167 26168 26169 26170 26171 26172 26173 26174 26175 26176 26177 26178 26179 26180 26181 26182 26183 26184 26185 26186 26187 26188 26189 26190 26191 26192 26193 26194 26195 26196 26197 26198 26199 26200
-	 * destination queue subsequently during bnxt_flow_create.
+	 * destination queue subsequently during bnxt_flow_create. So we
+	 * decrement the ref cnt of the L2 filter that would've been bumped
+	 * up previously in bnxt_validate_and_parse_flow as the old n-tuple
+	 * filter that was referencing it will be deleted now.
 	 */
+	bnxt_hwrm_clear_l2_filter(bp, old_filter);
 	if (new_filter->filter_type == HWRM_CFA_L2_FILTER) {
-		bnxt_hwrm_clear_l2_filter(bp, old_filter);
 		bnxt_hwrm_set_l2_filter(bp, new_filter->dst_id, new_filter);
 	} else {
 		if (new_filter->filter_type == HWRM_CFA_EM_FILTER)
@@ -1663,7 +1647,9 @@ bnxt_flow_create(struct rte_eth_dev *dev,
 
 	filter = bnxt_get_unused_filter(bp);
 	if (filter == NULL) {
-		PMD_DRV_LOG(ERR, "Not enough resources for a new flow.\n");
+		rte_flow_error_set(error, ENOSPC,
+				   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
+				   "Not enough resources for a new flow");
 		goto free_flow;
 	}
 
@@ -1729,12 +1715,24 @@ bnxt_flow_create(struct rte_eth_dev *dev,
 		filter->enables |=
 			HWRM_CFA_EM_FLOW_ALLOC_INPUT_ENABLES_L2_FILTER_ID;
 		ret = bnxt_hwrm_set_em_filter(bp, filter->dst_id, filter);
+		if (ret != 0) {
+			rte_flow_error_set(error, -ret,
+					   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
+					   "Failed to create EM filter");
+			goto free_filter;
+		}
 	}
 
 	if (filter->filter_type == HWRM_CFA_NTUPLE_FILTER) {
 		filter->enables |=
 			HWRM_CFA_NTUPLE_FILTER_ALLOC_INPUT_ENABLES_L2_FILTER_ID;
 		ret = bnxt_hwrm_set_ntuple_filter(bp, filter->dst_id, filter);
+		if (ret != 0) {
+			rte_flow_error_set(error, -ret,
+					   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
+					   "Failed to create ntuple filter");
+			goto free_filter;
+		}
 	}
 
 	vnic = find_matching_vnic(bp, filter);
@@ -1748,9 +1746,9 @@ bnxt_flow_create(struct rte_eth_dev *dev,
 		}
 
 		STAILQ_INSERT_TAIL(&vnic->filter, filter, next);
-		PMD_DRV_LOG(DEBUG, "Successfully created flow.\n");
 		STAILQ_INSERT_TAIL(&vnic->flow_list, flow, next);
 		bnxt_release_flow_lock(bp);
+		PMD_DRV_LOG(DEBUG, "Successfully created flow.\n");
 		return flow;
 	}
 
@@ -1765,7 +1763,7 @@ bnxt_flow_create(struct rte_eth_dev *dev,
 		rte_flow_error_set(error, 0,
 				   RTE_FLOW_ERROR_TYPE_NONE, NULL,
 				   "Flow with pattern exists, updating destination queue");
-	else
+	else if (!rte_errno)
 		rte_flow_error_set(error, -ret,
 				   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
 				   "Failed to create flow.");
@@ -1817,57 +1815,31 @@ static int bnxt_handle_tunnel_redirect_destroy(struct bnxt *bp,
 }
 
 static int
-bnxt_flow_destroy(struct rte_eth_dev *dev,
-		  struct rte_flow *flow,
-		  struct rte_flow_error *error)
+_bnxt_flow_destroy(struct bnxt *bp,
+		   struct rte_flow *flow,
+		    struct rte_flow_error *error)
 {
-	struct bnxt *bp = dev->data->dev_private;
 	struct bnxt_filter_info *filter;
 	struct bnxt_vnic_info *vnic;
 	int ret = 0;
 
-	bnxt_acquire_flow_lock(bp);
-	if (!flow) {
-		rte_flow_error_set(error, EINVAL,
-				   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
-				   "Invalid flow: failed to destroy flow.");
-		bnxt_release_flow_lock(bp);
-		return -EINVAL;
-	}
-
 	filter = flow->filter;
 	vnic = flow->vnic;
 
-	if (!filter) {
-		rte_flow_error_set(error, EINVAL,
-				   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
-				   "Invalid flow: failed to destroy flow.");
-		bnxt_release_flow_lock(bp);
-		return -EINVAL;
-	}
-
 	if (filter->filter_type == HWRM_CFA_TUNNEL_REDIRECT_FILTER &&
 	    filter->enables == filter->tunnel_type) {
-		ret = bnxt_handle_tunnel_redirect_destroy(bp,
-							  filter,
-							  error);
-		if (!ret) {
+		ret = bnxt_handle_tunnel_redirect_destroy(bp, filter, error);
+		if (!ret)
 			goto done;
-		} else {
-			bnxt_release_flow_lock(bp);
+		else
 			return ret;
-		}
 	}
 
 	ret = bnxt_match_filter(bp, filter);
 	if (ret == 0)
 		PMD_DRV_LOG(ERR, "Could not find matching flow\n");
 
-	if (filter->filter_type == HWRM_CFA_EM_FILTER)
-		ret = bnxt_hwrm_clear_em_filter(bp, filter);
-	if (filter->filter_type == HWRM_CFA_NTUPLE_FILTER)
-		ret = bnxt_hwrm_clear_ntuple_filter(bp, filter);
-	ret = bnxt_hwrm_clear_l2_filter(bp, filter);
+	ret = bnxt_clear_one_vnic_filter(bp, filter);
 
 done:
 	if (!ret) {
@@ -1903,7 +1875,36 @@ bnxt_flow_destroy(struct rte_eth_dev *dev,
 				   "Failed to destroy flow.");
 	}
 
+	return ret;
+}
+
+static int
+bnxt_flow_destroy(struct rte_eth_dev *dev,
+		  struct rte_flow *flow,
+		  struct rte_flow_error *error)
+{
+	struct bnxt *bp = dev->data->dev_private;
+	int ret = 0;
+
+	bnxt_acquire_flow_lock(bp);
+	if (!flow) {
+		rte_flow_error_set(error, EINVAL,
+				   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
+				   "Invalid flow: failed to destroy flow.");
+		bnxt_release_flow_lock(bp);
+		return -EINVAL;
+	}
+
+	if (!flow->filter) {
+		rte_flow_error_set(error, EINVAL,
+				   RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
+				   "Invalid flow: failed to destroy flow.");
+		bnxt_release_flow_lock(bp);
+		return -EINVAL;
+	}
+	ret = _bnxt_flow_destroy(bp, flow, error);
 	bnxt_release_flow_lock(bp);
+
 	return ret;
 }
 
@@ -1911,7 +1912,6 @@ static int
 bnxt_flow_flush(struct rte_eth_dev *dev, struct rte_flow_error *error)
 {
 	struct bnxt *bp = dev->data->dev_private;
-	struct bnxt_filter_info *filter = NULL;
 	struct bnxt_vnic_info *vnic;
 	struct rte_flow *flow;
 	unsigned int i;
@@ -1925,66 +1925,17 @@ bnxt_flow_flush(struct rte_eth_dev *dev, struct rte_flow_error *error)
 
 		while (!STAILQ_EMPTY(&vnic->flow_list)) {
 			flow = STAILQ_FIRST(&vnic->flow_list);
-			filter = flow->filter;
-
-			if (filter->filter_type ==
-			    HWRM_CFA_TUNNEL_REDIRECT_FILTER &&
-			    filter->enables == filter->tunnel_type) {
-				ret =
-				bnxt_handle_tunnel_redirect_destroy(bp,
-								    filter,
-								    error);
-				if (!ret) {
-					goto done;
-				} else {
-					bnxt_release_flow_lock(bp);
-					return ret;
-				}
-			}
-
-			if (filter->filter_type == HWRM_CFA_EM_FILTER)
-				ret = bnxt_hwrm_clear_em_filter(bp, filter);
-			if (filter->filter_type == HWRM_CFA_NTUPLE_FILTER)
-				ret = bnxt_hwrm_clear_ntuple_filter(bp, filter);
-			else if (i)
-				ret = bnxt_hwrm_clear_l2_filter(bp, filter);
 
-			if (ret) {
-				rte_flow_error_set
-					(error,
-					 -ret,
-					 RTE_FLOW_ERROR_TYPE_HANDLE,
-					 NULL,
-					 "Failed to flush flow in HW.");
-				bnxt_release_flow_lock(bp);
-				return -rte_errno;
-			}
-done:
-			STAILQ_REMOVE(&vnic->flow_list, flow,
-				      rte_flow, next);
-
-			STAILQ_REMOVE(&vnic->filter,
-				      filter,
-				      bnxt_filter_info,
-				      next);
-			bnxt_free_filter(bp, filter);
-
-			rte_free(flow);
+			if (!flow->filter)
+				continue;
 
-			/* If this was the last flow associated with this vnic,
-			 * switch the queue back to RSS pool.
-			 */
-			if (STAILQ_EMPTY(&vnic->flow_list)) {
-				rte_free(vnic->fw_grp_ids);
-				if (vnic->rx_queue_cnt > 1)
-					bnxt_hwrm_vnic_ctx_free(bp, vnic);
-				bnxt_hwrm_vnic_free(bp, vnic);
-				vnic->rx_queue_cnt = 0;
-			}
+			ret = _bnxt_flow_destroy(bp, flow, error);
+			if (ret)
+				break;
 		}
 	}
-
 	bnxt_release_flow_lock(bp);
+
 	return ret;
 }
 
diff --git a/dpdk/drivers/net/bnxt/bnxt_hwrm.c b/dpdk/drivers/net/bnxt/bnxt_hwrm.c
index 41730089b1..8025d5ad78 100644
--- a/dpdk/drivers/net/bnxt/bnxt_hwrm.c
+++ b/dpdk/drivers/net/bnxt/bnxt_hwrm.c
@@ -52,7 +52,7 @@ static int page_getenum(size_t size)
 	if (size <= 1 << 30)
 		return 30;
 	PMD_DRV_LOG(ERR, "Page size %zu out of range\n", size);
-	return sizeof(void *) * 8 - 1;
+	return sizeof(int) * 8 - 1;
 }
 
 static int page_roundup(size_t size)
@@ -100,11 +100,7 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
 	if (bp->flags & BNXT_FLAG_FATAL_ERROR)
 		return 0;
 
-	/* For VER_GET command, set timeout as 50ms */
-	if (rte_cpu_to_le_16(req->req_type) == HWRM_VER_GET)
-		timeout = HWRM_CMD_TIMEOUT;
-	else
-		timeout = bp->hwrm_cmd_timeout;
+	timeout = bp->hwrm_cmd_timeout;
 
 	if (bp->flags & BNXT_FLAG_SHORT_CMD ||
 	    msg_len > bp->max_req_len) {
@@ -168,8 +164,9 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
 		    rte_cpu_to_le_16(req->req_type) == HWRM_VER_GET)
 			return -ETIMEDOUT;
 
-		PMD_DRV_LOG(ERR, "Error(timeout) sending msg 0x%04x\n",
-			    req->req_type);
+		PMD_DRV_LOG(ERR,
+			    "Error(timeout) sending msg 0x%04x, seq_id %d\n",
+			    req->req_type, req->seq_id);
 		return -ETIMEDOUT;
 	}
 	return 0;
@@ -188,6 +185,10 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
  */
 #define HWRM_PREP(req, type, kong) do { \
 	rte_spinlock_lock(&bp->hwrm_lock); \
+	if (bp->hwrm_cmd_resp_addr == NULL) { \
+		rte_spinlock_unlock(&bp->hwrm_lock); \
+		return -EACCES; \
+	} \
 	memset(bp->hwrm_cmd_resp_addr, 0, bp->max_resp_len); \
 	req.req_type = rte_cpu_to_le_16(HWRM_##type); \
 	req.cmpl_ring = rte_cpu_to_le_16(-1); \
@@ -221,6 +222,8 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
 			rc = -EINVAL; \
 		else if (rc == HWRM_ERR_CODE_CMD_NOT_SUPPORTED) \
 			rc = -ENOTSUP; \
+		else if (rc == HWRM_ERR_CODE_HOT_RESET_PROGRESS) \
+			rc = -EAGAIN; \
 		else if (rc > 0) \
 			rc = -EIO; \
 		return rc; \
@@ -249,6 +252,8 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg,
 			rc = -EINVAL; \
 		else if (rc == HWRM_ERR_CODE_CMD_NOT_SUPPORTED) \
 			rc = -ENOTSUP; \
+		else if (rc == HWRM_ERR_CODE_HOT_RESET_PROGRESS) \
+			rc = -EAGAIN; \
 		else if (rc > 0) \
 			rc = -EIO; \
 		return rc; \
@@ -309,8 +314,8 @@ int bnxt_hwrm_cfa_l2_set_rx_mask(struct bnxt *bp,
 	if (vlan_table) {
 		if (!(mask & HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_VLAN_NONVLAN))
 			mask |= HWRM_CFA_L2_SET_RX_MASK_INPUT_MASK_VLANONLY;
-		req.vlan_tag_tbl_addr = rte_cpu_to_le_64(
-			 rte_mem_virt2iova(vlan_table));
+		req.vlan_tag_tbl_addr =
+			rte_cpu_to_le_64(rte_malloc_virt2iova(vlan_table));
 		req.num_vlan_tags = rte_cpu_to_le_32((uint32_t)vlan_count);
 	}
 	req.mask = rte_cpu_to_le_32(mask);
@@ -351,7 +356,7 @@ int bnxt_hwrm_cfa_vlan_antispoof_cfg(struct bnxt *bp, uint16_t fid,
 	req.fid = rte_cpu_to_le_16(fid);
 
 	req.vlan_tag_mask_tbl_addr =
-		rte_cpu_to_le_64(rte_mem_virt2iova(vlan_table));
+		rte_cpu_to_le_64(rte_malloc_virt2iova(vlan_table));
 	req.num_vlan_entries = rte_cpu_to_le_32((uint32_t)vlan_count);
 
 	rc = bnxt_hwrm_send_message(bp, &req, sizeof(req), BNXT_USE_CHIMP_MB);
@@ -363,10 +368,11 @@ int bnxt_hwrm_cfa_vlan_antispoof_cfg(struct bnxt *bp, uint16_t fid,
 }
 
 int bnxt_hwrm_clear_l2_filter(struct bnxt *bp,
-			   struct bnxt_filter_info *filter)
+			     struct bnxt_filter_info *filter)
 {
 	int rc = 0;
 	struct bnxt_filter_info *l2_filter = filter;
+	struct bnxt_vnic_info *vnic = NULL;
 	struct hwrm_cfa_l2_filter_free_input req = {.req_type = 0 };
 	struct hwrm_cfa_l2_filter_free_output *resp = bp->hwrm_cmd_resp_addr;
 
@@ -379,6 +385,9 @@ int bnxt_hwrm_clear_l2_filter(struct bnxt *bp,
 	PMD_DRV_LOG(DEBUG, "filter: %p l2_filter: %p ref_cnt: %d\n",
 		    filter, l2_filter, l2_filter->l2_ref_cnt);
 
+	if (l2_filter->l2_ref_cnt == 0)
+		return 0;
+
 	if (l2_filter->l2_ref_cnt > 0)
 		l2_filter->l2_ref_cnt--;
 
@@ -395,6 +404,14 @@ int bnxt_hwrm_clear_l2_filter(struct bnxt *bp,
 	HWRM_UNLOCK();
 
 	filter->fw_l2_filter_id = UINT64_MAX;
+	if (l2_filter->l2_ref_cnt == 0) {
+		vnic = l2_filter->vnic;
+		if (vnic) {
+			STAILQ_REMOVE(&vnic->filter, l2_filter,
+				      bnxt_filter_info, next);
+			bnxt_free_filter(bp, l2_filter);
+		}
+	}
 
 	return 0;
 }
@@ -430,6 +447,9 @@ int bnxt_hwrm_set_l2_filter(struct bnxt *bp,
 
 	HWRM_PREP(req, CFA_L2_FILTER_ALLOC, BNXT_USE_CHIMP_MB);
 
+	/* PMD does not support XDP and RoCE */
+	filter->flags |= HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_XDP_DISABLE |
+			HWRM_CFA_L2_FILTER_ALLOC_INPUT_FLAGS_TRAFFIC_L2;
 	req.flags = rte_cpu_to_le_32(filter->flags);
 
 	enables = filter->enables |
@@ -475,6 +495,8 @@ int bnxt_hwrm_set_l2_filter(struct bnxt *bp,
 	filter->fw_l2_filter_id = rte_le_to_cpu_64(resp->l2_filter_id);
 	HWRM_UNLOCK();
 
+	filter->l2_ref_cnt++;
+
 	return rc;
 }
 
@@ -567,6 +589,20 @@ static int bnxt_hwrm_ptp_qcfg(struct bnxt *bp)
 	return 0;
 }
 
+void bnxt_hwrm_free_vf_info(struct bnxt *bp)
+{
+	uint16_t i;
+
+	for (i = 0; i < bp->pf.max_vfs; i++) {
+		rte_free(bp->pf.vf_info[i].vlan_table);
+		bp->pf.vf_info[i].vlan_table = NULL;
+		rte_free(bp->pf.vf_info[i].vlan_as_table);
+		bp->pf.vf_info[i].vlan_as_table = NULL;
+	}
+	rte_free(bp->pf.vf_info);
+	bp->pf.vf_info = NULL;
+}
+
 static int __bnxt_hwrm_func_qcaps(struct bnxt *bp)
 {
 	int rc = 0;
@@ -593,9 +629,14 @@ static int __bnxt_hwrm_func_qcaps(struct bnxt *bp)
 		new_max_vfs = bp->pdev->max_vfs;
 		if (new_max_vfs != bp->pf.max_vfs) {
 			if (bp->pf.vf_info)
-				rte_free(bp->pf.vf_info);
-			bp->pf.vf_info = rte_malloc("bnxt_vf_info",
+				bnxt_hwrm_free_vf_info(bp);
+			bp->pf.vf_info = rte_zmalloc("bnxt_vf_info",
 			    sizeof(bp->pf.vf_info[0]) * new_max_vfs, 0);
+			if (bp->pf.vf_info == NULL) {
+				PMD_DRV_LOG(ERR, "Alloc vf info fail\n");
+				HWRM_UNLOCK();
+				return -ENOMEM;
+			}
 			bp->pf.max_vfs = new_max_vfs;
 			for (i = 0; i < new_max_vfs; i++) {
 				bp->pf.vf_info[i].fid = bp->pf.first_vf_id + i;
@@ -627,7 +668,12 @@ static int __bnxt_hwrm_func_qcaps(struct bnxt *bp)
 	}
 
 	bp->fw_fid = rte_le_to_cpu_32(resp->fid);
-	memcpy(bp->dflt_mac_addr, &resp->mac_address, RTE_ETHER_ADDR_LEN);
+	if (!bnxt_check_zero_bytes(resp->mac_address, RTE_ETHER_ADDR_LEN)) {
+		bp->flags |= BNXT_FLAG_DFLT_MAC_SET;
+		memcpy(bp->mac_addr, &resp->mac_address, RTE_ETHER_ADDR_LEN);
+	} else {
+		bp->flags &= ~BNXT_FLAG_DFLT_MAC_SET;
+	}
 	bp->max_rsscos_ctx = rte_le_to_cpu_16(resp->max_rsscos_ctx);
 	bp->max_cp_rings = rte_le_to_cpu_16(resp->max_cmpl_rings);
 	bp->max_tx_rings = rte_le_to_cpu_16(resp->max_tx_rings);
@@ -661,16 +707,15 @@ static int __bnxt_hwrm_func_qcaps(struct bnxt *bp)
 		bp->flags |= BNXT_FLAG_EXT_STATS_SUPPORTED;
 
 	if (flags & HWRM_FUNC_QCAPS_OUTPUT_FLAGS_ERROR_RECOVERY_CAPABLE) {
-		bp->flags |= BNXT_FLAG_FW_CAP_ERROR_RECOVERY;
+		bp->fw_cap |= BNXT_FW_CAP_ERROR_RECOVERY;
 		PMD_DRV_LOG(DEBUG, "Adapter Error recovery SUPPORTED\n");
-	} else {
-		bp->flags &= ~BNXT_FLAG_FW_CAP_ERROR_RECOVERY;
 	}
 
 	if (flags & HWRM_FUNC_QCAPS_OUTPUT_FLAGS_ERR_RECOVER_RELOAD)
-		bp->flags |= BNXT_FLAG_FW_CAP_ERR_RECOVER_RELOAD;
-	else
-		bp->flags &= ~BNXT_FLAG_FW_CAP_ERR_RECOVER_RELOAD;
+		bp->fw_cap |= BNXT_FW_CAP_ERR_RECOVER_RELOAD;
+
+	if (flags & HWRM_FUNC_QCAPS_OUTPUT_FLAGS_HOT_RESET_CAPABLE)
+		bp->fw_cap |= BNXT_FW_CAP_HOT_RESET;
 
 	HWRM_UNLOCK();
 
@@ -756,8 +801,9 @@ int bnxt_hwrm_func_driver_register(struct bnxt *bp)
 	if (bp->flags & BNXT_FLAG_REGISTERED)
 		return 0;
 
-	flags = HWRM_FUNC_DRV_RGTR_INPUT_FLAGS_HOT_RESET_SUPPORT;
-	if (bp->flags & BNXT_FLAG_FW_CAP_ERROR_RECOVERY)
+	if (bp->fw_cap & BNXT_FW_CAP_HOT_RESET)
+		flags = HWRM_FUNC_DRV_RGTR_INPUT_FLAGS_HOT_RESET_SUPPORT;
+	if (bp->fw_cap & BNXT_FW_CAP_ERROR_RECOVERY)
 		flags |= HWRM_FUNC_DRV_RGTR_INPUT_FLAGS_ERROR_RECOVERY_SUPPORT;
 
 	/* PFs and trusted VFs should indicate the support of the
@@ -797,7 +843,7 @@ int bnxt_hwrm_func_driver_register(struct bnxt *bp)
 				 ASYNC_CMPL_EVENT_ID_LINK_SPEED_CFG_CHANGE |
 				 ASYNC_CMPL_EVENT_ID_LINK_SPEED_CHANGE |
 				 ASYNC_CMPL_EVENT_ID_RESET_NOTIFY);
-	if (bp->flags & BNXT_FLAG_FW_CAP_ERROR_RECOVERY)
+	if (bp->fw_cap & BNXT_FW_CAP_ERROR_RECOVERY)
 		req.async_event_fwd[0] |=
 			rte_cpu_to_le_32(ASYNC_CMPL_EVENT_ID_ERROR_RECOVERY);
 	req.async_event_fwd[1] |=
@@ -810,7 +856,7 @@ int bnxt_hwrm_func_driver_register(struct bnxt *bp)
 
 	flags = rte_le_to_cpu_32(resp->flags);
 	if (flags & HWRM_FUNC_DRV_RGTR_OUTPUT_FLAGS_IF_CHANGE_SUPPORTED)
-		bp->flags |= BNXT_FLAG_FW_CAP_IF_CHANGE;
+		bp->fw_cap |= BNXT_FW_CAP_IF_CHANGE;
 
 	HWRM_UNLOCK();
 
@@ -934,7 +980,7 @@ int bnxt_hwrm_func_resc_qcaps(struct bnxt *bp)
 	return rc;
 }
 
-int bnxt_hwrm_ver_get(struct bnxt *bp)
+int bnxt_hwrm_ver_get(struct bnxt *bp, uint32_t timeout)
 {
 	int rc = 0;
 	struct hwrm_ver_get_input req = {.req_type = 0 };
@@ -945,6 +991,7 @@ int bnxt_hwrm_ver_get(struct bnxt *bp)
 	uint32_t dev_caps_cfg;
 
 	bp->max_req_len = HWRM_MAX_REQ_LEN;
+	bp->hwrm_cmd_timeout = timeout;
 	HWRM_PREP(req, VER_GET, BNXT_USE_CHIMP_MB);
 
 	req.hwrm_intf_maj = HWRM_VERSION_MAJOR;
@@ -958,10 +1005,11 @@ int bnxt_hwrm_ver_get(struct bnxt *bp)
 	else
 		HWRM_CHECK_RESULT();
 
-	PMD_DRV_LOG(INFO, "%d.%d.%d:%d.%d.%d\n",
+	PMD_DRV_LOG(INFO, "%d.%d.%d:%d.%d.%d.%d\n",
 		resp->hwrm_intf_maj_8b, resp->hwrm_intf_min_8b,
 		resp->hwrm_intf_upd_8b, resp->hwrm_fw_maj_8b,
-		resp->hwrm_fw_min_8b, resp->hwrm_fw_bld_8b);
+		resp->hwrm_fw_min_8b, resp->hwrm_fw_bld_8b,
+		resp->hwrm_fw_rsvd_8b);
 	bp->fw_ver = (resp->hwrm_fw_maj_8b << 24) |
 		     (resp->hwrm_fw_min_8b << 16) |
 		     (resp->hwrm_fw_bld_8b << 8) |
@@ -979,7 +1027,7 @@ int bnxt_hwrm_ver_get(struct bnxt *bp)
 	/* convert timeout to usec */
 	bp->hwrm_cmd_timeout *= 1000;
 	if (!bp->hwrm_cmd_timeout)
-		bp->hwrm_cmd_timeout = HWRM_CMD_TIMEOUT;
+		bp->hwrm_cmd_timeout = DFLT_HWRM_CMD_TIMEOUT;
 
 	if (resp->hwrm_intf_maj_8b != HWRM_VERSION_MAJOR) {
 		PMD_DRV_LOG(ERR, "Unsupported firmware API version\n");
@@ -1011,9 +1059,8 @@ int bnxt_hwrm_ver_get(struct bnxt *bp)
 			rc = -ENOMEM;
 			goto error;
 		}
-		rte_mem_lock_page(bp->hwrm_cmd_resp_addr);
 		bp->hwrm_cmd_resp_dma_addr =
-			rte_mem_virt2iova(bp->hwrm_cmd_resp_addr);
+			rte_malloc_virt2iova(bp->hwrm_cmd_resp_addr);
 		if (bp->hwrm_cmd_resp_dma_addr == RTE_BAD_IOVA) {
 			PMD_DRV_LOG(ERR,
 			"Unable to map response buffer to physical memory.\n");
@@ -1048,9 +1095,8 @@ int bnxt_hwrm_ver_get(struct bnxt *bp)
 			rc = -ENOMEM;
 			goto error;
 		}
-		rte_mem_lock_page(bp->hwrm_short_cmd_req_addr);
 		bp->hwrm_short_cmd_req_dma_addr =
-			rte_mem_virt2iova(bp->hwrm_short_cmd_req_addr);
+			rte_malloc_virt2iova(bp->hwrm_short_cmd_req_addr);
 		if (bp->hwrm_short_cmd_req_dma_addr == RTE_BAD_IOVA) {
 			rte_free(bp->hwrm_short_cmd_req_addr);
 			PMD_DRV_LOG(ERR,
@@ -1210,6 +1256,35 @@ static int bnxt_hwrm_port_phy_qcfg(struct bnxt *bp,
 	return rc;
 }
 
+static bool bnxt_find_lossy_profile(struct bnxt *bp)
+{
+	int i = 0;
+
+	for (i = BNXT_COS_QUEUE_COUNT - 1; i >= 0; i--) {
+		if (bp->tx_cos_queue[i].profile ==
+		    HWRM_QUEUE_SERVICE_PROFILE_LOSSY) {
+			bp->tx_cosq_id[0] = bp->tx_cos_queue[i].id;
+			return true;
+		}
+	}
+	return false;
+}
+
+static void bnxt_find_first_valid_profile(struct bnxt *bp)
+{
+	int i = 0;
+
+	for (i = BNXT_COS_QUEUE_COUNT - 1; i >= 0; i--) {
+		if (bp->tx_cos_queue[i].profile !=
+		    HWRM_QUEUE_SERVICE_PROFILE_UNKNOWN &&
+		    bp->tx_cos_queue[i].id !=
+		    HWRM_QUEUE_SERVICE_PROFILE_UNKNOWN) {
+			bp->tx_cosq_id[0] = bp->tx_cos_queue[i].id;
+			break;
+		}
+	}
+}
+
 int bnxt_hwrm_queue_qportcfg(struct bnxt *bp)
 {
 	int rc = 0;
@@ -1269,14 +1344,13 @@ int bnxt_hwrm_queue_qportcfg(struct bnxt *bp)
 						bp->tx_cos_queue[i].id;
 			}
 		} else {
-			for (i = BNXT_COS_QUEUE_COUNT - 1; i >= 0; i--) {
-				if (bp->tx_cos_queue[i].profile ==
-					HWRM_QUEUE_SERVICE_PROFILE_LOSSY) {
-					bp->tx_cosq_id[0] =
-						bp->tx_cos_queue[i].id;
-					break;
-				}
-			}
+			/* When CoS classification is disabled, for normal NIC
+			 * operations, ideally we should look to use LOSSY.
+			 * If not found, fallback to the first valid profile
+			 */
+			if (!bnxt_find_lossy_profile(bp))
+				bnxt_find_first_valid_profile(bp);
+
 		}
 	}
 
@@ -2072,8 +2146,8 @@ int bnxt_hwrm_vnic_tpa_cfg(struct bnxt *bp,
 				HWRM_VNIC_TPA_CFG_INPUT_FLAGS_GRO |
 				HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_ECN |
 			HWRM_VNIC_TPA_CFG_INPUT_FLAGS_AGG_WITH_SAME_GRE_SEQ);
-		req.max_agg_segs = rte_cpu_to_le_16(BNXT_TPA_MAX_AGGS(bp));
-		req.max_aggs = rte_cpu_to_le_16(BNXT_TPA_MAX_SEGS(bp));
+		req.max_aggs = rte_cpu_to_le_16(BNXT_TPA_MAX_AGGS(bp));
+		req.max_agg_segs = rte_cpu_to_le_16(BNXT_TPA_MAX_SEGS(bp));
 		req.min_agg_len = rte_cpu_to_le_32(512);
 	}
 	req.vnic_id = rte_cpu_to_le_16(vnic->fw_vnic_id);
@@ -2325,13 +2399,6 @@ void bnxt_free_hwrm_rx_ring(struct bnxt *bp, int queue_index)
 		if (BNXT_HAS_RING_GRPS(bp))
 			bp->grp_info[queue_index].rx_fw_ring_id =
 							INVALID_HW_RING_ID;
-		memset(rxr->rx_desc_ring, 0,
-		       rxr->rx_ring_struct->ring_size *
-		       sizeof(*rxr->rx_desc_ring));
-		memset(rxr->rx_buf_ring, 0,
-		       rxr->rx_ring_struct->ring_size *
-		       sizeof(*rxr->rx_buf_ring));
-		rxr->rx_prod = 0;
 	}
 	ring = rxr->ag_ring_struct;
 	if (ring->fw_ring_id != INVALID_HW_RING_ID) {
@@ -2339,11 +2406,6 @@ void bnxt_free_hwrm_rx_ring(struct bnxt *bp, int queue_index)
 				    BNXT_CHIP_THOR(bp) ?
 				    HWRM_RING_FREE_INPUT_RING_TYPE_RX_AGG :
 				    HWRM_RING_FREE_INPUT_RING_TYPE_RX);
-		ring->fw_ring_id = INVALID_HW_RING_ID;
-		memset(rxr->ag_buf_ring, 0,
-		       rxr->ag_ring_struct->ring_size *
-		       sizeof(*rxr->ag_buf_ring));
-		rxr->ag_prod = 0;
 		if (BNXT_HAS_RING_GRPS(bp))
 			bp->grp_info[queue_index].ag_fw_ring_id =
 							INVALID_HW_RING_ID;
@@ -2430,11 +2492,10 @@ int bnxt_alloc_hwrm_resources(struct bnxt *bp)
 		pdev->addr.bus, pdev->addr.devid, pdev->addr.function);
 	bp->max_resp_len = HWRM_MAX_RESP_LEN;
 	bp->hwrm_cmd_resp_addr = rte_malloc(type, bp->max_resp_len, 0);
-	rte_mem_lock_page(bp->hwrm_cmd_resp_addr);
 	if (bp->hwrm_cmd_resp_addr == NULL)
 		return -ENOMEM;
 	bp->hwrm_cmd_resp_dma_addr =
-		rte_mem_virt2iova(bp->hwrm_cmd_resp_addr);
+		rte_malloc_virt2iova(bp->hwrm_cmd_resp_addr);
 	if (bp->hwrm_cmd_resp_dma_addr == RTE_BAD_IOVA) {
 		PMD_DRV_LOG(ERR,
 			"unable to map response address to physical memory\n");
@@ -2445,18 +2506,32 @@ int bnxt_alloc_hwrm_resources(struct bnxt *bp)
 	return 0;
 }
 
+int
+bnxt_clear_one_vnic_filter(struct bnxt *bp, struct bnxt_filter_info *filter)
+{
+	int rc = 0;
+
+	if (filter->filter_type == HWRM_CFA_EM_FILTER) {
+		rc = bnxt_hwrm_clear_em_filter(bp, filter);
+		if (rc)
+			return rc;
+	} else if (filter->filter_type == HWRM_CFA_NTUPLE_FILTER) {
+		rc = bnxt_hwrm_clear_ntuple_filter(bp, filter);
+		if (rc)
+			return rc;
+	}
+
+	rc = bnxt_hwrm_clear_l2_filter(bp, filter);
+	return rc;
+}
+
 int bnxt_clear_hwrm_vnic_filters(struct bnxt *bp, struct bnxt_vnic_info *vnic)
 {
 	struct bnxt_filter_info *filter;
 	int rc = 0;
 
 	STAILQ_FOREACH(filter, &vnic->filter, next) {
-		if (filter->filter_type == HWRM_CFA_EM_FILTER)
-			rc = bnxt_hwrm_clear_em_filter(bp, filter);
-		else if (filter->filter_type == HWRM_CFA_NTUPLE_FILTER)
-			rc = bnxt_hwrm_clear_ntuple_filter(bp, filter);
-		else
-			rc = bnxt_hwrm_clear_l2_filter(bp, filter);
+		rc = bnxt_clear_one_vnic_filter(bp, filter);
 		STAILQ_REMOVE(&vnic->filter, filter, bnxt_filter_info, next);
 		bnxt_free_filter(bp, filter);
 	}
@@ -2474,12 +2549,7 @@ bnxt_clear_hwrm_vnic_flows(struct bnxt *bp, struct bnxt_vnic_info *vnic)
 		flow = STAILQ_FIRST(&vnic->flow_list);
 		filter = flow->filter;
 		PMD_DRV_LOG(DEBUG, "filter type %d\n", filter->filter_type);
-		if (filter->filter_type == HWRM_CFA_EM_FILTER)
-			rc = bnxt_hwrm_clear_em_filter(bp, filter);
-		else if (filter->filter_type == HWRM_CFA_NTUPLE_FILTER)
-			rc = bnxt_hwrm_clear_ntuple_filter(bp, filter);
-		else
-			rc = bnxt_hwrm_clear_l2_filter(bp, filter);
+		rc = bnxt_clear_one_vnic_filter(bp, filter);
 
 		STAILQ_REMOVE(&vnic->flow_list, flow, rte_flow, next);
 		rte_free(flow);
@@ -2914,10 +2984,10 @@ int bnxt_hwrm_func_qcfg(struct bnxt *bp, uint16_t *mtu)
 	case HWRM_FUNC_QCFG_OUTPUT_PORT_PARTITION_TYPE_NPAR1_5:
 	case HWRM_FUNC_QCFG_OUTPUT_PORT_PARTITION_TYPE_NPAR2_0:
 		/* FALLTHROUGH */
-		bp->port_partition_type = resp->port_partition_type;
+		bp->flags |= BNXT_FLAG_NPAR_PF;
 		break;
 	default:
-		bp->port_partition_type = 0;
+		bp->flags &= ~BNXT_FLAG_NPAR_PF;
 		break;
 	}
 
@@ -3053,9 +3123,9 @@ static void add_random_mac_if_needed(struct bnxt *bp,
 	}
 }
 
-static void reserve_resources_from_vf(struct bnxt *bp,
-				      struct hwrm_func_cfg_input *cfg_req,
-				      int vf)
+static int reserve_resources_from_vf(struct bnxt *bp,
+				     struct hwrm_func_cfg_input *cfg_req,
+				     int vf)
 {
 	struct hwrm_func_qcaps_input req = {0};
 	struct hwrm_func_qcaps_output *resp = bp->hwrm_cmd_resp_addr;
@@ -3089,6 +3159,8 @@ static void reserve_resources_from_vf(struct bnxt *bp,
 	bp->max_ring_grps -= rte_le_to_cpu_16(resp->max_hw_ring_grps);
 
 	HWRM_UNLOCK();
+
+	return 0;
 }
 
 int bnxt_hwrm_func_qcfg_current_vf_vlan(struct bnxt *bp, int vf)
@@ -3297,17 +3369,19 @@ int bnxt_hwrm_tunnel_dst_port_alloc(struct bnxt *bp, uint16_t port,
 
 	HWRM_PREP(req, TUNNEL_DST_PORT_ALLOC, BNXT_USE_CHIMP_MB);
 	req.tunnel_type = tunnel_type;
-	req.tunnel_dst_port_val = port;
+	req.tunnel_dst_port_val = rte_cpu_to_be_16(port);
 	rc = bnxt_hwrm_send_message(bp, &req, sizeof(req), BNXT_USE_CHIMP_MB);
 	HWRM_CHECK_RESULT();
 
 	switch (tunnel_type) {
 	case HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_VXLAN:
-		bp->vxlan_fw_dst_port_id = resp->tunnel_dst_port_id;
+		bp->vxlan_fw_dst_port_id =
+			rte_le_to_cpu_16(resp->tunnel_dst_port_id);
 		bp->vxlan_port = port;
 		break;
 	case HWRM_TUNNEL_DST_PORT_ALLOC_INPUT_TUNNEL_TYPE_GENEVE:
-		bp->geneve_fw_dst_port_id = resp->tunnel_dst_port_id;
+		bp->geneve_fw_dst_port_id =
+			rte_le_to_cpu_16(resp->tunnel_dst_port_id);
 		bp->geneve_port = port;
 		break;
 	default:
@@ -3382,7 +3456,7 @@ int bnxt_hwrm_func_buf_rgtr(struct bnxt *bp)
 			 page_getenum(bp->pf.active_vfs * HWRM_MAX_REQ_LEN));
 	req.req_buf_len = rte_cpu_to_le_16(HWRM_MAX_REQ_LEN);
 	req.req_buf_page_addr0 =
-		rte_cpu_to_le_64(rte_mem_virt2iova(bp->pf.vf_req_buf));
+		rte_cpu_to_le_64(rte_malloc_virt2iova(bp->pf.vf_req_buf));
 	if (req.req_buf_page_addr0 == RTE_BAD_IOVA) {
 		PMD_DRV_LOG(ERR,
 			"unable to map buffer address to physical memory\n");
@@ -3812,11 +3886,11 @@ int bnxt_get_nvram_directory(struct bnxt *bp, uint32_t len, uint8_t *data)
 
 	buflen = dir_entries * entry_length;
 	buf = rte_malloc("nvm_dir", buflen, 0);
-	rte_mem_lock_page(buf);
 	if (buf == NULL)
 		return -ENOMEM;
-	dma_handle = rte_mem_virt2iova(buf);
+	dma_handle = rte_malloc_virt2iova(buf);
 	if (dma_handle == RTE_BAD_IOVA) {
+		rte_free(buf);
 		PMD_DRV_LOG(ERR,
 			"unable to map response address to physical memory\n");
 		return -ENOMEM;
@@ -3846,12 +3920,12 @@ int bnxt_hwrm_get_nvram_item(struct bnxt *bp, uint32_t index,
 	struct hwrm_nvm_read_output *resp = bp->hwrm_cmd_resp_addr;
 
 	buf = rte_malloc("nvm_item", length, 0);
-	rte_mem_lock_page(buf);
 	if (!buf)
 		return -ENOMEM;
 
-	dma_handle = rte_mem_virt2iova(buf);
+	dma_handle = rte_malloc_virt2iova(buf);
 	if (dma_handle == RTE_BAD_IOVA) {
+		rte_free(buf);
 		PMD_DRV_LOG(ERR,
 			"unable to map response address to physical memory\n");
 		return -ENOMEM;
@@ -3900,12 +3974,12 @@ int bnxt_hwrm_flash_nvram(struct bnxt *bp, uint16_t dir_type,
 	uint8_t *buf;
 
 	buf = rte_malloc("nvm_write", data_len, 0);
-	rte_mem_lock_page(buf);
 	if (!buf)
 		return -ENOMEM;
 
-	dma_handle = rte_mem_virt2iova(buf);
+	dma_handle = rte_malloc_virt2iova(buf);
 	if (dma_handle == RTE_BAD_IOVA) {
+		rte_free(buf);
 		PMD_DRV_LOG(ERR,
 			"unable to map response address to physical memory\n");
 		return -ENOMEM;
@@ -3967,7 +4041,7 @@ static int bnxt_hwrm_func_vf_vnic_query(struct bnxt *bp, uint16_t vf,
 
 	req.vf_id = rte_cpu_to_le_16(bp->pf.first_vf_id + vf);
 	req.max_vnic_id_cnt = rte_cpu_to_le_32(bp->pf.total_vnics);
-	req.vnic_id_tbl_addr = rte_cpu_to_le_64(rte_mem_virt2iova(vnic_ids));
+	req.vnic_id_tbl_addr = rte_cpu_to_le_64(rte_malloc_virt2iova(vnic_ids));
 
 	if (req.vnic_id_tbl_addr == RTE_BAD_IOVA) {
 		HWRM_UNLOCK();
@@ -4391,37 +4465,35 @@ int bnxt_vnic_rss_configure(struct bnxt *bp, struct bnxt_vnic_info *vnic)
 {
 	unsigned int rss_idx, fw_idx, i;
 
+	if (vnic->fw_vnic_id == INVALID_HW_RING_ID)
+		return 0;
+
 	if (!(vnic->rss_table && vnic->hash_type))
 		return 0;
 
 	if (BNXT_CHIP_THOR(bp))
 		return bnxt_vnic_rss_configure_thor(bp, vnic);
 
-	if (vnic->fw_vnic_id == INVALID_HW_RING_ID)
-		return 0;
-
-	if (vnic->rss_table && vnic->hash_type) {
-		/*
-		 * Fill the RSS hash & redirection table with
-		 * ring group ids for all VNICs
-		 */
-		for (rss_idx = 0, fw_idx = 0; rss_idx < HW_HASH_INDEX_SIZE;
-			rss_idx++, fw_idx++) {
-			for (i = 0; i < bp->rx_cp_nr_rings; i++) {
-				fw_idx %= bp->rx_cp_nr_rings;
-				if (vnic->fw_grp_ids[fw_idx] !=
-				    INVALID_HW_RING_ID)
-					break;
-				fw_idx++;
-			}
-			if (i == bp->rx_cp_nr_rings)
-				return 0;
-			vnic->rss_table[rss_idx] = vnic->fw_grp_ids[fw_idx];
+	/*
+	 * Fill the RSS hash & redirection table with
+	 * ring group ids for all VNICs
+	 */
+	for (rss_idx = 0, fw_idx = 0; rss_idx < HW_HASH_INDEX_SIZE;
+	     rss_idx++, fw_idx++) {
+		for (i = 0; i < bp->rx_cp_nr_rings; i++) {
+			fw_idx %= bp->rx_cp_nr_rings;
+			if (vnic->fw_grp_ids[fw_idx] != INVALID_HW_RING_ID)
+				break;
+			fw_idx++;
 		}
-		return bnxt_hwrm_vnic_rss_cfg(bp, vnic);
+
+		if (i == bp->rx_cp_nr_rings)
+			return 0;
+
+		vnic->rss_table[rss_idx] = vnic->fw_grp_ids[fw_idx];
 	}
 
-	return 0;
+	return bnxt_hwrm_vnic_rss_cfg(bp, vnic);
 }
 
 static void bnxt_hwrm_set_coal_params(struct bnxt_coal *hw_coal,
@@ -4831,7 +4903,6 @@ int bnxt_hwrm_set_mac(struct bnxt *bp)
 
 	HWRM_CHECK_RESULT();
 
-	memcpy(bp->dflt_mac_addr, bp->mac_addr, RTE_ETHER_ADDR_LEN);
 	HWRM_UNLOCK();
 
 	return rc;
@@ -4844,7 +4915,7 @@ int bnxt_hwrm_if_change(struct bnxt *bp, bool up)
 	uint32_t flags;
 	int rc;
 
-	if (!(bp->flags & BNXT_FLAG_FW_CAP_IF_CHANGE))
+	if (!(bp->fw_cap & BNXT_FW_CAP_IF_CHANGE))
 		return 0;
 
 	/* Do not issue FUNC_DRV_IF_CHANGE during reset recovery.
@@ -4887,7 +4958,7 @@ int bnxt_hwrm_error_recovery_qcfg(struct bnxt *bp)
 	int rc;
 
 	/* Older FW does not have error recovery support */
-	if (!(bp->flags & BNXT_FLAG_FW_CAP_ERROR_RECOVERY))
+	if (!(bp->fw_cap & BNXT_FW_CAP_ERROR_RECOVERY))
 		return 0;
 
 	if (!info) {
@@ -5034,35 +5105,3 @@ int bnxt_hwrm_port_ts_query(struct bnxt *bp, uint8_t path, uint64_t *timestamp)
 
 	return rc;
 }
-
-int bnxt_hwrm_cfa_adv_flow_mgmt_qcaps(struct bnxt *bp)
-{
-	struct hwrm_cfa_adv_flow_mgnt_qcaps_output *resp =
-					bp->hwrm_cmd_resp_addr;
-	struct hwrm_cfa_adv_flow_mgnt_qcaps_input req = {0};
-	uint32_t flags = 0;
-	int rc = 0;
-
-	if (!(bp->flags & BNXT_FLAG_ADV_FLOW_MGMT))
-		return rc;
-
-	if (!(BNXT_PF(bp) || BNXT_VF_IS_TRUSTED(bp))) {
-		PMD_DRV_LOG(DEBUG,
-			    "Not a PF or trusted VF. Command not supported\n");
-		return 0;
-	}
-
-	HWRM_PREP(req, CFA_ADV_FLOW_MGNT_QCAPS, BNXT_USE_KONG(bp));
-	rc = bnxt_hwrm_send_message(bp, &req, sizeof(req), BNXT_USE_KONG(bp));
-
-	HWRM_CHECK_RESULT();
-	flags = rte_le_to_cpu_32(resp->flags);
-	HWRM_UNLOCK();
-
-	if (flags & HWRM_CFA_ADV_FLOW_MGNT_QCAPS_L2_HDR_SRC_FILTER_EN) {
-		bp->flow_flags |= BNXT_FLOW_FLAG_L2_HDR_SRC_FILTER_EN;
-		PMD_DRV_LOG(INFO, "Source L2 header filtering enabled\n");
-	}
-
-	return rc;
-}
diff --git a/dpdk/drivers/net/bnxt/bnxt_hwrm.h b/dpdk/drivers/net/bnxt/bnxt_hwrm.h
index abe5de9db6..8ceaeb59c0 100644
--- a/dpdk/drivers/net/bnxt/bnxt_hwrm.h
+++ b/dpdk/drivers/net/bnxt/bnxt_hwrm.h
@@ -35,6 +35,9 @@ struct bnxt_cp_ring_info;
 #define HWRM_QUEUE_SERVICE_PROFILE_LOSSY \
 	HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_LOSSY
 
+#define HWRM_QUEUE_SERVICE_PROFILE_UNKNOWN \
+	HWRM_QUEUE_QPORTCFG_OUTPUT_QUEUE_ID0_SERVICE_PROFILE_UNKNOWN
+
 #define HWRM_FUNC_RESOURCE_QCAPS_OUTPUT_VF_RESV_STRATEGY_MINIMAL_STATIC \
 	HWRM_FUNC_RESOURCE_QCAPS_OUTPUT_VF_RESERVATION_STRATEGY_MINIMAL_STATIC
 #define HWRM_FUNC_RESOURCE_QCAPS_OUTPUT_VF_RESV_STRATEGY_MAXIMAL \
@@ -86,6 +89,7 @@ int bnxt_hwrm_func_buf_rgtr(struct bnxt *bp);
 int bnxt_hwrm_func_buf_unrgtr(struct bnxt *bp);
 int bnxt_hwrm_func_driver_register(struct bnxt *bp);
 int bnxt_hwrm_func_qcaps(struct bnxt *bp);
+void bnxt_hwrm_free_vf_info(struct bnxt *bp);
 int bnxt_hwrm_func_reset(struct bnxt *bp);
 int bnxt_hwrm_func_driver_unregister(struct bnxt *bp, uint32_t flags);
 int bnxt_hwrm_func_qstats(struct bnxt *bp, uint16_t fid,
@@ -117,7 +121,7 @@ int bnxt_hwrm_stat_ctx_free(struct bnxt *bp,
 int bnxt_hwrm_ctx_qstats(struct bnxt *bp, uint32_t cid, int idx,
 			 struct rte_eth_stats *stats, uint8_t rx);
 
-int bnxt_hwrm_ver_get(struct bnxt *bp);
+int bnxt_hwrm_ver_get(struct bnxt *bp, uint32_t timeout);
 
 int bnxt_hwrm_vnic_alloc(struct bnxt *bp, struct bnxt_vnic_info *vnic);
 int bnxt_hwrm_vnic_cfg(struct bnxt *bp, struct bnxt_vnic_info *vnic);
@@ -226,5 +230,6 @@ int bnxt_hwrm_error_recovery_qcfg(struct bnxt *bp);
 int bnxt_hwrm_fw_reset(struct bnxt *bp);
 int bnxt_hwrm_port_ts_query(struct bnxt *bp, uint8_t path,
 			    uint64_t *timestamp);
-int bnxt_hwrm_cfa_adv_flow_mgmt_qcaps(struct bnxt *bp);
+int bnxt_clear_one_vnic_filter(struct bnxt *bp,
+			       struct bnxt_filter_info *filter);
 #endif
diff --git a/dpdk/drivers/net/bnxt/bnxt_irq.c b/dpdk/drivers/net/bnxt/bnxt_irq.c
index 846325ea96..40e1b0c980 100644
--- a/dpdk/drivers/net/bnxt/bnxt_irq.c
+++ b/dpdk/drivers/net/bnxt/bnxt_irq.c
@@ -181,5 +181,13 @@ int bnxt_request_int(struct bnxt *bp)
 			irq->requested = 1;
 	}
 
+#ifdef RTE_EXEC_ENV_FREEBSD
+	/**
+	 * In FreeBSD OS, nic_uio does not support interrupts and
+	 * interrupt register callback will fail.
+	 */
+	rc = 0;
+#endif
+
 	return rc;
 }
diff --git a/dpdk/drivers/net/bnxt/bnxt_ring.c b/dpdk/drivers/net/bnxt/bnxt_ring.c
index ea46fa9bc0..bb60f8ab0f 100644
--- a/dpdk/drivers/net/bnxt/bnxt_ring.c
+++ b/dpdk/drivers/net/bnxt/bnxt_ring.c
@@ -110,9 +110,7 @@ int bnxt_alloc_rings(struct bnxt *bp, uint16_t qidx,
 	uint64_t rx_offloads = bp->eth_dev->data->dev_conf.rxmode.offloads;
 	const struct rte_memzone *mz = NULL;
 	char mz_name[RTE_MEMZONE_NAMESIZE];
-	rte_iova_t mz_phys_addr_base;
 	rte_iova_t mz_phys_addr;
-	int sz;
 
 	int stats_len = (tx_ring_info || rx_ring_info) ?
 	    RTE_CACHE_LINE_ROUNDUP(sizeof(struct hwrm_stat_ctx_query_output) -
@@ -214,22 +212,7 @@ int bnxt_alloc_rings(struct bnxt *bp, uint16_t qidx,
 			return -ENOMEM;
 	}
 	memset(mz->addr, 0, mz->len);
-	mz_phys_addr_base = mz->iova;
 	mz_phys_addr = mz->iova;
-	if ((unsigned long)mz->addr == mz_phys_addr_base) {
-		PMD_DRV_LOG(DEBUG,
-			    "Memzone physical address same as virtual.\n");
-		PMD_DRV_LOG(DEBUG, "Using rte_mem_virt2iova()\n");
-		for (sz = 0; sz < total_alloc_len; sz += getpagesize())
-			rte_mem_lock_page(((char *)mz->addr) + sz);
-		mz_phys_addr_base = rte_mem_virt2iova(mz->addr);
-		mz_phys_addr = rte_mem_virt2iova(mz->addr);
-		if (mz_phys_addr == RTE_BAD_IOVA) {
-			PMD_DRV_LOG(ERR,
-			"unable to map ring address to physical memory\n");
-			return -ENOMEM;
-		}
-	}
 
 	if (tx_ring_info) {
 		txq->mz = mz;
@@ -468,6 +451,7 @@ int bnxt_alloc_rxtx_nq_ring(struct bnxt *bp)
 	ring->ring_mask = ring->ring_size - 1;
 	ring->vmem_size = 0;
 	ring->vmem = NULL;
+	ring->fw_ring_id = INVALID_HW_RING_ID;
 
 	nqr->cp_ring_struct = ring;
 	rc = bnxt_alloc_rings(bp, 0, NULL, NULL, nqr, NULL, "l2_nqr");
@@ -615,7 +599,7 @@ int bnxt_alloc_hwrm_rx_ring(struct bnxt *bp, int queue_index)
 
 	if (rxq->rx_started) {
 		if (bnxt_init_one_rx_ring(rxq)) {
-			RTE_LOG(ERR, PMD,
+			PMD_DRV_LOG(ERR,
 				"bnxt_init_one_rx_ring failed!\n");
 			bnxt_rx_queue_release_op(rxq);
 			rc = -ENOMEM;
diff --git a/dpdk/drivers/net/bnxt/bnxt_ring.h b/dpdk/drivers/net/bnxt/bnxt_ring.h
index 48a39d7884..0a4685d167 100644
--- a/dpdk/drivers/net/bnxt/bnxt_ring.h
+++ b/dpdk/drivers/net/bnxt/bnxt_ring.h
@@ -27,7 +27,7 @@
 #define DEFAULT_RX_RING_SIZE	256
 #define DEFAULT_TX_RING_SIZE	256
 
-#define AGG_RING_SIZE_FACTOR	2
+#define AGG_RING_SIZE_FACTOR	4
 #define AGG_RING_MULTIPLIER	2
 
 /* These assume 4k pages */
@@ -83,7 +83,7 @@ void bnxt_free_rxtx_nq_ring(struct bnxt *bp);
 static inline void bnxt_db_write(struct bnxt_db_info *db, uint32_t idx)
 {
 	if (db->db_64)
-		rte_write64_relaxed(db->db_key64 | idx, db->doorbell);
+		rte_write64(db->db_key64 | idx, db->doorbell);
 	else
 		rte_write32(db->db_key32 | idx, db->doorbell);
 }
@@ -94,7 +94,6 @@ static inline void bnxt_db_nq(struct bnxt_cp_ring_info *cpr)
 	if (unlikely(!cpr->cp_db.db_64))
 		return;
 
-	rte_smp_wmb();
 	rte_write64(cpr->cp_db.db_key64 | DBR_TYPE_NQ |
 		    RING_CMP(cpr->cp_ring_struct, cpr->cp_raw_cons),
 		    cpr->cp_db.doorbell);
@@ -106,7 +105,6 @@ static inline void bnxt_db_nq_arm(struct bnxt_cp_ring_info *cpr)
 	if (unlikely(!cpr->cp_db.db_64))
 		return;
 
-	rte_smp_wmb();
 	rte_write64(cpr->cp_db.db_key64 | DBR_TYPE_NQ_ARM |
 		    RING_CMP(cpr->cp_ring_struct, cpr->cp_raw_cons),
 		    cpr->cp_db.doorbell);
@@ -117,11 +115,18 @@ static inline void bnxt_db_cq(struct bnxt_cp_ring_info *cpr)
 	struct bnxt_db_info *db = &cpr->cp_db;
 	uint32_t idx = RING_CMP(cpr->cp_ring_struct, cpr->cp_raw_cons);
 
-	rte_smp_wmb();
-	if (db->db_64)
-		rte_write64(db->db_key64 | idx, db->doorbell);
-	else
-		B_CP_DIS_DB(cpr, cpr->cp_raw_cons);
+	if (db->db_64) {
+		uint64_t key_idx = db->db_key64 | idx;
+		void *doorbell = db->doorbell;
+
+		rte_compiler_barrier();
+		rte_write64_relaxed(key_idx, doorbell);
+	} else {
+		uint32_t cp_raw_cons = cpr->cp_raw_cons;
+
+		rte_compiler_barrier();
+		B_CP_DIS_DB(cpr, cp_raw_cons);
+	}
 }
 
 #endif
diff --git a/dpdk/drivers/net/bnxt/bnxt_rxq.c b/dpdk/drivers/net/bnxt/bnxt_rxq.c
index 457ebede0e..df00191c09 100644
--- a/dpdk/drivers/net/bnxt/bnxt_rxq.c
+++ b/dpdk/drivers/net/bnxt/bnxt_rxq.c
@@ -168,10 +168,8 @@ int bnxt_mq_rx_configure(struct bnxt *bp)
 	if (dev_conf->rxmode.mq_mode & ETH_MQ_RX_RSS_FLAG) {
 		struct rte_eth_rss_conf *rss = &dev_conf->rx_adv_conf.rss_conf;
 
-		if (bp->flags & BNXT_FLAG_UPDATE_HASH) {
-			rss = &bp->rss_conf;
+		if (bp->flags & BNXT_FLAG_UPDATE_HASH)
 			bp->flags &= ~BNXT_FLAG_UPDATE_HASH;
-		}
 
 		for (i = 0; i < bp->nr_vnics; i++) {
 			vnic = &bp->vnic_info[i];
@@ -203,11 +201,9 @@ void bnxt_rx_queue_release_mbufs(struct bnxt_rx_queue *rxq)
 	struct bnxt_tpa_info *tpa_info;
 	uint16_t i;
 
-	if (!rxq)
+	if (!rxq || !rxq->rx_ring)
 		return;
 
-	rte_spinlock_lock(&rxq->lock);
-
 	sw_ring = rxq->rx_ring->rx_buf_ring;
 	if (sw_ring) {
 		for (i = 0;
@@ -243,7 +239,6 @@ void bnxt_rx_queue_release_mbufs(struct bnxt_rx_queue *rxq)
 		}
 	}
 
-	rte_spinlock_unlock(&rxq->lock);
 }
 
 void bnxt_free_rx_mbufs(struct bnxt *bp)
@@ -268,12 +263,21 @@ void bnxt_rx_queue_release_op(void *rx_queue)
 		bnxt_rx_queue_release_mbufs(rxq);
 
 		/* Free RX ring hardware descriptors */
-		bnxt_free_ring(rxq->rx_ring->rx_ring_struct);
-		/* Free RX Agg ring hardware descriptors */
-		bnxt_free_ring(rxq->rx_ring->ag_ring_struct);
-
+		if (rxq->rx_ring) {
+			bnxt_free_ring(rxq->rx_ring->rx_ring_struct);
+			rte_free(rxq->rx_ring->rx_ring_struct);
+			/* Free RX Agg ring hardware descriptors */
+			bnxt_free_ring(rxq->rx_ring->ag_ring_struct);
+			rte_free(rxq->rx_ring->ag_ring_struct);
+
+			rte_free(rxq->rx_ring);
+		}
 		/* Free RX completion ring hardware descriptors */
-		bnxt_free_ring(rxq->cp_ring->cp_ring_struct);
+		if (rxq->cp_ring) {
+			bnxt_free_ring(rxq->cp_ring->cp_ring_struct);
+			rte_free(rxq->cp_ring->cp_ring_struct);
+			rte_free(rxq->cp_ring);
+		}
 
 		bnxt_free_rxq_stats(rxq);
 		rte_memzone_free(rxq->mz);
@@ -300,7 +304,7 @@ int bnxt_rx_queue_setup_op(struct rte_eth_dev *eth_dev,
 	if (rc)
 		return rc;
 
-	if (queue_idx >= BNXT_MAX_RINGS(bp)) {
+	if (queue_idx >= bnxt_max_rings(bp)) {
 		PMD_DRV_LOG(ERR,
 			"Cannot create Rx ring %d. Only %d rings available\n",
 			queue_idx, bp->max_rx_rings);
@@ -309,8 +313,7 @@ int bnxt_rx_queue_setup_op(struct rte_eth_dev *eth_dev,
 
 	if (!nb_desc || nb_desc > MAX_RX_DESC_CNT) {
 		PMD_DRV_LOG(ERR, "nb_desc %d is invalid\n", nb_desc);
-		rc = -EINVAL;
-		goto out;
+		return -EINVAL;
 	}
 
 	if (eth_dev->data->rx_queues) {
@@ -322,19 +325,26 @@ int bnxt_rx_queue_setup_op(struct rte_eth_dev *eth_dev,
 				 RTE_CACHE_LINE_SIZE, socket_id);
 	if (!rxq) {
 		PMD_DRV_LOG(ERR, "bnxt_rx_queue allocation failed!\n");
-		rc = -ENOMEM;
-		goto out;
+		return -ENOMEM;
 	}
 	rxq->bp = bp;
 	rxq->mb_pool = mp;
 	rxq->nb_rx_desc = nb_desc;
 	rxq->rx_free_thresh = rx_conf->rx_free_thresh;
 
+	if (rx_conf->rx_drop_en != BNXT_DEFAULT_RX_DROP_EN)
+		PMD_DRV_LOG(NOTICE,
+			    "Per-queue config of drop-en is not supported.\n");
+	rxq->drop_en = BNXT_DEFAULT_RX_DROP_EN;
+
 	PMD_DRV_LOG(DEBUG, "RX Buf MTU %d\n", eth_dev->data->mtu);
 
 	rc = bnxt_init_rx_ring_struct(rxq, socket_id);
-	if (rc)
-		goto out;
+	if (rc) {
+		PMD_DRV_LOG(ERR,
+			    "init_rx_ring_struct failed!\n");
+		goto err;
+	}
 
 	PMD_DRV_LOG(DEBUG, "RX Buf size is %d\n", rxq->rx_buf_size);
 	rxq->queue_id = queue_idx;
@@ -346,13 +356,12 @@ int bnxt_rx_queue_setup_op(struct rte_eth_dev *eth_dev,
 
 	eth_dev->data->rx_queues[queue_idx] = rxq;
 	/* Allocate RX ring hardware descriptors */
-	if (bnxt_alloc_rings(bp, queue_idx, NULL, rxq, rxq->cp_ring, NULL,
-			     "rxr")) {
+	rc = bnxt_alloc_rings(bp, queue_idx, NULL, rxq, rxq->cp_ring, NULL,
+			     "rxr");
+	if (rc) {
 		PMD_DRV_LOG(ERR,
-			"ring_dma_zone_reserve for rx_ring failed!\n");
-		bnxt_rx_queue_release_op(rxq);
-		rc = -ENOMEM;
-		goto out;
+			    "ring_dma_zone_reserve for rx_ring failed!\n");
+		goto err;
 	}
 	rte_atomic64_init(&rxq->rx_mbuf_alloc_fail);
 
@@ -370,13 +379,14 @@ int bnxt_rx_queue_setup_op(struct rte_eth_dev *eth_dev,
 		rxq->rx_started = true;
 	}
 	eth_dev->data->rx_queue_state[queue_idx] = queue_state;
-	rte_spinlock_init(&rxq->lock);
 
 	/* Configure mtu if it is different from what was configured before */
 	if (!queue_idx)
 		bnxt_mtu_set_op(eth_dev, eth_dev->data->mtu);
 
-out:
+	return 0;
+err:
+	bnxt_rx_queue_release_op(rxq);
 	return rc;
 }
 
@@ -540,12 +550,12 @@ int bnxt_rx_queue_stop(struct rte_eth_dev *dev, uint16_t rx_queue_id)
 		rc = bnxt_vnic_rss_configure(bp, vnic);
 	}
 
-	if (BNXT_CHIP_THOR(bp)) {
-		/* Compute current number of active receive queues. */
-		for (i = vnic->start_grp_id; i < vnic->end_grp_id; i++)
-			if (bp->rx_queues[i]->rx_started)
-				active_queue_cnt++;
+	/* Compute current number of active receive queues. */
+	for (i = vnic->start_grp_id; i < vnic->end_grp_id; i++)
+		if (bp->rx_queues[i]->rx_started)
+			active_queue_cnt++;
 
+	if (BNXT_CHIP_THOR(bp)) {
 		/*
 		 * For Thor, we need to ensure that the VNIC default receive
 		 * ring corresponds to an active receive queue. When no queue
@@ -565,6 +575,22 @@ int bnxt_rx_queue_stop(struct rte_eth_dev *dev, uint16_t rx_queue_id)
 			/* Reconfigure default receive ring. */
 			bnxt_hwrm_vnic_cfg(bp, vnic);
 		}
+	} else if (active_queue_cnt) {
+		/*
+		 * If the queue being stopped is the current default queue and
+		 * there are other active queues, pick one of them as the
+		 * default and reconfigure the vnic.
+		 */
+		if (vnic->dflt_ring_grp == bp->grp_info[rx_queue_id].fw_grp_id) {
+			for (i = vnic->start_grp_id; i < vnic->end_grp_id; i++) {
+				if (bp->rx_queues[i]->rx_started) {
+					vnic->dflt_ring_grp =
+						bp->grp_info[i].fw_grp_id;
+					bnxt_hwrm_vnic_cfg(bp, vnic);
+					break;
+				}
+			}
+		}
 	}
 
 	if (rc == 0)
diff --git a/dpdk/drivers/net/bnxt/bnxt_rxq.h b/dpdk/drivers/net/bnxt/bnxt_rxq.h
index 4f5182d9e9..ae3badb7a0 100644
--- a/dpdk/drivers/net/bnxt/bnxt_rxq.h
+++ b/dpdk/drivers/net/bnxt/bnxt_rxq.h
@@ -6,13 +6,13 @@
 #ifndef _BNXT_RQX_H_
 #define _BNXT_RQX_H_
 
+/* Drop by default when receive desc is not available. */
+#define BNXT_DEFAULT_RX_DROP_EN		1
+
 struct bnxt;
 struct bnxt_rx_ring_info;
 struct bnxt_cp_ring_info;
 struct bnxt_rx_queue {
-	rte_spinlock_t		lock;	/* Synchronize between rx_queue_stop
-					 * and fast path
-					 */
 	struct rte_mempool	*mb_pool; /* mbuf pool for RX ring */
 	struct rte_mbuf		*pkt_first_seg; /* 1st seg of pkt */
 	struct rte_mbuf		*pkt_last_seg; /* Last seg of pkt */
@@ -31,6 +31,7 @@ struct bnxt_rx_queue {
 	uint8_t			crc_len; /* 0 if CRC stripped, 4 otherwise */
 	uint8_t			rx_deferred_start; /* not in global dev start */
 	uint8_t			rx_started; /* RX queue is started */
+	uint8_t			drop_en; /* Drop when rx desc not available. */
 
 	struct bnxt		*bp;
 	int			index;
diff --git a/dpdk/drivers/net/bnxt/bnxt_rxr.c b/dpdk/drivers/net/bnxt/bnxt_rxr.c
index 3b713c2427..1cf8f3e17c 100644
--- a/dpdk/drivers/net/bnxt/bnxt_rxr.c
+++ b/dpdk/drivers/net/bnxt/bnxt_rxr.c
@@ -145,6 +145,7 @@ static void bnxt_tpa_start(struct bnxt_rx_queue *rxq,
 	tpa_info->mbuf = mbuf;
 	tpa_info->len = rte_le_to_cpu_32(tpa_start->len);
 
+	mbuf->data_off = RTE_PKTMBUF_HEADROOM;
 	mbuf->nb_segs = 1;
 	mbuf->next = NULL;
 	mbuf->pkt_len = rte_le_to_cpu_32(tpa_start->len);
@@ -261,6 +262,7 @@ static int bnxt_rx_pages(struct bnxt_rx_queue *rxq,
 		 */
 		rte_bitmap_set(rxr->ag_bitmap, ag_cons);
 	}
+	last->next = NULL;
 	bnxt_prod_ag_mbuf(rxq);
 	return 0;
 }
@@ -300,7 +302,6 @@ static inline struct rte_mbuf *bnxt_tpa_end(
 	mbuf = tpa_info->mbuf;
 	RTE_ASSERT(mbuf != NULL);
 
-	rte_prefetch0(mbuf);
 	if (agg_bufs) {
 		bnxt_rx_pages(rxq, mbuf, raw_cp_cons, agg_bufs, tpa_info);
 	}
@@ -474,8 +475,6 @@ static int bnxt_rx_pkt(struct rte_mbuf **rx_pkt,
 	if (mbuf == NULL)
 		return -EBUSY;
 
-	rte_prefetch0(mbuf);
-
 	mbuf->data_off = RTE_PKTMBUF_HEADROOM;
 	mbuf->nb_segs = 1;
 	mbuf->next = NULL;
@@ -606,6 +605,7 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 	struct bnxt_cp_ring_info *cpr = rxq->cp_ring;
 	struct bnxt_rx_ring_info *rxr = rxq->rx_ring;
 	uint32_t raw_cons = cpr->cp_raw_cons;
+	bool alloc_failed = false;
 	uint32_t cons;
 	int nb_rx_pkts = 0;
 	struct rx_pkt_cmpl *rxcmp;
@@ -618,14 +618,12 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 		return 0;
 
 	/* If Rx Q was stopped return */
-	if (unlikely(!rxq->rx_started ||
-		     !rte_spinlock_trylock(&rxq->lock)))
+	if (unlikely(!rxq->rx_started))
 		return 0;
 
 	/* Handle RX burst request */
 	while (1) {
 		cons = RING_CMP(cpr->cp_ring_struct, raw_cons);
-		rte_prefetch0(&cpr->cp_desc_ring[cons]);
 		rxcmp = (struct rx_pkt_cmpl *)&cpr->cp_desc_ring[cons];
 
 		if (!CMP_VALID(rxcmp, raw_cons, cpr->cp_ring_struct))
@@ -637,10 +635,14 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 		/* TODO: Avoid magic numbers... */
 		if ((CMP_TYPE(rxcmp) & 0x30) == 0x10) {
 			rc = bnxt_rx_pkt(&rx_pkts[nb_rx_pkts], rxq, &raw_cons);
-			if (likely(!rc) || rc == -ENOMEM)
+			if (!rc)
 				nb_rx_pkts++;
-			if (rc == -EBUSY)	/* partial completion */
+			else if (rc == -EBUSY)	/* partial completion */
 				break;
+			else if (rc == -ENOMEM) {
+				nb_rx_pkts++;
+				alloc_failed = true;
+			}
 		} else if (!BNXT_NUM_ASYNC_CPR(rxq->bp)) {
 			evt =
 			bnxt_event_hwrm_resp_handler(rxq->bp,
@@ -667,6 +669,10 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 		goto done;
 	}
 
+	/* Ring the completion queue doorbell. */
+	bnxt_db_cq(cpr);
+
+	/* Ring the receive descriptor doorbell. */
 	if (prod != rxr->rx_prod)
 		bnxt_db_write(&rxr->rx_db, rxr->rx_prod);
 
@@ -674,23 +680,23 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 	if (ag_prod != rxr->ag_prod)
 		bnxt_db_write(&rxr->ag_db, rxr->ag_prod);
 
-	bnxt_db_cq(cpr);
-
 	/* Attempt to alloc Rx buf in case of a previous allocation failure. */
-	if (rc == -ENOMEM) {
-		int i;
+	if (alloc_failed) {
+		uint16_t cnt;
 
-		for (i = prod; i <= nb_rx_pkts;
-			i = RING_NEXT(rxr->rx_ring_struct, i)) {
-			struct bnxt_sw_rx_bd *rx_buf = &rxr->rx_buf_ring[i];
+		for (cnt = 0; cnt < nb_rx_pkts; cnt++) {
+			struct bnxt_sw_rx_bd *rx_buf;
+
+			prod = RING_NEXT(rxr->rx_ring_struct, prod);
+			rx_buf = &rxr->rx_buf_ring[prod];
 
 			/* Buffer already allocated for this index. */
 			if (rx_buf->mbuf != NULL)
 				continue;
 
 			/* This slot is empty. Alloc buffer for Rx */
-			if (!bnxt_alloc_rx_data(rxq, rxr, i)) {
-				rxr->rx_prod = i;
+			if (!bnxt_alloc_rx_data(rxq, rxr, prod)) {
+				rxr->rx_prod = prod;
 				bnxt_db_write(&rxr->rx_db, rxr->rx_prod);
 			} else {
 				PMD_DRV_LOG(ERR, "Alloc  mbuf failed\n");
@@ -700,8 +706,6 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 	}
 
 done:
-	rte_spinlock_unlock(&rxq->lock);
-
 	return nb_rx_pkts;
 }
 
@@ -778,6 +782,7 @@ int bnxt_init_rx_ring_struct(struct bnxt_rx_queue *rxq, unsigned int socket_id)
 	ring->bd_dma = rxr->rx_desc_mapping;
 	ring->vmem_size = ring->ring_size * sizeof(struct bnxt_sw_rx_bd);
 	ring->vmem = (void **)&rxr->rx_buf_ring;
+	ring->fw_ring_id = INVALID_HW_RING_ID;
 
 	cpr = rte_zmalloc_socket("bnxt_rx_ring",
 				 sizeof(struct bnxt_cp_ring_info),
@@ -799,6 +804,7 @@ int bnxt_init_rx_ring_struct(struct bnxt_rx_queue *rxq, unsigned int socket_id)
 	ring->bd_dma = cpr->cp_desc_mapping;
 	ring->vmem_size = 0;
 	ring->vmem = NULL;
+	ring->fw_ring_id = INVALID_HW_RING_ID;
 
 	/* Allocate Aggregator rings */
 	ring = rte_zmalloc_socket("bnxt_rx_ring_struct",
@@ -814,6 +820,7 @@ int bnxt_init_rx_ring_struct(struct bnxt_rx_queue *rxq, unsigned int socket_id)
 	ring->bd_dma = rxr->ag_desc_mapping;
 	ring->vmem_size = ring->ring_size * sizeof(struct bnxt_sw_rx_bd);
 	ring->vmem = (void **)&rxr->ag_buf_ring;
+	ring->fw_ring_id = INVALID_HW_RING_ID;
 
 	return 0;
 }
@@ -844,7 +851,7 @@ int bnxt_init_one_rx_ring(struct bnxt_rx_queue *rxq)
 	size = rte_pktmbuf_data_room_size(rxq->mb_pool) - RTE_PKTMBUF_HEADROOM;
 	size = RTE_MIN(BNXT_MAX_PKT_LEN, size);
 
-	type = RX_PROD_PKT_BD_TYPE_RX_PROD_PKT | RX_PROD_PKT_BD_FLAGS_EOP_PAD;
+	type = RX_PROD_PKT_BD_TYPE_RX_PROD_PKT;
 
 	rxr = rxq->rx_ring;
 	ring = rxr->rx_ring_struct;
@@ -852,11 +859,13 @@ int bnxt_init_one_rx_ring(struct bnxt_rx_queue *rxq)
 
 	prod = rxr->rx_prod;
 	for (i = 0; i < ring->ring_size; i++) {
-		if (bnxt_alloc_rx_data(rxq, rxr, prod) != 0) {
-			PMD_DRV_LOG(WARNING,
-				"init'ed rx ring %d with %d/%d mbufs only\n",
-				rxq->queue_id, i, ring->ring_size);
-			break;
+		if (unlikely(!rxr->rx_buf_ring[i].mbuf)) {
+			if (bnxt_alloc_rx_data(rxq, rxr, prod) != 0) {
+				PMD_DRV_LOG(WARNING,
+					    "init'ed rx ring %d with %d/%d mbufs only\n",
+					    rxq->queue_id, i, ring->ring_size);
+				break;
+			}
 		}
 		rxr->rx_prod = prod;
 		prod = RING_NEXT(rxr->rx_ring_struct, prod);
@@ -868,11 +877,13 @@ int bnxt_init_one_rx_ring(struct bnxt_rx_queue *rxq)
 	prod = rxr->ag_prod;
 
 	for (i = 0; i < ring->ring_size; i++) {
-		if (bnxt_alloc_ag_data(rxq, rxr, prod) != 0) {
-			PMD_DRV_LOG(WARNING,
-			"init'ed AG ring %d with %d/%d mbufs only\n",
-			rxq->queue_id, i, ring->ring_size);
-			break;
+		if (unlikely(!rxr->ag_buf_ring[i].mbuf)) {
+			if (bnxt_alloc_ag_data(rxq, rxr, prod) != 0) {
+				PMD_DRV_LOG(WARNING,
+					    "init'ed AG ring %d with %d/%d mbufs only\n",
+					    rxq->queue_id, i, ring->ring_size);
+				break;
+			}
 		}
 		rxr->ag_prod = prod;
 		prod = RING_NEXT(rxr->ag_ring_struct, prod);
@@ -883,11 +894,13 @@ int bnxt_init_one_rx_ring(struct bnxt_rx_queue *rxq)
 		unsigned int max_aggs = BNXT_TPA_MAX_AGGS(rxq->bp);
 
 		for (i = 0; i < max_aggs; i++) {
-			rxr->tpa_info[i].mbuf =
-				__bnxt_alloc_rx_data(rxq->mb_pool);
-			if (!rxr->tpa_info[i].mbuf) {
-				rte_atomic64_inc(&rxq->rx_mbuf_alloc_fail);
-				return -ENOMEM;
+			if (unlikely(!rxr->tpa_info[i].mbuf)) {
+				rxr->tpa_info[i].mbuf =
+					__bnxt_alloc_rx_data(rxq->mb_pool);
+				if (!rxr->tpa_info[i].mbuf) {
+					rte_atomic64_inc(&rxq->rx_mbuf_alloc_fail);
+					return -ENOMEM;
+				}
 			}
 		}
 	}
diff --git a/dpdk/drivers/net/bnxt/bnxt_rxr.h b/dpdk/drivers/net/bnxt/bnxt_rxr.h
index 76bf88d707..410b46016b 100644
--- a/dpdk/drivers/net/bnxt/bnxt_rxr.h
+++ b/dpdk/drivers/net/bnxt/bnxt_rxr.h
@@ -212,8 +212,6 @@ struct bnxt_rx_ring_info {
 
 uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 			       uint16_t nb_pkts);
-uint16_t bnxt_dummy_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
-			      uint16_t nb_pkts);
 void bnxt_free_rx_rings(struct bnxt *bp);
 int bnxt_init_rx_ring_struct(struct bnxt_rx_queue *rxq, unsigned int socket_id);
 int bnxt_init_one_rx_ring(struct bnxt_rx_queue *rxq);
diff --git a/dpdk/drivers/net/bnxt/bnxt_rxtx_vec_sse.c b/dpdk/drivers/net/bnxt/bnxt_rxtx_vec_sse.c
index 22d9f9e84a..7529d0316b 100644
--- a/dpdk/drivers/net/bnxt/bnxt_rxtx_vec_sse.c
+++ b/dpdk/drivers/net/bnxt/bnxt_rxtx_vec_sse.c
@@ -233,8 +233,13 @@ bnxt_recv_pkts_vec(void *rx_queue, struct rte_mbuf **rx_pkts,
 	/* Return no more than RTE_BNXT_MAX_RX_BURST per call. */
 	nb_pkts = RTE_MIN(nb_pkts, RTE_BNXT_MAX_RX_BURST);
 
-	/* Make nb_pkts an integer multiple of RTE_BNXT_DESCS_PER_LOOP */
+	/*
+	 * Make nb_pkts an integer multiple of RTE_BNXT_DESCS_PER_LOOP.
+	 * nb_pkts < RTE_BNXT_DESCS_PER_LOOP, just return no packet
+	 */
 	nb_pkts = RTE_ALIGN_FLOOR(nb_pkts, RTE_BNXT_DESCS_PER_LOOP);
+	if (!nb_pkts)
+		return 0;
 
 	/* Handle RX burst request */
 	while (1) {
@@ -289,7 +294,8 @@ bnxt_recv_pkts_vec(void *rx_queue, struct rte_mbuf **rx_pkts,
 					(RX_PKT_CMPL_METADATA_VID_MASK |
 					RX_PKT_CMPL_METADATA_DE |
 					RX_PKT_CMPL_METADATA_PRI_MASK);
-				mbuf->ol_flags |= PKT_RX_VLAN;
+				mbuf->ol_flags |=
+					PKT_RX_VLAN | PKT_RX_VLAN_STRIPPED;
 			}
 
 			bnxt_parse_csum(mbuf, rxcmp1);
@@ -332,6 +338,8 @@ bnxt_tx_cmp_vec(struct bnxt_tx_queue *txq, int nr_pkts)
 		tx_buf = &txr->tx_buf_ring[cons];
 		cons = RING_NEXT(txr->tx_ring_struct, cons);
 		mbuf = rte_pktmbuf_prefree_seg(tx_buf->mbuf);
+		if (unlikely(mbuf == NULL))
+			continue;
 		tx_buf->mbuf = NULL;
 
 		if (blk && mbuf->pool != free[0]->pool) {
diff --git a/dpdk/drivers/net/bnxt/bnxt_stats.c b/dpdk/drivers/net/bnxt/bnxt_stats.c
index 14d355fd08..84011fc3ea 100644
--- a/dpdk/drivers/net/bnxt/bnxt_stats.c
+++ b/dpdk/drivers/net/bnxt/bnxt_stats.c
@@ -389,11 +389,8 @@ int bnxt_stats_get_op(struct rte_eth_dev *eth_dev,
 	if (rc)
 		return rc;
 
-	memset(bnxt_stats, 0, sizeof(*bnxt_stats));
-	if (!(bp->flags & BNXT_FLAG_INIT_DONE)) {
-		PMD_DRV_LOG(ERR, "Device Initialization not complete!\n");
+	if (!eth_dev->data->dev_started)
 		return -EIO;
-	}
 
 	num_q_stats = RTE_MIN(bp->rx_cp_nr_rings,
 			      (unsigned int)RTE_ETHDEV_QUEUE_STAT_CNTRS);
@@ -437,7 +434,7 @@ int bnxt_stats_reset_op(struct rte_eth_dev *eth_dev)
 	if (ret)
 		return ret;
 
-	if (!(bp->flags & BNXT_FLAG_INIT_DONE)) {
+	if (!eth_dev->data->dev_started) {
 		PMD_DRV_LOG(ERR, "Device Initialization not complete!\n");
 		return -EINVAL;
 	}
@@ -620,70 +617,3 @@ int bnxt_dev_xstats_reset_op(struct rte_eth_dev *eth_dev)
 
 	return ret;
 }
-
-int bnxt_dev_xstats_get_by_id_op(struct rte_eth_dev *dev, const uint64_t *ids,
-		uint64_t *values, unsigned int limit)
-{
-	/* Account for the Tx drop pkts aka the Anti spoof counter */
-	const unsigned int stat_cnt = RTE_DIM(bnxt_rx_stats_strings) +
-				RTE_DIM(bnxt_tx_stats_strings) + 1 +
-				RTE_DIM(bnxt_rx_ext_stats_strings) +
-				RTE_DIM(bnxt_tx_ext_stats_strings);
-	struct bnxt *bp = dev->data->dev_private;
-	struct rte_eth_xstat xstats[stat_cnt];
-	uint64_t values_copy[stat_cnt];
-	uint16_t i;
-	int rc;
-
-	rc = is_bnxt_in_error(bp);
-	if (rc)
-		return rc;
-
-	if (!ids)
-		return bnxt_dev_xstats_get_op(dev, xstats, stat_cnt);
-
-	bnxt_dev_xstats_get_by_id_op(dev, NULL, values_copy, stat_cnt);
-	for (i = 0; i < limit; i++) {
-		if (ids[i] >= stat_cnt) {
-			PMD_DRV_LOG(ERR, "id value isn't valid");
-			return -EINVAL;
-		}
-		values[i] = values_copy[ids[i]];
-	}
-	return stat_cnt;
-}
-
-int bnxt_dev_xstats_get_names_by_id_op(struct rte_eth_dev *dev,
-				struct rte_eth_xstat_name *xstats_names,
-				const uint64_t *ids, unsigned int limit)
-{
-	/* Account for the Tx drop pkts aka the Anti spoof counter */
-	const unsigned int stat_cnt = RTE_DIM(bnxt_rx_stats_strings) +
-				RTE_DIM(bnxt_tx_stats_strings) + 1 +
-				RTE_DIM(bnxt_rx_ext_stats_strings) +
-				RTE_DIM(bnxt_tx_ext_stats_strings);
-	struct rte_eth_xstat_name xstats_names_copy[stat_cnt];
-	struct bnxt *bp = dev->data->dev_private;
-	uint16_t i;
-	int rc;
-
-	rc = is_bnxt_in_error(bp);
-	if (rc)
-		return rc;
-
-	if (!ids)
-		return bnxt_dev_xstats_get_names_op(dev, xstats_names,
-						    stat_cnt);
-	bnxt_dev_xstats_get_names_by_id_op(dev, xstats_names_copy, NULL,
-			stat_cnt);
-
-	for (i = 0; i < limit; i++) {
-		if (ids[i] >= stat_cnt) {
-			PMD_DRV_LOG(ERR, "id value isn't valid");
-			return -EINVAL;
-		}
-		strcpy(xstats_names[i].name,
-				xstats_names_copy[ids[i]].name);
-	}
-	return stat_cnt;
-}
diff --git a/dpdk/drivers/net/bnxt/bnxt_txq.c b/dpdk/drivers/net/bnxt/bnxt_txq.c
index 2d7645eeb0..78625eef60 100644
--- a/dpdk/drivers/net/bnxt/bnxt_txq.c
+++ b/dpdk/drivers/net/bnxt/bnxt_txq.c
@@ -27,7 +27,7 @@ static void bnxt_tx_queue_release_mbufs(struct bnxt_tx_queue *txq)
 	struct bnxt_sw_tx_bd *sw_ring;
 	uint16_t i;
 
-	if (!txq)
+	if (!txq || !txq->tx_ring)
 		return;
 
 	sw_ring = txq->tx_ring->tx_buf_ring;
@@ -62,10 +62,18 @@ void bnxt_tx_queue_release_op(void *tx_queue)
 
 		/* Free TX ring hardware descriptors */
 		bnxt_tx_queue_release_mbufs(txq);
-		bnxt_free_ring(txq->tx_ring->tx_ring_struct);
+		if (txq->tx_ring) {
+			bnxt_free_ring(txq->tx_ring->tx_ring_struct);
+			rte_free(txq->tx_ring->tx_ring_struct);
+			rte_free(txq->tx_ring);
+		}
 
 		/* Free TX completion ring hardware descriptors */
-		bnxt_free_ring(txq->cp_ring->cp_ring_struct);
+		if (txq->cp_ring) {
+			bnxt_free_ring(txq->cp_ring->cp_ring_struct);
+			rte_free(txq->cp_ring->cp_ring_struct);
+			rte_free(txq->cp_ring);
+		}
 
 		bnxt_free_txq_stats(txq);
 		rte_memzone_free(txq->mz);
@@ -90,7 +98,7 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 	if (rc)
 		return rc;
 
-	if (queue_idx >= BNXT_MAX_RINGS(bp)) {
+	if (queue_idx >= bnxt_max_rings(bp)) {
 		PMD_DRV_LOG(ERR,
 			"Cannot create Tx ring %d. Only %d rings available\n",
 			queue_idx, bp->max_tx_rings);
@@ -99,8 +107,7 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 
 	if (!nb_desc || nb_desc > MAX_TX_DESC_CNT) {
 		PMD_DRV_LOG(ERR, "nb_desc %d is invalid", nb_desc);
-		rc = -EINVAL;
-		goto out;
+		return -EINVAL;
 	}
 
 	if (eth_dev->data->tx_queues) {
@@ -114,8 +121,7 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 				 RTE_CACHE_LINE_SIZE, socket_id);
 	if (!txq) {
 		PMD_DRV_LOG(ERR, "bnxt_tx_queue allocation failed!");
-		rc = -ENOMEM;
-		goto out;
+		return -ENOMEM;
 	}
 
 	txq->free = rte_zmalloc_socket(NULL,
@@ -123,9 +129,8 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 				       RTE_CACHE_LINE_SIZE, socket_id);
 	if (!txq->free) {
 		PMD_DRV_LOG(ERR, "allocation of tx mbuf free array failed!");
-		rte_free(txq);
 		rc = -ENOMEM;
-		goto out;
+		goto err;
 	}
 	txq->bp = bp;
 	txq->nb_tx_desc = nb_desc;
@@ -134,7 +139,7 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 
 	rc = bnxt_init_tx_ring_struct(txq, socket_id);
 	if (rc)
-		goto out;
+		goto err;
 
 	txq->queue_id = queue_idx;
 	txq->port_id = eth_dev->data->port_id;
@@ -143,16 +148,14 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 	if (bnxt_alloc_rings(bp, queue_idx, txq, NULL, txq->cp_ring, NULL,
 			     "txr")) {
 		PMD_DRV_LOG(ERR, "ring_dma_zone_reserve for tx_ring failed!");
-		bnxt_tx_queue_release_op(txq);
 		rc = -ENOMEM;
-		goto out;
+		goto err;
 	}
 
 	if (bnxt_init_one_tx_ring(txq)) {
 		PMD_DRV_LOG(ERR, "bnxt_init_one_tx_ring failed!");
-		bnxt_tx_queue_release_op(txq);
 		rc = -ENOMEM;
-		goto out;
+		goto err;
 	}
 
 	eth_dev->data->tx_queues[queue_idx] = txq;
@@ -161,6 +164,9 @@ int bnxt_tx_queue_setup_op(struct rte_eth_dev *eth_dev,
 		txq->tx_started = false;
 	else
 		txq->tx_started = true;
-out:
+
+	return 0;
+err:
+	bnxt_tx_queue_release_op(txq);
 	return rc;
 }
diff --git a/dpdk/drivers/net/bnxt/bnxt_txr.c b/dpdk/drivers/net/bnxt/bnxt_txr.c
index 16021407e8..9a18e8f6f7 100644
--- a/dpdk/drivers/net/bnxt/bnxt_txr.c
+++ b/dpdk/drivers/net/bnxt/bnxt_txr.c
@@ -78,6 +78,7 @@ int bnxt_init_tx_ring_struct(struct bnxt_tx_queue *txq, unsigned int socket_id)
 	ring->bd_dma = txr->tx_desc_mapping;
 	ring->vmem_size = ring->ring_size * sizeof(struct bnxt_sw_tx_bd);
 	ring->vmem = (void **)&txr->tx_buf_ring;
+	ring->fw_ring_id = INVALID_HW_RING_ID;
 
 	cpr = rte_zmalloc_socket("bnxt_tx_ring",
 				 sizeof(struct bnxt_cp_ring_info),
@@ -98,6 +99,7 @@ int bnxt_init_tx_ring_struct(struct bnxt_tx_queue *txq, unsigned int socket_id)
 	ring->bd_dma = cpr->cp_desc_mapping;
 	ring->vmem_size = 0;
 	ring->vmem = NULL;
+	ring->fw_ring_id = INVALID_HW_RING_ID;
 
 	return 0;
 }
diff --git a/dpdk/drivers/net/bnxt/bnxt_txr.h b/dpdk/drivers/net/bnxt/bnxt_txr.h
index e7f43f9d1d..08fd2e0142 100644
--- a/dpdk/drivers/net/bnxt/bnxt_txr.h
+++ b/dpdk/drivers/net/bnxt/bnxt_txr.h
@@ -57,8 +57,6 @@ int bnxt_init_one_tx_ring(struct bnxt_tx_queue *txq);
 int bnxt_init_tx_ring_struct(struct bnxt_tx_queue *txq, unsigned int socket_id);
 uint16_t bnxt_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,
 			       uint16_t nb_pkts);
-uint16_t bnxt_dummy_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,
-			      uint16_t nb_pkts);
 #ifdef RTE_ARCH_X86
 uint16_t bnxt_xmit_pkts_vec(void *tx_queue, struct rte_mbuf **tx_pkts,
 			    uint16_t nb_pkts);
diff --git a/dpdk/drivers/net/bnxt/bnxt_vnic.c b/dpdk/drivers/net/bnxt/bnxt_vnic.c
index 104342e13b..ef07721148 100644
--- a/dpdk/drivers/net/bnxt/bnxt_vnic.c
+++ b/dpdk/drivers/net/bnxt/bnxt_vnic.c
@@ -78,6 +78,9 @@ void bnxt_free_all_vnics(struct bnxt *bp)
 	struct bnxt_vnic_info *vnic;
 	unsigned int i;
 
+	if (bp->vnic_info == NULL)
+		return;
+
 	for (i = 0; i < bp->max_vnics; i++) {
 		vnic = &bp->vnic_info[i];
 		STAILQ_INSERT_TAIL(&bp->free_vnic_list, vnic, next);
@@ -150,17 +153,6 @@ int bnxt_alloc_vnic_attributes(struct bnxt *bp)
 			return -ENOMEM;
 	}
 	mz_phys_addr = mz->iova;
-	if ((unsigned long)mz->addr == mz_phys_addr) {
-		PMD_DRV_LOG(DEBUG,
-			    "Memzone physical address same as virtual.\n");
-		PMD_DRV_LOG(DEBUG, "Using rte_mem_virt2iova()\n");
-		mz_phys_addr = rte_mem_virt2iova(mz->addr);
-		if (mz_phys_addr == RTE_BAD_IOVA) {
-			PMD_DRV_LOG(ERR,
-				    "unable to map to physical memory\n");
-			return -ENOMEM;
-		}
-	}
 
 	for (i = 0; i < max_vnics; i++) {
 		vnic = &bp->vnic_info[i];
diff --git a/dpdk/drivers/net/bnxt/rte_pmd_bnxt.h b/dpdk/drivers/net/bnxt/rte_pmd_bnxt.h
index 2e893cc7bf..81d0d0e032 100644
--- a/dpdk/drivers/net/bnxt/rte_pmd_bnxt.h
+++ b/dpdk/drivers/net/bnxt/rte_pmd_bnxt.h
@@ -6,7 +6,8 @@
 #ifndef _PMD_BNXT_H_
 #define _PMD_BNXT_H_
 
-#include <rte_ethdev_driver.h>
+#include <rte_ethdev.h>
+#include <rte_ether.h>
 
 /*
  * Response sent back to the caller after callback
diff --git a/dpdk/drivers/net/bonding/eth_bond_8023ad_private.h b/dpdk/drivers/net/bonding/eth_bond_8023ad_private.h
index 6e44ffdb1c..9b5738afee 100644
--- a/dpdk/drivers/net/bonding/eth_bond_8023ad_private.h
+++ b/dpdk/drivers/net/bonding/eth_bond_8023ad_private.h
@@ -50,6 +50,7 @@
 #define SM_FLAGS_MOVED                      0x0100
 #define SM_FLAGS_PARTNER_SHORT_TIMEOUT      0x0200
 #define SM_FLAGS_NTT                        0x0400
+#define SM_FLAGS_EXPIRED                    0x0800
 
 #define BOND_LINK_FULL_DUPLEX_KEY           0x01
 #define BOND_LINK_SPEED_KEY_10M             0x02
@@ -103,6 +104,8 @@ struct port {
 
 	/** The operational Partner's port parameters */
 	struct port_params partner;
+	/** Partner administrative parameter values */
+	struct port_params partner_admin;
 
 	/* Additional port parameters not listed in documentation */
 	/** State machine flags */
diff --git a/dpdk/drivers/net/bonding/eth_bond_private.h b/dpdk/drivers/net/bonding/eth_bond_private.h
index c9b2d0fe46..af92a4c52a 100644
--- a/dpdk/drivers/net/bonding/eth_bond_private.h
+++ b/dpdk/drivers/net/bonding/eth_bond_private.h
@@ -50,6 +50,8 @@ extern const struct rte_flow_ops bond_flow_ops;
 /** Port Queue Mapping Structure */
 struct bond_rx_queue {
 	uint16_t queue_id;
+	/**< Next active_slave to poll */
+	uint16_t active_slave;
 	/**< Queue Id */
 	struct bond_dev_private *dev_private;
 	/**< Reference to eth_dev private structure */
@@ -132,7 +134,6 @@ struct bond_dev_private {
 	uint16_t nb_rx_queues;			/**< Total number of rx queues */
 	uint16_t nb_tx_queues;			/**< Total number of tx queues*/
 
-	uint16_t active_slave;		/**< Next active_slave to poll */
 	uint16_t active_slave_count;		/**< Number of active slaves */
 	uint16_t active_slaves[RTE_MAX_ETHPORTS];    /**< Active slave list */
 
diff --git a/dpdk/drivers/net/bonding/rte_eth_bond_8023ad.c b/dpdk/drivers/net/bonding/rte_eth_bond_8023ad.c
index b77a37ddb3..5fe004e551 100644
--- a/dpdk/drivers/net/bonding/rte_eth_bond_8023ad.c
+++ b/dpdk/drivers/net/bonding/rte_eth_bond_8023ad.c
@@ -356,16 +356,28 @@ rx_machine(struct bond_dev_private *internals, uint16_t slave_id,
 
 		timer_set(&port->current_while_timer, timeout);
 		ACTOR_STATE_CLR(port, EXPIRED);
+		SM_FLAG_CLR(port, EXPIRED);
 		return; /* No state change */
 	}
 
 	/* If CURRENT state timer is not running (stopped or expired)
 	 * transit to EXPIRED state from DISABLED or CURRENT */
 	if (!timer_is_running(&port->current_while_timer)) {
-		ACTOR_STATE_SET(port, EXPIRED);
-		PARTNER_STATE_CLR(port, SYNCHRONIZATION);
-		PARTNER_STATE_SET(port, LACP_SHORT_TIMEOUT);
-		timer_set(&port->current_while_timer, internals->mode4.short_timeout);
+		if (SM_FLAG(port, EXPIRED)) {
+			port->selected = UNSELECTED;
+			memcpy(&port->partner, &port->partner_admin,
+				sizeof(struct port_params));
+			record_default(port);
+			ACTOR_STATE_CLR(port, EXPIRED);
+			timer_cancel(&port->current_while_timer);
+		} else {
+			SM_FLAG_SET(port, EXPIRED);
+			ACTOR_STATE_SET(port, EXPIRED);
+			PARTNER_STATE_CLR(port, SYNCHRONIZATION);
+			PARTNER_STATE_SET(port, LACP_SHORT_TIMEOUT);
+			timer_set(&port->current_while_timer,
+				internals->mode4.short_timeout);
+		}
 	}
 }
 
@@ -798,7 +810,8 @@ rx_machine_update(struct bond_dev_private *internals, uint16_t slave_id,
 		RTE_ASSERT(lacp->lacpdu.subtype == SLOW_SUBTYPE_LACP);
 
 		partner = &lacp->lacpdu.partner;
-		if (rte_is_same_ether_addr(&partner->port_params.system,
Louis Abel's avatar
Louis Abel committed
26201 26202 26203 26204 26205 26206 26207 26208 26209 26210 26211 26212 26213 26214 26215 26216 26217 26218 26219 26220 26221 26222 26223 26224 26225 26226 26227 26228 26229 26230 26231 26232 26233 26234 26235 26236 26237 26238 26239 26240 26241 26242 26243 26244 26245 26246 26247 26248 26249 26250 26251 26252 26253 26254 26255 26256 26257 26258 26259 26260 26261 26262 26263 26264 26265 26266 26267 26268 26269 26270 26271 26272 26273 26274 26275 26276 26277 26278 26279 26280 26281 26282 26283 26284 26285 26286 26287 26288 26289 26290 26291 26292 26293 26294 26295 26296 26297 26298 26299 26300 26301 26302 26303 26304 26305 26306 26307 26308 26309 26310 26311 26312 26313 26314 26315 26316 26317 26318 26319 26320 26321 26322 26323 26324 26325 26326 26327 26328 26329 26330 26331 26332 26333 26334 26335 26336 26337 26338 26339 26340 26341 26342 26343 26344 26345 26346 26347 26348 26349 26350 26351 26352 26353 26354 26355 26356 26357 26358 26359 26360 26361 26362 26363 26364 26365 26366 26367 26368 26369 26370 26371 26372 26373 26374 26375 26376 26377 26378 26379 26380 26381 26382 26383 26384 26385 26386 26387 26388 26389 26390 26391 26392 26393 26394 26395 26396 26397 26398 26399 26400 26401 26402 26403 26404 26405 26406 26407 26408 26409 26410 26411 26412 26413 26414 26415 26416 26417 26418 26419 26420 26421 26422 26423 26424 26425 26426 26427 26428 26429 26430 26431 26432 26433 26434 26435 26436 26437 26438 26439 26440 26441 26442 26443 26444 26445 26446 26447 26448 26449 26450 26451 26452 26453 26454 26455 26456 26457 26458 26459 26460 26461 26462 26463 26464 26465 26466 26467 26468 26469 26470 26471 26472 26473 26474 26475 26476 26477 26478 26479 26480 26481 26482 26483 26484 26485 26486 26487 26488 26489 26490 26491 26492 26493 26494 26495 26496 26497 26498 26499 26500 26501 26502 26503 26504 26505 26506 26507 26508 26509 26510 26511 26512 26513 26514 26515 26516 26517 26518 26519 26520 26521 26522 26523 26524 26525 26526 26527 26528 26529 26530 26531 26532 26533 26534 26535 26536 26537 26538 26539 26540 26541 26542 26543 26544 26545 26546 26547 26548 26549 26550 26551 26552 26553 26554 26555 26556 26557 26558 26559 26560 26561 26562 26563 26564 26565 26566 26567 26568 26569 26570 26571 26572 26573 26574 26575 26576 26577 26578 26579 26580 26581 26582 26583 26584 26585 26586 26587 26588 26589 26590 26591 26592 26593 26594 26595 26596 26597 26598 26599 26600 26601 26602 26603 26604 26605 26606 26607 26608 26609 26610 26611 26612 26613 26614 26615 26616 26617 26618 26619 26620 26621 26622 26623 26624 26625 26626 26627 26628 26629 26630 26631 26632 26633 26634 26635 26636 26637 26638 26639 26640 26641 26642 26643 26644 26645 26646 26647 26648 26649 26650 26651 26652 26653 26654 26655 26656 26657 26658 26659 26660 26661 26662 26663 26664 26665 26666 26667 26668 26669 26670 26671 26672 26673 26674 26675 26676 26677 26678 26679 26680 26681 26682 26683 26684 26685 26686 26687 26688 26689 26690 26691 26692 26693 26694 26695 26696 26697 26698 26699 26700 26701 26702 26703 26704 26705 26706 26707 26708 26709 26710 26711 26712 26713 26714 26715 26716 26717 26718 26719 26720 26721 26722 26723 26724 26725 26726 26727 26728 26729 26730 26731 26732 26733 26734 26735 26736 26737 26738 26739 26740 26741 26742 26743 26744 26745 26746 26747 26748 26749 26750 26751 26752 26753 26754 26755 26756 26757 26758 26759 26760 26761 26762 26763 26764 26765 26766 26767 26768 26769 26770 26771 26772 26773 26774 26775 26776 26777 26778 26779 26780 26781 26782 26783 26784 26785 26786 26787 26788 26789 26790 26791 26792 26793 26794 26795 26796 26797 26798 26799 26800 26801 26802 26803 26804 26805 26806 26807 26808 26809 26810 26811 26812 26813 26814 26815 26816 26817 26818 26819 26820 26821 26822 26823 26824 26825 26826 26827 26828 26829 26830 26831 26832 26833 26834 26835 26836 26837 26838 26839 26840 26841 26842 26843 26844 26845 26846 26847 26848 26849 26850 26851 26852 26853 26854 26855 26856 26857 26858 26859 26860 26861 26862 26863 26864 26865 26866 26867 26868 26869 26870 26871 26872 26873 26874 26875 26876 26877 26878 26879 26880 26881 26882 26883 26884 26885 26886 26887 26888 26889 26890 26891 26892 26893 26894 26895 26896 26897 26898 26899 26900 26901 26902 26903 26904 26905 26906 26907 26908 26909 26910 26911 26912 26913 26914 26915 26916 26917 26918 26919 26920 26921 26922 26923 26924 26925 26926 26927 26928 26929 26930 26931 26932 26933 26934 26935 26936 26937 26938 26939 26940 26941 26942 26943 26944 26945 26946 26947 26948 26949 26950 26951 26952 26953 26954 26955 26956 26957 26958 26959 26960 26961 26962 26963 26964 26965 26966 26967 26968 26969 26970 26971 26972 26973 26974 26975 26976 26977 26978 26979 26980 26981 26982 26983 26984 26985 26986 26987 26988 26989 26990 26991 26992 26993 26994 26995 26996 26997 26998 26999 27000 27001 27002 27003 27004 27005 27006 27007 27008 27009 27010 27011 27012 27013 27014 27015 27016 27017 27018 27019 27020 27021 27022 27023 27024 27025 27026 27027 27028 27029 27030 27031 27032 27033 27034 27035 27036 27037 27038 27039 27040 27041 27042 27043 27044 27045 27046 27047 27048 27049 27050 27051 27052 27053 27054 27055 27056 27057 27058 27059 27060 27061 27062 27063 27064 27065 27066 27067 27068 27069 27070 27071 27072 27073 27074 27075 27076 27077 27078 27079 27080 27081 27082 27083 27084 27085 27086 27087 27088 27089 27090 27091 27092 27093 27094 27095 27096 27097 27098 27099 27100 27101 27102 27103 27104 27105 27106 27107 27108 27109 27110 27111 27112 27113 27114 27115 27116 27117 27118 27119 27120 27121 27122 27123 27124 27125 27126 27127 27128 27129 27130 27131 27132 27133 27134 27135 27136 27137 27138 27139 27140 27141 27142 27143 27144 27145 27146 27147 27148 27149 27150 27151 27152 27153 27154 27155 27156 27157 27158 27159 27160 27161 27162 27163 27164 27165 27166 27167 27168 27169 27170 27171 27172 27173 27174 27175 27176 27177 27178 27179 27180 27181 27182 27183 27184 27185 27186 27187 27188 27189 27190 27191 27192 27193 27194 27195 27196 27197 27198 27199 27200 27201 27202 27203 27204 27205 27206 27207 27208 27209 27210 27211 27212 27213 27214 27215 27216 27217 27218 27219 27220 27221 27222 27223 27224 27225 27226 27227 27228 27229 27230 27231 27232 27233 27234 27235 27236 27237 27238 27239 27240 27241 27242 27243 27244 27245 27246 27247 27248 27249 27250 27251 27252 27253 27254 27255 27256 27257 27258 27259 27260 27261 27262 27263 27264 27265 27266 27267 27268 27269 27270 27271 27272 27273 27274 27275 27276 27277 27278 27279 27280 27281 27282 27283 27284 27285 27286 27287 27288 27289 27290 27291 27292 27293 27294 27295 27296 27297 27298 27299 27300 27301 27302 27303 27304 27305 27306 27307 27308 27309 27310 27311 27312 27313 27314 27315 27316 27317 27318 27319 27320 27321 27322 27323 27324 27325 27326 27327 27328 27329 27330 27331 27332 27333 27334 27335 27336 27337 27338 27339 27340 27341 27342 27343 27344 27345 27346 27347 27348 27349 27350 27351 27352 27353 27354 27355 27356 27357 27358 27359 27360 27361 27362 27363 27364 27365 27366 27367 27368 27369 27370 27371 27372 27373 27374 27375 27376 27377 27378 27379 27380 27381 27382 27383 27384 27385 27386 27387 27388 27389 27390 27391 27392 27393 27394 27395 27396 27397 27398 27399 27400 27401 27402 27403 27404 27405 27406 27407 27408 27409 27410 27411 27412 27413 27414 27415 27416 27417 27418 27419 27420 27421 27422 27423 27424 27425 27426 27427 27428 27429 27430 27431 27432 27433 27434 27435 27436 27437 27438 27439 27440 27441 27442 27443 27444 27445 27446 27447 27448 27449 27450 27451 27452 27453 27454 27455 27456 27457 27458 27459 27460 27461 27462 27463 27464 27465 27466 27467 27468 27469 27470 27471 27472 27473 27474 27475 27476 27477 27478 27479 27480 27481 27482 27483 27484 27485 27486 27487 27488 27489 27490 27491 27492 27493 27494 27495 27496 27497 27498 27499 27500 27501 27502 27503 27504 27505 27506 27507 27508 27509 27510 27511 27512 27513 27514 27515 27516 27517 27518 27519 27520 27521 27522 27523 27524 27525 27526 27527 27528 27529 27530 27531 27532 27533 27534 27535 27536 27537 27538 27539 27540 27541 27542 27543 27544 27545 27546 27547 27548 27549 27550 27551 27552 27553 27554 27555 27556 27557 27558 27559 27560 27561 27562 27563 27564 27565 27566 27567 27568 27569 27570 27571 27572 27573 27574 27575 27576 27577 27578 27579 27580 27581 27582 27583 27584 27585 27586 27587 27588 27589 27590 27591 27592 27593 27594 27595 27596 27597 27598 27599 27600 27601 27602 27603 27604 27605 27606 27607 27608 27609 27610 27611 27612 27613 27614 27615 27616 27617 27618 27619 27620 27621 27622 27623 27624 27625 27626 27627 27628 27629 27630 27631 27632 27633 27634 27635 27636 27637 27638 27639 27640 27641 27642 27643 27644 27645 27646 27647 27648 27649 27650 27651 27652 27653 27654 27655 27656 27657 27658 27659 27660 27661 27662 27663 27664 27665 27666 27667 27668 27669 27670 27671 27672 27673 27674 27675 27676 27677 27678 27679 27680 27681 27682 27683 27684 27685 27686 27687 27688 27689 27690 27691 27692 27693 27694 27695 27696 27697 27698 27699 27700 27701 27702 27703 27704 27705 27706 27707 27708 27709 27710 27711 27712 27713 27714 27715 27716 27717 27718 27719 27720 27721 27722 27723 27724 27725 27726 27727 27728 27729 27730 27731 27732 27733 27734 27735 27736 27737 27738 27739 27740 27741 27742 27743 27744 27745 27746 27747 27748 27749 27750 27751 27752 27753 27754 27755 27756 27757 27758 27759 27760 27761 27762 27763 27764 27765 27766 27767 27768 27769 27770 27771 27772 27773 27774 27775 27776 27777 27778 27779 27780 27781 27782 27783 27784 27785 27786 27787 27788 27789 27790 27791 27792 27793 27794 27795 27796 27797 27798 27799 27800 27801 27802 27803 27804 27805 27806 27807 27808 27809 27810 27811 27812 27813 27814 27815 27816 27817 27818 27819 27820 27821 27822 27823 27824 27825 27826 27827 27828 27829 27830 27831 27832 27833 27834 27835 27836 27837 27838 27839 27840 27841 27842 27843 27844 27845 27846 27847 27848 27849 27850 27851 27852 27853 27854 27855 27856 27857 27858 27859 27860 27861 27862 27863 27864 27865 27866 27867 27868 27869 27870 27871 27872 27873 27874 27875 27876 27877 27878 27879 27880 27881 27882 27883 27884 27885 27886 27887 27888 27889 27890 27891 27892 27893 27894 27895 27896 27897 27898 27899 27900 27901 27902 27903 27904 27905 27906 27907 27908 27909 27910 27911 27912 27913 27914 27915 27916 27917 27918 27919 27920 27921 27922 27923 27924 27925 27926 27927 27928 27929 27930 27931 27932 27933 27934 27935 27936 27937 27938 27939 27940 27941 27942 27943 27944 27945 27946 27947 27948 27949 27950 27951 27952 27953 27954 27955 27956 27957 27958 27959 27960 27961 27962 27963 27964 27965 27966 27967 27968 27969 27970 27971 27972 27973 27974 27975 27976 27977 27978 27979 27980 27981 27982 27983 27984 27985 27986 27987 27988 27989 27990 27991 27992 27993 27994 27995 27996 27997 27998 27999 28000 28001 28002 28003 28004 28005 28006 28007 28008 28009 28010 28011 28012 28013 28014 28015 28016 28017 28018 28019 28020 28021 28022 28023 28024 28025 28026 28027 28028 28029 28030 28031 28032 28033 28034 28035 28036 28037 28038 28039 28040 28041 28042 28043 28044 28045 28046 28047 28048 28049 28050 28051 28052 28053 28054 28055 28056 28057 28058 28059 28060 28061 28062 28063 28064 28065 28066 28067 28068 28069 28070 28071 28072 28073 28074 28075 28076 28077 28078 28079 28080 28081 28082 28083 28084 28085 28086 28087 28088 28089 28090 28091 28092 28093 28094 28095 28096 28097 28098 28099 28100 28101 28102 28103 28104 28105 28106 28107 28108 28109 28110 28111 28112 28113 28114 28115 28116 28117 28118 28119 28120 28121 28122 28123 28124 28125 28126 28127 28128 28129 28130 28131 28132 28133 28134 28135 28136 28137 28138 28139 28140 28141 28142 28143 28144 28145 28146 28147 28148 28149 28150 28151 28152 28153 28154 28155 28156 28157 28158 28159 28160 28161 28162 28163 28164 28165 28166 28167 28168 28169 28170 28171 28172 28173 28174 28175 28176 28177 28178 28179 28180 28181 28182 28183 28184 28185 28186 28187 28188 28189 28190 28191 28192 28193 28194 28195 28196 28197 28198 28199 28200
+		if (rte_is_zero_ether_addr(&partner->port_params.system) ||
+			rte_is_same_ether_addr(&partner->port_params.system,
 			&internals->mode4.mac_addr)) {
 			/* This LACP frame is sending to the bonding port
 			 * so pass it to rx_machine.
@@ -1020,6 +1033,7 @@ bond_mode_8023ad_activate_slave(struct rte_eth_dev *bond_dev,
 	port->actor.port_number = rte_cpu_to_be_16(slave_id + 1);
 
 	memcpy(&port->partner, &initial, sizeof(struct port_params));
+	memcpy(&port->partner_admin, &initial, sizeof(struct port_params));
 
 	/* default states */
 	port->actor_state = STATE_AGGREGATION | STATE_LACP_ACTIVE | STATE_DEFAULTED;
@@ -1043,7 +1057,7 @@ bond_mode_8023ad_activate_slave(struct rte_eth_dev *bond_dev,
 	RTE_ASSERT(port->tx_ring == NULL);
 
 	socket_id = rte_eth_dev_socket_id(slave_id);
-	if (socket_id == (int)LCORE_ID_ANY)
+	if (socket_id == -1)
 		socket_id = rte_socket_id();
 
 	element_size = sizeof(struct slow_protocol_frame) +
@@ -1320,8 +1334,7 @@ bond_mode_8023ad_handle_slow_pkt(struct bond_dev_private *internals,
 		rte_eth_macaddr_get(slave_id, &m_hdr->eth_hdr.s_addr);
 
 		if (internals->mode4.dedicated_queues.enabled == 0) {
-			int retval = rte_ring_enqueue(port->tx_ring, pkt);
-			if (retval != 0) {
+			if (rte_ring_enqueue(port->tx_ring, pkt) != 0) {
 				/* reset timer */
 				port->rx_marker_timer = 0;
 				wrn = WRN_TX_QUEUE_FULL;
@@ -1341,8 +1354,7 @@ bond_mode_8023ad_handle_slow_pkt(struct bond_dev_private *internals,
 		}
 	} else if (likely(subtype == SLOW_SUBTYPE_LACP)) {
 		if (internals->mode4.dedicated_queues.enabled == 0) {
-			int retval = rte_ring_enqueue(port->rx_ring, pkt);
-			if (retval != 0) {
+			if (rte_ring_enqueue(port->rx_ring, pkt) != 0) {
 				/* If RX fing full free lacpdu message and drop packet */
 				wrn = WRN_RX_QUEUE_FULL;
 				goto free_out;
@@ -1675,9 +1687,6 @@ rte_eth_bond_8023ad_dedicated_queues_enable(uint16_t port)
 	dev = &rte_eth_devices[port];
 	internals = dev->data->dev_private;
 
-	if (check_for_bonded_ethdev(dev) != 0)
-		return -1;
-
 	if (bond_8023ad_slow_pkt_hw_filter_supported(port) != 0)
 		return -1;
 
@@ -1704,9 +1713,6 @@ rte_eth_bond_8023ad_dedicated_queues_disable(uint16_t port)
 	dev = &rte_eth_devices[port];
 	internals = dev->data->dev_private;
 
-	if (check_for_bonded_ethdev(dev) != 0)
-		return -1;
-
 	/* Device must be stopped to set up slow queue */
 	if (dev->data->dev_started)
 		return -1;
diff --git a/dpdk/drivers/net/bonding/rte_eth_bond_api.c b/dpdk/drivers/net/bonding/rte_eth_bond_api.c
index f38eb3b47f..a4007fe07c 100644
--- a/dpdk/drivers/net/bonding/rte_eth_bond_api.c
+++ b/dpdk/drivers/net/bonding/rte_eth_bond_api.c
@@ -129,12 +129,6 @@ deactivate_slave(struct rte_eth_dev *eth_dev, uint16_t port_id)
 	RTE_ASSERT(active_count < RTE_DIM(internals->active_slaves));
 	internals->active_slave_count = active_count;
 
-	/* Resetting active_slave when reaches to max
-	 * no of slaves in active list
-	 */
-	if (internals->active_slave >= active_count)
-		internals->active_slave = 0;
-
 	if (eth_dev->data->dev_started) {
 		if (internals->mode == BONDING_MODE_8023AD) {
 			bond_mode_8023ad_start(eth_dev);
@@ -167,7 +161,7 @@ rte_eth_bond_create(const char *name, uint8_t mode, uint8_t socket_id)
 
 	ret = rte_vdev_init(name, devargs);
 	if (ret)
-		return -ENOMEM;
+		return ret;
 
 	ret = rte_eth_dev_get_port_by_name(name, &port_id);
 	RTE_ASSERT(!ret);
@@ -698,6 +692,7 @@ __eth_bond_slave_remove_lock_free(uint16_t bonded_port_id,
 			internals->current_primary_port = internals->slaves[0].port_id;
 		else
 			internals->primary_port = 0;
+		mac_address_slaves_update(bonded_eth_dev);
 	}
 
 	if (internals->active_slave_count < 1) {
diff --git a/dpdk/drivers/net/bonding/rte_eth_bond_args.c b/dpdk/drivers/net/bonding/rte_eth_bond_args.c
index abdf552610..8c5f90dc63 100644
--- a/dpdk/drivers/net/bonding/rte_eth_bond_args.c
+++ b/dpdk/drivers/net/bonding/rte_eth_bond_args.c
@@ -22,23 +22,37 @@ const char *pmd_bond_init_valid_arguments[] = {
 	NULL
 };
 
+static inline int
+bond_pci_addr_cmp(const struct rte_device *dev, const void *_pci_addr)
+{
+	const struct rte_pci_device *pdev = RTE_DEV_TO_PCI_CONST(dev);
+	const struct rte_pci_addr *paddr = _pci_addr;
+
+	return rte_pci_addr_cmp(&pdev->addr, paddr);
+}
+
 static inline int
 find_port_id_by_pci_addr(const struct rte_pci_addr *pci_addr)
 {
-	struct rte_pci_device *pci_dev;
-	struct rte_pci_addr *eth_pci_addr;
+	struct rte_bus *pci_bus;
+	struct rte_device *dev;
 	unsigned i;
 
-	RTE_ETH_FOREACH_DEV(i) {
-		pci_dev = RTE_ETH_DEV_TO_PCI(&rte_eth_devices[i]);
-		eth_pci_addr = &pci_dev->addr;
+	pci_bus = rte_bus_find_by_name("pci");
+	if (pci_bus == NULL) {
+		RTE_BOND_LOG(ERR, "No PCI bus found");
+		return -1;
+	}
 
-		if (pci_addr->bus == eth_pci_addr->bus &&
-			pci_addr->devid == eth_pci_addr->devid &&
-			pci_addr->domain == eth_pci_addr->domain &&
-			pci_addr->function == eth_pci_addr->function)
-			return i;
+	dev = pci_bus->find_device(NULL, bond_pci_addr_cmp, pci_addr);
+	if (dev == NULL) {
+		RTE_BOND_LOG(ERR, "unable to find PCI device");
+		return -1;
 	}
+
+	RTE_ETH_FOREACH_DEV(i)
+		if (rte_eth_devices[i].device == dev)
+			return i;
 	return -1;
 }
 
@@ -57,15 +71,6 @@ find_port_id_by_dev_name(const char *name)
 	return -1;
 }
 
-static inline int
-bond_pci_addr_cmp(const struct rte_device *dev, const void *_pci_addr)
-{
-	const struct rte_pci_device *pdev = RTE_DEV_TO_PCI_CONST(dev);
-	const struct rte_pci_addr *paddr = _pci_addr;
-
-	return rte_pci_addr_cmp(&pdev->addr, paddr);
-}
-
 /**
  * Parses a port identifier string to a port id by pci address, then by name,
  * and finally port id.
@@ -74,23 +79,10 @@ static inline int
 parse_port_id(const char *port_str)
 {
 	struct rte_pci_addr dev_addr;
-	struct rte_bus *pci_bus;
-	struct rte_device *dev;
 	int port_id;
 
-	pci_bus = rte_bus_find_by_name("pci");
-	if (pci_bus == NULL) {
-		RTE_BOND_LOG(ERR, "unable to find PCI bus\n");
-		return -1;
-	}
-
 	/* try parsing as pci address, physical devices */
-	if (pci_bus->parse(port_str, &dev_addr) == 0) {
-		dev = pci_bus->find_device(NULL, bond_pci_addr_cmp, &dev_addr);
-		if (dev == NULL) {
-			RTE_BOND_LOG(ERR, "unable to find PCI device");
-			return -1;
-		}
+	if (rte_pci_addr_parse(port_str, &dev_addr) == 0) {
 		port_id = find_port_id_by_pci_addr(&dev_addr);
 		if (port_id < 0)
 			return -1;
@@ -108,9 +100,8 @@ parse_port_id(const char *port_str)
 		}
 	}
 
-	if (port_id < 0 || port_id > RTE_MAX_ETHPORTS) {
-		RTE_BOND_LOG(ERR, "Slave port specified (%s) outside expected range",
-				port_str);
+	if (!rte_eth_dev_is_valid_port(port_id)) {
+		RTE_BOND_LOG(ERR, "Specified port (%s) is invalid", port_str);
 		return -1;
 	}
 	return port_id;
diff --git a/dpdk/drivers/net/bonding/rte_eth_bond_pmd.c b/dpdk/drivers/net/bonding/rte_eth_bond_pmd.c
index 707a0f3cdd..e7cb418053 100644
--- a/dpdk/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/dpdk/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -69,7 +69,7 @@ bond_ethdev_rx_burst(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	struct bond_rx_queue *bd_rx_q = (struct bond_rx_queue *)queue;
 	internals = bd_rx_q->dev_private;
 	slave_count = internals->active_slave_count;
-	active_slave = internals->active_slave;
+	active_slave = bd_rx_q->active_slave;
 
 	for (i = 0; i < slave_count && nb_pkts; i++) {
 		uint16_t num_rx_slave;
@@ -86,8 +86,8 @@ bond_ethdev_rx_burst(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 			active_slave = 0;
 	}
 
-	if (++internals->active_slave >= slave_count)
-		internals->active_slave = 0;
+	if (++bd_rx_q->active_slave >= slave_count)
+		bd_rx_q->active_slave = 0;
 	return num_rx_total;
 }
 
@@ -303,9 +303,9 @@ rx_burst_8023ad(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts,
 	memcpy(slaves, internals->active_slaves,
 			sizeof(internals->active_slaves[0]) * slave_count);
 
-	idx = internals->active_slave;
+	idx = bd_rx_q->active_slave;
 	if (idx >= slave_count) {
-		internals->active_slave = 0;
+		bd_rx_q->active_slave = 0;
 		idx = 0;
 	}
 	for (i = 0; i < slave_count && num_rx_total < nb_pkts; i++) {
@@ -367,8 +367,8 @@ rx_burst_8023ad(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts,
 			idx = 0;
 	}
 
-	if (++internals->active_slave >= slave_count)
-		internals->active_slave = 0;
+	if (++bd_rx_q->active_slave >= slave_count)
+		bd_rx_q->active_slave = 0;
 
 	return num_rx_total;
 }
@@ -534,8 +534,8 @@ mode6_debug(const char __attribute__((unused)) *info,
 static uint16_t
 bond_ethdev_rx_burst_alb(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 {
-	struct bond_tx_queue *bd_tx_q = (struct bond_tx_queue *)queue;
-	struct bond_dev_private *internals = bd_tx_q->dev_private;
+	struct bond_rx_queue *bd_rx_q = (struct bond_rx_queue *)queue;
+	struct bond_dev_private *internals = bd_rx_q->dev_private;
 	struct rte_ether_hdr *eth_h;
 	uint16_t ether_type, offset;
 	uint16_t nb_recv_pkts;
@@ -1502,6 +1502,7 @@ int
 mac_address_slaves_update(struct rte_eth_dev *bonded_eth_dev)
 {
 	struct bond_dev_private *internals = bonded_eth_dev->data->dev_private;
+	bool set;
 	int i;
 
 	/* Update slave devices MAC addresses */
@@ -1529,15 +1530,16 @@ mac_address_slaves_update(struct rte_eth_dev *bonded_eth_dev)
 	case BONDING_MODE_TLB:
 	case BONDING_MODE_ALB:
 	default:
+		set = true;
 		for (i = 0; i < internals->slave_count; i++) {
 			if (internals->slaves[i].port_id ==
 					internals->current_primary_port) {
 				if (rte_eth_dev_default_mac_addr_set(
-						internals->primary_port,
+						internals->current_primary_port,
 						bonded_eth_dev->data->mac_addrs)) {
 					RTE_BOND_LOG(ERR, "Failed to update port Id %d MAC address",
 							internals->current_primary_port);
-					return -1;
+					set = false;
 				}
 			} else {
 				if (rte_eth_dev_default_mac_addr_set(
@@ -1545,10 +1547,11 @@ mac_address_slaves_update(struct rte_eth_dev *bonded_eth_dev)
 						&internals->slaves[i].persisted_mac_addr)) {
 					RTE_BOND_LOG(ERR, "Failed to update port Id %d MAC address",
 							internals->slaves[i].port_id);
-					return -1;
 				}
 			}
 		}
+		if (!set)
+			return -1;
 	}
 
 	return 0;
@@ -2873,6 +2876,7 @@ bond_ethdev_lsc_event_callback(uint16_t port_id, enum rte_eth_event_type type,
 						internals->active_slaves[0]);
 			else
 				internals->current_primary_port = internals->primary_port;
+			mac_address_slaves_update(bonded_eth_dev);
 		}
 	}
 
@@ -2931,7 +2935,8 @@ bond_ethdev_rss_reta_update(struct rte_eth_dev *dev,
 		return -EINVAL;
 
 	 /* Copy RETA table */
-	reta_count = reta_size / RTE_RETA_GROUP_SIZE;
+	reta_count = (reta_size + RTE_RETA_GROUP_SIZE - 1) /
+			RTE_RETA_GROUP_SIZE;
 
 	for (i = 0; i < reta_count; i++) {
 		internals->reta_conf[i].mask = reta_conf[i].mask;
diff --git a/dpdk/drivers/net/cxgbe/base/adapter.h b/dpdk/drivers/net/cxgbe/base/adapter.h
index db654ad9cd..eabd70a213 100644
--- a/dpdk/drivers/net/cxgbe/base/adapter.h
+++ b/dpdk/drivers/net/cxgbe/base/adapter.h
@@ -816,6 +816,7 @@ int t4_sge_eth_rxq_start(struct adapter *adap, struct sge_rspq *rq);
 int t4_sge_eth_rxq_stop(struct adapter *adap, struct sge_rspq *rq);
 void t4_sge_eth_rxq_release(struct adapter *adap, struct sge_eth_rxq *rxq);
 void t4_sge_eth_clear_queues(struct port_info *pi);
+void t4_sge_eth_release_queues(struct port_info *pi);
 int cxgb4_set_rspq_intr_params(struct sge_rspq *q, unsigned int us,
 			       unsigned int cnt);
 int cxgbe_poll(struct sge_rspq *q, struct rte_mbuf **rx_pkts,
diff --git a/dpdk/drivers/net/cxgbe/cxgbe.h b/dpdk/drivers/net/cxgbe/cxgbe.h
index 6c1f73ac4b..8b8babc5e4 100644
--- a/dpdk/drivers/net/cxgbe/cxgbe.h
+++ b/dpdk/drivers/net/cxgbe/cxgbe.h
@@ -19,6 +19,10 @@
 #define CXGBE_MAX_RX_PKTLEN (9000 + RTE_ETHER_HDR_LEN + \
 				RTE_ETHER_CRC_LEN) /* max pkt */
 
+/* The max frame size with default MTU */
+#define CXGBE_ETH_MAX_LEN (RTE_ETHER_MTU + \
+		RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN)
+
 /* Max poll time is 100 * 100msec = 10 sec */
 #define CXGBE_LINK_STATUS_POLL_MS 100 /* 100ms */
 #define CXGBE_LINK_STATUS_POLL_CNT 100 /* Max number of times to poll */
@@ -40,7 +44,8 @@
 			   DEV_TX_OFFLOAD_IPV4_CKSUM | \
 			   DEV_TX_OFFLOAD_UDP_CKSUM | \
 			   DEV_TX_OFFLOAD_TCP_CKSUM | \
-			   DEV_TX_OFFLOAD_TCP_TSO)
+			   DEV_TX_OFFLOAD_TCP_TSO | \
+			   DEV_TX_OFFLOAD_MULTI_SEGS)
 
 #define CXGBE_RX_OFFLOADS (DEV_RX_OFFLOAD_VLAN_STRIP | \
 			   DEV_RX_OFFLOAD_IPV4_CKSUM | \
diff --git a/dpdk/drivers/net/cxgbe/cxgbe_ethdev.c b/dpdk/drivers/net/cxgbe/cxgbe_ethdev.c
index 51b63ef574..352b47fdfb 100644
--- a/dpdk/drivers/net/cxgbe/cxgbe_ethdev.c
+++ b/dpdk/drivers/net/cxgbe/cxgbe_ethdev.c
@@ -74,6 +74,9 @@ uint16_t cxgbe_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,
 	t4_os_lock(&txq->txq_lock);
 	/* free up desc from already completed tx */
 	reclaim_completed_tx(&txq->q);
+	if (unlikely(!nb_pkts))
+		goto out_unlock;
+
 	rte_prefetch0(rte_pktmbuf_mtod(tx_pkts[0], volatile void *));
 	while (total_sent < nb_pkts) {
 		pkts_remain = nb_pkts - total_sent;
@@ -94,6 +97,7 @@ uint16_t cxgbe_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,
 		reclaim_completed_tx(&txq->q);
 	}
 
+out_unlock:
 	t4_os_unlock(&txq->txq_lock);
 	return total_sent;
 }
@@ -300,7 +304,7 @@ int cxgbe_dev_mtu_set(struct rte_eth_dev *eth_dev, uint16_t mtu)
 		return -EINVAL;
 
 	/* set to jumbo mode if needed */
-	if (new_mtu > RTE_ETHER_MAX_LEN)
+	if (new_mtu > CXGBE_ETH_MAX_LEN)
 		eth_dev->data->dev_conf.rxmode.offloads |=
 			DEV_RX_OFFLOAD_JUMBO_FRAME;
 	else
@@ -329,12 +333,7 @@ void cxgbe_dev_close(struct rte_eth_dev *eth_dev)
 		return;
 
 	cxgbe_down(pi);
-
-	/*
-	 *  We clear queues only if both tx and rx path of the port
-	 *  have been disabled
-	 */
-	t4_sge_eth_clear_queues(pi);
+	t4_sge_eth_release_queues(pi);
 }
 
 /* Start the device.
@@ -649,7 +648,7 @@ int cxgbe_dev_rx_queue_setup(struct rte_eth_dev *eth_dev,
 		rxq->fl.size = temp_nb_desc;
 
 	/* Set to jumbo mode if necessary */
-	if (pkt_len > RTE_ETHER_MAX_LEN)
+	if (pkt_len > CXGBE_ETH_MAX_LEN)
 		eth_dev->data->dev_conf.rxmode.offloads |=
 			DEV_RX_OFFLOAD_JUMBO_FRAME;
 	else
diff --git a/dpdk/drivers/net/cxgbe/cxgbe_filter.c b/dpdk/drivers/net/cxgbe/cxgbe_filter.c
index b9d9d5d391..7affa0785a 100644
--- a/dpdk/drivers/net/cxgbe/cxgbe_filter.c
+++ b/dpdk/drivers/net/cxgbe/cxgbe_filter.c
@@ -8,6 +8,7 @@
 #include "base/t4_tcb.h"
 #include "base/t4_regs.h"
 #include "cxgbe_filter.h"
+#include "mps_tcam.h"
 #include "clip_tbl.h"
 #include "l2t.h"
 
@@ -269,6 +270,30 @@ int cxgbe_alloc_ftid(struct adapter *adap, u8 nentries)
 	return pos < size ? pos : -1;
 }
 
+/**
+ * Clear a filter and release any of its resources that we own.  This also
+ * clears the filter's "pending" status.
+ */
+static void clear_filter(struct filter_entry *f)
+{
+	struct port_info *pi = ethdev2pinfo(f->dev);
+
+	if (f->clipt)
+		cxgbe_clip_release(f->dev, f->clipt);
+
+	if (f->l2t)
+		cxgbe_l2t_release(f->l2t);
+
+	if (f->fs.mask.macidx)
+		cxgbe_mpstcam_remove(pi, f->fs.val.macidx);
+
+	/* The zeroing of the filter rule below clears the filter valid,
+	 * pending, locked flags etc. so it's all we need for
+	 * this operation.
+	 */
+	memset(f, 0, sizeof(*f));
+}
+
 /**
  * Construct hash filter ntuple.
  */
@@ -555,13 +580,26 @@ static int cxgbe_set_hash_filter(struct rte_eth_dev *dev,
 
 	f = t4_os_alloc(sizeof(*f));
 	if (!f)
-		goto out_err;
+		return -ENOMEM;
 
 	f->fs = *fs;
 	f->ctx = ctx;
 	f->dev = dev;
 	f->fs.iq = iq;
 
+	/* Allocate MPS TCAM entry to match Destination MAC. */
+	if (f->fs.mask.macidx) {
+		int idx;
+
+		idx = cxgbe_mpstcam_alloc(pi, f->fs.val.dmac, f->fs.mask.dmac);
+		if (idx <= 0) {
+			ret = -ENOMEM;
+			goto out_err;
+		}
+
+		f->fs.val.macidx = idx;
+	}
+
 	/*
 	 * If the new filter requires loopback Destination MAC and/or VLAN
 	 * rewriting then we need to allocate a Layer 2 Table (L2T) entry for
@@ -592,7 +630,7 @@ static int cxgbe_set_hash_filter(struct rte_eth_dev *dev,
 		mbuf = rte_pktmbuf_alloc(ctrlq->mb_pool);
 		if (!mbuf) {
 			ret = -ENOMEM;
-			goto free_clip;
+			goto free_atid;
 		}
 
 		mbuf->data_len = size;
@@ -622,33 +660,15 @@ static int cxgbe_set_hash_filter(struct rte_eth_dev *dev,
 	t4_mgmt_tx(ctrlq, mbuf);
 	return 0;
 
-free_clip:
-	cxgbe_clip_release(f->dev, f->clipt);
 free_atid:
 	cxgbe_free_atid(t, atid);
 
 out_err:
+	clear_filter(f);
 	t4_os_free(f);
 	return ret;
 }
 
-/**
- * Clear a filter and release any of its resources that we own.  This also
- * clears the filter's "pending" status.
- */
-static void clear_filter(struct filter_entry *f)
-{
-	if (f->clipt)
-		cxgbe_clip_release(f->dev, f->clipt);
-
-	/*
-	 * The zeroing of the filter rule below clears the filter valid,
-	 * pending, locked flags etc. so it's all we need for
-	 * this operation.
-	 */
-	memset(f, 0, sizeof(*f));
-}
-
 /**
  * t4_mk_filtdelwr - create a delete filter WR
  * @adap: adapter context
@@ -718,19 +738,6 @@ static int set_filter_wr(struct rte_eth_dev *dev, unsigned int fidx)
 	unsigned int port_id = ethdev2pinfo(dev)->port_id;
 	int ret;
 
-	/*
-	 * If the new filter requires loopback Destination MAC and/or VLAN
-	 * rewriting then we need to allocate a Layer 2 Table (L2T) entry for
-	 * the filter.
-	 */
-	if (f->fs.newvlan) {
-		/* allocate L2T entry for new filter */
-		f->l2t = cxgbe_l2t_alloc_switching(f->dev, f->fs.vlan,
-						   f->fs.eport, f->fs.dmac);
-		if (!f->l2t)
-			return -ENOMEM;
-	}
-
 	ctrlq = &adapter->sge.ctrlq[port_id];
 	mbuf = rte_pktmbuf_alloc(ctrlq->mb_pool);
 	if (!mbuf) {
@@ -1007,16 +1014,6 @@ int cxgbe_set_filter(struct rte_eth_dev *dev, unsigned int filter_id,
 		return ret;
 	}
 
-	/*
-	 * Allocate a clip table entry only if we have non-zero IPv6 address
-	 */
-	if (chip_ver > CHELSIO_T5 && fs->type &&
-	    memcmp(fs->val.lip, bitoff, sizeof(bitoff))) {
-		f->clipt = cxgbe_clip_alloc(dev, (u32 *)&fs->val.lip);
-		if (!f->clipt)
-			goto free_tid;
-	}
-
 	/*
 	 * Convert the filter specification into our internal format.
 	 * We copy the PF/VF specification into the Outer VLAN field
@@ -1027,6 +1024,42 @@ int cxgbe_set_filter(struct rte_eth_dev *dev, unsigned int filter_id,
 	f->fs.iq = iq;
 	f->dev = dev;
 
+	/* Allocate MPS TCAM entry to match Destination MAC. */
+	if (f->fs.mask.macidx) {
+		int idx;
+
+		idx = cxgbe_mpstcam_alloc(pi, f->fs.val.dmac, f->fs.mask.dmac);
+		if (idx <= 0) {
+			ret = -ENOMEM;
+			goto free_tid;
+		}
+
+		f->fs.val.macidx = idx;
+	}
+
+	/* Allocate a clip table entry only if we have non-zero IPv6 address. */
+	if (chip_ver > CHELSIO_T5 && f->fs.type &&
+	    memcmp(f->fs.val.lip, bitoff, sizeof(bitoff))) {
+		f->clipt = cxgbe_clip_alloc(dev, (u32 *)&f->fs.val.lip);
+		if (!f->clipt) {
+			ret = -ENOMEM;
+			goto free_tid;
+		}
+	}
+
+	/* If the new filter requires loopback Destination MAC and/or VLAN
+	 * rewriting then we need to allocate a Layer 2 Table (L2T) entry for
+	 * the filter.
+	 */
+	if (f->fs.newvlan) {
+		f->l2t = cxgbe_l2t_alloc_switching(f->dev, f->fs.vlan,
+						   f->fs.eport, f->fs.dmac);
+		if (!f->l2t) {
+			ret = -ENOMEM;
+			goto free_tid;
+		}
+	}
+
 	/*
 	 * Attempt to set the filter.  If we don't succeed, we clear
 	 * it and return the failure.
@@ -1107,6 +1140,7 @@ void cxgbe_hash_filter_rpl(struct adapter *adap,
 		}
 
 		cxgbe_free_atid(t, ftid);
+		clear_filter(f);
 		t4_os_free(f);
 	}
 
@@ -1331,13 +1365,8 @@ void cxgbe_hash_del_filter_rpl(struct adapter *adap,
 	}
 
 	ctx = f->ctx;
-	f->ctx = NULL;
-
-	f->valid = 0;
-
-	if (f->clipt)
-		cxgbe_clip_release(f->dev, f->clipt);
 
+	clear_filter(f);
 	cxgbe_remove_tid(t, 0, tid, 0);
 	t4_os_free(f);
 
diff --git a/dpdk/drivers/net/cxgbe/cxgbe_filter.h b/dpdk/drivers/net/cxgbe/cxgbe_filter.h
index 06021c8544..e69e9d3f59 100644
--- a/dpdk/drivers/net/cxgbe/cxgbe_filter.h
+++ b/dpdk/drivers/net/cxgbe/cxgbe_filter.h
@@ -69,8 +69,10 @@ struct ch_filter_tuple {
 	uint16_t lport;		/* local port */
 	uint16_t fport;		/* foreign port */
 
+	uint8_t dmac[6];        /* Destination MAC to match */
+
 	/* reservations for future additions */
-	uint8_t rsvd[12];
+	uint8_t rsvd[6];
 };
 
 /*
diff --git a/dpdk/drivers/net/cxgbe/cxgbe_flow.c b/dpdk/drivers/net/cxgbe/cxgbe_flow.c
index 9070f4960d..1298fb12a8 100644
--- a/dpdk/drivers/net/cxgbe/cxgbe_flow.c
+++ b/dpdk/drivers/net/cxgbe/cxgbe_flow.c
@@ -190,20 +190,9 @@ ch_rte_parsetype_eth(const void *dmask, const struct rte_flow_item *item,
 					  "src mac filtering not supported");
 
 	if (!rte_is_zero_ether_addr(&mask->dst)) {
-		const u8 *addr = (const u8 *)&spec->dst.addr_bytes[0];
-		const u8 *m = (const u8 *)&mask->dst.addr_bytes[0];
-		struct rte_flow *flow = (struct rte_flow *)fs->private;
-		struct port_info *pi = (struct port_info *)
-					(flow->dev->data->dev_private);
-		int idx;
-
-		idx = cxgbe_mpstcam_alloc(pi, addr, m);
-		if (idx <= 0)
-			return rte_flow_error_set(e, idx,
-						  RTE_FLOW_ERROR_TYPE_ITEM,
-						  NULL, "unable to allocate mac"
-						  " entry in h/w");
-		CXGBE_FILL_FS(idx, 0x1ff, macidx);
+		CXGBE_FILL_FS(0, 0x1ff, macidx);
+		CXGBE_FILL_FS_MEMCPY(spec->dst.addr_bytes, mask->dst.addr_bytes,
+				     dmac);
 	}
 
 	/* Only set outer ethertype, if we didn't encounter VLAN item yet.
@@ -230,7 +219,7 @@ ch_rte_parsetype_port(const void *dmask, const struct rte_flow_item *item,
 	if (val->index > 0x7)
 		return rte_flow_error_set(e, EINVAL, RTE_FLOW_ERROR_TYPE_ITEM,
 					  item,
-					  "port index upto 0x7 is supported");
+					  "port index up to 0x7 is supported");
 
 	CXGBE_FILL_FS(val->index, mask->index, iport);
 
@@ -1085,17 +1074,6 @@ static int __cxgbe_flow_destroy(struct rte_eth_dev *dev, struct rte_flow *flow)
 		return ctx.result;
 	}
 
-	fs = &flow->fs;
-	if (fs->mask.macidx) {
-		struct port_info *pi = (struct port_info *)
-					(dev->data->dev_private);
-		int ret;
-
-		ret = cxgbe_mpstcam_remove(pi, fs->val.macidx);
-		if (!ret)
-			return ret;
-	}
-
 	return 0;
 }
 
diff --git a/dpdk/drivers/net/cxgbe/mps_tcam.c b/dpdk/drivers/net/cxgbe/mps_tcam.c
index 5302d1343d..6e5fae9928 100644
--- a/dpdk/drivers/net/cxgbe/mps_tcam.c
+++ b/dpdk/drivers/net/cxgbe/mps_tcam.c
@@ -140,6 +140,7 @@ int cxgbe_mpstcam_modify(struct port_info *pi, int idx, const u8 *addr)
 	/* idx can now be different from what user provided */
 	entry = &mpstcam->entry[idx];
 	memcpy(entry->eth_addr, addr, RTE_ETHER_ADDR_LEN);
+	memset(entry->mask, ~0, RTE_ETHER_ADDR_LEN);
 	/* NOTE: we have considered the case that idx returned by t4_change_mac
 	 * will be different from the user provided value only if user
 	 * provided value is -1
diff --git a/dpdk/drivers/net/cxgbe/sge.c b/dpdk/drivers/net/cxgbe/sge.c
index aba85a2090..7587c46aab 100644
--- a/dpdk/drivers/net/cxgbe/sge.c
+++ b/dpdk/drivers/net/cxgbe/sge.c
@@ -1421,16 +1421,49 @@ int t4_mgmt_tx(struct sge_ctrl_txq *q, struct rte_mbuf *mbuf)
 	return ctrl_xmit(q, mbuf);
 }
 
+static int cxgbe_dma_mzone_name(char *name, size_t len, uint16_t port_id,
+				uint16_t queue_id, const char *ring_name)
+{
+	return snprintf(name, len, "eth_p%d_q%d_%s",
+			port_id, queue_id, ring_name);
+}
+
+static int cxgbe_dma_zone_free(const struct rte_eth_dev *dev,
+			       const char *ring_name,
+			       uint16_t queue_id)
+{
+	char z_name[RTE_MEMZONE_NAMESIZE];
+	const struct rte_memzone *mz;
+	int rc = 0;
+
+	rc = cxgbe_dma_mzone_name(z_name, sizeof(z_name), dev->data->port_id,
+				  queue_id, ring_name);
+	if (rc >= RTE_MEMZONE_NAMESIZE) {
+		RTE_ETHDEV_LOG(ERR, "ring name too long\n");
+		return -ENAMETOOLONG;
+	}
+
+	mz = rte_memzone_lookup(z_name);
+	if (mz)
+		rc = rte_memzone_free(mz);
+	else
+		rc = -ENOENT;
+
+	return rc;
+}
+
 /**
  * alloc_ring - allocate resources for an SGE descriptor ring
- * @dev: the PCI device's core device
+ * @dev: the port associated with the queue
+ * @z_name: memzone's name
+ * @queue_id: queue index
+ * @socket_id: preferred socket id for memory allocations
  * @nelem: the number of descriptors
  * @elem_size: the size of each descriptor
+ * @stat_size: extra space in HW ring for status information
  * @sw_size: the size of the SW state associated with each ring element
  * @phys: the physical address of the allocated ring
  * @metadata: address of the array holding the SW state for the ring
- * @stat_size: extra space in HW ring for status information
- * @node: preferred node for memory allocations
  *
  * Allocates resources for an SGE descriptor ring, such as Tx queues,
  * free buffer lists, or response queues.  Each SGE ring requires
@@ -1440,39 +1473,34 @@ int t4_mgmt_tx(struct sge_ctrl_txq *q, struct rte_mbuf *mbuf)
  * of the function), the bus address of the HW ring, and the address
  * of the SW ring.
  */
-static void *alloc_ring(size_t nelem, size_t elem_size,
-			size_t sw_size, dma_addr_t *phys, void *metadata,
-			size_t stat_size, __rte_unused uint16_t queue_id,
-			int socket_id, const char *z_name,
-			const char *z_name_sw)
+static void *alloc_ring(struct rte_eth_dev *dev, const char *z_name,
+			uint16_t queue_id, int socket_id, size_t nelem,
+			size_t elem_size, size_t stat_size, size_t sw_size,
+			dma_addr_t *phys, void *metadata)
 {
 	size_t len = CXGBE_MAX_RING_DESC_SIZE * elem_size + stat_size;
+	char z_name_sw[RTE_MEMZONE_NAMESIZE];
 	const struct rte_memzone *tz;
 	void *s = NULL;
 
+	snprintf(z_name_sw, sizeof(z_name_sw), "eth_p%d_q%d_%s_sw_ring",
+		 dev->data->port_id, queue_id, z_name);
+
 	dev_debug(adapter, "%s: nelem = %zu; elem_size = %zu; sw_size = %zu; "
 		  "stat_size = %zu; queue_id = %u; socket_id = %d; z_name = %s;"
 		  " z_name_sw = %s\n", __func__, nelem, elem_size, sw_size,
 		  stat_size, queue_id, socket_id, z_name, z_name_sw);
 
-	tz = rte_memzone_lookup(z_name);
-	if (tz) {
-		dev_debug(adapter, "%s: tz exists...returning existing..\n",
-			  __func__);
-		goto alloc_sw_ring;
-	}
-
 	/*
 	 * Allocate TX/RX ring hardware descriptors. A memzone large enough to
 	 * handle the maximum ring size is allocated in order to allow for
 	 * resizing in later calls to the queue setup function.
 	 */
-	tz = rte_memzone_reserve_aligned(z_name, len, socket_id,
-			RTE_MEMZONE_IOVA_CONTIG, 4096);
+	tz = rte_eth_dma_zone_reserve(dev, z_name, queue_id, len, 4096,
+				      socket_id);
 	if (!tz)
 		return NULL;
 
-alloc_sw_ring:
 	memset(tz->addr, 0, len);
 	if (sw_size) {
 		s = rte_zmalloc_socket(z_name_sw, nelem * sw_size,
@@ -1788,21 +1816,15 @@ int t4_sge_alloc_rxq(struct adapter *adap, struct sge_rspq *iq, bool fwevtq,
 	struct fw_iq_cmd c;
 	struct sge *s = &adap->sge;
 	struct port_info *pi = eth_dev->data->dev_private;
-	char z_name[RTE_MEMZONE_NAMESIZE];
-	char z_name_sw[RTE_MEMZONE_NAMESIZE];
 	unsigned int nb_refill;
 	u8 pciechan;
 
 	/* Size needs to be multiple of 16, including status entry. */
 	iq->size = cxgbe_roundup(iq->size, 16);
 
-	snprintf(z_name, sizeof(z_name), "eth_p%d_q%d_%s",
-			eth_dev->data->port_id, queue_id,
-			fwevtq ? "fwq_ring" : "rx_ring");
-	snprintf(z_name_sw, sizeof(z_name_sw), "%s_sw_ring", z_name);
-
-	iq->desc = alloc_ring(iq->size, iq->iqe_len, 0, &iq->phys_addr, NULL, 0,
-			      queue_id, socket_id, z_name, z_name_sw);
+	iq->desc = alloc_ring(eth_dev, fwevtq ? "fwq_ring" : "rx_ring",
+			      queue_id, socket_id, iq->size, iq->iqe_len,
+			      0, 0, &iq->phys_addr, NULL);
 	if (!iq->desc)
 		return -ENOMEM;
 
@@ -1860,18 +1882,14 @@ int t4_sge_alloc_rxq(struct adapter *adap, struct sge_rspq *iq, bool fwevtq,
 			fl->size = s->fl_starve_thres - 1 + 2 * 8;
 		fl->size = cxgbe_roundup(fl->size, 8);
 
-		snprintf(z_name, sizeof(z_name), "eth_p%d_q%d_%s",
-				eth_dev->data->port_id, queue_id,
-				fwevtq ? "fwq_ring" : "fl_ring");
-		snprintf(z_name_sw, sizeof(z_name_sw), "%s_sw_ring", z_name);
-
-		fl->desc = alloc_ring(fl->size, sizeof(__be64),
+		fl->desc = alloc_ring(eth_dev, "fl_ring", queue_id, socket_id,
+				      fl->size, sizeof(__be64), s->stat_len,
 				      sizeof(struct rx_sw_desc),
-				      &fl->addr, &fl->sdesc, s->stat_len,
-				      queue_id, socket_id, z_name, z_name_sw);
-
-		if (!fl->desc)
-			goto fl_nomem;
+				      &fl->addr, &fl->sdesc);
+		if (!fl->desc) {
+			ret = -ENOMEM;
+			goto err;
+		}
 
 		flsz = fl->size / 8 + s->stat_len / sizeof(struct tx_desc);
 		c.iqns_to_fl0congen |=
@@ -1991,8 +2009,6 @@ int t4_sge_alloc_rxq(struct adapter *adap, struct sge_rspq *iq, bool fwevtq,
 refill_fl_err:
 	t4_iq_free(adap, adap->mbox, adap->pf, 0, FW_IQ_TYPE_FL_INT_CAP,
 		   iq->cntxt_id, fl->cntxt_id, 0xffff);
-fl_nomem:
-	ret = -ENOMEM;
 err:
 	iq->cntxt_id = 0;
 	iq->abs_id = 0;
@@ -2058,21 +2074,15 @@ int t4_sge_alloc_eth_txq(struct adapter *adap, struct sge_eth_txq *txq,
 	struct fw_eq_eth_cmd c;
 	struct sge *s = &adap->sge;
 	struct port_info *pi = eth_dev->data->dev_private;
-	char z_name[RTE_MEMZONE_NAMESIZE];
-	char z_name_sw[RTE_MEMZONE_NAMESIZE];
 	u8 pciechan;
 
 	/* Add status entries */
 	nentries = txq->q.size + s->stat_len / sizeof(struct tx_desc);
 
-	snprintf(z_name, sizeof(z_name), "eth_p%d_q%d_%s",
-			eth_dev->data->port_id, queue_id, "tx_ring");
-	snprintf(z_name_sw, sizeof(z_name_sw), "%s_sw_ring", z_name);
-
-	txq->q.desc = alloc_ring(txq->q.size, sizeof(struct tx_desc),
-				 sizeof(struct tx_sw_desc), &txq->q.phys_addr,
-				 &txq->q.sdesc, s->stat_len, queue_id,
-				 socket_id, z_name, z_name_sw);
+	txq->q.desc = alloc_ring(eth_dev, "tx_ring", queue_id, socket_id,
+				 txq->q.size, sizeof(struct tx_desc),
+				 s->stat_len, sizeof(struct tx_sw_desc),
+				 &txq->q.phys_addr, &txq->q.sdesc);
 	if (!txq->q.desc)
 		return -ENOMEM;
 
@@ -2137,20 +2147,13 @@ int t4_sge_alloc_ctrl_txq(struct adapter *adap, struct sge_ctrl_txq *txq,
 	struct fw_eq_ctrl_cmd c;
 	struct sge *s = &adap->sge;
 	struct port_info *pi = eth_dev->data->dev_private;
-	char z_name[RTE_MEMZONE_NAMESIZE];
-	char z_name_sw[RTE_MEMZONE_NAMESIZE];
 
 	/* Add status entries */
 	nentries = txq->q.size + s->stat_len / sizeof(struct tx_desc);
 
-	snprintf(z_name, sizeof(z_name), "eth_p%d_q%d_%s",
-			eth_dev->data->port_id, queue_id, "ctrl_tx_ring");
-	snprintf(z_name_sw, sizeof(z_name_sw), "%s_sw_ring", z_name);
-
-	txq->q.desc = alloc_ring(txq->q.size, sizeof(struct tx_desc),
-				 0, &txq->q.phys_addr,
-				 NULL, 0, queue_id,
-				 socket_id, z_name, z_name_sw);
+	txq->q.desc = alloc_ring(eth_dev, "ctrl_tx_ring", queue_id,
+				 socket_id, txq->q.size, sizeof(struct tx_desc),
+				 0, 0, &txq->q.phys_addr, NULL);
 	if (!txq->q.desc)
 		return -ENOMEM;
 
@@ -2262,6 +2265,36 @@ void t4_sge_eth_txq_release(struct adapter *adap, struct sge_eth_txq *txq)
 	}
 }
 
+void t4_sge_eth_release_queues(struct port_info *pi)
+{
+	struct adapter *adap = pi->adapter;
+	struct sge_eth_rxq *rxq;
+	struct sge_eth_txq *txq;
+	unsigned int i;
+
+	rxq = &adap->sge.ethrxq[pi->first_qset];
+	/* clean up Ethernet Tx/Rx queues */
+	for (i = 0; i < pi->n_rx_qsets; i++, rxq++) {
+		/* Free only the queues allocated */
+		if (rxq->rspq.desc) {
+			t4_sge_eth_rxq_release(adap, rxq);
+			cxgbe_dma_zone_free(rxq->rspq.eth_dev, "fl_ring", i);
+			cxgbe_dma_zone_free(rxq->rspq.eth_dev, "rx_ring", i);
+			rxq->rspq.eth_dev = NULL;
+		}
+	}
+
+	txq = &adap->sge.ethtxq[pi->first_qset];
+	for (i = 0; i < pi->n_tx_qsets; i++, txq++) {
+		/* Free only the queues allocated */
+		if (txq->q.desc) {
+			t4_sge_eth_txq_release(adap, txq);
+			cxgbe_dma_zone_free(txq->eth_dev, "tx_ring", i);
+			txq->eth_dev = NULL;
+		}
+	}
+}
+
 void t4_sge_tx_monitor_start(struct adapter *adap)
 {
 	rte_eal_alarm_set(50, tx_timer_cb, (void *)adap);
@@ -2281,21 +2314,6 @@ void t4_sge_tx_monitor_stop(struct adapter *adap)
 void t4_free_sge_resources(struct adapter *adap)
 {
 	unsigned int i;
-	struct sge_eth_rxq *rxq = &adap->sge.ethrxq[0];
-	struct sge_eth_txq *txq = &adap->sge.ethtxq[0];
-
-	/* clean up Ethernet Tx/Rx queues */
-	for (i = 0; i < adap->sge.max_ethqsets; i++, rxq++, txq++) {
-		/* Free only the queues allocated */
-		if (rxq->rspq.desc) {
-			t4_sge_eth_rxq_release(adap, rxq);
-			rxq->rspq.eth_dev = NULL;
-		}
-		if (txq->q.desc) {
-			t4_sge_eth_txq_release(adap, txq);
-			txq->eth_dev = NULL;
-		}
-	}
 
 	/* clean up control Tx queues */
 	for (i = 0; i < ARRAY_SIZE(adap->sge.ctrlq); i++) {
@@ -2305,12 +2323,17 @@ void t4_free_sge_resources(struct adapter *adap)
 			reclaim_completed_tx_imm(&cq->q);
 			t4_ctrl_eq_free(adap, adap->mbox, adap->pf, 0,
 					cq->q.cntxt_id);
+			cxgbe_dma_zone_free(adap->eth_dev, "ctrl_tx_ring", i);
+			rte_mempool_free(cq->mb_pool);
 			free_txq(&cq->q);
 		}
 	}
 
-	if (adap->sge.fw_evtq.desc)
+	/* clean up firmware event queue */
+	if (adap->sge.fw_evtq.desc) {
 		free_rspq_fl(adap, &adap->sge.fw_evtq, NULL);
+		cxgbe_dma_zone_free(adap->eth_dev, "fwq_ring", 0);
+	}
 }
 
 /**
diff --git a/dpdk/drivers/net/dpaa/dpaa_ethdev.c b/dpdk/drivers/net/dpaa/dpaa_ethdev.c
index 26805f17b7..4d5946103a 100644
--- a/dpdk/drivers/net/dpaa/dpaa_ethdev.c
+++ b/dpdk/drivers/net/dpaa/dpaa_ethdev.c
@@ -173,8 +173,8 @@ dpaa_mtu_set(struct rte_eth_dev *dev, uint16_t mtu)
 		return -EINVAL;
 	}
 
-	if (frame_size > RTE_ETHER_MAX_LEN)
-		dev->data->dev_conf.rxmode.offloads &=
+	if (frame_size > DPAA_ETH_MAX_LEN)
+		dev->data->dev_conf.rxmode.offloads |=
 						DEV_RX_OFFLOAD_JUMBO_FRAME;
 	else
 		dev->data->dev_conf.rxmode.offloads &=
@@ -881,8 +881,8 @@ dpaa_dev_rx_queue_count(struct rte_eth_dev *dev, uint16_t rx_queue_id)
 	PMD_INIT_FUNC_TRACE();
 
 	if (qman_query_fq_frm_cnt(rxq, &frm_cnt) == 0) {
-		RTE_LOG(DEBUG, PMD, "RX frame count for q(%d) is %u\n",
-			rx_queue_id, frm_cnt);
+		DPAA_PMD_DEBUG("RX frame count for q(%d) is %u",
+			       rx_queue_id, frm_cnt);
 	}
 	return frm_cnt;
 }
@@ -996,8 +996,7 @@ dpaa_dev_add_mac_addr(struct rte_eth_dev *dev,
 	ret = fman_if_add_mac_addr(dpaa_intf->fif, addr->addr_bytes, index);
 
 	if (ret)
-		RTE_LOG(ERR, PMD, "error: Adding the MAC ADDR failed:"
-			" err = %d", ret);
+		DPAA_PMD_ERR("Adding the MAC ADDR failed: err = %d", ret);
 	return 0;
 }
 
@@ -1023,7 +1022,7 @@ dpaa_dev_set_mac_addr(struct rte_eth_dev *dev,
 
 	ret = fman_if_add_mac_addr(dpaa_intf->fif, addr->addr_bytes, 0);
 	if (ret)
-		RTE_LOG(ERR, PMD, "error: Setting the MAC ADDR failed %d", ret);
+		DPAA_PMD_ERR("Setting the MAC ADDR failed %d", ret);
 
 	return ret;
 }
@@ -1121,7 +1120,7 @@ is_dpaa_supported(struct rte_eth_dev *dev)
 }
 
 int
-rte_pmd_dpaa_set_tx_loopback(uint8_t port, uint8_t on)
+rte_pmd_dpaa_set_tx_loopback(uint16_t port, uint8_t on)
 {
 	struct rte_eth_dev *dev;
 	struct dpaa_if *dpaa_intf;
@@ -1306,6 +1305,7 @@ dpaa_dev_init(struct rte_eth_dev *eth_dev)
 	struct fman_if *fman_intf;
 	struct fman_if_bpool *bp, *tmp_bp;
 	uint32_t cgrid[DPAA_MAX_NUM_PCD_QUEUES];
+	char eth_buf[RTE_ETHER_ADDR_FMT_SIZE];
 
 	PMD_INIT_FUNC_TRACE();
 
@@ -1457,15 +1457,9 @@ dpaa_dev_init(struct rte_eth_dev *eth_dev)
 
 	/* copy the primary mac address */
 	rte_ether_addr_copy(&fman_intf->mac_addr, &eth_dev->data->mac_addrs[0]);
+	rte_ether_format_addr(eth_buf, sizeof(eth_buf), &fman_intf->mac_addr);
 
-	RTE_LOG(INFO, PMD, "net: dpaa: %s: %02x:%02x:%02x:%02x:%02x:%02x\n",
-		dpaa_device->name,
-		fman_intf->mac_addr.addr_bytes[0],
-		fman_intf->mac_addr.addr_bytes[1],
-		fman_intf->mac_addr.addr_bytes[2],
-		fman_intf->mac_addr.addr_bytes[3],
-		fman_intf->mac_addr.addr_bytes[4],
-		fman_intf->mac_addr.addr_bytes[5]);
+	DPAA_PMD_INFO("net: dpaa: %s: %s", dpaa_device->name, eth_buf);
 
 	/* Disable RX mode */
 	fman_if_discard_rx_errors(fman_intf);
@@ -1578,8 +1572,7 @@ rte_dpaa_probe(struct rte_dpaa_driver *dpaa_drv __rte_unused,
 
 	if (!is_global_init && (rte_eal_process_type() == RTE_PROC_PRIMARY)) {
 		if (access("/tmp/fmc.bin", F_OK) == -1) {
-			RTE_LOG(INFO, PMD,
-				"* FMC not configured.Enabling default mode\n");
+			DPAA_PMD_INFO("* FMC not configured.Enabling default mode");
 			default_q = 1;
 		}
 
diff --git a/dpdk/drivers/net/dpaa/dpaa_ethdev.h b/dpdk/drivers/net/dpaa/dpaa_ethdev.h
index da06f1faa1..9d27aa34bf 100644
--- a/dpdk/drivers/net/dpaa/dpaa_ethdev.h
+++ b/dpdk/drivers/net/dpaa/dpaa_ethdev.h
@@ -57,6 +57,10 @@
 #define VLAN_TAG_SIZE   4 /** < Vlan Header Length */
 #endif
 
+#define DPAA_ETH_MAX_LEN (RTE_ETHER_MTU + \
+			  RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN + \
+			  VLAN_TAG_SIZE)
+
 /* PCD frame queues */
 #define DPAA_PCD_FQID_START		0x400
 #define DPAA_PCD_FQID_MULTIPLIER	0x100
diff --git a/dpdk/drivers/net/dpaa/dpaa_rxtx.c b/dpdk/drivers/net/dpaa/dpaa_rxtx.c
index 5dba1db8b3..3aeecb7d2e 100644
--- a/dpdk/drivers/net/dpaa/dpaa_rxtx.c
+++ b/dpdk/drivers/net/dpaa/dpaa_rxtx.c
@@ -305,7 +305,7 @@ dpaa_eth_sg_to_mbuf(const struct qm_fd *fd, uint32_t ifid)
 	struct qm_sg_entry *sgt, *sg_temp;
 	void *vaddr, *sg_vaddr;
 	int i = 0;
-	uint8_t fd_offset = fd->offset;
+	uint16_t fd_offset = fd->offset;
 
 	vaddr = DPAA_MEMPOOL_PTOV(bp_info, qm_fd_addr(fd));
 	if (!vaddr) {
diff --git a/dpdk/drivers/net/dpaa/rte_pmd_dpaa.h b/dpdk/drivers/net/dpaa/rte_pmd_dpaa.h
index 37eea9b032..ec45633ba2 100644
--- a/dpdk/drivers/net/dpaa/rte_pmd_dpaa.h
+++ b/dpdk/drivers/net/dpaa/rte_pmd_dpaa.h
@@ -15,8 +15,6 @@
  *
  */
 
-#include <rte_ethdev_driver.h>
-
 /**
  * Enable/Disable TX loopback
  *
@@ -31,6 +29,6 @@
  *   - (-EINVAL) if bad parameter.
  */
 int
-rte_pmd_dpaa_set_tx_loopback(uint8_t port, uint8_t on);
+rte_pmd_dpaa_set_tx_loopback(uint16_t port, uint8_t on);
 
 #endif /* _PMD_DPAA_H_ */
diff --git a/dpdk/drivers/net/dpaa2/dpaa2_ethdev.c b/dpdk/drivers/net/dpaa2/dpaa2_ethdev.c
index 2cde55e7cc..5b7529690b 100644
--- a/dpdk/drivers/net/dpaa2/dpaa2_ethdev.c
+++ b/dpdk/drivers/net/dpaa2/dpaa2_ethdev.c
@@ -147,7 +147,7 @@ dpaa2_vlan_offload_set(struct rte_eth_dev *dev, int mask)
 {
 	struct dpaa2_dev_priv *priv = dev->data->dev_private;
 	struct fsl_mc_io *dpni = dev->process_private;
-	int ret;
+	int ret = 0;
 
 	PMD_INIT_FUNC_TRACE();
 
@@ -155,7 +155,7 @@ dpaa2_vlan_offload_set(struct rte_eth_dev *dev, int mask)
 		/* VLAN Filter not avaialble */
 		if (!priv->max_vlan_filters) {
 			DPAA2_PMD_INFO("VLAN filter not available");
-			goto next_mask;
+			return -ENOTSUP;
 		}
 
 		if (dev->data->dev_conf.rxmode.offloads &
@@ -168,14 +168,8 @@ dpaa2_vlan_offload_set(struct rte_eth_dev *dev, int mask)
 		if (ret < 0)
 			DPAA2_PMD_INFO("Unable to set vlan filter = %d", ret);
 	}
-next_mask:
-	if (mask & ETH_VLAN_EXTEND_MASK) {
-		if (dev->data->dev_conf.rxmode.offloads &
-			DEV_RX_OFFLOAD_VLAN_EXTEND)
-			DPAA2_PMD_INFO("VLAN extend offload not supported");
-	}
 
-	return 0;
+	return ret;
 }
 
 static int
@@ -255,8 +249,6 @@ dpaa2_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
 
 	PMD_INIT_FUNC_TRACE();
 
-	dev_info->if_index = priv->hw_id;
-
 	dev_info->max_mac_addrs = priv->max_mac_filters;
 	dev_info->max_rx_pktlen = DPAA2_MAX_RX_PKT_LEN;
 	dev_info->min_rx_bufsize = DPAA2_MIN_RX_BUF_SIZE;
@@ -553,9 +545,6 @@ dpaa2_eth_dev_configure(struct rte_eth_dev *dev)
 	if (rx_offloads & DEV_RX_OFFLOAD_VLAN_FILTER)
 		dpaa2_vlan_offload_set(dev, ETH_VLAN_FILTER_MASK);
 
-	/* update the current status */
-	dpaa2_dev_link_update(dev, 0);
-
 	return 0;
 }
 
@@ -663,7 +652,7 @@ dpaa2_dev_rx_queue_setup(struct rte_eth_dev *dev,
 						DPNI_CP_CONGESTION_GROUP,
 						DPNI_QUEUE_RX,
 						dpaa2_q->tc_index,
-						flow_id, &taildrop);
+						dpaa2_q->cgid, &taildrop);
 		} else {
 			/*enabling per rx queue congestion control */
 			taildrop.threshold = CONG_THRESHOLD_RX_BYTES_Q;
@@ -690,7 +679,7 @@ dpaa2_dev_rx_queue_setup(struct rte_eth_dev *dev,
 			ret = dpni_set_taildrop(dpni, CMD_PRI_LOW, priv->token,
 					DPNI_CP_CONGESTION_GROUP, DPNI_QUEUE_RX,
 					dpaa2_q->tc_index,
-					flow_id, &taildrop);
+					dpaa2_q->cgid, &taildrop);
 		} else {
 			ret = dpni_set_taildrop(dpni, CMD_PRI_LOW, priv->token,
 					DPNI_CP_QUEUE, DPNI_QUEUE_RX,
@@ -1288,7 +1277,7 @@ dpaa2_dev_mtu_set(struct rte_eth_dev *dev, uint16_t mtu)
 	if (mtu < RTE_ETHER_MIN_MTU || frame_size > DPAA2_MAX_RX_PKT_LEN)
 		return -EINVAL;
 
-	if (frame_size > RTE_ETHER_MAX_LEN)
+	if (frame_size > DPAA2_ETH_MAX_LEN)
 		dev->data->dev_conf.rxmode.offloads |=
 						DEV_RX_OFFLOAD_JUMBO_FRAME;
 	else
@@ -1757,6 +1746,7 @@ dpaa2_dev_set_link_up(struct rte_eth_dev *dev)
 	/* changing tx burst function to start enqueues */
 	dev->tx_pkt_burst = dpaa2_dev_tx;
 	dev->data->dev_link.link_status = state.up;
+	dev->data->dev_link.link_speed = state.rate;
 
 	if (state.up)
 		DPAA2_PMD_INFO("Port %d Link is Up", dev->data->port_id);
diff --git a/dpdk/drivers/net/dpaa2/dpaa2_ethdev.h b/dpdk/drivers/net/dpaa2/dpaa2_ethdev.h
index 95674b26b9..a4807881fc 100644
--- a/dpdk/drivers/net/dpaa2/dpaa2_ethdev.h
+++ b/dpdk/drivers/net/dpaa2/dpaa2_ethdev.h
@@ -24,6 +24,10 @@
 #define MAX_TX_QUEUES		16
 #define MAX_DPNI		8
 
+#define DPAA2_ETH_MAX_LEN (RTE_ETHER_MTU + \
+			   RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN + \
+			   VLAN_TAG_SIZE)
+
 /*default tc to be used for ,congestion, distribution etc configuration. */
 #define DPAA2_DEF_TC		0
 
@@ -135,7 +139,6 @@ struct dpaa2_dev_priv {
 	uint16_t ss_offset;
 	uint64_t ss_iova;
 	uint64_t ss_param_iova;
-#if defined(RTE_LIBRTE_IEEE1588)
 	/*stores timestamp of last received packet on dev*/
 	uint64_t rx_timestamp;
 	/*stores timestamp of last received tx confirmation packet on dev*/
@@ -144,7 +147,6 @@ struct dpaa2_dev_priv {
 	 * it corresponds to last packet transmitted
 	 */
 	struct dpaa2_queue *next_tx_conf_queue;
-#endif
 
 	struct rte_eth_dev *eth_dev; /**< Pointer back to holding ethdev */
 
@@ -200,7 +202,6 @@ void dpaa2_dev_free_eqresp_buf(uint16_t eqresp_ci);
 void dpaa2_flow_clean(struct rte_eth_dev *dev);
 uint16_t dpaa2_dev_tx_conf(void *queue)  __attribute__((unused));
 
-#if defined(RTE_LIBRTE_IEEE1588)
 int dpaa2_timesync_enable(struct rte_eth_dev *dev);
 int dpaa2_timesync_disable(struct rte_eth_dev *dev);
 int dpaa2_timesync_read_time(struct rte_eth_dev *dev,
@@ -213,5 +214,4 @@ int dpaa2_timesync_read_rx_timestamp(struct rte_eth_dev *dev,
 						uint32_t flags __rte_unused);
 int dpaa2_timesync_read_tx_timestamp(struct rte_eth_dev *dev,
 					  struct timespec *timestamp);
-#endif
 #endif /* _DPAA2_ETHDEV_H */
diff --git a/dpdk/drivers/net/dpaa2/dpaa2_flow.c b/dpdk/drivers/net/dpaa2/dpaa2_flow.c
index 2212650320..8aa65db305 100644
--- a/dpdk/drivers/net/dpaa2/dpaa2_flow.c
+++ b/dpdk/drivers/net/dpaa2/dpaa2_flow.c
@@ -1850,13 +1850,13 @@ struct rte_flow *dpaa2_flow_create(struct rte_eth_dev *dev,
 	key_iova = (size_t)rte_malloc(NULL, 256, 64);
 	if (!key_iova) {
 		DPAA2_PMD_ERR(
-			"Memory allocation failure for rule configration\n");
+			"Memory allocation failure for rule configuration\n");
 		goto mem_failure;
 	}
 	mask_iova = (size_t)rte_malloc(NULL, 256, 64);
 	if (!mask_iova) {
 		DPAA2_PMD_ERR(
-			"Memory allocation failure for rule configration\n");
+			"Memory allocation failure for rule configuration\n");
 		goto mem_failure;
 	}
 
diff --git a/dpdk/drivers/net/dpaa2/dpaa2_mux.c b/dpdk/drivers/net/dpaa2/dpaa2_mux.c
index 1910cc4184..af90adb828 100644
--- a/dpdk/drivers/net/dpaa2/dpaa2_mux.c
+++ b/dpdk/drivers/net/dpaa2/dpaa2_mux.c
@@ -84,7 +84,7 @@ rte_pmd_dpaa2_mux_flow_create(uint32_t dpdmux_id,
 			   (2 * DIST_PARAM_IOVA_SIZE), RTE_CACHE_LINE_SIZE);
 	if (!flow) {
 		DPAA2_PMD_ERR(
-			"Memory allocation failure for rule configration\n");
+			"Memory allocation failure for rule configuration\n");
 		goto creation_error;
 	}
 	key_iova = (void *)((size_t)flow + sizeof(struct rte_flow));
diff --git a/dpdk/drivers/net/dpaa2/dpaa2_ptp.c b/dpdk/drivers/net/dpaa2/dpaa2_ptp.c
index 316912fe3e..bd9bcd58b0 100644
--- a/dpdk/drivers/net/dpaa2/dpaa2_ptp.c
+++ b/dpdk/drivers/net/dpaa2/dpaa2_ptp.c
@@ -129,6 +129,7 @@ int dpaa2_timesync_read_rx_timestamp(struct rte_eth_dev *dev,
 	return 0;
 }
 
+#if defined(RTE_LIBRTE_IEEE1588)
 static int
 dpaa2_create_dprtc_device(int vdev_fd __rte_unused,
 			   struct vfio_device_info *obj_info __rte_unused,
@@ -179,3 +180,4 @@ static struct rte_dpaa2_object rte_dpaa2_dprtc_obj = {
 };
 
 RTE_PMD_REGISTER_DPAA2_OBJECT(dprtc, rte_dpaa2_dprtc_obj);
+#endif
diff --git a/dpdk/drivers/net/dpaa2/meson.build b/dpdk/drivers/net/dpaa2/meson.build
index 571cdb7d4b..fc4707db10 100644
--- a/dpdk/drivers/net/dpaa2/meson.build
+++ b/dpdk/drivers/net/dpaa2/meson.build
@@ -13,15 +13,12 @@ sources = files('base/dpaa2_hw_dpni.c',
 		'dpaa2_flow.c',
 		'dpaa2_rxtx.c',
 		'dpaa2_sparser.c',
+		'dpaa2_ptp.c',
+		'mc/dprtc.c',
 		'mc/dpkg.c',
 		'mc/dpdmux.c',
 		'mc/dpni.c')
 
-if dpdk_conf.has('RTE_LIBRTE_IEEE1588')
-	sources += files('mc/dprtc.c')
-	sources += files('dpaa2_ptp.c')
-endif
-
 includes += include_directories('base', 'mc')
 
 # depends on fslmc bus which uses experimental API
diff --git a/dpdk/drivers/net/e1000/e1000_ethdev.h b/dpdk/drivers/net/e1000/e1000_ethdev.h
index 1e41ae9de1..6b1e599441 100644
--- a/dpdk/drivers/net/e1000/e1000_ethdev.h
+++ b/dpdk/drivers/net/e1000/e1000_ethdev.h
@@ -97,7 +97,7 @@
  */
 #define E1000_ETH_OVERHEAD (RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN + \
 				VLAN_TAG_SIZE)
-
+#define E1000_ETH_MAX_LEN (RTE_ETHER_MTU + E1000_ETH_OVERHEAD)
 /*
  * Maximum number of Ring Descriptors.
  *
diff --git a/dpdk/drivers/net/e1000/em_ethdev.c b/dpdk/drivers/net/e1000/em_ethdev.c
index 080cbe2df5..4a6e6b8d73 100644
--- a/dpdk/drivers/net/e1000/em_ethdev.c
+++ b/dpdk/drivers/net/e1000/em_ethdev.c
@@ -321,7 +321,7 @@ eth_em_dev_uninit(struct rte_eth_dev *eth_dev)
 	PMD_INIT_FUNC_TRACE();
 
 	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
-		return -EPERM;
+		return 0;
 
 	eth_em_close(eth_dev);
 
@@ -1795,8 +1795,7 @@ eth_em_mtu_set(struct rte_eth_dev *dev, uint16_t mtu)
 	if (ret != 0)
 		return ret;
 
-	frame_size = mtu + RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN +
-		VLAN_TAG_SIZE;
+	frame_size = mtu + E1000_ETH_OVERHEAD;
 
 	/* check that mtu is within the allowed range */
 	if (mtu < RTE_ETHER_MIN_MTU || frame_size > dev_info.max_rx_pktlen)
@@ -1812,7 +1811,7 @@ eth_em_mtu_set(struct rte_eth_dev *dev, uint16_t mtu)
 	rctl = E1000_READ_REG(hw, E1000_RCTL);
 
 	/* switch to jumbo mode if needed */
-	if (frame_size > RTE_ETHER_MAX_LEN) {
+	if (frame_size > E1000_ETH_MAX_LEN) {
 		dev->data->dev_conf.rxmode.offloads |=
 			DEV_RX_OFFLOAD_JUMBO_FRAME;
 		rctl |= E1000_RCTL_LPE;
diff --git a/dpdk/drivers/net/e1000/igb_ethdev.c b/dpdk/drivers/net/e1000/igb_ethdev.c
index a3e30dbe5a..a7886041f6 100644
--- a/dpdk/drivers/net/e1000/igb_ethdev.c
+++ b/dpdk/drivers/net/e1000/igb_ethdev.c
@@ -922,7 +922,7 @@ eth_igb_dev_uninit(struct rte_eth_dev *eth_dev)
 	PMD_INIT_FUNC_TRACE();
 
 	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
-		return -EPERM;
+		return 0;
 
 	eth_igb_close(eth_dev);
 
@@ -1043,7 +1043,7 @@ eth_igbvf_dev_uninit(struct rte_eth_dev *eth_dev)
 	PMD_INIT_FUNC_TRACE();
 
 	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
-		return -EPERM;
+		return 0;
 
 	igbvf_dev_close(eth_dev);
 
@@ -3087,6 +3087,7 @@ eth_igb_flow_ctrl_set(struct rte_eth_dev *dev, struct rte_eth_fc_conf *fc_conf)
 	uint32_t rx_buf_size;
 	uint32_t max_high_water;
 	uint32_t rctl;
+	uint32_t ctrl;
 
 	hw = E1000_DEV_PRIVATE_TO_HW(dev->data->dev_private);
 	if (fc_conf->autoneg != hw->mac.autoneg)
@@ -3124,6 +3125,39 @@ eth_igb_flow_ctrl_set(struct rte_eth_dev *dev, struct rte_eth_fc_conf *fc_conf)
 			rctl &= ~E1000_RCTL_PMCF;
 
 		E1000_WRITE_REG(hw, E1000_RCTL, rctl);
+
+		/*
+		 * check if we want to change flow control mode - driver doesn't have native
+		 * capability to do that, so we'll write the registers ourselves
+		 */
+		ctrl = E1000_READ_REG(hw, E1000_CTRL);
+
+		/*
+		 * set or clear E1000_CTRL_RFCE and E1000_CTRL_TFCE bits depending
+		 * on configuration
+		 */
+		switch (fc_conf->mode) {
+		case RTE_FC_NONE:
+			ctrl &= ~E1000_CTRL_RFCE & ~E1000_CTRL_TFCE;
+			break;
+		case RTE_FC_RX_PAUSE:
+			ctrl |= E1000_CTRL_RFCE;
+			ctrl &= ~E1000_CTRL_TFCE;
+			break;
+		case RTE_FC_TX_PAUSE:
+			ctrl |= E1000_CTRL_TFCE;
+			ctrl &= ~E1000_CTRL_RFCE;
+			break;
+		case RTE_FC_FULL:
+			ctrl |= E1000_CTRL_RFCE | E1000_CTRL_TFCE;
+			break;
+		default:
+			PMD_INIT_LOG(ERR, "invalid flow control mode");
+			return -EINVAL;
+		}
+
+		E1000_WRITE_REG(hw, E1000_CTRL, ctrl);
+
 		E1000_WRITE_FLUSH(hw);
 
 		return 0;
@@ -4543,7 +4577,7 @@ eth_igb_mtu_set(struct rte_eth_dev *dev, uint16_t mtu)
 	rctl = E1000_READ_REG(hw, E1000_RCTL);
 
 	/* switch to jumbo mode if needed */
-	if (frame_size > RTE_ETHER_MAX_LEN) {
+	if (frame_size > E1000_ETH_MAX_LEN) {
 		dev->data->dev_conf.rxmode.offloads |=
 			DEV_RX_OFFLOAD_JUMBO_FRAME;
 		rctl |= E1000_RCTL_LPE;
diff --git a/dpdk/drivers/net/e1000/igb_rxtx.c b/dpdk/drivers/net/e1000/igb_rxtx.c
index 684fa4ad89..5260bbe341 100644
--- a/dpdk/drivers/net/e1000/igb_rxtx.c
+++ b/dpdk/drivers/net/e1000/igb_rxtx.c
@@ -1295,113 +1295,107 @@ igb_tx_done_cleanup(struct igb_tx_queue *txq, uint32_t free_cnt)
 	uint16_t tx_id;    /* Current segment being processed. */
 	uint16_t tx_last;  /* Last segment in the current packet. */
 	uint16_t tx_next;  /* First segment of the next packet. */
-	int count;
+	int count = 0;
 
-	if (txq != NULL) {
-		count = 0;
-		sw_ring = txq->sw_ring;
-		txr = txq->tx_ring;
+	if (!txq)
+		return -ENODEV;
 
-		/*
-		 * tx_tail is the last sent packet on the sw_ring. Goto the end
-		 * of that packet (the last segment in the packet chain) and
-		 * then the next segment will be the start of the oldest segment
-		 * in the sw_ring. This is the first packet that will be
-		 * attempted to be freed.
-		 */
+	sw_ring = txq->sw_ring;
+	txr = txq->tx_ring;
+
+	/* tx_tail is the last sent packet on the sw_ring. Goto the end
+	 * of that packet (the last segment in the packet chain) and
+	 * then the next segment will be the start of the oldest segment
+	 * in the sw_ring. This is the first packet that will be
+	 * attempted to be freed.
+	 */
 
-		/* Get last segment in most recently added packet. */
-		tx_first = sw_ring[txq->tx_tail].last_id;
+	/* Get last segment in most recently added packet. */
+	tx_first = sw_ring[txq->tx_tail].last_id;
 
-		/* Get the next segment, which is the oldest segment in ring. */
-		tx_first = sw_ring[tx_first].next_id;
+	/* Get the next segment, which is the oldest segment in ring. */
+	tx_first = sw_ring[tx_first].next_id;
 
-		/* Set the current index to the first. */
-		tx_id = tx_first;
+	/* Set the current index to the first. */
+	tx_id = tx_first;
 
-		/*
-		 * Loop through each packet. For each packet, verify that an
-		 * mbuf exists and that the last segment is free. If so, free
-		 * it and move on.
-		 */
-		while (1) {
-			tx_last = sw_ring[tx_id].last_id;
-
-			if (sw_ring[tx_last].mbuf) {
-				if (txr[tx_last].wb.status &
-						E1000_TXD_STAT_DD) {
-					/*
-					 * Increment the number of packets
-					 * freed.
-					 */
-					count++;
-
-					/* Get the start of the next packet. */
-					tx_next = sw_ring[tx_last].next_id;
-
-					/*
-					 * Loop through all segments in a
-					 * packet.
-					 */
-					do {
-						rte_pktmbuf_free_seg(sw_ring[tx_id].mbuf);
+	/* Loop through each packet. For each packet, verify that an
+	 * mbuf exists and that the last segment is free. If so, free
+	 * it and move on.
+	 */
+	while (1) {
+		tx_last = sw_ring[tx_id].last_id;
+
+		if (sw_ring[tx_last].mbuf) {
+			if (txr[tx_last].wb.status &
+			    E1000_TXD_STAT_DD) {
+				/* Increment the number of packets
+				 * freed.
+				 */
+				count++;
+
+				/* Get the start of the next packet. */
+				tx_next = sw_ring[tx_last].next_id;
+
+				/* Loop through all segments in a
+				 * packet.
+				 */
+				do {
+					if (sw_ring[tx_id].mbuf) {
+						rte_pktmbuf_free_seg(
+							sw_ring[tx_id].mbuf);
 						sw_ring[tx_id].mbuf = NULL;
 						sw_ring[tx_id].last_id = tx_id;
+					}
 
-						/* Move to next segemnt. */
-						tx_id = sw_ring[tx_id].next_id;
+					/* Move to next segemnt. */
+					tx_id = sw_ring[tx_id].next_id;
 
-					} while (tx_id != tx_next);
+				} while (tx_id != tx_next);
 
-					if (unlikely(count == (int)free_cnt))
-						break;
-				} else
-					/*
-					 * mbuf still in use, nothing left to
-					 * free.
-					 */
+				if (unlikely(count == (int)free_cnt))
 					break;
 			} else {
-				/*
-				 * There are multiple reasons to be here:
-				 * 1) All the packets on the ring have been
-				 *    freed - tx_id is equal to tx_first
-				 *    and some packets have been freed.
-				 *    - Done, exit
-				 * 2) Interfaces has not sent a rings worth of
-				 *    packets yet, so the segment after tail is
-				 *    still empty. Or a previous call to this
-				 *    function freed some of the segments but
-				 *    not all so there is a hole in the list.
-				 *    Hopefully this is a rare case.
-				 *    - Walk the list and find the next mbuf. If
-				 *      there isn't one, then done.
+				/* mbuf still in use, nothing left to
+				 * free.
 				 */
-				if (likely((tx_id == tx_first) && (count != 0)))
-					break;
+				break;
+			}
+		} else {
+			/* There are multiple reasons to be here:
+			 * 1) All the packets on the ring have been
+			 *    freed - tx_id is equal to tx_first
+			 *    and some packets have been freed.
+			 *    - Done, exit
+			 * 2) Interfaces has not sent a rings worth of
+			 *    packets yet, so the segment after tail is
+			 *    still empty. Or a previous call to this
+			 *    function freed some of the segments but
+			 *    not all so there is a hole in the list.
+			 *    Hopefully this is a rare case.
+			 *    - Walk the list and find the next mbuf. If
+			 *      there isn't one, then done.
+			 */
+			if (likely(tx_id == tx_first && count != 0))
+				break;
 
-				/*
-				 * Walk the list and find the next mbuf, if any.
-				 */
-				do {
-					/* Move to next segemnt. */
-					tx_id = sw_ring[tx_id].next_id;
+			/* Walk the list and find the next mbuf, if any. */
+			do {
+				/* Move to next segemnt. */
+				tx_id = sw_ring[tx_id].next_id;
 
-					if (sw_ring[tx_id].mbuf)
-						break;
+				if (sw_ring[tx_id].mbuf)
+					break;
 
-				} while (tx_id != tx_first);
+			} while (tx_id != tx_first);
 
-				/*
-				 * Determine why previous loop bailed. If there
-				 * is not an mbuf, done.
-				 */
-				if (sw_ring[tx_id].mbuf == NULL)
-					break;
-			}
+			/* Determine why previous loop bailed. If there
+			 * is not an mbuf, done.
+			 */
+			if (!sw_ring[tx_id].mbuf)
+				break;
 		}
-	} else
-		count = -ENODEV;
+	}
 
 	return count;
 }
@@ -1637,8 +1631,10 @@ uint64_t
 igb_get_rx_port_offloads_capa(struct rte_eth_dev *dev)
 {
 	uint64_t rx_offload_capa;
+	struct e1000_hw *hw;
+
+	hw = E1000_DEV_PRIVATE_TO_HW(dev->data->dev_private);
 
-	RTE_SET_USED(dev);
 	rx_offload_capa = DEV_RX_OFFLOAD_VLAN_STRIP  |
 			  DEV_RX_OFFLOAD_VLAN_FILTER |
 			  DEV_RX_OFFLOAD_IPV4_CKSUM  |
@@ -1649,6 +1645,11 @@ igb_get_rx_port_offloads_capa(struct rte_eth_dev *dev)
 			  DEV_RX_OFFLOAD_SCATTER     |
 			  DEV_RX_OFFLOAD_RSS_HASH;
 
+	if (hw->mac.type == e1000_i350 ||
+	    hw->mac.type == e1000_i210 ||
+	    hw->mac.type == e1000_i211)
+		rx_offload_capa |= DEV_RX_OFFLOAD_VLAN_EXTEND;
+
 	return rx_offload_capa;
 }
 
diff --git a/dpdk/drivers/net/ena/base/ena_com.c b/dpdk/drivers/net/ena/base/ena_com.c
index 8b51660a45..f8e8f448e3 100644
--- a/dpdk/drivers/net/ena/base/ena_com.c
+++ b/dpdk/drivers/net/ena/base/ena_com.c
@@ -401,19 +401,21 @@ static int ena_com_init_io_cq(struct ena_com_dev *ena_dev,
 	size = io_cq->cdesc_entry_size_in_bytes * io_cq->q_depth;
 	io_cq->bus = ena_dev->bus;
 
-	ENA_MEM_ALLOC_COHERENT_NODE(ena_dev->dmadev,
-			size,
-			io_cq->cdesc_addr.virt_addr,
-			io_cq->cdesc_addr.phys_addr,
-			io_cq->cdesc_addr.mem_handle,
-			ctx->numa_node,
-			prev_node);
+	ENA_MEM_ALLOC_COHERENT_NODE_ALIGNED(ena_dev->dmadev,
+					    size,
+					    io_cq->cdesc_addr.virt_addr,
+					    io_cq->cdesc_addr.phys_addr,
+					    io_cq->cdesc_addr.mem_handle,
+					    ctx->numa_node,
+					    prev_node,
+					    ENA_CDESC_RING_SIZE_ALIGNMENT);
 	if (!io_cq->cdesc_addr.virt_addr) {
-		ENA_MEM_ALLOC_COHERENT(ena_dev->dmadev,
-				       size,
-				       io_cq->cdesc_addr.virt_addr,
-				       io_cq->cdesc_addr.phys_addr,
-				       io_cq->cdesc_addr.mem_handle);
+		ENA_MEM_ALLOC_COHERENT_ALIGNED(ena_dev->dmadev,
+					       size,
+					       io_cq->cdesc_addr.virt_addr,
+					       io_cq->cdesc_addr.phys_addr,
+					       io_cq->cdesc_addr.mem_handle,
+					       ENA_CDESC_RING_SIZE_ALIGNMENT);
 	}
 
 	if (!io_cq->cdesc_addr.virt_addr) {
@@ -525,11 +527,11 @@ static int ena_com_wait_and_process_admin_cq_polling(struct ena_comp_ctx *comp_c
 	timeout = ENA_GET_SYSTEM_TIMEOUT(admin_queue->completion_timeout);
 
 	while (1) {
-                ENA_SPINLOCK_LOCK(admin_queue->q_lock, flags);
-                ena_com_handle_admin_completion(admin_queue);
-                ENA_SPINLOCK_UNLOCK(admin_queue->q_lock, flags);
+		ENA_SPINLOCK_LOCK(admin_queue->q_lock, flags);
+		ena_com_handle_admin_completion(admin_queue);
+		ENA_SPINLOCK_UNLOCK(admin_queue->q_lock, flags);
 
-                if (comp_ctx->status != ENA_CMD_SUBMITTED)
+		if (comp_ctx->status != ENA_CMD_SUBMITTED)
 			break;
 
 		if (ENA_TIME_EXPIRE(timeout)) {
@@ -1634,9 +1636,11 @@ void ena_com_admin_destroy(struct ena_com_dev *ena_dev)
 	struct ena_com_aenq *aenq = &ena_dev->aenq;
 	u16 size;
 
-	ENA_WAIT_EVENT_DESTROY(admin_queue->comp_ctx->wait_event);
-	if (admin_queue->comp_ctx)
+	if (admin_queue->comp_ctx) {
+		ENA_WAIT_EVENT_DESTROY(admin_queue->comp_ctx->wait_event);
 		ENA_MEM_FREE(ena_dev->dmadev, admin_queue->comp_ctx);
+	}
+
 	admin_queue->comp_ctx = NULL;
 	size = ADMIN_SQ_SIZE(admin_queue->q_depth);
 	if (sq->entries)
@@ -2313,7 +2317,7 @@ int ena_com_set_hash_function(struct ena_com_dev *ena_dev)
 	if (unlikely(ret))
 		return ret;
 
-	if (get_resp.u.flow_hash_func.supported_func & (1 << rss->hash_func)) {
+	if (get_resp.u.flow_hash_func.supported_func & BIT(rss->hash_func)) {
 		ena_trc_err("Func hash %d isn't supported by device, abort\n",
 			    rss->hash_func);
 		return ENA_COM_UNSUPPORTED;
@@ -2356,12 +2360,14 @@ int ena_com_fill_hash_function(struct ena_com_dev *ena_dev,
 			       enum ena_admin_hash_functions func,
 			       const u8 *key, u16 key_len, u32 init_val)
 {
-	struct ena_rss *rss = &ena_dev->rss;
+	struct ena_admin_feature_rss_flow_hash_control *hash_key;
 	struct ena_admin_get_feat_resp get_resp;
-	struct ena_admin_feature_rss_flow_hash_control *hash_key =
-		rss->hash_key;
+	enum ena_admin_hash_functions old_func;
+	struct ena_rss *rss = &ena_dev->rss;
 	int rc;
 
+	hash_key = rss->hash_key;
+
 	/* Make sure size is a mult of DWs */
 	if (unlikely(key_len & 0x3))
 		return ENA_COM_INVAL;
@@ -2373,7 +2379,7 @@ int ena_com_fill_hash_function(struct ena_com_dev *ena_dev,
 	if (unlikely(rc))
 		return rc;
 
-	if (!((1 << func) & get_resp.u.flow_hash_func.supported_func)) {
+	if (!(BIT(func) & get_resp.u.flow_hash_func.supported_func)) {
 		ena_trc_err("Flow hash function %d isn't supported\n", func);
 		return ENA_COM_UNSUPPORTED;
 	}
@@ -2398,11 +2404,13 @@ int ena_com_fill_hash_function(struct ena_com_dev *ena_dev,
 		return ENA_COM_INVAL;
 	}
 
+	old_func = rss->hash_func;
+	rss->hash_func = func;
 	rc = ena_com_set_hash_function(ena_dev);
 
 	/* Restore the old function */
 	if (unlikely(rc))
-		ena_com_get_hash_function(ena_dev, NULL, NULL);
+		rss->hash_func = old_func;
 
 	return rc;
 }
@@ -2424,7 +2432,11 @@ int ena_com_get_hash_function(struct ena_com_dev *ena_dev,
 	if (unlikely(rc))
 		return rc;
 
-	rss->hash_func = get_resp.u.flow_hash_func.selected_func;
+	/* ENA_FFS returns 1 in case the lsb is set */
+	rss->hash_func = ENA_FFS(get_resp.u.flow_hash_func.selected_func);
+	if (rss->hash_func)
+		rss->hash_func--;
+
 	if (func)
 		*func = rss->hash_func;
 
diff --git a/dpdk/drivers/net/ena/base/ena_com.h b/dpdk/drivers/net/ena/base/ena_com.h
index ef42bd4f56..fed2dec3e4 100644
--- a/dpdk/drivers/net/ena/base/ena_com.h
+++ b/dpdk/drivers/net/ena/base/ena_com.h
@@ -9,9 +9,9 @@
 #include "ena_plat.h"
 #include "ena_includes.h"
 
-#define ENA_MAX_NUM_IO_QUEUES		128U
+#define ENA_MAX_NUM_IO_QUEUES 128U
 /* We need to queues for each IO (on for Tx and one for Rx) */
-#define ENA_TOTAL_NUM_QUEUES		(2 * (ENA_MAX_NUM_IO_QUEUES))
+#define ENA_TOTAL_NUM_QUEUES (2 * (ENA_MAX_NUM_IO_QUEUES))
 
 #define ENA_MAX_HANDLERS 256
 
@@ -24,6 +24,8 @@
 #define ADMIN_CQ_SIZE(depth)	((depth) * sizeof(struct ena_admin_acq_entry))
 #define ADMIN_AENQ_SIZE(depth)	((depth) * sizeof(struct ena_admin_aenq_entry))
 
+#define ENA_CDESC_RING_SIZE_ALIGNMENT	(1 << 12) /* 4K */
+
 /*****************************************************************************/
 /*****************************************************************************/
 /* ENA adaptive interrupt moderation settings */
@@ -55,9 +57,9 @@
 #define ENA_INTR_MODER_LEVEL_STRIDE			1
 #define ENA_INTR_BYTE_COUNT_NOT_SUPPORTED		0xFFFFFF
 
-#define ENA_HW_HINTS_NO_TIMEOUT				0xFFFF
+#define ENA_HW_HINTS_NO_TIMEOUT 0xFFFF
 
-#define ENA_FEATURE_MAX_QUEUE_EXT_VER	1
+#define ENA_FEATURE_MAX_QUEUE_EXT_VER 1
 
 enum ena_intr_moder_level {
 	ENA_INTR_MODER_LOWEST = 0,
@@ -404,7 +406,7 @@ extern "C" {
  */
 int ena_com_mmio_reg_read_request_init(struct ena_com_dev *ena_dev);
 
-/* ena_com_set_mmio_read_mode - Enable/disable the mmio reg read mechanism
+/* ena_com_set_mmio_read_mode - Enable/disable the indirect mmio reg read mechanism
  * @ena_dev: ENA communication layer struct
  * @readless_supported: readless mode (enable/disable)
  */
@@ -527,7 +529,7 @@ bool ena_com_get_ena_admin_polling_mode(struct ena_com_dev *ena_dev);
 /* ena_com_admin_q_comp_intr_handler - admin queue interrupt handler
  * @ena_dev: ENA communication layer struct
  *
- * This method go over the admin completion queue and wake up all the pending
+ * This method goes over the admin completion queue and wakes up all the pending
  * threads that wait on the commands wait event.
  *
  * @note: Should be called after MSI-X interrupt.
@@ -537,7 +539,7 @@ void ena_com_admin_q_comp_intr_handler(struct ena_com_dev *ena_dev);
 /* ena_com_aenq_intr_handler - AENQ interrupt handler
  * @ena_dev: ENA communication layer struct
  *
- * This method go over the async event notification queue and call the proper
+ * This method goes over the async event notification queue and calls the proper
  * aenq handler.
  */
 void ena_com_aenq_intr_handler(struct ena_com_dev *dev, void *data);
@@ -554,14 +556,14 @@ void ena_com_abort_admin_commands(struct ena_com_dev *ena_dev);
 /* ena_com_wait_for_abort_completion - Wait for admin commands abort.
  * @ena_dev: ENA communication layer struct
  *
- * This method wait until all the outstanding admin commands will be completed.
+ * This method waits until all the outstanding admin commands are completed.
  */
 void ena_com_wait_for_abort_completion(struct ena_com_dev *ena_dev);
 
 /* ena_com_validate_version - Validate the device parameters
  * @ena_dev: ENA communication layer struct
  *
- * This method validate the device parameters are the same as the saved
+ * This method verifies the device parameters are the same as the saved
  * parameters in ena_dev.
  * This method is useful after device reset, to validate the device mac address
  * and the device offloads are the same as before the reset.
@@ -763,7 +765,7 @@ int ena_com_set_hash_ctrl(struct ena_com_dev *ena_dev);
  *
  * Retrieve the hash control from the device.
  *
- * @note, If the caller called ena_com_fill_hash_ctrl but didn't flash
+ * @note: If the caller called ena_com_fill_hash_ctrl but didn't flash
  * it to the device, the new configuration will be lost.
  *
  * @return: 0 on Success and negative value otherwise.
@@ -815,7 +817,7 @@ int ena_com_indirect_table_set(struct ena_com_dev *ena_dev);
  *
  * Retrieve the RSS indirection table from the device.
  *
- * @note: If the caller called ena_com_indirect_table_fill_entry but didn't flash
+ * @note: If the caller called ena_com_indirect_table_fill_entry but didn't flush
  * it to the device, the new configuration will be lost.
  *
  * @return: 0 on Success and negative value otherwise.
@@ -841,14 +843,14 @@ int ena_com_allocate_debug_area(struct ena_com_dev *ena_dev,
 /* ena_com_delete_debug_area - Free the debug area resources.
  * @ena_dev: ENA communication layer struct
  *
- * Free the allocate debug area.
+ * Free the allocated debug area.
  */
 void ena_com_delete_debug_area(struct ena_com_dev *ena_dev);
 
 /* ena_com_delete_host_info - Free the host info resources.
  * @ena_dev: ENA communication layer struct
  *
- * Free the allocate host info.
+ * Free the allocated host info.
  */
 void ena_com_delete_host_info(struct ena_com_dev *ena_dev);
 
@@ -889,9 +891,9 @@ int ena_com_destroy_io_cq(struct ena_com_dev *ena_dev,
  * @cmd_completion: command completion return value.
  * @cmd_comp_size: command completion size.
 
- * Submit an admin command and then wait until the device will return a
+ * Submit an admin command and then wait until the device returns a
  * completion.
- * The completion will be copyed into cmd_comp.
+ * The completion will be copied into cmd_comp.
  *
  * @return - 0 on success, negative value on failure.
  */
@@ -1083,7 +1085,7 @@ static inline void ena_com_calculate_interrupt_delay(struct ena_com_dev *ena_dev
  * @intr_reg: interrupt register to update.
  * @rx_delay_interval: Rx interval in usecs
  * @tx_delay_interval: Tx interval in usecs
- * @unmask: unask enable/disable
+ * @unmask: unmask enable/disable
  *
  * Prepare interrupt update register with the supplied parameters.
  */
diff --git a/dpdk/drivers/net/ena/base/ena_plat_dpdk.h b/dpdk/drivers/net/ena/base/ena_plat_dpdk.h
index 9e1492cac4..9773be09e7 100644
--- a/dpdk/drivers/net/ena/base/ena_plat_dpdk.h
+++ b/dpdk/drivers/net/ena/base/ena_plat_dpdk.h
@@ -1,5 +1,5 @@
 /* SPDX-License-Identifier: BSD-3-Clause
- * Copyright (c) 2015-2019 Amazon.com, Inc. or its affiliates.
+ * Copyright (c) 2015-2020 Amazon.com, Inc. or its affiliates.
  * All rights reserved.
  */
 
@@ -55,8 +55,8 @@ typedef uint64_t dma_addr_t;
 
 #define ENA_ABORT() abort()
 
-#define ENA_MSLEEP(x) rte_delay_ms(x)
-#define ENA_UDELAY(x) rte_delay_us(x)
+#define ENA_MSLEEP(x) rte_delay_us_sleep(x * 1000)
+#define ENA_UDELAY(x) rte_delay_us_block(x)
 
 #define ENA_TOUCH(x) ((void)(x))
 #define memcpy_toio memcpy
@@ -71,26 +71,15 @@ typedef uint64_t dma_addr_t;
 	(rte_get_timer_cycles() * US_PER_S / rte_get_timer_hz())
 
 extern int ena_logtype_com;
-#if RTE_LOG_DP_LEVEL >= RTE_LOG_DEBUG
-#define ENA_ASSERT(cond, format, arg...)				\
-	do {								\
-		if (unlikely(!(cond))) {				\
-			rte_log(RTE_LOGTYPE_ERR, ena_logtype_com,	\
Loading
Loading full blame...