X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=dpdk%2FMakefile;h=4d8dea283b3d50039262979adc06783b4d2bef40;hb=8a19f12a0cfe6d611f6e266931af691fb69a74ad;hp=c6968d7cea74bc8ba106f99d1d722a9eb9dde910;hpb=9ec92d38bb5c2ec05f7698f58195c81f14120fb4;p=vpp.git diff --git a/dpdk/Makefile b/dpdk/Makefile index c6968d7cea7..4d8dea283b3 100644 --- a/dpdk/Makefile +++ b/dpdk/Makefile @@ -19,30 +19,47 @@ DPDK_INSTALL_DIR ?= $(CURDIR)/_install DPDK_PKTMBUF_HEADROOM ?= 128 DPDK_DOWNLOAD_DIR ?= $(HOME)/Downloads DPDK_DEBUG ?= n -DPDK_CRYPTO_SW_PMD ?= n DPDK_MLX4_PMD ?= n DPDK_MLX5_PMD ?= n B := $(DPDK_BUILD_DIR) I := $(DPDK_INSTALL_DIR) -DPDK_VERSION ?= 17.05 -PKG_SUFFIX ?= vpp3 +DPDK_VERSION ?= 17.08 +PKG_SUFFIX ?= vpp1 DPDK_BASE_URL ?= http://fast.dpdk.org/rel DPDK_TARBALL := dpdk-$(DPDK_VERSION).tar.xz DPDK_TAR_URL := $(DPDK_BASE_URL)/$(DPDK_TARBALL) -DPDK_17.02_TARBALL_MD5_CKSUM := 6b9f7387c35641f4e8dbba3e528f2376 DPDK_17.05_TARBALL_MD5_CKSUM := 0a68c31cd6a6cabeed0a4331073e4c05 +DPDK_17.08_TARBALL_MD5_CKSUM := 0641f59ea8ea98afefa7cfa2699f6241 DPDK_SOURCE := $(B)/dpdk-$(DPDK_VERSION) +MACHINE=$(shell uname -m) -ifeq ($(DPDK_CRYPTO_SW_PMD),y) -AESNIMB_LIB_TARBALL := v0.44-gcm.2.tar.gz -AESNIMB_LIB_TARBALL_URL := http://github.com/01org/intel-ipsec-mb/archive/$(AESNIMB_LIB_TARBALL) -AESNIMB_LIB_SOURCE := $(B)/intel-ipsec-mb-0.44-gcm.2 -ISA_L_CRYPTO_LIB_TARBALL := isa_l_crypto.tar.gz -ISA_L_CRYPTO_LIB_TARBALL_URL := http://github.com/01org/isa-l_crypto/archive/master.tar.gz -ISA_L_CRYPTO_LIB_SOURCE := $(B)/isa-l_crypto-master +AESNI ?= n +ISA_L_CRYPTO_LIB := n + +IPSEC_MB_VER ?= 0.46 +ISA_L_CRYPTO_VER := 2.18.0 + +ifeq ($(MACHINE),$(filter $(MACHINE),x86_64)) +AESNI = y +# DPDK pre 17.08 depends on ISA-L Crypto library for GCM PMD + ifneq ($(firstword $(sort $(DPDK_VERSION), 17.08)), 17.08) + ISA_L_CRYPTO_LIB = y + IPSEC_MB_VER = 0.45 + $(info Building ISA-L Crypto $(ISA_L_CRYPTO_VER) library) + endif +$(info Building IPSec-MB $(IPSEC_MB_VER) library) endif +AESNIMB_LIB_TARBALL := v$(IPSEC_MB_VER).tar.gz +AESNIMB_LIB_TARBALL_URL := http://github.com/01org/intel-ipsec-mb/archive/$(AESNIMB_LIB_TARBALL) +AESNIMB_LIB_SOURCE := $(B)/intel-ipsec-mb-$(IPSEC_MB_VER) + +ISA_L_CRYPTO_LIB_TARBALL := v$(ISA_L_CRYPTO_VER).tar.gz +ISA_L_CRYPTO_LIB_TARBALL_URL := http://github.com/01org/isa-l_crypto/archive/$(ISA_L_CRYPTO_LIB_TARBALL) +ISA_L_CRYPTO_LIB_SOURCE := $(B)/isa-l_crypto-$(ISA_L_CRYPTO_VER) +ISA_L_CRYPTO_INSTALL_DIR := $(ISA_L_CRYPTO_LIB_SOURCE)/install + ifneq (,$(findstring clang,$(CC))) DPDK_CC=clang else ifneq (,$(findstring icc,$(CC))) @@ -51,8 +68,6 @@ else DPDK_CC=gcc endif -MACHINE=$(shell uname -m) - ############################################################################## # Intel x86 ############################################################################## @@ -60,15 +75,23 @@ ifeq ($(MACHINE),$(filter $(MACHINE),x86_64 i686)) DPDK_TARGET ?= $(MACHINE)-native-linuxapp-$(DPDK_CC) DPDK_MACHINE ?= nhm DPDK_TUNE ?= core-avx2 - +else ifeq ($(MACHINE),aarch64) +export CROSS="" +ifneq (,$(findstring thunder,$(shell [[ -f /sys/bus/pci/devices/0000:00:01.0/uevent ]] && cat /sys/bus/pci/devices/0000:00:01.0/uevent | grep cavium))) ############################################################################## # Cavium ThunderX ############################################################################## -else ifneq (,$(findstring thunder,$(shell cat /sys/bus/pci/devices/0000:00:01.0/uevent | grep cavium))) -export CROSS="" DPDK_TARGET ?= arm64-thunderx-linuxapp-$(DPDK_CC) DPDK_MACHINE ?= thunderx DPDK_TUNE ?= generic +else +############################################################################## +# Generic ARM64 +############################################################################## +DPDK_TARGET ?= arm64-armv8a-linuxapp-$(DPDK_CC) +DPDK_MACHINE ?= armv8a +DPDK_TUNE ?= generic +endif ############################################################################## # Unknown platofrm @@ -77,7 +100,13 @@ else $(error unknown platform) endif -JOBS := $(shell grep processor /proc/cpuinfo | wc -l) +# /proc/cpuinfo does not exist on platforms without a /proc and on some +# platforms, notably inside containers, it has no content. In those cases +# we assume there's 1 processor; we use 2*ncpu for the -j option. +# NB: GNU Make 4.2 will let us use '$(file