i40e: enlarge the number of supported queues
cover i40e: enlarge the number of supported queues
There was a software limitation of 64 queues, it should be enlarged to the hardware allowed maximum. As all the queues are shared among PF, VFs and VMDq, the number of queues supported in PF, VFs and VMDq may vary on different use cases.
Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queues
config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 146 ++++++++++++++++---------------------- drivers/net/i40e/i40e_ethdev.h | 8 +++ drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 5 files changed, 74 insertions(+), 88 deletions(-)
Signature · 1 line
1.9.3
PATCH 1/2 i40e: adjust the number of queues for RSS
It adjusts the number of queues for RSS from power of 2 to any as long as it does not exceeds the hardware allowed.
--- drivers/net/i40e/i40e_ethdev.c | 8 ++++---- drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/net/i40e/i40e_ethdev.c +4 -4
@@ -5153,12 +5153,12 @@ i40e_pf_config_rss(struct i40e_pf *pf)* If both VMDQ and RSS enabled, not all of PF queues are configured. * It's necessary to calulate the actual PF queues that are configured. */ -if (pf->dev_data->dev_conf.rxmode.mq_mode Ð_MQ_RX_VMDQ_FLAG ) { +if (pf->dev_data->dev_conf.rxmode.mq_mode Ð_MQ_RX_VMDQ_FLAG ) num =i40e_pf_calc_configured_queues_num (pf); - num =i40e_align_floor (num); - }else - num =i40e_align_floor (pf->dev_data->nb_rx_queues); +else + num = pf->dev_data->nb_rx_queues; + num =RTE_MIN (num,I40E_MAX_Q_PER_TC );PMD_INIT_LOG (INFO ,"Max of contiguous %u PF queues are configured" , num);
drivers/net/i40e/i40e_ethdev_vf.c +1 -1
@@ -1915,7 +1915,7 @@ i40evf_config_rss(struct i40e_vf *vf)return 0 ; } - num =i40e_align_floor (vf->dev_data->nb_rx_queues); + num =RTE_MIN (vf->dev_data->nb_rx_queues,I40E_MAX_QP_NUM_PER_VF );/* Fill out the look up table */ for (i =0 , j =0 ; i < nb_q; i++, j++) {if (j >= num)
Signature · 1 line
1.9.3
PATCH 2/2 i40e: Enlarge the number of supported queues
In reply to Helin ZhangIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
--- config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 138 +++++++++++++++++------------------------ drivers/net/i40e/i40e_ethdev.h | 8 +++ 4 files changed, 69 insertions(+), 83 deletions(-)
config/common_bsdapp +2 -1
@@ -141,7 +141,7 @@ CONFIG_RTE_LIBRTE_KVARGS=y CONFIG_RTE_LIBRTE_ETHER=y CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n CONFIG_RTE_MAX_ETHPORTS=32 -CONFIG_RTE_MAX_QUEUES_PER_PORT=256 +CONFIG_RTE_MAX_QUEUES_PER_PORT=1024 CONFIG_RTE_LIBRTE_IEEE1588=n CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16 CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
@@ -187,6 +187,7 @@ CONFIG_RTE_LIBRTE_I40E_DEBUG_TX_FREE=n CONFIG_RTE_LIBRTE_I40E_DEBUG_DRIVER=n CONFIG_RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC=y CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC=n +CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF=64 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF=4 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 # interval up to 8160 us, aligned to 2 (or default value)
config/common_linuxapp +2 -1
@@ -139,7 +139,7 @@ CONFIG_RTE_LIBRTE_KVARGS=y CONFIG_RTE_LIBRTE_ETHER=y CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n CONFIG_RTE_MAX_ETHPORTS=32 -CONFIG_RTE_MAX_QUEUES_PER_PORT=256 +CONFIG_RTE_MAX_QUEUES_PER_PORT=1024 CONFIG_RTE_LIBRTE_IEEE1588=n CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16 CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
@@ -185,6 +185,7 @@ CONFIG_RTE_LIBRTE_I40E_DEBUG_TX_FREE=n CONFIG_RTE_LIBRTE_I40E_DEBUG_DRIVER=n CONFIG_RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC=y CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC=n +CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF=64 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF=4 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 # interval up to 8160 us, aligned to 2 (or default value)
drivers/net/i40e/i40e_ethdev.c +57 -81
177 lines not on this page · raw message
drivers/net/i40e/i40e_ethdev.h +8 -0
@@ -370,10 +370,18 @@ struct i40e_pf {uint16_t vf_num;/* Each of below queue pairs should be power of 2 since it's the precondition after TC configuration applied */ +uint16_t lan_nb_qp_max;uint16_t lan_nb_qps;/* The number of queue pairs of LAN */ +uint16_t lan_qp_offset; +uint16_t vmdq_nb_qp_max;uint16_t vmdq_nb_qps;/* The number of queue pairs of VMDq */ +uint16_t vmdq_qp_offset; +uint16_t vf_nb_qp_max;uint16_t vf_nb_qps;/* The number of queue pairs of VF */ +uint16_t vf_qp_offset;uint16_t fdir_nb_qps;/* The number of queue pairs of Flow Director */ +uint16_t fdir_qp_offset; +uint16_t hash_lut_size;/* The size of hash lookup table */ /* store VXLAN UDP ports */ uint16_t vxlan_ports[I40E_MAX_PF_UDP_OFFLOAD_PORTS ];
Signature · 1 line
1.9.3
Re: [PATCH 2/2] i40e: Enlarge the number of supported queues
Hello Helin, Bruce,
Quoted 4 lines · Helin Zhang
It enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
I looked at the commit that introduced this limitation, can't we just get rid of this ?
The primary process should know the current max queue number and initialises the array properly before any secondary process tries to set any callback, or tries to call rx/tx functions.
Did I miss something ?
Signature · 1 line
David Marchand
Re: [PATCH 2/2] i40e: Enlarge the number of supported queues
Hi David
PF, VFs VMDq, FD on the same port share the queues, actually we can know the total number of the queues, the maximum number of queues may vary depends on how they will be used with PF, VF, VMDq AND FD. So the users will define the number for each, the code will just check the total number of them and make sure not exceed that.
Regards,
Helin
From: David Marchand [mailto:[email protected]]
Sent: Monday, September 21, 2015 3:42 PM
To: Zhang, Helin; Richardson, Bruce
Cc: [email protected]; Pei, Yulong
Subject: Re: [dpdk-dev] [PATCH 2/2] i40e: Enlarge the number of supported queues
Hello Helin, Bruce,
On Sun, Sep 20, 2015 at 4:51 PM, Helin Zhang <[email protected]<mailto:[email protected]>> wrote:
It enlarges the number of supported queues to hardware allowed
maximum. There was a software limitation of 64 per physical port
which is not reasonable.
I looked at the commit that introduced this limitation, can't we just get rid of this ?
The primary process should know the current max queue number and initialises the array properly before any secondary process tries to set any callback, or tries to call rx/tx functions. Did I miss something ?
--
David Marchand
Re: [PATCH 2/2] i40e: Enlarge the number of supported queues
In reply to David MarchandHi David
PF, VFs VMDq, FD on the same port share the queues, actually we can know the total number of the queues, the maximum number of queues may vary depends on how they will be used with PF, VF, VMDq AND FD. So the users will define the number for each, the code will just check the total number of them and make sure not exceed that.
Regards,
Helin
Note: just resend it with plain text format.
From: David Marchand [mailto:[email protected]]
Sent: Monday, September 21, 2015 3:42 PM
To: Zhang, Helin; Richardson, Bruce
Cc: [email protected]; Pei, Yulong
Subject: Re: [dpdk-dev] [PATCH 2/2] i40e: Enlarge the number of supported queues
Hello Helin, Bruce,
On Sun, Sep 20, 2015 at 4:51 PM, Helin Zhang <[email protected]> wrote:
It enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
I looked at the commit that introduced this limitation, can't we just get rid of this ?
The primary process should know the current max queue number and initialises the array properly before any secondary process tries to set any callback, or tries to call rx/tx functions. Did I miss something ?
Signature · 1 line
David Marchand
Re: [PATCH 2/2] i40e: Enlarge the number of supported queues
In reply to Helin ZhangHi, helin
Few comments
Quoted 26 lines
a/drivers/net/i40e/i40e_ethdev.cb/drivers/net/i40e/i40e_ethdev.cindex 4b70588..3bdcaa4 100644drivers/net/i40e/i40e_ethdev.c +1
-7@@ -2240,113 +2240,88 @@ i40e_pf_parameter_init(struct rte_eth_dev *dev) {struct i40e_pf *pf =I40E_DEV_PRIVATE_TO_PF (dev->data- >dev_private);struct i40e_hw *hw =I40E_PF_TO_HW (pf); -uint16_t sum_queues =0 , sum_vsis, left_queues; +uint16_t qp_count =0 , vsi_count =0 ; -/* First check if FW support SRIOV */ if (dev->pci_dev->max_vfs && !hw->func_caps.sr_iov_1_1) {PMD_INIT_LOG (ERR ,"HW configuration doesn't support SRIOV");return -EINVAL ; } pf->flags =I40E_FLAG_HEADER_SPLIT_DISABLED ; - pf->max_num_vsi =RTE_MIN (hw->func_caps.num_vsis, I40E_MAX_NUM_VSIS); -PMD_INIT_LOG (INFO ,"Max supported VSIs:%u" , pf->max_num_vsi); -/* Allocate queues for pf */ -if (hw->func_caps.rss) { - pf->flags |=I40E_FLAG_RSS ;
drivers/net/i40e/i40e_ethdev.c i40e_pf_parameter_init(struct rte_eth_dev · line 2259
Quoted 10 lines
drivers/net/i40e/i40e_ethdev.c +5
-4- pf->lan_nb_qps =RTE_MIN (hw->func_caps.num_tx_qp, - (uint32_t)(1 << hw- >func_caps.rss_table_entry_width)); - pf->lan_nb_qps =i40e_align_floor (pf->lan_nb_qps); - }else + pf->max_num_vsi = hw->func_caps.num_vsis; + pf->lan_nb_qp_max =RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF ; + pf->vmdq_nb_qp_max =RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM ; + pf->vf_nb_qp_max =RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF ; +
Need use the NUM_PER_VF but not NUM_PER_PFpf->vf_nb_qp_max = RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF; ==> pf->vf_nb_qp_max = RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF;
Re: [PATCH 2/2] i40e: Enlarge the number of supported queues
Quoted 42 lines
-----Original Message-----
From: Wu, Jingjing
Sent: Monday, October 19, 2015 4:30 PM
To: Zhang, Helin; [email protected]
Cc: Pei, Yulong; Liu, Yong
Subject: RE: [PATCH 2/2] i40e: Enlarge the number of supported queuesHi, helin
Few comments
Quoted 29 lines
a/drivers/net/i40e/i40e_ethdev.cb/drivers/net/i40e/i40e_ethdev.cindex
4b70588..3bdcaa4 100644drivers/net/i40e/i40e_ethdev.c +1
-9@@ -2240,113 +2240,88 @@ i40e_pf_parameter_init(struct rte_eth_dev *dev) {struct i40e_pf *pf =I40E_DEV_PRIVATE_TO_PF (dev->data- >dev_private);struct i40e_hw *hw =I40E_PF_TO_HW (pf); -uint16_t sum_queues =0 , sum_vsis, left_queues; +uint16_t qp_count =0 , vsi_count =0 ; -/* First check if FW support SRIOV */ if (dev->pci_dev->max_vfs && !hw->func_caps.sr_iov_1_1) {PMD_INIT_LOG (ERR ,"HW configuration doesn't support SRIOV" );return -EINVAL ; } pf->flags =I40E_FLAG_HEADER_SPLIT_DISABLED ; - pf->max_num_vsi =RTE_MIN (hw->func_caps.num_vsis, I40E_MAX_NUM_VSIS); -PMD_INIT_LOG (INFO ,"Max supported VSIs:%u" , pf->max_num_vsi); -/* Allocate queues for pf */ -if (hw->func_caps.rss) { - pf->flags |=I40E_FLAG_RSS ; - pf->lan_nb_qps =RTE_MIN (hw->func_caps.num_tx_qp, - (uint32_t)(1 << hw- >func_caps.rss_table_entry_width));
Quoted 10 lines
drivers/net/i40e/i40e_ethdev.c i40e_pf_parameter_init(struct rte_eth_dev *dev) · line 2255
Quoted 7 lines
drivers/net/i40e/i40e_ethdev.c +5
-2- pf->lan_nb_qps =i40e_align_floor (pf->lan_nb_qps); - }else + pf->max_num_vsi = hw->func_caps.num_vsis; + pf->lan_nb_qp_max =RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF ; + pf->vmdq_nb_qp_max =RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM ; + pf->vf_nb_qp_max =RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF ; +Need use the
NUM_PER_VFbut notNUM_PER_PFpf->vf_nb_qp_max= RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF; ==>pf->pf->vf_nb_qp_max=RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF;
Yes, you are right. Thank you very much!
I will correct it in the next version.
Helin
Quoted 1 line
v2 cover i40e: Enlarge the number of supported queues
In reply to Helin ZhangIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
v2 changes:
Fixed issues of using wrong configured number of VF queues.
Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queues
config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 146 ++++++++++++++++---------------------- drivers/net/i40e/i40e_ethdev.h | 8 +++ drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 5 files changed, 74 insertions(+), 88 deletions(-)
Signature · 1 line
1.9.3
PATCH v2 1/2 i40e: adjust the number of queues for RSS
It adjusts the number of queues for RSS from power of 2 to any as long as it does not exceeds the hardware allowed.
--- drivers/net/i40e/i40e_ethdev.c | 8 ++++---- drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/net/i40e/i40e_ethdev.c +4 -4
@@ -5153,12 +5153,12 @@ i40e_pf_config_rss(struct i40e_pf *pf)* If both VMDQ and RSS enabled, not all of PF queues are configured. * It's necessary to calulate the actual PF queues that are configured. */ -if (pf->dev_data->dev_conf.rxmode.mq_mode Ð_MQ_RX_VMDQ_FLAG ) { +if (pf->dev_data->dev_conf.rxmode.mq_mode Ð_MQ_RX_VMDQ_FLAG ) num =i40e_pf_calc_configured_queues_num (pf); - num =i40e_align_floor (num); - }else - num =i40e_align_floor (pf->dev_data->nb_rx_queues); +else + num = pf->dev_data->nb_rx_queues; + num =RTE_MIN (num,I40E_MAX_Q_PER_TC );PMD_INIT_LOG (INFO ,"Max of contiguous %u PF queues are configured" , num);
drivers/net/i40e/i40e_ethdev_vf.c +1 -1
@@ -1915,7 +1915,7 @@ i40evf_config_rss(struct i40e_vf *vf)return 0 ; } - num =i40e_align_floor (vf->dev_data->nb_rx_queues); + num =RTE_MIN (vf->dev_data->nb_rx_queues,I40E_MAX_QP_NUM_PER_VF );/* Fill out the look up table */ for (i =0 , j =0 ; i < nb_q; i++, j++) {if (j >= num)
Signature · 1 line
1.9.3
PATCH v2 2/2 i40e: Enlarge the number of supported queues
In reply to Helin ZhangIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
--- config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 138 +++++++++++++++++------------------------ drivers/net/i40e/i40e_ethdev.h | 8 +++ 4 files changed, 69 insertions(+), 83 deletions(-)
v2 changes:
Fixed issues of using wrong configured number of VF queues
config/common_bsdapp +2 -1
@@ -141,7 +141,7 @@ CONFIG_RTE_LIBRTE_KVARGS=y CONFIG_RTE_LIBRTE_ETHER=y CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n CONFIG_RTE_MAX_ETHPORTS=32 -CONFIG_RTE_MAX_QUEUES_PER_PORT=256 +CONFIG_RTE_MAX_QUEUES_PER_PORT=1024 CONFIG_RTE_LIBRTE_IEEE1588=n CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16 CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
@@ -187,6 +187,7 @@ CONFIG_RTE_LIBRTE_I40E_DEBUG_TX_FREE=n CONFIG_RTE_LIBRTE_I40E_DEBUG_DRIVER=n CONFIG_RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC=y CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC=n +CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF=64 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF=4 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 # interval up to 8160 us, aligned to 2 (or default value)
config/common_linuxapp +2 -1
@@ -139,7 +139,7 @@ CONFIG_RTE_LIBRTE_KVARGS=y CONFIG_RTE_LIBRTE_ETHER=y CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n CONFIG_RTE_MAX_ETHPORTS=32 -CONFIG_RTE_MAX_QUEUES_PER_PORT=256 +CONFIG_RTE_MAX_QUEUES_PER_PORT=1024 CONFIG_RTE_LIBRTE_IEEE1588=n CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16 CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
@@ -185,6 +185,7 @@ CONFIG_RTE_LIBRTE_I40E_DEBUG_TX_FREE=n CONFIG_RTE_LIBRTE_I40E_DEBUG_DRIVER=n CONFIG_RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC=y CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC=n +CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF=64 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF=4 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 # interval up to 8160 us, aligned to 2 (or default value)
drivers/net/i40e/i40e_ethdev.c +57 -81
177 lines not on this page · raw message
drivers/net/i40e/i40e_ethdev.h +8 -0
@@ -370,10 +370,18 @@ struct i40e_pf {uint16_t vf_num;/* Each of below queue pairs should be power of 2 since it's the precondition after TC configuration applied */ +uint16_t lan_nb_qp_max;uint16_t lan_nb_qps;/* The number of queue pairs of LAN */ +uint16_t lan_qp_offset; +uint16_t vmdq_nb_qp_max;uint16_t vmdq_nb_qps;/* The number of queue pairs of VMDq */ +uint16_t vmdq_qp_offset; +uint16_t vf_nb_qp_max;uint16_t vf_nb_qps;/* The number of queue pairs of VF */ +uint16_t vf_qp_offset;uint16_t fdir_nb_qps;/* The number of queue pairs of Flow Director */ +uint16_t fdir_qp_offset; +uint16_t hash_lut_size;/* The size of hash lookup table */ /* store VXLAN UDP ports */ uint16_t vxlan_ports[I40E_MAX_PF_UDP_OFFLOAD_PORTS ];
Signature · 1 line
1.9.3
Re: [PATCH v2 0/2] i40e: Enlarge the number of supported queues
In reply to Helin ZhangQuoted 27 lines
-----Original Message-----
From: Zhang, Helin
Sent: Thursday, October 22, 2015 3:28 PM
To: [email protected]
Cc: Pei, Yulong; Liu, Yong; Wu, Jingjing; Zhang, Helin
Subject: [PATCH v2 0/2] i40e: Enlarge the number of supported queuesIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
v2 changes:
Fixed issues of using wrong configured number of VF queues.Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queuesconfig/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 146 ++++++++++++++++---------------------- drivers/net/i40e/i40e_ethdev.h | 8 +++ drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 5 files changed, 74 insertions(+), 88 deletions(-)
Quoted 2 lines
--
1.9.3
Re: [PATCH v2 2/2] i40e: Enlarge the number of supported queues
In reply to Helin Zhang2015-10-22 15:28, Helin Zhang:
Quoted 10 lines
It enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
Signed-off-by Helin Zhang <[email protected]>--- config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 138 +++++++++++++++++------------------------ drivers/net/i40e/i40e_ethdev.h | 8 +++
Please update the release notes (remove deprecation notice and add ABI change).
Re: [PATCH v2 2/2] i40e: Enlarge the number of supported queues
Quoted 20 lines
-----Original Message-----
From: Thomas Monjalon [mailto:[email protected]]
Sent: Tuesday, November 3, 2015 9:17 AM
To: Zhang, Helin
Cc: [email protected]; Pei, Yulong
Subject: Re: [dpdk-dev] [PATCH v2 2/2] i40e: Enlarge the number of supported queues2015-10-22 15:28, Helin Zhang:
Quoted 9 lines
It enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
Signed-off-by Helin Zhang <[email protected]>--- config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- drivers/net/i40e/i40e_ethdev.c | 138
Quoted 5 lines
+++++++++++++++++------------------------
Quoted 1 line
drivers/net/i40e/i40e_ethdev.h | 8 +++Please update the release notes (remove deprecation notice and add ABI change).
OK. Sorry for the missing! Thank you very much for the reminder!
Regards,
Helin
PATCH v3 1/2 i40e: adjust the number of queues for RSS
In reply to Helin ZhangIt adjusts the number of queues for RSS from power of 2 to any as long as it does not exceeds the hardware allowed.
--- drivers/net/i40e/i40e_ethdev.c | 8 ++++---- drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/net/i40e/i40e_ethdev.c +4 -4
@@ -5729,12 +5729,12 @@ i40e_pf_config_rss(struct i40e_pf *pf)* If both VMDQ and RSS enabled, not all of PF queues are configured. * It's necessary to calulate the actual PF queues that are configured. */ -if (pf->dev_data->dev_conf.rxmode.mq_mode Ð_MQ_RX_VMDQ_FLAG ) { +if (pf->dev_data->dev_conf.rxmode.mq_mode Ð_MQ_RX_VMDQ_FLAG ) num =i40e_pf_calc_configured_queues_num (pf); - num =i40e_align_floor (num); - }else - num =i40e_align_floor (pf->dev_data->nb_rx_queues); +else + num = pf->dev_data->nb_rx_queues; + num =RTE_MIN (num,I40E_MAX_Q_PER_TC );PMD_INIT_LOG (INFO ,"Max of contiguous %u PF queues are configured" , num);
drivers/net/i40e/i40e_ethdev_vf.c +1 -1
@@ -2169,7 +2169,7 @@ i40evf_config_rss(struct i40e_vf *vf)return 0 ; } - num =i40e_align_floor (vf->dev_data->nb_rx_queues); + num =RTE_MIN (vf->dev_data->nb_rx_queues,I40E_MAX_QP_NUM_PER_VF );/* Fill out the look up table */ for (i =0 , j =0 ; i < nb_q; i++, j++) {if (j >= num)
Signature · 1 line
1.9.3
v3 cover i40e: Enlarge the number of supported queues
In reply to Helin ZhangIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
v2 changes:
Fixed issues of using wrong configured number of VF queues.
v3 changes:
Updated release notes.
Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queues
config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- doc/guides/rel_notes/deprecation.rst | 5 -- doc/guides/rel_notes/release_2_2.rst | 12 +++ drivers/net/i40e/i40e_ethdev.c | 146 +++++++++++++++-------------------- drivers/net/i40e/i40e_ethdev.h | 8 ++ drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 7 files changed, 86 insertions(+), 93 deletions(-)
Signature · 1 line
1.9.3
PATCH v3 2/2 i40e: Enlarge the number of supported queues
It enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
--- config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- doc/guides/rel_notes/deprecation.rst | 5 -- doc/guides/rel_notes/release_2_2.rst | 12 +++ drivers/net/i40e/i40e_ethdev.c | 138 +++++++++++++++-------------------- drivers/net/i40e/i40e_ethdev.h | 8 ++ 6 files changed, 81 insertions(+), 88 deletions(-)
v2 changes:
Fixed issues of using wrong configured number of VF queues.
v3 changes:
Updated release notes.
config/common_bsdapp +2 -1
@@ -141,7 +141,7 @@ CONFIG_RTE_LIBRTE_KVARGS=y CONFIG_RTE_LIBRTE_ETHER=y CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n CONFIG_RTE_MAX_ETHPORTS=32 -CONFIG_RTE_MAX_QUEUES_PER_PORT=256 +CONFIG_RTE_MAX_QUEUES_PER_PORT=1024 CONFIG_RTE_LIBRTE_IEEE1588=n CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16 CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
@@ -189,6 +189,7 @@ CONFIG_RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC=y CONFIG_RTE_LIBRTE_I40E_INC_VECTOR=y CONFIG_RTE_LIBRTE_I40E_RX_OLFLAGS_ENABLE=y CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC=n +CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF=64 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF=4 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 # interval up to 8160 us, aligned to 2 (or default value)
config/common_linuxapp +2 -1
@@ -139,7 +139,7 @@ CONFIG_RTE_LIBRTE_KVARGS=y CONFIG_RTE_LIBRTE_ETHER=y CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n CONFIG_RTE_MAX_ETHPORTS=32 -CONFIG_RTE_MAX_QUEUES_PER_PORT=256 +CONFIG_RTE_MAX_QUEUES_PER_PORT=1024 CONFIG_RTE_LIBRTE_IEEE1588=n CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16 CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
@@ -187,6 +187,7 @@ CONFIG_RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC=y CONFIG_RTE_LIBRTE_I40E_INC_VECTOR=y CONFIG_RTE_LIBRTE_I40E_RX_OLFLAGS_ENABLE=y CONFIG_RTE_LIBRTE_I40E_16BYTE_RX_DESC=n +CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF=64 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF=4 CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 # interval up to 8160 us, aligned to 2 (or default value)
doc/guides/rel_notes/deprecation.rst +0 -5
@@ -8,11 +8,6 @@ API and ABI deprecation notices are to be posted here. Deprecation Notices ------------------- -* Significant ABI changes are planned for struct rte_eth_dev to support up to - 1024 queues per port. This change will be in release 2.2. - There is no backward compatibility planned from release 2.2. - All binaries will need to be rebuilt from release 2.2. - * The following fields have been deprecated in rte_eth_stats: ibadcrc, ibadlen, imcasts, fdirmatch, fdirmiss, tx_pause_xon, rx_pause_xon, tx_pause_xoff, rx_pause_xoff
doc/guides/rel_notes/release_2_2.rst +12 -0
@@ -116,6 +116,13 @@ Drivers Fixed i40e issue that occurred when a DPDK application didn't initialize ports if memory wasn't available on socket 0. +* **i40e: Fixed issue of cannot supporting more than 64 queues per port.** + + Fixed the issue in i40e of cannot supporting more than 64 queues per port, + though hardware actually supports that. The real number of queues may vary, + as long as the total number of queues used in PF, VFs, VMDq and FD does not + exceeds the hardware maximum. + * **vhost: Fixed Qemu shutdown.** Fixed issue with libvirt ``virsh destroy`` not killing the VM.
@@ -205,6 +212,11 @@ ABI Changes * librte_cfgfile: Allow longer names and values by increasing the constants CFG_NAME_LEN and CFG_VALUE_LEN to 64 and 256 respectively. +* i40e: From 2.2, enlarge the maximum number of queues per port by increasing + the config parameter of CONFIG_RTE_MAX_QUEUES_PER_PORT to 1024. Also an new + config parameter of CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF will be added to + configure the maximum number of queues per PF. + Shared Library Versions -----------------------
drivers/net/i40e/i40e_ethdev.c +57 -81
182 lines not on this page · raw message
drivers/net/i40e/i40e_ethdev.h +8 -0
@@ -402,10 +402,18 @@ struct i40e_pf {uint16_t vf_num;/* Each of below queue pairs should be power of 2 since it's the precondition after TC configuration applied */ +uint16_t lan_nb_qp_max;uint16_t lan_nb_qps;/* The number of queue pairs of LAN */ +uint16_t lan_qp_offset; +uint16_t vmdq_nb_qp_max;uint16_t vmdq_nb_qps;/* The number of queue pairs of VMDq */ +uint16_t vmdq_qp_offset; +uint16_t vf_nb_qp_max;uint16_t vf_nb_qps;/* The number of queue pairs of VF */ +uint16_t vf_qp_offset;uint16_t fdir_nb_qps;/* The number of queue pairs of Flow Director */ +uint16_t fdir_qp_offset; +uint16_t hash_lut_size;/* The size of hash lookup table */ /* store VXLAN UDP ports */ uint16_t vxlan_ports[I40E_MAX_PF_UDP_OFFLOAD_PORTS ];
Signature · 1 line
1.9.3
Thomas Monjalon
AppliedRe: [PATCH v3 0/2] i40e: Enlarge the number of supported queues
In reply to Helin Zhang2015-11-03 23:40, Helin Zhang:
Quoted 6 lines
It enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
v2 changes:
Fixed issues of using wrong configured number of VF queues.
Quoted 6 lines
v3 changes:
Updated release notes.Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queues
Applied, thanks
Re: [PATCH v3 0/2] i40e: Enlarge the number of supported queues
In reply to Helin ZhangQuoted 9 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Helin Zhang
Sent: Tuesday, November 3, 2015 3:40 PM
To: [email protected]
Subject: [dpdk-dev] [PATCH v3 0/2] i40e: Enlarge the number of supported queuesIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not reasonable.
Hi Helin,
Is the layout of the queues and how CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF affects them documented?
I'm wondering if I increase CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF to more than 64 queue, will they be contiguous? For example, if I increase to 128 will I be able to use queues 0-127, or there will there be gaps for queues reserved for VMDQ etc.
Kevin.
Quoted 23 lines
v2 changes:
Fixed issues of using wrong configured number of VF queues.v3 changes:
Updated release notes.Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queuesconfig/common_bsdapp | 3 +- config/common_linuxapp | 3 +- doc/guides/rel_notes/deprecation.rst | 5 -- doc/guides/rel_notes/release_2_2.rst | 12 +++ drivers/net/i40e/i40e_ethdev.c | 146 +++++++++++++++------------------ -- drivers/net/i40e/i40e_ethdev.h | 8 ++ drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 7 files changed, 86 insertions(+), 93 deletions(-)--
1.9.3
Re: [PATCH v3 0/2] i40e: Enlarge the number of supported queues
Quoted 18 lines
-----Original Message-----
From: Traynor, Kevin
Sent: Wednesday, November 4, 2015 10:54 PM
To: Zhang, Helin; [email protected]
Subject: RE: [dpdk-dev] [PATCH v3 0/2] i40e: Enlarge the number of supported queuesQuoted 9 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Helin Zhang
Sent: Tuesday, November 3, 2015 3:40 PM
To: [email protected]
Subject: [dpdk-dev] [PATCH v3 0/2] i40e: Enlarge the number of supported queuesIt enlarges the number of supported queues to hardware allowed maximum. There was a software limitation of 64 per physical port which is not
Quoted 7 lines
reasonable.
Hi Helin,
Is the layout of the queues and how
CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF
affects them documented?
Its name is quite straight forward, this is the number of queue user allowed in a PF.
Quoted 5 lines
I'm wondering if I increase
CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_PFto more than 64 queue, will they be contiguous? For example, if I increase to 128 will I be able to use queues 0-127, or there will there be gaps for queues reserved for VMDQ etc.
0 is reserved for FD, so 1-128 is for your case.
Regards,
Helin
Quoted 27 lines
Kevin.
Quoted 11 lines
v2 changes:
Fixed issues of using wrong configured number of VF queues.v3 changes:
Updated release notes.Helin Zhang (2):
i40e: adjust the number of queues for RSS
i40e: Enlarge the number of supported queuesQuoted 5 lines
config/common_bsdapp | 3 +- config/common_linuxapp | 3 +- doc/guides/rel_notes/deprecation.rst | 5 -- doc/guides/rel_notes/release_2_2.rst | 12 +++ drivers/net/i40e/i40e_ethdev.c | 146+++++++++++++++------------------
Quoted 7 lines
--
drivers/net/i40e/i40e_ethdev.h | 8 ++ drivers/net/i40e/i40e_ethdev_vf.c | 2 +- 7 files changed, 86 insertions(+), 93 deletions(-)--
1.9.3