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
examples/l3fwd-power: add interrupt-only mode
[dpdk.git]
/
examples
/
ethtool
/
lib
/
rte_ethtool.c
diff --git
a/examples/ethtool/lib/rte_ethtool.c
b/examples/ethtool/lib/rte_ethtool.c
index
8393b0d
..
db8150e
100644
(file)
--- a/
examples/ethtool/lib/rte_ethtool.c
+++ b/
examples/ethtool/lib/rte_ethtool.c
@@
-314,10
+314,15
@@
rte_ethtool_net_stop(uint16_t port_id)
int
rte_ethtool_net_get_mac_addr(uint16_t port_id, struct rte_ether_addr *addr)
{
int
rte_ethtool_net_get_mac_addr(uint16_t port_id, struct rte_ether_addr *addr)
{
+ int ret;
+
RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
if (addr == NULL)
return -EINVAL;
RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
if (addr == NULL)
return -EINVAL;
- rte_eth_macaddr_get(port_id, addr);
+
+ ret = rte_eth_macaddr_get(port_id, addr);
+ if (ret != 0)
+ return ret;
return 0;
}
return 0;
}
@@
-397,7
+402,9
@@
rte_ethtool_net_set_rx_mode(uint16_t port_id)
}
/* Enable Rx vlan filter, VF unspport status is discard */
}
/* Enable Rx vlan filter, VF unspport status is discard */
- rte_eth_dev_set_vlan_offload(port_id, ETH_VLAN_FILTER_MASK);
+ ret = rte_eth_dev_set_vlan_offload(port_id, ETH_VLAN_FILTER_MASK);
+ if (ret != 0)
+ return ret;
return 0;
}
return 0;
}