[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <PH0PR11MB5880DBF5BD3925FD14EF0F058F362@PH0PR11MB5880.namprd11.prod.outlook.com>
Date: Mon, 25 Mar 2024 11:00:52 +0000
From: "Romanowski, Rafal" <rafal.romanowski@...el.com>
To: Paul Menzel <pmenzel@...gen.mpg.de>, "Loktionov, Aleksandr"
<aleksandr.loktionov@...el.com>
CC: "Nguyen, Anthony L" <anthony.l.nguyen@...el.com>, "Kubalewski, Arkadiusz"
<arkadiusz.kubalewski@...el.com>, "intel-wired-lan@...ts.osuosl.org"
<intel-wired-lan@...ts.osuosl.org>, "netdev@...r.kernel.org"
<netdev@...r.kernel.org>
Subject: RE: [Intel-wired-lan] [PATCH iwl-net v2] i40e: fix
i40e_count_filters() to count only active/new filters
> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of
> Paul Menzel
> Sent: Wednesday, March 13, 2024 12:05 PM
> To: Loktionov, Aleksandr <aleksandr.loktionov@...el.com>
> Cc: Nguyen, Anthony L <anthony.l.nguyen@...el.com>; Kubalewski, Arkadiusz
> <arkadiusz.kubalewski@...el.com>; intel-wired-lan@...ts.osuosl.org;
> netdev@...r.kernel.org
> Subject: Re: [Intel-wired-lan] [PATCH iwl-net v2] i40e: fix i40e_count_filters()
> to count only active/new filters
>
> Dear Aleksandr,
>
>
> Am 13.03.24 um 10:44 schrieb Aleksandr Loktionov:
> > The bug usually affects untrusted VFs, because they are limited to
> > 18MACs, it affects them badly, not letting to create MAC all filters.
> > Not stable to reproduce, it happens when VF user creates MAC filters
> > when other MACVLAN operations are happened in parallel.
> > But consequence is that VF can't receive desired traffic.
> >
> > Fix counter to be bumped only for new or active filters.
> >
> > Fixes: 621650cabee5 ("i40e: Refactoring VF MAC filters counting to
> > make more reliable")
> > Signed-off-by: Aleksandr Loktionov <aleksandr.loktionov@...el.com>
> > Reviewed-by: Arkadiusz Kubalewski <arkadiusz.kubalewski@...el.com>
> > ---
> > v1 -> v2: add explanation about the bug
>
> Thank you very much. (I personally wouldn’t break lines just because a
> sentence ends.)
>
> > ---
> > drivers/net/ethernet/intel/i40e/i40e_main.c | 7 +++++--
> > 1 file changed, 5 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c
> > b/drivers/net/ethernet/intel/i40e/i40e_main.c
> > index 89a3401..6010a49 100644
> > --- a/drivers/net/ethernet/intel/i40e/i40e_main.c
> > +++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
> > @@ -1257,8 +1257,11 @@ int i40e_count_filters(struct i40e_vsi *vsi)
> > int bkt;
> > int cnt = 0;
> >
> > - hash_for_each_safe(vsi->mac_filter_hash, bkt, h, f, hlist)
> > - ++cnt;
> > + hash_for_each_safe(vsi->mac_filter_hash, bkt, h, f, hlist) {
> > + if (f->state == I40E_FILTER_NEW ||
> > + f->state == I40E_FILTER_ACTIVE)
> > + ++cnt;
> > + }
> >
> > return cnt;
> > }
>
> Reviewed-by: Paul Menzel <pmenzel@...gen.mpg.de>
>
>
> Kind regards,
>
> Paul
Tested-by: Rafal Romanowski <rafal.romanowski@...el.com>
Powered by blists - more mailing lists