From: Dongyang Pan <197020236@qq.com> Date: Sat, 4 Jul 2020 01:15:26 +0000 (+0800) Subject: net/bonding: delete redundant code X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=2db4cf9d01c5920be0397e5c7aba61779c997753;p=dpdk.git net/bonding: delete redundant code The function valid_bonded_port_id() has already contains function rte_eth_dev_is_valid_port(), so delete redundant check. Fixes: 588ae95e7983 ("net/bonding: fix port ID check") Cc: stable@dpdk.org Signed-off-by: Dongyang Pan <197020236@qq.com> Reviewed-by: Wei Hu (Xavier) --- diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c b/drivers/net/bonding/rte_eth_bond_8023ad.c index 3991825ad9..b24a446862 100644 --- a/drivers/net/bonding/rte_eth_bond_8023ad.c +++ b/drivers/net/bonding/rte_eth_bond_8023ad.c @@ -1676,9 +1676,6 @@ rte_eth_bond_8023ad_dedicated_queues_enable(uint16_t port) dev = &rte_eth_devices[port]; internals = dev->data->dev_private; - if (check_for_bonded_ethdev(dev) != 0) - return -1; - if (bond_8023ad_slow_pkt_hw_filter_supported(port) != 0) return -1; @@ -1705,9 +1702,6 @@ rte_eth_bond_8023ad_dedicated_queues_disable(uint16_t port) dev = &rte_eth_devices[port]; internals = dev->data->dev_private; - if (check_for_bonded_ethdev(dev) != 0) - return -1; - /* Device must be stopped to set up slow queue */ if (dev->data->dev_started) return -1;