app/testpmd: merge ports list update functions
authorThomas Monjalon <thomas@monjalon.net>
Thu, 25 Oct 2018 15:11:14 +0000 (17:11 +0200)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 26 Oct 2018 20:14:06 +0000 (22:14 +0200)
commit4f1de450c90d1873652a4fa3c03370741a5ec55b
tree717f26e56f7b11e55fba85583030d620403e6add
parentf8e5baa2662d2cc89af25e8b077e4a6ae073754a
app/testpmd: merge ports list update functions

The arrays ports_ids and fwd_ports_ids require the same kind
of update when some ports are removed or added.

The functions update_fwd_ports() and remove_unused_fwd_ports()
are merged in the new function remove_invalid_ports().
The part for adding new port is moved into setup_attached_port().

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
app/test-pmd/testpmd.c