From: Andrew Lunn <andrew@lunn.ch>
To: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
kernel@savoirfairelinux.com,
"David S. Miller" <davem@davemloft.net>,
Guenter Roeck <linux@roeck-us.net>,
Florian Fainelli <f.fainelli@gmail.com>,
Neil Armstrong <narmstrong@baylibre.com>
Subject: Re: [PATCH net-next 0/4] net: dsa: mv88e6xxx: fix hardware bridging
Date: Thu, 15 Oct 2015 04:52:50 +0200 [thread overview]
Message-ID: <20151015025250.GA12436@lunn.ch> (raw)
In-Reply-To: <20151015012854.GA10868@ketchup.lan>
On Wed, Oct 14, 2015 at 09:28:55PM -0400, Vivien Didelot wrote:
> On Oct. Thursday 15 (42) 12:46 AM, Andrew Lunn wrote:
> > On Sun, Oct 11, 2015 at 06:08:34PM -0400, Vivien Didelot wrote:
> > > DSA and its drivers currently hook the NETDEV_CHANGEUPPER net_device event in
> > > order to configure the VLAN map of every port.
> > >
> > > This VLAN map is a feature of these switch chips to hardcode and restrict which
> > > output ports a given input port can egress frames to.
> > >
> > > A Linux bridge is a simple untagged VLAN propagated by the bridge code itself.
> > > With a proper 802.1Q support, a driver does not need this hook anymore, and
> > > will simply program the related VLAN object.
> > >
> > > This patchset improves the hardware bridging code in the mv88e6xxx driver with
> > > a strict 802.1Q mode.
> >
> > Hi Vivien
> >
> > I just tested this as part of net-next/master, and found a problem....
> >
> > If i do:
> >
> > ip link set lan0 up
> > ip addr add 192.168.10.2/24 dev lan0
> >
> > It will not ping. Looking in sys/kernel/debug/dsa0/stats i see
> > broadcast packets, probably ARP, being received at the port.
> > But they are not being forwarded out the CPU port.
> >
> > If however i do
> >
> > brctl addbr br0
> > brctl addif br0 lan0
> > ip addr add 192.168.10.2/24 dev br0
> > ip link set br0 up
> >
> > i can ping.
> >
> > So it looks like we are too restrictive by default. You should be able
> > to use interfaces as they are, without a bridge.
>
> Correct, if the ports are not in a VLAN by default, they cannot talk.
Hi Vivien
This is a regression. Ports of the switch should work like normal
Linux interfaces. And up until now, they did. This patchset changed
that.
As Florian pointed out, these interfaces are separated from each
other. So you need something like a bridge per port by default, which
then gets removed and replaced when a port is added to a Linux bridge.
We also need to take care of VLANs. When the port is not a member of a
linux bridge, i expect all VLAN tagged frames to be received, as well
as untagged frames. This is normal Linux behaviour. But i never got
around to testing this with DSA.
Andrew
next prev parent reply other threads:[~2015-10-15 2:52 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-11 22:08 [PATCH net-next 0/4] net: dsa: mv88e6xxx: fix hardware bridging Vivien Didelot
2015-10-11 22:08 ` [PATCH net-next 1/4] net: dsa: mv88e6xxx: bridges do not need an FID Vivien Didelot
2015-10-11 22:08 ` [PATCH net-next 2/4] net: dsa: mv88e6xxx: do not support per-port FID Vivien Didelot
2015-10-11 22:08 ` [PATCH net-next 3/4] net: dsa: do not warn unsupported bridge ops Vivien Didelot
2015-10-11 22:08 ` [PATCH net-next 4/4] net: dsa: mv88e6xxx: fix hardware bridging Vivien Didelot
2015-10-13 11:27 ` [PATCH net-next 0/4] " David Miller
2015-10-14 22:46 ` Andrew Lunn
2015-10-15 1:28 ` Vivien Didelot
2015-10-15 1:44 ` Florian Fainelli
2015-10-15 12:39 ` Vivien Didelot
2015-10-15 2:52 ` Andrew Lunn [this message]
2015-10-15 3:16 ` Guenter Roeck
2015-10-15 12:41 ` Vivien Didelot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20151015025250.GA12436@lunn.ch \
--to=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=kernel@savoirfairelinux.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=narmstrong@baylibre.com \
--cc=netdev@vger.kernel.org \
--cc=vivien.didelot@savoirfairelinux.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).