git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/iavf: check max SIMD bitwidth
[dpdk.git]
/
drivers
/
net
/
failsafe
/
failsafe_args.c
diff --git
a/drivers/net/failsafe/failsafe_args.c
b/drivers/net/failsafe/failsafe_args.c
index
3351c5b
..
707490b
100644
(file)
--- a/
drivers/net/failsafe/failsafe_args.c
+++ b/
drivers/net/failsafe/failsafe_args.c
@@
-367,16
+367,12
@@
static int
fs_get_mac_addr_arg(const char *key __rte_unused,
const char *value, void *out)
{
fs_get_mac_addr_arg(const char *key __rte_unused,
const char *value, void *out)
{
- struct ether_addr *ea = out;
- int ret;
+ struct rte_ether_addr *ea = out;
if ((value == NULL) || (out == NULL))
return -EINVAL;
if ((value == NULL) || (out == NULL))
return -EINVAL;
- ret = sscanf(value, "%hhx:%hhx:%hhx:%hhx:%hhx:%hhx",
- &ea->addr_bytes[0], &ea->addr_bytes[1],
- &ea->addr_bytes[2], &ea->addr_bytes[3],
- &ea->addr_bytes[4], &ea->addr_bytes[5]);
- return ret != ETHER_ADDR_LEN;
+
+ return rte_ether_unformat_addr(value, ea);
}
int
}
int