net/nfp: unify the queue threshold value

Message ID 20241218061745.1696899-1-chaoyong.he@corigine.com (mailing list archive)
State Accepted, archived
Delegated to: Stephen Hemminger
Headers
Series net/nfp: unify the queue threshold value |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/loongarch-compilation success Compilation OK
ci/loongarch-unit-testing success Unit Testing PASS
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/github-robot: build success github build: passed
ci/intel-Functional success Functional PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-marvell-Functional success Functional Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-unit-arm64-testing success Testing PASS
ci/iol-compile-arm64-testing success Testing PASS
ci/iol-unit-amd64-testing success Testing PASS
ci/iol-sample-apps-testing success Testing PASS
ci/iol-compile-amd64-testing success Testing PASS

Commit Message

Chaoyong He Dec. 18, 2024, 6:17 a.m. UTC
Make sure the Rx queue threshold value query by API
'rte_eth_rx_queue_info_get()' and 'rte_eth_dev_info_get()' unify.

Same for the Tx queue threshold value.

Signed-off-by: Chaoyong He <chaoyong.he@corigine.com>
Reviewed-by: Peng Zhang <peng.zhang@corigine.com>
---
 drivers/net/nfp/nfp_rxtx.c | 2 ++
 1 file changed, 2 insertions(+)
  

Patch

diff --git a/drivers/net/nfp/nfp_rxtx.c b/drivers/net/nfp/nfp_rxtx.c
index 35fb637b21..ad1eb21d2f 100644
--- a/drivers/net/nfp/nfp_rxtx.c
+++ b/drivers/net/nfp/nfp_rxtx.c
@@ -862,6 +862,7 @@  nfp_net_rx_queue_info_get(struct rte_eth_dev *dev,
 	nfp_net_infos_get(dev, &dev_info);
 	info->conf.offloads = dev_info.rx_offload_capa &
 			dev->data->dev_conf.rxmode.offloads;
+	info->conf.rx_thresh = dev_info.default_rxconf.rx_thresh;
 }
 
 void
@@ -883,6 +884,7 @@  nfp_net_tx_queue_info_get(struct rte_eth_dev *dev,
 	nfp_net_infos_get(dev, &dev_info);
 	info->conf.offloads = dev_info.tx_offload_capa &
 			dev->data->dev_conf.txmode.offloads;
+	info->conf.tx_thresh = dev_info.default_txconf.tx_thresh;
 }
 
 void