diff mbox series

[iwl-net,v1] ice: don't stop netdev tx queues when setting up XSK socket

Message ID 20230908113101.153591-1-kamil.maziarz@intel.com
State Changes Requested
Headers show
Series [iwl-net,v1] ice: don't stop netdev tx queues when setting up XSK socket | expand

Commit Message

Kamil Maziarz Sept. 8, 2023, 11:31 a.m. UTC
Avoid stopping netdev  tx queues during XSK setup by removing
netif_tx_stop_queue() and netif_tx_start_queue(). These changes
prevent unnecessary stopping and starting of netdev transmit queues
during the setup of XDP socket. Without this change, after stopping
the XDP traffic flow tracker and then stopping the XDP prog - NETDEV
WATCHDOG transmit queue timed out appears.

Signed-off-by: Kamil Maziarz <kamil.maziarz@intel.com>
Signed-off-by: Piotr Raczynski <piotr.raczynski@intel.com>
---
 drivers/net/ethernet/intel/ice/ice_xsk.c | 2 --
 1 file changed, 2 deletions(-)

Comments

Wojciech Drewek Sept. 8, 2023, 11:36 a.m. UTC | #1
> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@osuosl.org> On Behalf Of Kamil
> Maziarz
> Sent: Friday, September 8, 2023 1:31 PM
> To: intel-wired-lan@lists.osuosl.org
> Cc: Maziarz, Kamil <kamil.maziarz@intel.com>
> Subject: [Intel-wired-lan] [PATCH iwl-net v1] ice: don't stop netdev tx queues
> when setting up XSK socket
> 
> Avoid stopping netdev  tx queues during XSK setup by removing
> netif_tx_stop_queue() and netif_tx_start_queue(). These changes
> prevent unnecessary stopping and starting of netdev transmit queues
> during the setup of XDP socket. Without this change, after stopping
> the XDP traffic flow tracker and then stopping the XDP prog - NETDEV
> WATCHDOG transmit queue timed out appears.
> 
> Signed-off-by: Kamil Maziarz <kamil.maziarz@intel.com>
> Signed-off-by: Piotr Raczynski <piotr.raczynski@intel.com>

Why Piotr's signed off? Is he an author of this patch? Missing Co-developed-by?
Although the patch is too small for Co-developed-by tag IMO.

> ---
>  drivers/net/ethernet/intel/ice/ice_xsk.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/ice/ice_xsk.c
> b/drivers/net/ethernet/intel/ice/ice_xsk.c
> index a7fe2b4ce655..cd56ceae8aef 100644
> --- a/drivers/net/ethernet/intel/ice/ice_xsk.c
> +++ b/drivers/net/ethernet/intel/ice/ice_xsk.c
> @@ -179,7 +179,6 @@ static int ice_qp_dis(struct ice_vsi *vsi, u16 q_idx)
>  			return -EBUSY;
>  		usleep_range(1000, 2000);
>  	}
> -	netif_tx_stop_queue(netdev_get_tx_queue(vsi->netdev, q_idx));
> 
>  	ice_fill_txq_meta(vsi, tx_ring, &txq_meta);
>  	err = ice_vsi_stop_tx_ring(vsi, ICE_NO_RESET, 0, tx_ring, &txq_meta);
> @@ -268,7 +267,6 @@ static int ice_qp_ena(struct ice_vsi *vsi, u16 q_idx)
>  	ice_qvec_toggle_napi(vsi, q_vector, true);
>  	ice_qvec_ena_irq(vsi, q_vector);
> 
> -	netif_tx_start_queue(netdev_get_tx_queue(vsi->netdev, q_idx));
>  free_buf:
>  	kfree(qg_buf);
>  	return err;
> --
> 2.31.1
> 
> _______________________________________________
> Intel-wired-lan mailing list
> Intel-wired-lan@osuosl.org
> https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
Tony Nguyen Sept. 8, 2023, 8:12 p.m. UTC | #2
Cc: Maciej

On 9/8/2023 4:36 AM, Drewek, Wojciech wrote:
> 
> 
>> -----Original Message-----
>> From: Intel-wired-lan <intel-wired-lan-bounces@osuosl.org> On Behalf Of Kamil
>> Maziarz
>> Sent: Friday, September 8, 2023 1:31 PM
>> To: intel-wired-lan@lists.osuosl.org
>> Cc: Maziarz, Kamil <kamil.maziarz@intel.com>
>> Subject: [Intel-wired-lan] [PATCH iwl-net v1] ice: don't stop netdev tx queues
>> when setting up XSK socket
>>
>> Avoid stopping netdev  tx queues during XSK setup by removing
>> netif_tx_stop_queue() and netif_tx_start_queue(). These changes
>> prevent unnecessary stopping and starting of netdev transmit queues
>> during the setup of XDP socket. Without this change, after stopping
>> the XDP traffic flow tracker and then stopping the XDP prog - NETDEV
>> WATCHDOG transmit queue timed out appears.
>>
>> Signed-off-by: Kamil Maziarz <kamil.maziarz@intel.com>
>> Signed-off-by: Piotr Raczynski <piotr.raczynski@intel.com>
> 
> Why Piotr's signed off? Is he an author of this patch? Missing Co-developed-by?
> Although the patch is too small for Co-developed-by tag IMO.

Also, missing a Fixes:

>> ---
>>   drivers/net/ethernet/intel/ice/ice_xsk.c | 2 --
>>   1 file changed, 2 deletions(-)
>>
>> diff --git a/drivers/net/ethernet/intel/ice/ice_xsk.c
>> b/drivers/net/ethernet/intel/ice/ice_xsk.c
>> index a7fe2b4ce655..cd56ceae8aef 100644
>> --- a/drivers/net/ethernet/intel/ice/ice_xsk.c
>> +++ b/drivers/net/ethernet/intel/ice/ice_xsk.c
>> @@ -179,7 +179,6 @@ static int ice_qp_dis(struct ice_vsi *vsi, u16 q_idx)
>>   			return -EBUSY;
>>   		usleep_range(1000, 2000);
>>   	}
>> -	netif_tx_stop_queue(netdev_get_tx_queue(vsi->netdev, q_idx));
>>
>>   	ice_fill_txq_meta(vsi, tx_ring, &txq_meta);
>>   	err = ice_vsi_stop_tx_ring(vsi, ICE_NO_RESET, 0, tx_ring, &txq_meta);
>> @@ -268,7 +267,6 @@ static int ice_qp_ena(struct ice_vsi *vsi, u16 q_idx)
>>   	ice_qvec_toggle_napi(vsi, q_vector, true);
>>   	ice_qvec_ena_irq(vsi, q_vector);
>>
>> -	netif_tx_start_queue(netdev_get_tx_queue(vsi->netdev, q_idx));
>>   free_buf:
>>   	kfree(qg_buf);
>>   	return err;
>> --
>> 2.31.1
>>
>> _______________________________________________
>> Intel-wired-lan mailing list
>> Intel-wired-lan@osuosl.org
>> https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
> _______________________________________________
> Intel-wired-lan mailing list
> Intel-wired-lan@osuosl.org
> https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
diff mbox series

Patch

diff --git a/drivers/net/ethernet/intel/ice/ice_xsk.c b/drivers/net/ethernet/intel/ice/ice_xsk.c
index a7fe2b4ce655..cd56ceae8aef 100644
--- a/drivers/net/ethernet/intel/ice/ice_xsk.c
+++ b/drivers/net/ethernet/intel/ice/ice_xsk.c
@@ -179,7 +179,6 @@  static int ice_qp_dis(struct ice_vsi *vsi, u16 q_idx)
 			return -EBUSY;
 		usleep_range(1000, 2000);
 	}
-	netif_tx_stop_queue(netdev_get_tx_queue(vsi->netdev, q_idx));
 
 	ice_fill_txq_meta(vsi, tx_ring, &txq_meta);
 	err = ice_vsi_stop_tx_ring(vsi, ICE_NO_RESET, 0, tx_ring, &txq_meta);
@@ -268,7 +267,6 @@  static int ice_qp_ena(struct ice_vsi *vsi, u16 q_idx)
 	ice_qvec_toggle_napi(vsi, q_vector, true);
 	ice_qvec_ena_irq(vsi, q_vector);
 
-	netif_tx_start_queue(netdev_get_tx_queue(vsi->netdev, q_idx));
 free_buf:
 	kfree(qg_buf);
 	return err;