summaryrefslogtreecommitdiff
path: root/examples/l2fwd-keepalive
diff options
context:
space:
mode:
authorMauricio Vasquez B <mauricio.vasquezbernal@studenti.polito.it>2016-05-03 23:16:57 +0200
committerThomas Monjalon <thomas.monjalon@6wind.com>2016-05-16 21:01:51 +0200
commitb4e0f64ff271ccc78f6275b6bd49194e86fd4f4b (patch)
tree2a4695177a7b7b352433f8e90e590434b4174e7c /examples/l2fwd-keepalive
parent6b3ac0da69e21de7e0e78ed0441b870281288143 (diff)
downloaddpdk-b4e0f64ff271ccc78f6275b6bd49194e86fd4f4b.zip
dpdk-b4e0f64ff271ccc78f6275b6bd49194e86fd4f4b.tar.gz
dpdk-b4e0f64ff271ccc78f6275b6bd49194e86fd4f4b.tar.xz
examples: remove useless check of port count
The rte_eth_dev_count() function will never return a value greater than RTE_MAX_ETHPORTS, so that checking is useless. Signed-off-by: Mauricio Vasquez B <mauricio.vasquezbernal@studenti.polito.it> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Diffstat (limited to 'examples/l2fwd-keepalive')
-rw-r--r--examples/l2fwd-keepalive/main.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/examples/l2fwd-keepalive/main.c b/examples/l2fwd-keepalive/main.c
index 8da89aa..4a0d9b6 100644
--- a/examples/l2fwd-keepalive/main.c
+++ b/examples/l2fwd-keepalive/main.c
@@ -570,9 +570,6 @@ main(int argc, char **argv)
if (nb_ports == 0)
rte_exit(EXIT_FAILURE, "No Ethernet ports - bye\n");
- if (nb_ports > RTE_MAX_ETHPORTS)
- nb_ports = RTE_MAX_ETHPORTS;
-
/* reset l2fwd_dst_ports */
for (portid = 0; portid < RTE_MAX_ETHPORTS; portid++)
l2fwd_dst_ports[portid] = 0;