lkml.org 
[lkml]   [2024]   [Apr]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH net-next v8 13/16] net: dsa: vsc73xx: Implement the tag_8021q VLAN operations
On Wed, Apr 03, 2024 at 12:37:29PM +0200, Pawel Dembicki wrote:
> @@ -756,6 +756,12 @@ static int vsc73xx_setup(struct dsa_switch *ds)
>
> mdelay(50);
>
> + rtnl_lock();
> + ret = dsa_tag_8021q_register(ds, htons(ETH_P_8021Q));
> + rtnl_unlock();
> + if (ret)
> + return ret;
> +

No dsa_tag_8021q_unregister() in vsc73xx_teardown()?

Also, a bit odd placement, while the resets haven't all finished (this
falls in between the IP multicast flood mask and the PHY resets. It
makes future refactoring of the other code harder.

Additionally (and much worse), even later in vsc73xx_setup(), you clear
the VLAN table with portmaps of 0. Doesn't this wipe out the
configuration made by
dsa_tag_8021q_register()
-> dsa_tag_8021q_setup()
-> dsa_tag_8021q_port_setup()
-> dsa_port_tag_8021q_vlan_add()
-> dsa_switch_tag_8021q_vlan_add()
-> dsa_port_do_tag_8021q_vlan_add()
-> vsc73xx_tag_8021q_vlan_add()
-> vsc73xx_tag_8021q_vlan_add()
?

\
 
 \ /
  Last update: 2024-05-27 16:26    [W:0.114 / U:1.568 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site