From 0f72e563a2398f07abc237b253ff24040dbdc133 Mon Sep 17 00:00:00 2001 From: Intel Date: Mon, 3 Jun 2013 00:00:00 +0000 Subject: [PATCH] ethdev: add PF support Signed-off-by: Intel --- lib/librte_ether/rte_ethdev.h | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h index 64a2d57c61..a1c898af22 100644 --- a/lib/librte_ether/rte_ethdev.h +++ b/lib/librte_ether/rte_ethdev.h @@ -356,8 +356,10 @@ enum rte_eth_nb_tcs { * in VMDQ+DCB configurations. */ enum rte_eth_nb_pools { + ETH_8_POOLS = 8, /**< 8 pools with DCB. */ ETH_16_POOLS = 16, /**< 16 pools with DCB. */ - ETH_32_POOLS = 32 /**< 32 pools with DCB. */ + ETH_32_POOLS = 32, /**< 32 pools with DCB. */ + ETH_64_POOLS = 64 /**< 32 pools with DCB. */ }; /* This structure may be extended in future. */ @@ -931,6 +933,14 @@ struct rte_eth_dev { struct rte_eth_dev_cb_list callbacks; /**< User application callbacks */ }; +struct rte_eth_dev_sriov { + uint8_t active; /**< SRIOV is active with 16, 32 or 64 pools */ + uint8_t nb_q_per_pool; /**< rx queue number per pool */ + uint16_t def_vmdq_idx; /**< Default pool num used for PF */ + uint16_t def_pool_q_idx; /**< Default pool queue start reg index */ +}; +#define RTE_ETH_DEV_SRIOV(dev) ((dev)->data->sriov) + /** * @internal * The data part, with no function pointers, associated with each ethernet device. @@ -943,6 +953,8 @@ struct rte_eth_dev_data { void **tx_queues; /**< Array of pointers to TX queues. */ uint16_t nb_rx_queues; /**< Number of RX queues. */ uint16_t nb_tx_queues; /**< Number of TX queues. */ + + struct rte_eth_dev_sriov sriov; /**< SRIOV data */ void *dev_private; /**< PMD-specific private data */ -- 2.20.1