net/i40e/vf: reset scatter_rx flag when configuration complies
PATCH 1/1 net/i40e/vf: reset scatter_rx flag when configuration complies
From: Eduard Serra <[email protected]>
Scatter RX (scattered_rx) flag is currently not being resetted when new configuration is suplied to reconfigure a port, rendering the rx callback logic to always fall through the scatter branch.
--- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ drivers/net/i40e/i40e_rxtx.c | 2 ++ 2 files changed, 4 insertions(+)
drivers/net/i40e/i40e_ethdev_vf.c +2 -0
@@ -1750,6 +1750,8 @@ i40evf_rxq_init(struct rte_eth_dev *dev, struct i40e_rx_queue *rxq)if (dev_data->dev_conf.rxmode.enable_scatter || (rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ; }return 0 ;
drivers/net/i40e/i40e_rxtx.c +2 -0
@@ -2561,6 +2561,8 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)/* Check if scattered RX needs to be used. */ if ((rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ; }/* Init the RX tail regieter. */
Signature · 1 line
2.7.4
Hi Serra:
Quoted 8 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Friday, March 30, 2018 4:13 AM
To: Zhang, Qi Z <[email protected]>
Cc: [email protected]; Eduard Serra <[email protected]>
Subject: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration complies
Quoted 4 lines
From: Eduard Serra <[email protected]>
Scatter RX (
scattered_rx) flag is currently not being resetted when new configuration is suplied to reconfigure a port, rendering the rx callback logic to
s/suplied/supplied
Quoted 14 lines
always fall through the scatter branch.
Signed-off-by Eduard Serra <[email protected]>--- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ drivers/net/i40e/i40e_rxtx.c | 2 ++ 2 files changed, 4 insertions(+)drivers/net/i40e/i40e_ethdev_vf.c +0
-0
drivers/net/i40e/i40e_ethdev_vf.c i40evf_rxq_init(struct rte_eth_dev *dev, struct · line 1755
Quoted 6 lines
drivers/net/i40e/i40e_ethdev_vf.c +2
-0@@ -1750,6 +1750,8 @@ i40evf_rxq_init(struct rte_eth_dev *dev, struct i40e_rx_queue *rxq)if (dev_data->dev_conf.rxmode.enable_scatter || (rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;
Scattered_rx should not be reset if any queue already required You should reset it before the queue loop
drivers/net/i40e/i40e_rxtx.c i40e_rx_queue_init(struct i40e_rx_queue *rxq) · line 2565
Quoted 13 lines
drivers/net/i40e/i40e_ethdev_vf.c +0
-0}drivers/net/i40e/i40e_ethdev_vf.c +0
-0return 0 ;drivers/net/i40e/i40e_rxtx.c index renamed from drivers/net/i40e/i40e_rxtx.c +0
-01217e5a..8698747 100644
drivers/net/i40e/i40e_rxtx.c +2
-0@@ -2561,6 +2561,8 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)/* Check if scattered RX needs to be used. */ if ((rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;
Same as above.
Regards
Qi
Quoted 5 lines
drivers/net/i40e/i40e_rxtx.c +0
-1}/* Init the RX tail regieter. */ --2.7.4
Quoted 36 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Zhang, Qi Z
Sent: Monday, April 2, 2018 8:14 PM
To: [email protected]
Cc: [email protected]
Subject: Re: [dpdk-dev] [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesHi Serra:
Quoted 8 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Friday, March 30, 2018 4:13 AM
To: Zhang, Qi Z <[email protected]>
Cc: [email protected]; Eduard Serra <[email protected]>
Subject: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesQuoted 5 lines
From: Eduard Serra <[email protected]>
Scatter RX (
scattered_rx) flag is currently not being resetted when new configuration is suplied to reconfigure a port, rendering the rx callback logic tos/suplied/supplied
Quoted 8 lines
always fall through the scatter branch.
Signed-off-by Eduard Serra <[email protected]>--- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ drivers/net/i40e/i40e_rxtx.c | 2 ++ 2 files changed, 4 insertions(+)
Quoted 15 lines
drivers/net/i40e/i40e_ethdev_vf.c i40evf_rxq_init(struct rte_eth_dev *dev, struct · line 1755
Quoted 12 lines
drivers/net/i40e/i40e_ethdev_vf.c +2
-0@@ -1750,6 +1750,8 @@ i40evf_rxq_init(struct rte_eth_dev *dev, struct i40e_rx_queue *rxq)if (dev_data->dev_conf.rxmode.enable_scatter || (rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;
Scattered_rxshould not be reset if any queue already required You should reset it before the queue loop
Does it mean a NACK?
/Helin
Quoted 26 lines
Quoted 10 lines
drivers/net/i40e/i40e_ethdev_vf.c +0
-0}drivers/net/i40e/i40e_ethdev_vf.c +0
-0return 0 ;(quoted diff) +0
-0
b/drivers/net/i40e/i40e_rxtx.cindex
1217e5a..8698747 100644drivers/net/i40e/i40e_rxtx.c i40e_rx_queue_init(struct i40e_rx_queue *rxq) · line 2565
Quoted 5 lines
drivers/net/i40e/i40e_rxtx.c +2
-0@@ -2561,6 +2561,8 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)/* Check if scattered RX needs to be used. */ if ((rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;Same as above.
Regards
QiQuoted 5 lines
drivers/net/i40e/i40e_rxtx.c +0
-1}/* Init the RX tail regieter. */ --2.7.4
Quoted 61 lines
-----Original Message-----
From: Zhang, Helin
Sent: Friday, April 6, 2018 4:46 PM
To: Zhang, Qi Z; [email protected]
Cc: [email protected]
Subject: RE: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesQuoted 34 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Zhang, Qi Z
Sent: Monday, April 2, 2018 8:14 PM
To: [email protected]
Cc: [email protected]
Subject: Re: [dpdk-dev] [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesHi Serra:
Quoted 8 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Friday, March 30, 2018 4:13 AM
To: Zhang, Qi Z <[email protected]>
Cc: [email protected]; Eduard Serra <[email protected]>
Subject: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesQuoted 5 lines
From: Eduard Serra <[email protected]>
Scatter RX (
scattered_rx) flag is currently not being resetted when new configuration is suplied to reconfigure a port, rendering the rx callback logic tos/suplied/supplied
Quoted 8 lines
always fall through the scatter branch.
Signed-off-by Eduard Serra <[email protected]>--- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ drivers/net/i40e/i40e_rxtx.c | 2 ++ 2 files changed, 4 insertions(+)Quoted 15 lines
drivers/net/i40e/i40e_ethdev_vf.c i40evf_rxq_init(struct rte_eth_dev *dev, · line 1755
Quoted 12 lines
drivers/net/i40e/i40e_ethdev_vf.c +2
-0@@ -1750,6 +1750,8 @@ i40evf_rxq_init(struct rte_eth_dev *dev, struct i40e_rx_queue *rxq)if (dev_data->dev_conf.rxmode.enable_scatter || (rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;
Scattered_rxshould not be reset if any queue already required You should reset it before the queue loop
Quoted 3 lines
Does it mean a NACK?
/Helin
Anyway, please fix the checkpatch warnings reported on patchwork. Thanks!
/Helin
Quoted 27 lines
Quoted 27 lines
Quoted 11 lines
drivers/net/i40e/i40e_ethdev_vf.c +0
-0}drivers/net/i40e/i40e_ethdev_vf.c +0
-0return 0 ;(quoted diff) +0
-0
b/drivers/net/i40e/i40e_rxtx.cindex
1217e5a..8698747 100644drivers/net/i40e/i40e_rxtx.c i40e_rx_queue_init(struct i40e_rx_queue *rxq) · line 2565
Quoted 5 lines
drivers/net/i40e/i40e_rxtx.c +2
-0@@ -2561,6 +2561,8 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)/* Check if scattered RX needs to be used. */ if ((rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;Same as above.
Regards
QiQuoted 5 lines
drivers/net/i40e/i40e_rxtx.c +0
-1}/* Init the RX tail regieter. */ --2.7.4
Quoted 72 lines
-----Original Message-----
From: Zhang, Helin
Sent: Friday, April 6, 2018 11:54 PM
To: Zhang, Qi Z <[email protected]>; [email protected]
Cc: [email protected]
Subject: RE: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesQuoted 60 lines
-----Original Message-----
From: Zhang, Helin
Sent: Friday, April 6, 2018 4:46 PM
To: Zhang, Qi Z; [email protected]
Cc: [email protected]
Subject: RE: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesQuoted 34 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Zhang, Qi Z
Sent: Monday, April 2, 2018 8:14 PM
To: [email protected]
Cc: [email protected]
Subject: Re: [dpdk-dev] [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesHi Serra:
Quoted 8 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Friday, March 30, 2018 4:13 AM
To: Zhang, Qi Z <[email protected]>
Cc: [email protected]; Eduard Serra <[email protected]>
Subject: [PATCH]net/i40e/vf: resetscatter_rxflag when configuration compliesQuoted 5 lines
From: Eduard Serra <[email protected]>
Scatter RX (
scattered_rx) flag is currently not being resetted when new configuration is suplied to reconfigure a port, rendering the rx callback logic tos/suplied/supplied
Quoted 8 lines
always fall through the scatter branch.
Signed-off-by Eduard Serra <[email protected]>--- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ drivers/net/i40e/i40e_rxtx.c | 2 ++ 2 files changed, 4 insertions(+)Quoted 15 lines
drivers/net/i40e/i40e_ethdev_vf.c i40evf_rxq_init(struct rte_eth_dev *dev, · line 1755
Quoted 12 lines
drivers/net/i40e/i40e_ethdev_vf.c +2
-0@@ -1750,6 +1750,8 @@ i40evf_rxq_init(struct rte_eth_dev *dev, struct i40e_rx_queue *rxq)if (dev_data->dev_conf.rxmode.enable_scatter || (rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;
Scattered_rxshould not be reset if any queue already required You should reset it before the queue loopDoes it mean a NACK?
Yes the fix is not correct.
Quoted 32 lines
Quoted 2 lines
/Helin
Anyway, please fix the checkpatch warnings reported on patchwork. Thanks!
/Helin
Quoted 27 lines
Quoted 27 lines
Quoted 11 lines
drivers/net/i40e/i40e_ethdev_vf.c +0
-0}drivers/net/i40e/i40e_ethdev_vf.c +0
-0return 0 ;(quoted diff) +0
-0
b/drivers/net/i40e/i40e_rxtx.cindex
1217e5a..8698747 100644drivers/net/i40e/i40e_rxtx.c i40e_rx_queue_init(struct i40e_rx_queue *rxq) · line 2565
Quoted 5 lines
drivers/net/i40e/i40e_rxtx.c +2
-0@@ -2561,6 +2561,8 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)/* Check if scattered RX needs to be used. */ if ((rxq->max_pkt_len +2 *I40E_VLAN_TAG_SIZE ) > buf_size) { dev_data->scattered_rx =1 ; + }else { + dev_data->scattered_rx =0 ;Same as above.
Regards
QiQuoted 5 lines
drivers/net/i40e/i40e_rxtx.c +0
-1}/* Init the RX tail regieter. */ --2.7.4