summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2016-04-11 12:51:00 +0200
committerGerrit Code Review <gerrit@fd.io>2016-04-11 13:04:16 +0000
commit5ba5f83b797c2629b89cabbefea1c8bb4dccbbcd (patch)
treefaeccbb697b0b88adef6e360db9565ca9ba3b636
parentc47e9796746f96f1f8f08fb95c98f5bf632705f4 (diff)
Bump DPDK 16.04 to RC4
Change-Id: Ia9affeee54e860b6039d7ee0f411bd022b1dc76c Signed-off-by: Damjan Marion <damarion@cisco.com>
-rw-r--r--dpdk/Makefile2
-rw-r--r--vnet/vnet/devices/dpdk/init.c30
2 files changed, 31 insertions, 1 deletions
diff --git a/dpdk/Makefile b/dpdk/Makefile
index 316efc01640..e1aafcbb1fd 100644
--- a/dpdk/Makefile
+++ b/dpdk/Makefile
@@ -29,7 +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_16.04-rc4_TARBALL_MD5_CKSUM := 0de766a629999881e1c6e0de25d92bc0
DPDK_SOURCE := $(B)/dpdk-$(DPDK_VERSION)
DPDK_TARGET := x86_64-native-linuxapp-gcc
JOBS := $(shell grep processor /proc/cpuinfo | wc -l)
diff --git a/vnet/vnet/devices/dpdk/init.c b/vnet/vnet/devices/dpdk/init.c
index 822b05d4c11..179386970cc 100644
--- a/vnet/vnet/devices/dpdk/init.c
+++ b/vnet/vnet/devices/dpdk/init.c
@@ -1512,6 +1512,35 @@ void dpdk_update_link_state (dpdk_device_t * xd, f64 now)
break;
}
}
+#if RTE_VERSION >= RTE_VERSION_NUM(16, 4, 0, 0)
+ if (hw_flags_chg || (xd->link.link_speed != prev_link.link_speed))
+ {
+ hw_flags_chg = 1;
+ switch (xd->link.link_speed)
+ {
+ case ETH_SPEED_NUM_10M:
+ hw_flags |= VNET_HW_INTERFACE_FLAG_SPEED_10M;
+ break;
+ case ETH_SPEED_NUM_100M:
+ hw_flags |= VNET_HW_INTERFACE_FLAG_SPEED_100M;
+ break;
+ case ETH_SPEED_NUM_1G:
+ hw_flags |= VNET_HW_INTERFACE_FLAG_SPEED_1G;
+ break;
+ case ETH_SPEED_NUM_10G:
+ hw_flags |= VNET_HW_INTERFACE_FLAG_SPEED_10G;
+ break;
+ case ETH_SPEED_NUM_40G:
+ hw_flags |= VNET_HW_INTERFACE_FLAG_SPEED_40G;
+ break;
+ case 0:
+ break;
+ default:
+ clib_warning("unknown link speed %d", xd->link.link_speed);
+ break;
+ }
+ }
+#else
if (hw_flags_chg || (xd->link.link_speed != prev_link.link_speed))
{
hw_flags_chg = 1;
@@ -1539,6 +1568,7 @@ void dpdk_update_link_state (dpdk_device_t * xd, f64 now)
break;
}
}
+#endif
if (hw_flags_chg)
{
if (LINK_STATE_ELOGS)