[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+h21hraJBaizE1VDaH+sKRe-M-RQUsKU5rJh=UJ9WANCbFwcg@mail.gmail.com>
Date: Sat, 16 Nov 2019 18:26:06 +0200
From: Vladimir Oltean <olteanv@...il.com>
To: Andrew Lunn <andrew@...n.ch>
Cc: Florian Fainelli <f.fainelli@...il.com>,
Vivien Didelot <vivien.didelot@...il.com>,
"David S. Miller" <davem@...emloft.net>,
netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH net-next] net: dsa: tag_8021q: Fix dsa_8021q_restore_pvid
for an absent pvid
On Sat, 16 Nov 2019 at 18:24, Andrew Lunn <andrew@...n.ch> wrote:
>
> On Sat, Nov 16, 2019 at 06:08:42PM +0200, Vladimir Oltean wrote:
> > This sequence of operations:
> > ip link set dev br0 type bridge vlan_filtering 1
> > bridge vlan del dev swp2 vid 1
> > ip link set dev br0 type bridge vlan_filtering 1
> > ip link set dev br0 type bridge vlan_filtering 0
>
> > --- a/net/dsa/tag_8021q.c
> > +++ b/net/dsa/tag_8021q.c
> > @@ -105,7 +105,7 @@ static int dsa_8021q_restore_pvid(struct dsa_switch *ds, int port)
> > slave = dsa_to_port(ds, port)->slave;
> >
> > err = br_vlan_get_pvid(slave, &pvid);
> > - if (err < 0)
> > + if (!pvid || err < 0)
> > /* There is no pvid on the bridge for this port, which is
> > * perfectly valid. Nothing to restore, bye-bye!
> > */
>
> This looks very similar to the previous patch. Some explanation would
> be good. Did you send it for the wrong tree? Or are there really
> different fixes for different trees?
>
> Thanks
> Andrew
Hi Andrew,
The context is different:
dsa_to_port(ds, port)
vs
ds->ports[port]
This is due to Vivien's recent rework in DSA's port list vs port array.
Regards,
-Vladimir
Powered by blists - more mailing lists