[dpdk-dev] [RFC PATCH 1/3] librte_ether: VF max queue number setting
Wenzhuo Lu
wenzhuo.lu at intel.com
Mon Jul 31 21:27:18 CEST 2017
Add a global variable to set the max queue number per VF.
This variable is only valid on PF.
Signed-off-by: Wenzhuo Lu <wenzhuo.lu at intel.com>
---
lib/librte_ether/rte_ethdev.c | 3 +++
lib/librte_ether/rte_ethdev.h | 2 ++
2 files changed, 5 insertions(+)
diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c
index d4ebb1b..9d3e650 100644
--- a/lib/librte_ether/rte_ethdev.c
+++ b/lib/librte_ether/rte_ethdev.c
@@ -138,6 +138,9 @@ enum {
STAT_QMAP_RX
};
+/**< Max queue number per VF, only valid on PF port. */
+uint32_t g_max_queue_number_per_vf = 4;
+
uint8_t
rte_eth_find_next(uint8_t port_id)
{
diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index 0e99090..1c3f668 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -1091,6 +1091,8 @@ struct rte_eth_dcb_info {
/**< l2 tunnel forwarding mask */
#define ETH_L2_TUNNEL_FORWARDING_MASK 0x00000008
+extern uint32_t g_max_queue_number_per_vf;
+
/*
* Definitions of all functions exported by an Ethernet driver through the
* the generic structure of type *eth_dev_ops* supplied in the *rte_eth_dev*
--
1.9.3
More information about the dev
mailing list