lkml.org 
[lkml]   [2022]   [Sep]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RFC net-next 0/5] net: vlan: fix bridge binding behavior and add selftests
On Wed, 21 Sep 2022 07:45:07 +0300 Nikolay Aleksandrov wrote:
> > IDK, vlan knows it's calling the bridge:
> >
> > + if ((vlan->flags ^ old_flags) & VLAN_FLAG_BRIDGE_BINDING &&
> > + netif_is_bridge_master(vlan->real_dev)) {
>
> This one is more of an optimization so notifications are sent only when the bridge
> is involved, it can be removed if other interested parties show up.
>
> > bridge knows it's vlan calling:
> >
> > + if (is_vlan_dev(dev)) {
> > + br_vlan_device_event(dev, event, ptr);
> >
> > going thru the generic NETDEV notifier seems odd.
> >
> > If this is just to avoid the dependency we can perhaps add a stub
> > like net/ipv4/udp_tunnel_stub.c ?
>
> I suggested the notifier to be more generic and be able to re-use it for other link types although
> I don't have other use cases in mind right now. Stubs are an alternative as long as they and
> their lifetime are properly managed. I don't have a strong preference here so if you prefer
> stubs I'm good.

Yup, stub seems simpler and more efficient to me. Only time will
tell if indeed this ntf type would have been reused further.. 🤷

\
 
 \ /
  Last update: 2022-09-21 14:43    [W:3.453 / U:1.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site