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
vdpa/mlx5: set default queue indices
[dpdk.git]
/
app
/
pdump
/
main.c
diff --git
a/app/pdump/main.c
b/app/pdump/main.c
index
c1b9012
..
d05a023
100644
(file)
--- a/
app/pdump/main.c
+++ b/
app/pdump/main.c
@@
-595,7
+595,7
@@
configure_vdev(uint16_t port_id)
if (ret != 0)
rte_exit(EXIT_FAILURE, "dev config failed\n");
if (ret != 0)
rte_exit(EXIT_FAILURE, "dev config failed\n");
-
for (q = 0; q < txRings; q++) {
+ for (q = 0; q < txRings; q++) {
ret = rte_eth_tx_queue_setup(port_id, q, TX_DESC_PER_QUEUE,
rte_eth_dev_socket_id(port_id), NULL);
if (ret < 0)
ret = rte_eth_tx_queue_setup(port_id, q, TX_DESC_PER_QUEUE,
rte_eth_dev_socket_id(port_id), NULL);
if (ret < 0)
@@
-606,7
+606,10
@@
configure_vdev(uint16_t port_id)
if (ret < 0)
rte_exit(EXIT_FAILURE, "dev start failed\n");
if (ret < 0)
rte_exit(EXIT_FAILURE, "dev start failed\n");
- rte_eth_macaddr_get(port_id, &addr);
+ ret = rte_eth_macaddr_get(port_id, &addr);
+ if (ret != 0)
+ rte_exit(EXIT_FAILURE, "macaddr get failed\n");
+
printf("Port %u MAC: %02"PRIx8" %02"PRIx8" %02"PRIx8
" %02"PRIx8" %02"PRIx8" %02"PRIx8"\n",
port_id,
printf("Port %u MAC: %02"PRIx8" %02"PRIx8" %02"PRIx8
" %02"PRIx8" %02"PRIx8" %02"PRIx8"\n",
port_id,
@@
-614,7
+617,13
@@
configure_vdev(uint16_t port_id)
addr.addr_bytes[2], addr.addr_bytes[3],
addr.addr_bytes[4], addr.addr_bytes[5]);
addr.addr_bytes[2], addr.addr_bytes[3],
addr.addr_bytes[4], addr.addr_bytes[5]);
- rte_eth_promiscuous_enable(port_id);
+ ret = rte_eth_promiscuous_enable(port_id);
+ if (ret != 0) {
+ rte_exit(EXIT_FAILURE,
+ "promiscuous mode enable failed: %s\n",
+ rte_strerror(-ret));
+ return ret;
+ }
return 0;
}
return 0;
}