aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2016-03-29 22:37:02 +0200
committerGerrit Code Review <gerrit@fd.io>2016-03-29 21:25:12 +0000
commit0df78dda5ae1e1e082c2e0ea282ba5494c3d4b31 (patch)
tree5a0cc761507b69bedf055cdb5fe550eeaa3ac75f
parent23650e6cada50246ba211cec168ddd6738a26f67 (diff)
Add DPDK 16.04-rc2 support
Can be used by specifying DPDK_VERSION=16.04-rc2 in the make command line Change-Id: I657b44d7ca22f1ef57756e7703088020fab12bc6 Signed-off-by: Damjan Marion <damarion@cisco.com>
-rw-r--r--Makefile3
-rw-r--r--dpdk/Makefile5
-rw-r--r--vnet/vnet/devices/virtio/vhost-user.h4
3 files changed, 8 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index a9b4d9ab961..31222cafc76 100644
--- a/Makefile
+++ b/Makefile
@@ -31,7 +31,7 @@ RPM_DEPENDS = redhat-lsb glibc-static java-1.8.0-openjdk-devel
RPM_DEPENDS += openssl-devel https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm apr-devel
EPEL_DEPENDS = libconfuse-devel ganglia-devel
-ifneq ("$(wildcard $(STARTUP_DIR)/startup.conf),"")
+ifneq ($(wildcard $(STARTUP_DIR)/startup.conf),)
STARTUP_CONF ?= $(STARTUP_DIR)/startup.conf
endif
@@ -76,6 +76,7 @@ help:
@echo " STARTUP_DIR = $(STARTUP_DIR)"
@echo " GDB = $(GDB)"
@echo " PLATFORM = $(PLATFORM)"
+ @echo " DPDK_VERSION = $(DPDK_VERSION)"
$(BR)/.bootstrap.ok:
ifeq ("$(shell lsb_release -si)", "Ubuntu")
diff --git a/dpdk/Makefile b/dpdk/Makefile
index e6e2b5f8700..316efc01640 100644
--- a/dpdk/Makefile
+++ b/dpdk/Makefile
@@ -29,6 +29,7 @@ DPDK_TARBALL := dpdk-$(DPDK_VERSION).tar.gz
DPDK_TAR_URL := $(DPDK_BASE_URL)/$(DPDK_TARBALL)
DPDK_2.1.0_TARBALL_MD5_CKSUM := 205a0d12bfd6eb717d57506272f43519
DPDK_2.2.0_TARBALL_MD5_CKSUM := 22e2fd68cd5504f43fe9a5a6fd6dd938
+DPDK_16.04-rc2_TARBALL_MD5_CKSUM := a642985d2694d8cf8fdfdf0723be3406
DPDK_SOURCE := $(B)/dpdk-$(DPDK_VERSION)
DPDK_TARGET := x86_64-native-linuxapp-gcc
JOBS := $(shell grep processor /proc/cpuinfo | wc -l)
@@ -82,7 +83,7 @@ all: build
$(B)/custom-config: $(B)/.patch.ok Makefile
@echo --- generating custom config from $(DPDK_SOURCE)/config/common_linuxapp ---
- @cp $(DPDK_SOURCE)/config/common_linuxapp $@
+ @cpp -undef -ffreestanding -x assembler-with-cpp $(DPDK_SOURCE)/config/common_linuxapp $@
$(call set,RTE_MACHINE,$(DPDK_MACHINE))
$(call set,RTE_ARCH,"x86_64")
$(call set,RTE_ARCH_X86_64,y)
@@ -145,11 +146,13 @@ $(B)/.extract.ok: $(B)/.download.ok
extract: $(B)/.extract.ok
$(B)/.patch.ok: $(B)/.extract.ok
+ifneq ($(wildcard $(CURDIR)/dpdk-$(DPDK_VERSION)_patches/*.patch),)
@echo --- patching ---
for f in $(CURDIR)/dpdk-$(DPDK_VERSION)_patches/*.patch ; do \
echo Applying patch: $$(basename $$f) ; \
patch -p1 -d $(DPDK_SOURCE) < $$f ; \
done
+endif
@touch $@
.PHONY: patch
diff --git a/vnet/vnet/devices/virtio/vhost-user.h b/vnet/vnet/devices/virtio/vhost-user.h
index be011165b1f..d6d557311e3 100644
--- a/vnet/vnet/devices/virtio/vhost-user.h
+++ b/vnet/vnet/devices/virtio/vhost-user.h
@@ -78,11 +78,11 @@ typedef struct vhost_user_memory {
vhost_user_memory_region_t regions[VHOST_MEMORY_MAX_NREGIONS];
} vhost_user_memory_t;
-typedef struct vhost_vring_state {
+typedef struct {
unsigned int index, num;
} vhost_vring_state_t;
-typedef struct vhost_vring_addr {
+typedef struct {
unsigned int index, flags;
u64 desc_user_addr, used_user_addr, avail_user_addr, log_guest_addr;
} vhost_vring_addr_t;