mirror of
https://github.com/openvswitch/ovs
synced 2025-08-31 06:15:47 +00:00
netdev-dpdk: Return rx/tx queue sizes only for ETH devices.
'dev->requested_{rxq,txq}_size' and 'dev->{rxq,txq}_size' are
relevant only for DPDK_DEV_ETH devices and should be skipped
in 'netdev_dpdk_get_config()' for other ports.
CC: Ciara Loftus <ciara.loftus@intel.com>
Fixes: b685696b8c
("netdev-dpdk: Allow configurable queue sizes for 'dpdk' ports")
Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
This commit is contained in:
committed by
Daniele Di Proietto
parent
5dd57e80e6
commit
451f26fdce
@@ -1056,13 +1056,18 @@ netdev_dpdk_get_config(const struct netdev *netdev, struct smap *args)
|
||||
smap_add_format(args, "configured_rx_queues", "%d", netdev->n_rxq);
|
||||
smap_add_format(args, "requested_tx_queues", "%d", dev->requested_n_txq);
|
||||
smap_add_format(args, "configured_tx_queues", "%d", netdev->n_txq);
|
||||
smap_add_format(args, "requested_rxq_descriptors", "%d",
|
||||
dev->requested_rxq_size);
|
||||
smap_add_format(args, "configured_rxq_descriptors", "%d", dev->rxq_size);
|
||||
smap_add_format(args, "requested_txq_descriptors", "%d",
|
||||
dev->requested_txq_size);
|
||||
smap_add_format(args, "configured_txq_descriptors", "%d", dev->txq_size);
|
||||
smap_add_format(args, "mtu", "%d", dev->mtu);
|
||||
|
||||
if (dev->type == DPDK_DEV_ETH) {
|
||||
smap_add_format(args, "requested_rxq_descriptors", "%d",
|
||||
dev->requested_rxq_size);
|
||||
smap_add_format(args, "configured_rxq_descriptors", "%d",
|
||||
dev->rxq_size);
|
||||
smap_add_format(args, "requested_txq_descriptors", "%d",
|
||||
dev->requested_txq_size);
|
||||
smap_add_format(args, "configured_txq_descriptors", "%d",
|
||||
dev->txq_size);
|
||||
}
|
||||
ovs_mutex_unlock(&dev->mutex);
|
||||
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user