net/bonding: use new ethernet address parser
authorStephen Hemminger <stephen@networkplumber.org>
Fri, 5 Jul 2019 17:16:21 +0000 (10:16 -0700)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 8 Jul 2019 19:26:52 +0000 (21:26 +0200)
The cmdline library used to be the only way to parse a
mac address. Now there is rte_ether_unformat_addr.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
drivers/net/bonding/Makefile
drivers/net/bonding/meson.build
drivers/net/bonding/rte_eth_bond_args.c

index 1893e3c..26c1782 100644 (file)
@@ -12,7 +12,7 @@ CFLAGS += -DALLOW_EXPERIMENTAL_API
 CFLAGS += -O3
 CFLAGS += $(WERROR_FLAGS)
 LDLIBS += -lrte_eal -lrte_mbuf -lrte_mempool -lrte_ring
-LDLIBS += -lrte_ethdev -lrte_net -lrte_kvargs -lrte_cmdline
+LDLIBS += -lrte_ethdev -lrte_net -lrte_kvargs
 LDLIBS += -lrte_pci -lrte_bus_pci
 LDLIBS += -lrte_bus_vdev
 
index 00374ed..6267210 100644 (file)
@@ -8,6 +8,6 @@ sources = files('rte_eth_bond_api.c', 'rte_eth_bond_pmd.c', 'rte_eth_bond_flow.c
        'rte_eth_bond_args.c', 'rte_eth_bond_8023ad.c', 'rte_eth_bond_alb.c')
 
 deps += 'sched' # needed for rte_bitmap.h
-deps += ['ip_frag', 'cmdline']
+deps += ['ip_frag']
 
 install_headers('rte_eth_bond.h', 'rte_eth_bond_8023ad.h')
index 01bbb06..936440f 100644 (file)
@@ -7,9 +7,6 @@
 #include <rte_bus_pci.h>
 #include <rte_kvargs.h>
 
-#include <cmdline_parse.h>
-#include <cmdline_parse_etheraddr.h>
-
 #include "rte_eth_bond.h"
 #include "rte_eth_bond_private.h"
 
@@ -281,8 +278,7 @@ bond_ethdev_parse_bond_mac_addr_kvarg(const char *key __rte_unused,
                return -1;
 
        /* Parse MAC */
-       return cmdline_parse_etheraddr(NULL, value, extra_args,
-               sizeof(struct rte_ether_addr));
+       return rte_ether_unformat_addr(value, extra_args);
 }
 
 int