All of lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
@ 2019-10-07 22:07 Jeff Kirsher
  2019-10-08 16:54 ` Bowers, AndrewX
  0 siblings, 1 reply; 5+ messages in thread
From: Jeff Kirsher @ 2019-10-07 22:07 UTC (permalink / raw)
  To: intel-wired-lan

Magnus's fix to resolve a potential receive buffer starvation for AF_XDP
got applied to both the i40e_xsk_umem_enable/disable() functions, when it
should have only been applied to the "enable".  So clean up the undesired
code in the disable function.

CC: Magnus Karlsson <magnus.karlsson@intel.com>
Fixes: 1f459bdc2007 ("i40e: fix potential RX buffer starvation for AF_XDP")
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
 drivers/net/ethernet/intel/i40e/i40e_xsk.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/net/ethernet/intel/i40e/i40e_xsk.c b/drivers/net/ethernet/intel/i40e/i40e_xsk.c
index b1c3227ae4ab..a05dfecdd9b4 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_xsk.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_xsk.c
@@ -157,11 +157,6 @@ static int i40e_xsk_umem_disable(struct i40e_vsi *vsi, u16 qid)
 		err = i40e_queue_pair_enable(vsi, qid);
 		if (err)
 			return err;
-
-		/* Kick start the NAPI context so that receiving will start */
-		err = i40e_xsk_wakeup(vsi->netdev, qid, XDP_WAKEUP_RX);
-		if (err)
-			return err;
 	}
 
 	return 0;
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
  2019-10-07 22:07 [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP Jeff Kirsher
@ 2019-10-08 16:54 ` Bowers, AndrewX
  0 siblings, 0 replies; 5+ messages in thread
From: Bowers, AndrewX @ 2019-10-08 16:54 UTC (permalink / raw)
  To: intel-wired-lan

> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces at osuosl.org] On
> Behalf Of Jeff Kirsher
> Sent: Monday, October 7, 2019 3:07 PM
> To: intel-wired-lan at lists.osuosl.org
> Cc: Karlsson, Magnus <magnus.karlsson@intel.com>
> Subject: [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
> 
> Magnus's fix to resolve a potential receive buffer starvation for AF_XDP got
> applied to both the i40e_xsk_umem_enable/disable() functions, when it
> should have only been applied to the "enable".  So clean up the undesired
> code in the disable function.
> 
> CC: Magnus Karlsson <magnus.karlsson@intel.com>
> Fixes: 1f459bdc2007 ("i40e: fix potential RX buffer starvation for AF_XDP")
> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
> ---
>  drivers/net/ethernet/intel/i40e/i40e_xsk.c | 5 -----
>  1 file changed, 5 deletions(-)

Tested-by: Andrew Bowers <andrewx.bowers@intel.com>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
  2020-01-05  8:46 Jeff Kirsher
  2020-01-07 23:28 ` Bowers, AndrewX
@ 2020-01-09  0:52 ` Jacob Keller
  1 sibling, 0 replies; 5+ messages in thread
From: Jacob Keller @ 2020-01-09  0:52 UTC (permalink / raw)
  To: intel-wired-lan

On 1/5/2020 12:46 AM, Jeff Kirsher wrote:
> Magnus's fix to resolve a potential receive buffer starvation for AF_XDP
> got applied to both the i40e_xsk_umem_enable/disable() functions, when it
> should have only been applied to the "enable".  So clean up the undesired
> code in the disable function.
> 
> CC: Magnus Karlsson <magnus.karlsson@intel.com>
> Fixes: 1f459bdc2007 ("i40e: fix potential RX buffer starvation for AF_XDP")
> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
> ---
>  drivers/net/ethernet/intel/i40e/i40e_xsk.c | 5 -----
>  1 file changed, 5 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/i40e/i40e_xsk.c b/drivers/net/ethernet/intel/i40e/i40e_xsk.c
> index 42058fad6a3c..1b13d8e0d67a 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_xsk.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_xsk.c
> @@ -114,11 +114,6 @@ static int i40e_xsk_umem_enable(struct i40e_vsi *vsi, struct xdp_umem *umem,

Umm.. Based on the commit message, you meant to remove only from the
disable function, not the enable one...

And indeed you actually did in October:

2c19e395e061 ("i40e: Fix receive buffer starvation for AF_XDP")
Date:   Mon Oct 7 15:07:24 2019 -0700

I think this patch should be dropped from your tree.

(Thanks Lihong for pointing this out to me!)

Thanks,
Jake

>  		err = i40e_queue_pair_enable(vsi, qid);
>  		if (err)
>  			return err;
> -
> -		/* Kick start the NAPI context so that receiving will start */
> -		err = i40e_xsk_wakeup(vsi->netdev, qid, XDP_WAKEUP_RX);
> -		if (err)
> -			return err;
>  	}
>  
>  	return 0;
> 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
  2020-01-05  8:46 Jeff Kirsher
@ 2020-01-07 23:28 ` Bowers, AndrewX
  2020-01-09  0:52 ` Jacob Keller
  1 sibling, 0 replies; 5+ messages in thread
From: Bowers, AndrewX @ 2020-01-07 23:28 UTC (permalink / raw)
  To: intel-wired-lan

> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces at osuosl.org] On
> Behalf Of Jeff Kirsher
> Sent: Sunday, January 5, 2020 12:46 AM
> To: intel-wired-lan at lists.osuosl.org
> Cc: Karlsson, Magnus <magnus.karlsson@intel.com>
> Subject: [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
> 
> Magnus's fix to resolve a potential receive buffer starvation for AF_XDP got
> applied to both the i40e_xsk_umem_enable/disable() functions, when it
> should have only been applied to the "enable".  So clean up the undesired
> code in the disable function.
> 
> CC: Magnus Karlsson <magnus.karlsson@intel.com>
> Fixes: 1f459bdc2007 ("i40e: fix potential RX buffer starvation for AF_XDP")
> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
> ---
>  drivers/net/ethernet/intel/i40e/i40e_xsk.c | 5 -----
>  1 file changed, 5 deletions(-)

Tested-by: Andrew Bowers <andrewx.bowers@intel.com>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP
@ 2020-01-05  8:46 Jeff Kirsher
  2020-01-07 23:28 ` Bowers, AndrewX
  2020-01-09  0:52 ` Jacob Keller
  0 siblings, 2 replies; 5+ messages in thread
From: Jeff Kirsher @ 2020-01-05  8:46 UTC (permalink / raw)
  To: intel-wired-lan

Magnus's fix to resolve a potential receive buffer starvation for AF_XDP
got applied to both the i40e_xsk_umem_enable/disable() functions, when it
should have only been applied to the "enable".  So clean up the undesired
code in the disable function.

CC: Magnus Karlsson <magnus.karlsson@intel.com>
Fixes: 1f459bdc2007 ("i40e: fix potential RX buffer starvation for AF_XDP")
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
 drivers/net/ethernet/intel/i40e/i40e_xsk.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/net/ethernet/intel/i40e/i40e_xsk.c b/drivers/net/ethernet/intel/i40e/i40e_xsk.c
index 42058fad6a3c..1b13d8e0d67a 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_xsk.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_xsk.c
@@ -114,11 +114,6 @@ static int i40e_xsk_umem_enable(struct i40e_vsi *vsi, struct xdp_umem *umem,
 		err = i40e_queue_pair_enable(vsi, qid);
 		if (err)
 			return err;
-
-		/* Kick start the NAPI context so that receiving will start */
-		err = i40e_xsk_wakeup(vsi->netdev, qid, XDP_WAKEUP_RX);
-		if (err)
-			return err;
 	}
 
 	return 0;
-- 
2.24.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-01-09  0:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-07 22:07 [Intel-wired-lan] [net] i40e: Fix receive buffer starvation for AF_XDP Jeff Kirsher
2019-10-08 16:54 ` Bowers, AndrewX
2020-01-05  8:46 Jeff Kirsher
2020-01-07 23:28 ` Bowers, AndrewX
2020-01-09  0:52 ` Jacob Keller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.