From ce3d555e43e3795b5d9507fcfc76b7a0a92fd0d6 Mon Sep 17 00:00:00 2001 From: Christian Ehrhardt Date: Thu, 2 Mar 2017 16:15:51 +0100 Subject: Imported Upstream version 16.11.1 Change-Id: I1e965265578efaaf08e5628607f53d2386d2df9f Signed-off-by: Christian Ehrhardt --- app/test-pmd/Makefile | 2 ++ app/test-pmd/cmdline.c | 24 ++++++++++++++++++++++++ 2 files changed, 26 insertions(+) (limited to 'app/test-pmd') diff --git a/app/test-pmd/Makefile b/app/test-pmd/Makefile index 891b85ac..92c0c1b0 100644 --- a/app/test-pmd/Makefile +++ b/app/test-pmd/Makefile @@ -58,7 +58,9 @@ SRCS-y += csumonly.c SRCS-y += icmpecho.c SRCS-$(CONFIG_RTE_LIBRTE_IEEE1588) += ieee1588fwd.c +ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),y) _LDLIBS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += -lrte_pmd_ixgbe +endif CFLAGS_cmdline.o := -D_GNU_SOURCE diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c index 63b55dcb..315a252e 100644 --- a/app/test-pmd/cmdline.c +++ b/app/test-pmd/cmdline.c @@ -10807,6 +10807,9 @@ cmd_set_vf_vlan_anti_spoof_parsed( int ret = 0; int is_on = (strcmp(res->on_off, "on") == 0) ? 1 : 0; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_vf_vlan_anti_spoof(res->port_id, res->vf_id, is_on); switch (ret) { @@ -10892,6 +10895,9 @@ cmd_set_vf_mac_anti_spoof_parsed( int ret; int is_on = (strcmp(res->on_off, "on") == 0) ? 1 : 0; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_vf_mac_anti_spoof(res->port_id, res->vf_id, is_on); switch (ret) { @@ -10977,6 +10983,9 @@ cmd_set_vf_vlan_stripq_parsed( int ret = 0; int is_on = (strcmp(res->on_off, "on") == 0) ? 1 : 0; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_vf_vlan_stripq(res->port_id, res->vf_id, is_on); switch (ret) { case 0: @@ -11060,6 +11069,9 @@ cmd_set_vf_vlan_insert_parsed( struct cmd_vf_vlan_insert_result *res = parsed_result; int ret; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_vf_vlan_insert(res->port_id, res->vf_id, res->vlan_id); switch (ret) { case 0: @@ -11134,6 +11146,9 @@ cmd_set_tx_loopback_parsed( int ret; int is_on = (strcmp(res->on_off, "on") == 0) ? 1 : 0; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_tx_loopback(res->port_id, is_on); switch (ret) { case 0: @@ -11211,6 +11226,9 @@ cmd_set_all_queues_drop_en_parsed( int ret = 0; int is_on = (strcmp(res->on_off, "on") == 0) ? 1 : 0; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_all_queues_drop_en(res->port_id, is_on); switch (ret) { case 0: @@ -11294,6 +11312,9 @@ cmd_set_vf_split_drop_en_parsed( int ret; int is_on = (strcmp(res->on_off, "on") == 0) ? 1 : 0; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_vf_split_drop_en(res->port_id, res->vf_id, is_on); switch (ret) { @@ -11378,6 +11399,9 @@ cmd_set_vf_mac_addr_parsed( struct cmd_set_vf_mac_addr_result *res = parsed_result; int ret; + if (port_id_is_invalid(res->port_id, ENABLED_WARN)) + return; + ret = rte_pmd_ixgbe_set_vf_mac_addr(res->port_id, res->vf_id, &res->mac_addr); switch (ret) { -- cgit 1.2.3-korg