Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-19 Thread Brenden Blanco
On Tue, Jul 19, 2016 at 04:33:28PM +0300, Tariq Toukan wrote: [...] > >So, I took Dave's suggestion to heart, and spent the last 2 days seeing > >what was possible to implement with just xdp as the focus, rather than > >an overall cleanup which Tariq will be looking at. > > > >Unfortunately, this t

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-15 Thread Brenden Blanco
On Wed, Jul 13, 2016 at 08:40:59AM -0700, Brenden Blanco wrote: > On Wed, Jul 13, 2016 at 10:17:26AM +0300, Tariq Toukan wrote: > > > > On 13/07/2016 3:54 AM, Brenden Blanco wrote: > > >On Tue, Jul 12, 2016 at 02:18:32PM -0700, David Miller wrote: > > >>From: Brenden Blanco > > >>Date: Tue, 12 Ju

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-13 Thread Brenden Blanco
On Wed, Jul 13, 2016 at 10:17:26AM +0300, Tariq Toukan wrote: > > On 13/07/2016 3:54 AM, Brenden Blanco wrote: > >On Tue, Jul 12, 2016 at 02:18:32PM -0700, David Miller wrote: > >>From: Brenden Blanco > >>Date: Tue, 12 Jul 2016 00:51:29 -0700 > >> > >>>+ mlx4_en_free_resources(priv); > >>>+ > >>

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-13 Thread Tariq Toukan
On 13/07/2016 3:54 AM, Brenden Blanco wrote: On Tue, Jul 12, 2016 at 02:18:32PM -0700, David Miller wrote: From: Brenden Blanco Date: Tue, 12 Jul 2016 00:51:29 -0700 + mlx4_en_free_resources(priv); + old_prog = xchg(&priv->prog, prog); if (old_prog) bpf_

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread Brenden Blanco
On Tue, Jul 12, 2016 at 02:18:32PM -0700, David Miller wrote: > From: Brenden Blanco > Date: Tue, 12 Jul 2016 00:51:29 -0700 > > > + mlx4_en_free_resources(priv); > > + > > old_prog = xchg(&priv->prog, prog); > > if (old_prog) > > bpf_prog_put(old_prog); > > > > - return

RE: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread Tariq Toukan
>The mlx4 driver by default allocates order-3 pages for the ring to consume in >multiple fragments. When the device has an xdp program, this behavior will >prevent tx actions since the page must be re-mapped in TODEVICE mode, which >cannot be done if the page is still shared. > >Start by making

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread David Miller
From: Brenden Blanco Date: Tue, 12 Jul 2016 00:51:29 -0700 > + mlx4_en_free_resources(priv); > + > old_prog = xchg(&priv->prog, prog); > if (old_prog) > bpf_prog_put(old_prog); > > - return 0; > + err = mlx4_en_alloc_resources(priv); > + if (err) { > +

[PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread Brenden Blanco
The mlx4 driver by default allocates order-3 pages for the ring to consume in multiple fragments. When the device has an xdp program, this behavior will prevent tx actions since the page must be re-mapped in TODEVICE mode, which cannot be done if the page is still shared. Start by making the alloc