- Update to 16.04
- Drop all patches, they're not needed anymore - Drop linker script generation, its upstream now - Enable vhost numa support again
This commit is contained in:
parent
4047cbae56
commit
e17ab00173
1
.gitignore
vendored
1
.gitignore
vendored
@ -3,3 +3,4 @@
|
|||||||
/dpdk-2.0.0.tar.gz
|
/dpdk-2.0.0.tar.gz
|
||||||
/dpdk-2.1.0.tar.gz
|
/dpdk-2.1.0.tar.gz
|
||||||
/dpdk-2.2.0.tar.gz
|
/dpdk-2.2.0.tar.gz
|
||||||
|
/dpdk-16.04.tar.gz
|
||||||
|
@ -1,152 +0,0 @@
|
|||||||
commit f85ab16a916be178a4cb61575f414c43fc98313d
|
|
||||||
Author: Panu Matilainen <pmatilai@redhat.com>
|
|
||||||
Date: Tue Dec 8 13:42:26 2015 +0200
|
|
||||||
|
|
||||||
mk: fix external shared library dependencies of libraries
|
|
||||||
|
|
||||||
Similar to commit 5f9115e58cc6f304ff4ade694cf5823d32887d1a etc, but
|
|
||||||
for libraries. Clean up librte_vhost CFLAGS/LDFLAGS/LDLIBS confusion
|
|
||||||
while at it.
|
|
||||||
|
|
||||||
Requiring applications to know about library internal details like
|
|
||||||
dependencies to external helper libraries is a limitation of
|
|
||||||
static linkage, shared libraries should always know their own
|
|
||||||
dependencies for sane operation.
|
|
||||||
|
|
||||||
Linking with the combined library (whether shared or not) still
|
|
||||||
requires knowing the internal dependencies, and intra-dpdk
|
|
||||||
dependencies are also not currently recorded.
|
|
||||||
|
|
||||||
Signed-off-by: Panu Matilainen <pmatilai@redhat.com>
|
|
||||||
|
|
||||||
diff --git a/app/test/Makefile b/app/test/Makefile
|
|
||||||
index ec33e1a..abb0545 100644
|
|
||||||
--- a/app/test/Makefile
|
|
||||||
+++ b/app/test/Makefile
|
|
||||||
@@ -182,6 +182,8 @@ endif
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
+LDLIBS += -lm
|
|
||||||
+
|
|
||||||
include $(RTE_SDK)/mk/rte.app.mk
|
|
||||||
|
|
||||||
endif
|
|
||||||
diff --git a/lib/librte_eal/bsdapp/eal/Makefile b/lib/librte_eal/bsdapp/eal/Makefile
|
|
||||||
index 65b293f..b7b6016 100644
|
|
||||||
--- a/lib/librte_eal/bsdapp/eal/Makefile
|
|
||||||
+++ b/lib/librte_eal/bsdapp/eal/Makefile
|
|
||||||
@@ -42,6 +42,9 @@ CFLAGS += -I$(RTE_SDK)/lib/librte_ring
|
|
||||||
CFLAGS += -I$(RTE_SDK)/lib/librte_mempool
|
|
||||||
CFLAGS += $(WERROR_FLAGS) -O3
|
|
||||||
|
|
||||||
+LDLIBS += -lpthread
|
|
||||||
+LDLIBS += -ldl
|
|
||||||
+
|
|
||||||
EXPORT_MAP := rte_eal_version.map
|
|
||||||
|
|
||||||
LIBABIVER := 2
|
|
||||||
diff --git a/lib/librte_eal/linuxapp/eal/Makefile b/lib/librte_eal/linuxapp/eal/Makefile
|
|
||||||
index 26eced5..0efb9e4 100644
|
|
||||||
--- a/lib/librte_eal/linuxapp/eal/Makefile
|
|
||||||
+++ b/lib/librte_eal/linuxapp/eal/Makefile
|
|
||||||
@@ -47,6 +47,9 @@ CFLAGS += -I$(RTE_SDK)/lib/librte_mempool
|
|
||||||
CFLAGS += -I$(RTE_SDK)/lib/librte_ivshmem
|
|
||||||
CFLAGS += $(WERROR_FLAGS) -O3
|
|
||||||
|
|
||||||
+LDLIBS += -lpthread
|
|
||||||
+LDLIBS += -ldl
|
|
||||||
+
|
|
||||||
# specific to linuxapp exec-env
|
|
||||||
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) := eal.c
|
|
||||||
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_hugepage_info.c
|
|
||||||
diff --git a/lib/librte_sched/Makefile b/lib/librte_sched/Makefile
|
|
||||||
index b1cb285..4d631f6 100644
|
|
||||||
--- a/lib/librte_sched/Makefile
|
|
||||||
+++ b/lib/librte_sched/Makefile
|
|
||||||
@@ -41,6 +41,9 @@ CFLAGS += $(WERROR_FLAGS)
|
|
||||||
|
|
||||||
CFLAGS_rte_red.o := -D_GNU_SOURCE
|
|
||||||
|
|
||||||
+LDLIBS += -lm
|
|
||||||
+LDLIBS += -lrt
|
|
||||||
+
|
|
||||||
EXPORT_MAP := rte_sched_version.map
|
|
||||||
|
|
||||||
LIBABIVER := 1
|
|
||||||
diff --git a/lib/librte_vhost/Makefile b/lib/librte_vhost/Makefile
|
|
||||||
index 6681f22..4aecc69 100644
|
|
||||||
--- a/lib/librte_vhost/Makefile
|
|
||||||
+++ b/lib/librte_vhost/Makefile
|
|
||||||
@@ -42,12 +42,12 @@ CFLAGS += $(WERROR_FLAGS) -I$(SRCDIR) -O3 -D_FILE_OFFSET_BITS=64
|
|
||||||
ifeq ($(CONFIG_RTE_LIBRTE_VHOST_USER),y)
|
|
||||||
CFLAGS += -I vhost_user
|
|
||||||
else
|
|
||||||
-CFLAGS += -I vhost_cuse -lfuse
|
|
||||||
-LDFLAGS += -lfuse
|
|
||||||
+CFLAGS += -I vhost_cuse
|
|
||||||
+LDLIBS += -lfuse
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTE_LIBRTE_VHOST_NUMA),y)
|
|
||||||
-LDFLAGS += -lnuma
|
|
||||||
+LDLIBS += -lnuma
|
|
||||||
endif
|
|
||||||
|
|
||||||
# all source are stored in SRCS-y
|
|
||||||
diff --git a/mk/exec-env/linuxapp/rte.vars.mk b/mk/exec-env/linuxapp/rte.vars.mk
|
|
||||||
index 5fd7d85..d51bd17 100644
|
|
||||||
--- a/mk/exec-env/linuxapp/rte.vars.mk
|
|
||||||
+++ b/mk/exec-env/linuxapp/rte.vars.mk
|
|
||||||
@@ -48,7 +48,7 @@ endif
|
|
||||||
# Workaround lack of DT_NEEDED entry
|
|
||||||
EXECENV_LDFLAGS = --no-as-needed
|
|
||||||
|
|
||||||
-EXECENV_LDLIBS = -lrt -lm
|
|
||||||
+EXECENV_LDLIBS =
|
|
||||||
EXECENV_ASFLAGS =
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y)
|
|
||||||
diff --git a/mk/rte.app.mk b/mk/rte.app.mk
|
|
||||||
index 8ecab41..4ecaa6c 100644
|
|
||||||
--- a/mk/rte.app.mk
|
|
||||||
+++ b/mk/rte.app.mk
|
|
||||||
@@ -81,23 +81,11 @@ _LDLIBS-$(CONFIG_RTE_LIBRTE_LPM) += -lrte_lpm
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_POWER) += -lrte_power
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_ACL) += -lrte_acl
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_METER) += -lrte_meter
|
|
||||||
-
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_SCHED) += -lrte_sched
|
|
||||||
-_LDLIBS-$(CONFIG_RTE_LIBRTE_SCHED) += -lm
|
|
||||||
-_LDLIBS-$(CONFIG_RTE_LIBRTE_SCHED) += -lrt
|
|
||||||
-
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lrte_vhost
|
|
||||||
|
|
||||||
endif # ! CONFIG_RTE_BUILD_COMBINE_LIBS
|
|
||||||
|
|
||||||
-ifeq ($(CONFIG_RTE_LIBRTE_VHOST_NUMA),y)
|
|
||||||
-_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lnuma
|
|
||||||
-endif
|
|
||||||
-
|
|
||||||
-ifeq ($(CONFIG_RTE_LIBRTE_VHOST_USER),n)
|
|
||||||
-_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lfuse
|
|
||||||
-endif
|
|
||||||
-
|
|
||||||
# The static libraries do not know their dependencies.
|
|
||||||
# The combined library fails also to store this information.
|
|
||||||
# So linking with static or combined library requires explicit dependencies.
|
|
||||||
@@ -111,6 +99,14 @@ _LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_XENVIRT) += -lxenstore
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_MPIPE_PMD) += -lgxio
|
|
||||||
# QAT PMD has a dependency on libcrypto (from openssl) for calculating HMAC precomputes
|
|
||||||
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_QAT) += -lcrypto
|
|
||||||
+_LDLIBS-$(CONFIG_RTE_LIBRTE_SCHED) += -lm
|
|
||||||
+_LDLIBS-$(CONFIG_RTE_LIBRTE_SCHED) += -lrt
|
|
||||||
+ifeq ($(CONFIG_RTE_LIBRTE_VHOST_NUMA),y)
|
|
||||||
+_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lnuma
|
|
||||||
+endif
|
|
||||||
+ifeq ($(CONFIG_RTE_LIBRTE_VHOST_USER),n)
|
|
||||||
+_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lfuse
|
|
||||||
+endif
|
|
||||||
endif # CONFIG_RTE_BUILD_COMBINE_LIBS or not CONFIG_RTE_BUILD_SHARED_LIBS
|
|
||||||
|
|
||||||
_LDLIBS-y += --start-group
|
|
@ -1,12 +0,0 @@
|
|||||||
diff -up dpdk-2.2.0/examples/ip_pipeline/Makefile.examples dpdk-2.2.0/examples/ip_pipeline/Makefile
|
|
||||||
--- dpdk-2.2.0/examples/ip_pipeline/Makefile.examples 2016-01-20 14:30:19.266011981 +0200
|
|
||||||
+++ dpdk-2.2.0/examples/ip_pipeline/Makefile 2016-01-20 14:30:28.638006264 +0200
|
|
||||||
@@ -73,7 +73,7 @@ SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pi
|
|
||||||
SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) += pipeline_routing.c
|
|
||||||
|
|
||||||
CFLAGS += -I$(SRCDIR) -I$(SRCDIR)/pipeline
|
|
||||||
-CFLAGS += -O3
|
|
||||||
+CFLAGS += -O3 -msse4
|
|
||||||
CFLAGS += $(WERROR_FLAGS) -Wno-error=unused-function -Wno-error=unused-variable
|
|
||||||
|
|
||||||
include $(RTE_SDK)/mk/rte.extapp.mk
|
|
@ -1,33 +0,0 @@
|
|||||||
diff -up ./drivers/net/e1000/base/e1000_phy.c.indent ./drivers/net/e1000/base/e1000_phy.c
|
|
||||||
--- ./drivers/net/e1000/base/e1000_phy.c.indent 2016-02-15 13:42:25.576470272 -0500
|
|
||||||
+++ ./drivers/net/e1000/base/e1000_phy.c 2016-02-15 13:48:18.070422353 -0500
|
|
||||||
@@ -4153,12 +4153,13 @@ s32 e1000_read_phy_reg_mphy(struct e1000
|
|
||||||
*data = E1000_READ_REG(hw, E1000_MPHY_DATA);
|
|
||||||
|
|
||||||
/* Disable access to mPHY if it was originally disabled */
|
|
||||||
- if (locked)
|
|
||||||
+ if (locked) {
|
|
||||||
ready = e1000_is_mphy_ready(hw);
|
|
||||||
if (!ready)
|
|
||||||
return -E1000_ERR_PHY;
|
|
||||||
E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL,
|
|
||||||
E1000_MPHY_DIS_ACCESS);
|
|
||||||
+ }
|
|
||||||
|
|
||||||
return E1000_SUCCESS;
|
|
||||||
}
|
|
||||||
@@ -4218,12 +4219,13 @@ s32 e1000_write_phy_reg_mphy(struct e100
|
|
||||||
E1000_WRITE_REG(hw, E1000_MPHY_DATA, data);
|
|
||||||
|
|
||||||
/* Disable access to mPHY if it was originally disabled */
|
|
||||||
- if (locked)
|
|
||||||
+ if (locked) {
|
|
||||||
ready = e1000_is_mphy_ready(hw);
|
|
||||||
if (!ready)
|
|
||||||
return -E1000_ERR_PHY;
|
|
||||||
E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL,
|
|
||||||
E1000_MPHY_DIS_ACCESS);
|
|
||||||
+ }
|
|
||||||
|
|
||||||
return E1000_SUCCESS;
|
|
||||||
}
|
|
@ -1,16 +0,0 @@
|
|||||||
diff -up ./drivers/net/ixgbe/ixgbe_ethdev.c.ixgbe_ethdev ./drivers/net/ixgbe/ixgbe_ethdev.c
|
|
||||||
--- ./drivers/net/ixgbe/ixgbe_ethdev.c.ixgbe_ethdev 2016-02-15 15:27:26.677573547 -0500
|
|
||||||
+++ ./drivers/net/ixgbe/ixgbe_ethdev.c 2016-02-15 15:28:41.771693991 -0500
|
|
||||||
@@ -4258,10 +4258,11 @@ ixgbe_set_pool_vlan_filter(struct rte_et
|
|
||||||
if (ixgbe_vmdq_mode_check(hw) < 0)
|
|
||||||
return (-ENOTSUP);
|
|
||||||
for (pool_idx = 0; pool_idx < ETH_64_POOLS; pool_idx++) {
|
|
||||||
- if (pool_mask & ((uint64_t)(1ULL << pool_idx)))
|
|
||||||
+ if (pool_mask & ((uint64_t)(1ULL << pool_idx))) {
|
|
||||||
ret = hw->mac.ops.set_vfta(hw,vlan,pool_idx,vlan_on);
|
|
||||||
if (ret < 0)
|
|
||||||
return ret;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
|
|
||||||
return ret;
|
|
@ -1,12 +0,0 @@
|
|||||||
diff -up ./drivers/net/ixgbe/ixgbe_rxtx.c.ixgbe ./drivers/net/ixgbe/ixgbe_rxtx.c
|
|
||||||
--- ./drivers/net/ixgbe/ixgbe_rxtx.c.ixgbe 2016-02-15 15:07:07.874139300 -0500
|
|
||||||
+++ ./drivers/net/ixgbe/ixgbe_rxtx.c 2016-02-15 15:09:18.420830519 -0500
|
|
||||||
@@ -1574,6 +1574,8 @@ ixgbe_recv_pkts_lro(void *rx_queue, stru
|
|
||||||
uint32_t staterr;
|
|
||||||
|
|
||||||
next_desc:
|
|
||||||
+ next_rxe = NULL;
|
|
||||||
+
|
|
||||||
/*
|
|
||||||
* The code in this whole file uses the volatile pointer to
|
|
||||||
* ensure the read ordering of the status and the rest of the
|
|
@ -1,15 +0,0 @@
|
|||||||
diff -up ./drivers/net/ixgbe/ixgbe_pf.c.ixgbe_pf ./drivers/net/ixgbe/ixgbe_pf.c
|
|
||||||
--- ./drivers/net/ixgbe/ixgbe_pf.c.ixgbe_pf 2016-02-15 15:39:44.723411150 -0500
|
|
||||||
+++ ./drivers/net/ixgbe/ixgbe_pf.c 2016-02-15 15:40:16.297302507 -0500
|
|
||||||
@@ -236,9 +236,9 @@ int ixgbe_pf_host_configure(struct rte_e
|
|
||||||
vfre_slot = (vf_num >> VFRE_SHIFT) > 0 ? 1 : 0;
|
|
||||||
|
|
||||||
/* Enable pools reserved to PF only */
|
|
||||||
- IXGBE_WRITE_REG(hw, IXGBE_VFRE(vfre_slot), (~0) << vfre_offset);
|
|
||||||
+ IXGBE_WRITE_REG(hw, IXGBE_VFRE(vfre_slot), UINT_MAX << vfre_offset);
|
|
||||||
IXGBE_WRITE_REG(hw, IXGBE_VFRE(vfre_slot ^ 1), vfre_slot - 1);
|
|
||||||
- IXGBE_WRITE_REG(hw, IXGBE_VFTE(vfre_slot), (~0) << vfre_offset);
|
|
||||||
+ IXGBE_WRITE_REG(hw, IXGBE_VFTE(vfre_slot), UINT_MAX << vfre_offset);
|
|
||||||
IXGBE_WRITE_REG(hw, IXGBE_VFTE(vfre_slot ^ 1), vfre_slot - 1);
|
|
||||||
|
|
||||||
/* PFDMA Tx General Switch Control Enables VMDQ loopback */
|
|
@ -1,21 +0,0 @@
|
|||||||
diff -up ./examples/l3fwd/main.c.mainfix ./examples/l3fwd/main.c
|
|
||||||
--- ./examples/l3fwd/main.c.mainfix 2016-02-16 11:35:19.639478702 -0500
|
|
||||||
+++ ./examples/l3fwd/main.c 2016-02-16 11:37:30.337193083 -0500
|
|
||||||
@@ -1098,7 +1098,7 @@ l3fwd_simple_forward(struct rte_mbuf *m,
|
|
||||||
++(ipv4_hdr->hdr_checksum);
|
|
||||||
#endif
|
|
||||||
/* dst addr */
|
|
||||||
- *(uint64_t *)ð_hdr->d_addr = dest_eth_addr[dst_port];
|
|
||||||
+ memcpy(ð_hdr->d_addr, &dest_eth_addr[dst_port], sizeof(uint64_t));
|
|
||||||
|
|
||||||
/* src addr */
|
|
||||||
ether_addr_copy(&ports_eth_addr[dst_port], ð_hdr->s_addr);
|
|
||||||
@@ -1117,7 +1117,7 @@ l3fwd_simple_forward(struct rte_mbuf *m,
|
|
||||||
dst_port = portid;
|
|
||||||
|
|
||||||
/* dst addr */
|
|
||||||
- *(uint64_t *)ð_hdr->d_addr = dest_eth_addr[dst_port];
|
|
||||||
+ memcpy(ð_hdr->d_addr, &dest_eth_addr[dst_port], sizeof(uint64_t));
|
|
||||||
|
|
||||||
/* src addr */
|
|
||||||
ether_addr_copy(&ports_eth_addr[dst_port], ð_hdr->s_addr);
|
|
@ -1,16 +0,0 @@
|
|||||||
diff -up ./examples/ip_pipeline/pipeline/pipeline_firewall.c.pfire ./examples/ip_pipeline/pipeline/pipeline_firewall.c
|
|
||||||
--- ./examples/ip_pipeline/pipeline/pipeline_firewall.c.pfire 2016-02-16 10:16:03.856528168 -0500
|
|
||||||
+++ ./examples/ip_pipeline/pipeline/pipeline_firewall.c 2016-02-16 10:17:31.128996838 -0500
|
|
||||||
@@ -256,10 +256,10 @@ app_pipeline_firewall_key_check_and_norm
|
|
||||||
return -1;
|
|
||||||
|
|
||||||
if (src_ip_depth)
|
|
||||||
- src_ip_netmask = (~0) << (32 - src_ip_depth);
|
|
||||||
+ src_ip_netmask = UINT_MAX << (32 - src_ip_depth);
|
|
||||||
|
|
||||||
if (dst_ip_depth)
|
|
||||||
- dst_ip_netmask = ((~0) << (32 - dst_ip_depth));
|
|
||||||
+ dst_ip_netmask = (UINT_MAX << (32 - dst_ip_depth));
|
|
||||||
|
|
||||||
key->key.ipv4_5tuple.src_ip &= src_ip_netmask;
|
|
||||||
key->key.ipv4_5tuple.dst_ip &= dst_ip_netmask;
|
|
@ -1,21 +0,0 @@
|
|||||||
diff -up ./examples/ip_pipeline/pipeline/pipeline_common_fe.c.pipe_common ./examples/ip_pipeline/pipeline/pipeline_common_fe.c
|
|
||||||
--- ./examples/ip_pipeline/pipeline/pipeline_common_fe.c.pipe_common 2016-02-15 16:51:32.161025145 -0500
|
|
||||||
+++ ./examples/ip_pipeline/pipeline/pipeline_common_fe.c 2016-02-15 16:55:05.654052482 -0500
|
|
||||||
@@ -337,7 +337,7 @@ app_link_config(struct app_params *app,
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
- netmask = (~0) << (32 - depth);
|
|
||||||
+ netmask = UINT_MAX << (32 - depth);
|
|
||||||
host = ip & netmask;
|
|
||||||
bcast = host | (~netmask);
|
|
||||||
|
|
||||||
@@ -889,7 +889,7 @@ print_link_info(struct app_link_params *
|
|
||||||
{
|
|
||||||
struct rte_eth_stats stats;
|
|
||||||
struct ether_addr *mac_addr;
|
|
||||||
- uint32_t netmask = (~0) << (32 - p->depth);
|
|
||||||
+ uint32_t netmask = UINT_MAX << (32 - p->depth);
|
|
||||||
uint32_t host = p->ip & netmask;
|
|
||||||
uint32_t bcast = host | (~netmask);
|
|
||||||
|
|
@ -1,39 +0,0 @@
|
|||||||
diff -up ./examples/ip_pipeline/pipeline/pipeline_routing_be.c.proutebe ./examples/ip_pipeline/pipeline/pipeline_routing_be.c
|
|
||||||
--- ./examples/ip_pipeline/pipeline/pipeline_routing_be.c.proutebe 2015-12-15 12:06:58.000000000 -0500
|
|
||||||
+++ ./examples/ip_pipeline/pipeline/pipeline_routing_be.c 2016-02-16 11:22:04.187871609 -0500
|
|
||||||
@@ -1461,7 +1461,7 @@ pipeline_routing_msg_req_route_add_handl
|
|
||||||
uint64_t macaddr_dst;
|
|
||||||
uint64_t ethertype = ETHER_TYPE_IPv4;
|
|
||||||
|
|
||||||
- macaddr_dst = *((uint64_t *)&(req->data.ethernet.macaddr));
|
|
||||||
+ memcpy(&macaddr_dst, &(req->data.ethernet.macaddr), sizeof(uint64_t));
|
|
||||||
macaddr_dst = rte_bswap64(macaddr_dst << 16);
|
|
||||||
|
|
||||||
entry_arp0.slab[0] =
|
|
||||||
@@ -1502,7 +1502,7 @@ pipeline_routing_msg_req_route_add_handl
|
|
||||||
uint64_t svlan = req->data.l2.qinq.svlan;
|
|
||||||
uint64_t cvlan = req->data.l2.qinq.cvlan;
|
|
||||||
|
|
||||||
- macaddr_dst = *((uint64_t *)&(req->data.ethernet.macaddr));
|
|
||||||
+ memcpy(&macaddr_dst, &(req->data.ethernet.macaddr), sizeof(uint64_t));
|
|
||||||
macaddr_dst = rte_bswap64(macaddr_dst << 16);
|
|
||||||
|
|
||||||
entry_arp0.slab[0] = rte_bswap64((svlan << 48) |
|
|
||||||
@@ -1561,7 +1561,7 @@ pipeline_routing_msg_req_route_add_handl
|
|
||||||
uint64_t label3 = req->data.l2.mpls.labels[3];
|
|
||||||
uint32_t n_labels = req->data.l2.mpls.n_labels;
|
|
||||||
|
|
||||||
- macaddr_dst = *((uint64_t *)&(req->data.ethernet.macaddr));
|
|
||||||
+ memcpy(&macaddr_dst, &(req->data.ethernet.macaddr), sizeof(uint64_t));
|
|
||||||
macaddr_dst = rte_bswap64(macaddr_dst << 16);
|
|
||||||
|
|
||||||
switch (n_labels) {
|
|
||||||
@@ -1811,7 +1811,7 @@ pipeline_routing_msg_req_arp_add_handler
|
|
||||||
return rsp;
|
|
||||||
}
|
|
||||||
|
|
||||||
- entry.macaddr = *((uint64_t *)&(req->macaddr));
|
|
||||||
+ memcpy(&entry.macaddr, &(req->macaddr), sizeof(uint64_t));
|
|
||||||
entry.macaddr = entry.macaddr << 16;
|
|
||||||
|
|
||||||
rsp->status = rte_pipeline_table_entry_add(p->p,
|
|
@ -1,21 +0,0 @@
|
|||||||
diff -up ./examples/ip_pipeline/pipeline/pipeline_routing.c.pipe_route ./examples/ip_pipeline/pipeline/pipeline_routing.c
|
|
||||||
--- ./examples/ip_pipeline/pipeline/pipeline_routing.c.pipe_route 2016-02-15 16:37:25.909132363 -0500
|
|
||||||
+++ ./examples/ip_pipeline/pipeline/pipeline_routing.c 2016-02-15 16:38:28.644903861 -0500
|
|
||||||
@@ -319,7 +319,7 @@ app_pipeline_routing_add_route(struct ap
|
|
||||||
if ((depth == 0) || (depth > 32))
|
|
||||||
return -1;
|
|
||||||
|
|
||||||
- netmask = (~0) << (32 - depth);
|
|
||||||
+ netmask = UINT_MAX << (32 - depth);
|
|
||||||
key->key.ipv4.ip &= netmask;
|
|
||||||
|
|
||||||
/* data */
|
|
||||||
@@ -421,7 +421,7 @@ app_pipeline_routing_delete_route(struct
|
|
||||||
if ((depth == 0) || (depth > 32))
|
|
||||||
return -1;
|
|
||||||
|
|
||||||
- netmask = (~0) << (32 - depth);
|
|
||||||
+ netmask = UINT_MAX << (32 - depth);
|
|
||||||
key->key.ipv4.ip &= netmask;
|
|
||||||
}
|
|
||||||
break;
|
|
@ -1,95 +0,0 @@
|
|||||||
diff -up ./lib/librte_lpm/rte_lpm.h.pun ./lib/librte_lpm/rte_lpm.h
|
|
||||||
--- ./lib/librte_lpm/rte_lpm.h.pun 2015-12-15 12:06:58.000000000 -0500
|
|
||||||
+++ ./lib/librte_lpm/rte_lpm.h 2016-02-15 12:45:26.306750412 -0500
|
|
||||||
@@ -43,6 +43,7 @@
|
|
||||||
#include <sys/queue.h>
|
|
||||||
#include <stdint.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
+#include <string.h>
|
|
||||||
#include <rte_branch_prediction.h>
|
|
||||||
#include <rte_byteorder.h>
|
|
||||||
#include <rte_memory.h>
|
|
||||||
@@ -286,7 +287,7 @@ rte_lpm_lookup(struct rte_lpm *lpm, uint
|
|
||||||
RTE_LPM_RETURN_IF_TRUE(((lpm == NULL) || (next_hop == NULL)), -EINVAL);
|
|
||||||
|
|
||||||
/* Copy tbl24 entry */
|
|
||||||
- tbl_entry = *(const uint16_t *)&lpm->tbl24[tbl24_index];
|
|
||||||
+ memcpy(&tbl_entry, &lpm->tbl24[tbl24_index], sizeof(uint16_t));
|
|
||||||
|
|
||||||
/* Copy tbl8 entry (only if needed) */
|
|
||||||
if (unlikely((tbl_entry & RTE_LPM_VALID_EXT_ENTRY_BITMASK) ==
|
|
||||||
@@ -295,7 +296,7 @@ rte_lpm_lookup(struct rte_lpm *lpm, uint
|
|
||||||
unsigned tbl8_index = (uint8_t)ip +
|
|
||||||
((uint8_t)tbl_entry * RTE_LPM_TBL8_GROUP_NUM_ENTRIES);
|
|
||||||
|
|
||||||
- tbl_entry = *(const uint16_t *)&lpm->tbl8[tbl8_index];
|
|
||||||
+ memcpy(&tbl_entry, &lpm->tbl8[tbl8_index], sizeof(uint16_t));
|
|
||||||
}
|
|
||||||
|
|
||||||
*next_hop = (uint8_t)tbl_entry;
|
|
||||||
@@ -342,7 +343,7 @@ rte_lpm_lookup_bulk_func(const struct rt
|
|
||||||
|
|
||||||
for (i = 0; i < n; i++) {
|
|
||||||
/* Simply copy tbl24 entry to output */
|
|
||||||
- next_hops[i] = *(const uint16_t *)&lpm->tbl24[tbl24_indexes[i]];
|
|
||||||
+ memcpy(&next_hops[i], &lpm->tbl24[tbl24_indexes[i]], sizeof(uint16_t));
|
|
||||||
|
|
||||||
/* Overwrite output with tbl8 entry if needed */
|
|
||||||
if (unlikely((next_hops[i] & RTE_LPM_VALID_EXT_ENTRY_BITMASK) ==
|
|
||||||
@@ -352,7 +353,7 @@ rte_lpm_lookup_bulk_func(const struct rt
|
|
||||||
((uint8_t)next_hops[i] *
|
|
||||||
RTE_LPM_TBL8_GROUP_NUM_ENTRIES);
|
|
||||||
|
|
||||||
- next_hops[i] = *(const uint16_t *)&lpm->tbl8[tbl8_index];
|
|
||||||
+ memcpy(&next_hops[i], &lpm->tbl8[tbl8_index], sizeof(uint16_t));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return 0;
|
|
||||||
@@ -419,13 +420,13 @@ rte_lpm_lookupx4(const struct rte_lpm *l
|
|
||||||
idx = _mm_cvtsi128_si64(i24);
|
|
||||||
i24 = _mm_srli_si128(i24, sizeof(uint64_t));
|
|
||||||
|
|
||||||
- tbl[0] = *(const uint16_t *)&lpm->tbl24[(uint32_t)idx];
|
|
||||||
- tbl[1] = *(const uint16_t *)&lpm->tbl24[idx >> 32];
|
|
||||||
+ memcpy(&tbl[0], &lpm->tbl24[(uint32_t)idx], sizeof(uint16_t));
|
|
||||||
+ memcpy(&tbl[1], &lpm->tbl24[idx >> 32], sizeof(uint16_t));
|
|
||||||
|
|
||||||
idx = _mm_cvtsi128_si64(i24);
|
|
||||||
|
|
||||||
- tbl[2] = *(const uint16_t *)&lpm->tbl24[(uint32_t)idx];
|
|
||||||
- tbl[3] = *(const uint16_t *)&lpm->tbl24[idx >> 32];
|
|
||||||
+ memcpy(&tbl[2], &lpm->tbl24[(uint32_t)idx], sizeof(uint16_t));
|
|
||||||
+ memcpy(&tbl[3], &lpm->tbl24[idx >> 32], sizeof(uint16_t));
|
|
||||||
|
|
||||||
/* get 4 indexes for tbl8[]. */
|
|
||||||
i8.x = _mm_and_si128(ip, mask8);
|
|
||||||
@@ -446,25 +447,25 @@ rte_lpm_lookupx4(const struct rte_lpm *l
|
|
||||||
RTE_LPM_VALID_EXT_ENTRY_BITMASK)) {
|
|
||||||
i8.u32[0] = i8.u32[0] +
|
|
||||||
(uint8_t)tbl[0] * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
|
|
||||||
- tbl[0] = *(const uint16_t *)&lpm->tbl8[i8.u32[0]];
|
|
||||||
+ memcpy(&tbl[0], &lpm->tbl8[i8.u32[0]], sizeof(uint16_t));
|
|
||||||
}
|
|
||||||
if (unlikely((pt >> 16 & RTE_LPM_VALID_EXT_ENTRY_BITMASK) ==
|
|
||||||
RTE_LPM_VALID_EXT_ENTRY_BITMASK)) {
|
|
||||||
i8.u32[1] = i8.u32[1] +
|
|
||||||
(uint8_t)tbl[1] * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
|
|
||||||
- tbl[1] = *(const uint16_t *)&lpm->tbl8[i8.u32[1]];
|
|
||||||
+ memcpy(&tbl[1], &lpm->tbl8[i8.u32[1]], sizeof(uint16_t));
|
|
||||||
}
|
|
||||||
if (unlikely((pt >> 32 & RTE_LPM_VALID_EXT_ENTRY_BITMASK) ==
|
|
||||||
RTE_LPM_VALID_EXT_ENTRY_BITMASK)) {
|
|
||||||
i8.u32[2] = i8.u32[2] +
|
|
||||||
(uint8_t)tbl[2] * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
|
|
||||||
- tbl[2] = *(const uint16_t *)&lpm->tbl8[i8.u32[2]];
|
|
||||||
+ memcpy(&tbl[2], &lpm->tbl8[i8.u32[2]], sizeof(uint16_t));
|
|
||||||
}
|
|
||||||
if (unlikely((pt >> 48 & RTE_LPM_VALID_EXT_ENTRY_BITMASK) ==
|
|
||||||
RTE_LPM_VALID_EXT_ENTRY_BITMASK)) {
|
|
||||||
i8.u32[3] = i8.u32[3] +
|
|
||||||
(uint8_t)tbl[3] * RTE_LPM_TBL8_GROUP_NUM_ENTRIES;
|
|
||||||
- tbl[3] = *(const uint16_t *)&lpm->tbl8[i8.u32[3]];
|
|
||||||
+ memcpy(&tbl[3], &lpm->tbl8[i8.u32[3]], sizeof(uint16_t));
|
|
||||||
}
|
|
||||||
|
|
||||||
hop[0] = (tbl[0] & RTE_LPM_LOOKUP_SUCCESS) ? (uint8_t)tbl[0] : defv;
|
|
@ -1,33 +0,0 @@
|
|||||||
diff -up ./drivers/net/e1000/em_ethdev.c.shift ./drivers/net/e1000/em_ethdev.c
|
|
||||||
--- ./drivers/net/e1000/em_ethdev.c.shift 2016-02-15 14:26:14.678723144 -0500
|
|
||||||
+++ ./drivers/net/e1000/em_ethdev.c 2016-02-15 14:29:50.859841821 -0500
|
|
||||||
@@ -637,13 +637,14 @@ eth_em_start(struct rte_eth_dev *dev)
|
|
||||||
|
|
||||||
if (rte_intr_allow_others(intr_handle)) {
|
|
||||||
/* check if lsc interrupt is enabled */
|
|
||||||
- if (dev->data->dev_conf.intr_conf.lsc != 0)
|
|
||||||
+ if (dev->data->dev_conf.intr_conf.lsc != 0) {
|
|
||||||
ret = eth_em_interrupt_setup(dev);
|
|
||||||
if (ret) {
|
|
||||||
PMD_INIT_LOG(ERR, "Unable to setup interrupts");
|
|
||||||
em_dev_clear_queues(dev);
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
+ }
|
|
||||||
} else {
|
|
||||||
rte_intr_callback_unregister(intr_handle,
|
|
||||||
eth_em_interrupt_handler,
|
|
||||||
diff -up ./drivers/net/e1000/igb_pf.c.shift ./drivers/net/e1000/igb_pf.c
|
|
||||||
--- ./drivers/net/e1000/igb_pf.c.shift 2016-02-15 14:09:55.541062415 -0500
|
|
||||||
+++ ./drivers/net/e1000/igb_pf.c 2016-02-15 14:09:18.566018267 -0500
|
|
||||||
@@ -172,8 +172,8 @@ int igb_pf_host_configure(struct rte_eth
|
|
||||||
E1000_WRITE_REG(hw, E1000_VT_CTL, vtctl);
|
|
||||||
|
|
||||||
/* Enable pools reserved to PF only */
|
|
||||||
- E1000_WRITE_REG(hw, E1000_VFRE, (~0) << vf_num);
|
|
||||||
- E1000_WRITE_REG(hw, E1000_VFTE, (~0) << vf_num);
|
|
||||||
+ E1000_WRITE_REG(hw, E1000_VFRE, UINT_MAX << vf_num);
|
|
||||||
+ E1000_WRITE_REG(hw, E1000_VFTE, UINT_MAX << vf_num);
|
|
||||||
|
|
||||||
/* PFDMA Tx General Switch Control Enables VMDQ loopback */
|
|
||||||
if (hw->mac.type == e1000_i350)
|
|
@ -1,15 +0,0 @@
|
|||||||
diff -up ./app/test/test.c.test ./app/test/test.c
|
|
||||||
--- ./app/test/test.c.test 2016-02-15 16:07:28.736385392 -0500
|
|
||||||
+++ ./app/test/test.c 2016-02-15 16:08:06.596454441 -0500
|
|
||||||
@@ -162,9 +162,10 @@ unit_test_suite_runner(struct unit_test_
|
|
||||||
int test_success;
|
|
||||||
unsigned total = 0, executed = 0, skipped = 0, succeeded = 0, failed = 0;
|
|
||||||
|
|
||||||
- if (suite->suite_name)
|
|
||||||
+ if (suite->suite_name) {
|
|
||||||
printf(" + ------------------------------------------------------- +\n");
|
|
||||||
printf(" + Test Suite : %s\n", suite->suite_name);
|
|
||||||
+ }
|
|
||||||
|
|
||||||
if (suite->setup)
|
|
||||||
if (suite->setup() != 0)
|
|
@ -1,24 +0,0 @@
|
|||||||
diff --git a/drivers/net/i40e/Makefile b/drivers/net/i40e/Makefile
|
|
||||||
index 033ee4a..3917b0c 100644
|
|
||||||
--- a/drivers/net/i40e/Makefile
|
|
||||||
+++ b/drivers/net/i40e/Makefile
|
|
||||||
@@ -55,7 +55,6 @@ CFLAGS_BASE_DRIVER += -Wno-sign-compare
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-unused-value
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-unused-parameter
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-strict-aliasing
|
|
||||||
-CFLAGS_BASE_DRIVER += -Wno-format
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-missing-field-initializers
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-pointer-to-int-cast
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-format-nonliteral
|
|
||||||
@@ -65,11 +64,9 @@ CFLAGS_BASE_DRIVER = -Wno-sign-compare
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-unused-value
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-unused-parameter
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-strict-aliasing
|
|
||||||
-CFLAGS_BASE_DRIVER += -Wno-format
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-missing-field-initializers
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-pointer-to-int-cast
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-format-nonliteral
|
|
||||||
-CFLAGS_BASE_DRIVER += -Wno-format-security
|
|
||||||
CFLAGS_BASE_DRIVER += -Wno-unused-variable
|
|
||||||
|
|
||||||
ifeq ($(shell test $(GCC_VERSION) -ge 44 && echo 1), 1)
|
|
61
dpdk.spec
61
dpdk.spec
@ -7,28 +7,12 @@
|
|||||||
# Add option to build the PDF documentation separately (--with pdfdoc)
|
# Add option to build the PDF documentation separately (--with pdfdoc)
|
||||||
%bcond_with pdfdoc
|
%bcond_with pdfdoc
|
||||||
|
|
||||||
|
|
||||||
Name: dpdk
|
Name: dpdk
|
||||||
Version: 2.2.0
|
Version: 16.04
|
||||||
Release: 7%{?dist}
|
Release: 1%{?dist}
|
||||||
URL: http://dpdk.org
|
URL: http://dpdk.org
|
||||||
Source: http://dpdk.org/browse/dpdk/snapshot/dpdk-%{version}.tar.gz
|
Source: http://dpdk.org/browse/dpdk/snapshot/dpdk-%{version}.tar.gz
|
||||||
|
|
||||||
Patch2: dpdk-2.2-dtneeded.patch
|
|
||||||
Patch4: dpdk-2.2-examples.patch
|
|
||||||
Patch5: dpdk-2.2-punning.patch
|
|
||||||
Patch6: dpdk-2.2-indent.patch
|
|
||||||
Patch7: dpdk-2.2-shift.patch
|
|
||||||
Patch9: dpdk-2.2-ixgbe-fixes.patch
|
|
||||||
Patch10: dpdk-2.2-ixgbe-ethdev-fixes.patch
|
|
||||||
Patch11: dpdk-2.2-ixgbe-pf-fixes.patch
|
|
||||||
Patch12: dpdk-2.2-test-fixes.patch
|
|
||||||
Patch13: dpdk-2.2-pipeline-routing-fixes.patch
|
|
||||||
Patch14: dpdk-2.2-pipeline-common-fixes.patch
|
|
||||||
Patch15: dpdk-2.2-pfire-fixes.patch
|
|
||||||
Patch16: dpdk-2.2-pipeline-routebe-fixes.patch
|
|
||||||
Patch17: dpdk-2.2-l3fwd-main.patch
|
|
||||||
|
|
||||||
Summary: Set of libraries and drivers for fast packet processing
|
Summary: Set of libraries and drivers for fast packet processing
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -120,20 +104,6 @@ as L2 and L3 forwarding.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch2 -p1 -z .dtneeded
|
|
||||||
%patch4 -p1 -z .examples
|
|
||||||
%patch5 -p1 -z .pun
|
|
||||||
%patch6 -p1 -z .indent
|
|
||||||
%patch7 -p1 -z .shift
|
|
||||||
%patch9 -p1 -z .ixgbe
|
|
||||||
%patch10 -p1 -z .ixgbe_ethdev
|
|
||||||
%patch11 -p1 -z .ixgbe_pf
|
|
||||||
%patch12 -p1 -z .test
|
|
||||||
%patch13 -p1 -z .pipeline
|
|
||||||
%patch14 -p1 -z .pipe_common
|
|
||||||
%patch15 -p1 -z .pfire
|
|
||||||
%patch16 -p1 -z .proutebe
|
|
||||||
%patch17 -p1 -z .l3fwmain
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# set up a method for modifying the resulting .config file
|
# set up a method for modifying the resulting .config file
|
||||||
@ -174,8 +144,7 @@ setconf CONFIG_RTE_EAL_PMD_PATH '"%{pmddir}"'
|
|||||||
|
|
||||||
setconf CONFIG_RTE_LIBRTE_BNX2X_PMD y
|
setconf CONFIG_RTE_LIBRTE_BNX2X_PMD y
|
||||||
setconf CONFIG_RTE_LIBRTE_PMD_PCAP y
|
setconf CONFIG_RTE_LIBRTE_PMD_PCAP y
|
||||||
# Temporarily disabled
|
setconf CONFIG_RTE_LIBRTE_VHOST_NUMA y
|
||||||
setconf CONFIG_RTE_LIBRTE_VHOST_NUMA n
|
|
||||||
|
|
||||||
setconf CONFIG_RTE_EAL_IGB_UIO n
|
setconf CONFIG_RTE_EAL_IGB_UIO n
|
||||||
setconf CONFIG_RTE_LIBRTE_KNI n
|
setconf CONFIG_RTE_LIBRTE_KNI n
|
||||||
@ -241,24 +210,6 @@ EOF
|
|||||||
# Fixup target machine mismatch
|
# Fixup target machine mismatch
|
||||||
sed -i -e 's:-%{machine_tmpl}-:-%{machine}-:g' %{buildroot}/%{_sysconfdir}/profile.d/dpdk-sdk*
|
sed -i -e 's:-%{machine_tmpl}-:-%{machine}-:g' %{buildroot}/%{_sysconfdir}/profile.d/dpdk-sdk*
|
||||||
|
|
||||||
# Upstream has an option to build a combined library but it's bloatware which
|
|
||||||
# wont work at all when library versions start moving, replace it with a
|
|
||||||
# linker script which avoids these issues. Linking against the script during
|
|
||||||
# build resolves into links to the actual used libraries which is just fine
|
|
||||||
# for us, so this combined library is a build-time only construct now.
|
|
||||||
%if %{with shared}
|
|
||||||
libext=so
|
|
||||||
%else
|
|
||||||
libext=a
|
|
||||||
%endif
|
|
||||||
comblib=libdpdk.${libext}
|
|
||||||
|
|
||||||
echo "GROUP (" > ${comblib}
|
|
||||||
find %{buildroot}/%{_libdir}/ -name "*.${libext}" |\
|
|
||||||
sed -e "s:^%{buildroot}/: :g" >> ${comblib}
|
|
||||||
echo ")" >> ${comblib}
|
|
||||||
install -m 644 ${comblib} %{buildroot}/%{_libdir}/${comblib}
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
# BSD
|
# BSD
|
||||||
%{_bindir}/testpmd
|
%{_bindir}/testpmd
|
||||||
@ -302,6 +253,12 @@ install -m 644 ${comblib} %{buildroot}/%{_libdir}/${comblib}
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Apr 14 2016 Panu Matilainen <pmatilai@redhat.com> - 16.04-1
|
||||||
|
- Update to 16.04
|
||||||
|
- Drop all patches, they're not needed anymore
|
||||||
|
- Drop linker script generation, its upstream now
|
||||||
|
- Enable vhost numa support again
|
||||||
|
|
||||||
* Wed Mar 16 2016 Panu Matilainen <pmatilai@redhat.com> - 2.2.0-7
|
* Wed Mar 16 2016 Panu Matilainen <pmatilai@redhat.com> - 2.2.0-7
|
||||||
- vhost numa code causes crashes, disable until upstream fixes
|
- vhost numa code causes crashes, disable until upstream fixes
|
||||||
- Generalize target/machine/etc macros to enable i686 builds
|
- Generalize target/machine/etc macros to enable i686 builds
|
||||||
|
Loading…
Reference in New Issue
Block a user