[dpdk-dev] [PATCH 4/4] tile: fix remaining build issues
Chris Metcalf
cmetcalf at mellanox.com
Sat Feb 18 02:52:29 CET 2017
Re-enable CONFIG_RTE_LIBRTE_SCHED, since it is needed to build
correctly.
Fix a few warnings when compiling mpipe_tilegx.c.
Remove an empty rte_cpu_feature_table[] array using a bogus type.
Properly set RTE_OBJCOPY_{TARGET,ARCH} in mk/arch/tile/rte.vars.mk.
Signed-off-by: Chris Metcalf <cmetcalf at mellanox.com>
---
config/defconfig_tile-tilegx-linuxapp-gcc | 1 -
drivers/net/mpipe/mpipe_tilegx.c | 21 ++++++++++++---------
lib/librte_eal/common/arch/tile/rte_cpuflags.c | 3 ---
mk/arch/tile/rte.vars.mk | 5 +++++
4 files changed, 17 insertions(+), 13 deletions(-)
diff --git a/config/defconfig_tile-tilegx-linuxapp-gcc b/config/defconfig_tile-tilegx-linuxapp-gcc
index 44add62567d7..310e876bb4f5 100644
--- a/config/defconfig_tile-tilegx-linuxapp-gcc
+++ b/config/defconfig_tile-tilegx-linuxapp-gcc
@@ -66,7 +66,6 @@ CONFIG_RTE_LIBRTE_ENIC_PMD=n
# So they're turned off.
CONFIG_RTE_LIBRTE_LPM=n
CONFIG_RTE_LIBRTE_ACL=n
-CONFIG_RTE_LIBRTE_SCHED=n
CONFIG_RTE_LIBRTE_PORT=n
CONFIG_RTE_LIBRTE_TABLE=n
CONFIG_RTE_LIBRTE_PIPELINE=n
diff --git a/drivers/net/mpipe/mpipe_tilegx.c b/drivers/net/mpipe/mpipe_tilegx.c
index adba3306adbc..60d5f815f273 100644
--- a/drivers/net/mpipe/mpipe_tilegx.c
+++ b/drivers/net/mpipe/mpipe_tilegx.c
@@ -567,7 +567,7 @@ mpipe_register_segment(struct mpipe_dev_priv *priv, const struct rte_memseg *ms)
{
size_t size = ms->hugepage_sz;
uint8_t *addr, *end;
- int rc;
+ int rc = -EINVAL;
for (addr = ms->addr, end = addr + ms->len; addr < end; addr += size) {
rc = gxio_mpipe_register_page(priv->context, priv->stack, addr,
@@ -1630,6 +1630,17 @@ rte_pmd_mpipe_probe_common(struct rte_vdev_driver *drv, const char *ifname,
return 0;
}
+static int rte_pmd_mpipe_xgbe_probe(const char *ifname, const char *params);
+static int rte_pmd_mpipe_gbe_probe(const char *ifname, const char *params);
+
+static struct rte_vdev_driver pmd_mpipe_xgbe_drv = {
+ .probe = rte_pmd_mpipe_xgbe_probe,
+};
+
+static struct rte_vdev_driver pmd_mpipe_gbe_drv = {
+ .probe = rte_pmd_mpipe_gbe_probe,
+};
+
static int
rte_pmd_mpipe_xgbe_probe(const char *ifname, const char *params __rte_unused)
{
@@ -1642,14 +1653,6 @@ rte_pmd_mpipe_gbe_probe(const char *ifname, const char *params __rte_unused)
return rte_pmd_mpipe_probe_common(&pmd_mpipe_gbe_drv, ifname, params);
}
-static struct rte_vdev_driver pmd_mpipe_xgbe_drv = {
- .probe = rte_pmd_mpipe_xgbe_probe,
-};
-
-static struct rte_vdev_driver pmd_mpipe_gbe_drv = {
- .probe = rte_pmd_mpipe_gbe_probe,
-};
-
RTE_PMD_REGISTER_VDEV(net_mpipe_xgbe, pmd_mpipe_xgbe_drv);
RTE_PMD_REGISTER_ALIAS(net_mpipe_xgbe, xgbe);
RTE_PMD_REGISTER_VDEV(net_mpipe_gbe, pmd_mpipe_gbe_drv);
diff --git a/lib/librte_eal/common/arch/tile/rte_cpuflags.c b/lib/librte_eal/common/arch/tile/rte_cpuflags.c
index a2b6c51a2bc5..0872891352ec 100644
--- a/lib/librte_eal/common/arch/tile/rte_cpuflags.c
+++ b/lib/librte_eal/common/arch/tile/rte_cpuflags.c
@@ -34,9 +34,6 @@
#include <errno.h>
-const struct feature_entry rte_cpu_feature_table[] = {
-};
-
/*
* Checks if a particular flag is available on current machine.
*/
diff --git a/mk/arch/tile/rte.vars.mk b/mk/arch/tile/rte.vars.mk
index 5ad37389c9a8..2c612c48f6d7 100644
--- a/mk/arch/tile/rte.vars.mk
+++ b/mk/arch/tile/rte.vars.mk
@@ -37,3 +37,8 @@ CPU_LDFLAGS ?=
CPU_ASFLAGS ?=
export ARCH CROSS CPU_CFLAGS CPU_LDFLAGS CPU_ASFLAGS
+
+RTE_OBJCOPY_TARGET = elf64-tilegx-le
+RTE_OBJCOPY_ARCH = tilegx
+
+export RTE_OBJCOPY_TARGET RTE_OBJCOPY_ARCH
--
2.7.2
More information about the dev
mailing list