From: Andrew Lunn <andrew@lunn.ch>
To: Igor Mitsyanko <igor.mitsyanko.os@quantenna.com>
Cc: ivecera@redhat.com, jiri@resnulli.us, netdev@vger.kernel.org,
bridge@lists.linux-foundation.org,
sergey.matyukevich.os@quantenna.com, ashevchenko@quantenna.com,
smaksimenko@quantenna.com, dlebed@quantenna.com
Subject: Re: [RFC PATCH net-next 3/5] bridge: allow switchdev port to handle flooding by itself
Date: Tue, 13 Mar 2018 02:11:40 +0100 [thread overview]
Message-ID: <20180313011140.GA5778@lunn.ch> (raw)
In-Reply-To: <c22c1758-e383-2930-34c8-8c8c7b8455c1@quantenna.com>
> The flag was introduced to enable hardware switch capabilities of
> drivers/net/wireless/quantenna/qtnfmac wifi driver. It does not have any
> switchdev functionality in upstream tree at this moment, and this patchset
> was intended as a preparatory change.
O.K. But i suggest you add basic switchdev support first. Then think
about adding new functionality. That way you can learn more about
switchdev, and we can learn more about your hardware.
> qtnfmac driver provides several physical radios (5 GHz and 2.4 GHz), each
> can have up to 8 virtual network interfaces. These interfaces can be bridged
> together in various configurations, and I'm trying to figure out what is the
> most efficient way to handle it from bridging perspective.
I think the first thing to do is get this part correctly represented
by switchdev. I don't think any of us maintainers have thought about
how wireless and switchdev can be combined. The wifi model seems to be
one phy device, with multiple MACs running on top of it, with each MAC
being a single SSID. So is it one SSID per virtual interface? Or are
your virtual network interfaces actually virtual phys in the wireless
model, and you can have multiple MACs on top of each virtual phy?
> My assumption was that software FDB and hardware FDB should always
> be in sync with each other. I guess it is a safe assumption if
> handled correctly? Hardware should send a notification for each new
> FDB it has learned, and switchdev driver should process FDB
> notifications from software bridge.
No, you cannot make this assumption. Take the example of DSA
switches. They are generally connected over an MDIO bus, or an SPI
bus. The bandwidth is small. How long do you think it takes the
hardware to learn 8K MAC addresses with 5x 1Gbps ports receiving 64
byte packets? DSA drivers have no way of keeping up with the
hardware. And there is no need to. Everything works fine with the SW
and the HW bridge having different dynamic FDB entries.
I don't even think your hardware will have the hardware and software
in sync. How fast can your hardware learn new addresses? 'Line' rate?
Or do you prevent the hardware learning a new address until the
software bridge has confirmed it has learnt the previous new address?
> qtnfmac hardware has its own memory and maintains FWT table, so for the best
> efficiency forwarding between virtual interfaces should be handled locally.
> Qtnfmac can handle all the mentioned flooding by itself:
> - unknown unicasts
> - broadcast and unknown multicast
> - known multicasts (does have IGMP snooping)
> - can do multicast-to-unicast translation if required.
>
> The most important usecase IMO is a muticast transmission, specific example
> being:
> - 2.4GHz x 8 and 5GHz x 8 virtual wifi interfaces, bridged with backbone
> ethernet interface in Linux
> - multicast video streaming from a server behind ethernet
> - multicast clients connected to some wifi interfaces
I agree this makes sense. But we need to ensure the solution is
generic, not something which just works for your hardware/firmware. I
know somebody who would love to be able to do something like this with
DSA drivers. They would probably sacrifice IGMP snooping and just
flood everywhere, if that is all the hardware could do. But so far,
i've not been able to figure out a way to do this.
Andrew
next prev parent reply other threads:[~2018-03-13 1:11 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-10 3:03 [PATCH net-next 0/5] Switchdev: flooding offload option Igor Mitsyanko
2018-03-10 3:03 ` [PATCH net-next 1/5] bridge: initialize port flags with switchdev defaults Igor Mitsyanko
2018-03-10 16:30 ` Andrew Lunn
2018-03-12 18:44 ` Igor Mitsyanko
2018-03-10 16:32 ` Stephen Hemminger
2018-03-12 19:03 ` Igor Mitsyanko
2018-03-10 3:03 ` [PATCH net-next 2/5] bridge: propagate BR_ flags updates through sysfs to switchdev Igor Mitsyanko
2018-03-10 16:38 ` Andrew Lunn
2018-03-12 20:07 ` Igor Mitsyanko
2018-03-10 3:03 ` [RFC PATCH net-next 3/5] bridge: allow switchdev port to handle flooding by itself Igor Mitsyanko
2018-03-10 16:55 ` Andrew Lunn
2018-03-12 23:00 ` Igor Mitsyanko
2018-03-13 1:11 ` Andrew Lunn [this message]
2018-03-13 14:41 ` Roopa Prabhu
2018-03-10 3:03 ` [RFC PATCH net-next 4/5] bridge: provide sysfs and netlink interface to set BR_FLOOD_OFFLOAD Igor Mitsyanko
2018-03-10 3:03 ` [RFC PATCH net-next 5/5] bridge: verify "HW only" flags can't be set without HW support Igor Mitsyanko
2018-03-10 22:08 ` [PATCH net-next 0/5] Switchdev: flooding offload option Andrew Lunn
2018-03-12 23:08 ` Igor Mitsyanko
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=20180313011140.GA5778@lunn.ch \
--to=andrew@lunn.ch \
--cc=ashevchenko@quantenna.com \
--cc=bridge@lists.linux-foundation.org \
--cc=dlebed@quantenna.com \
--cc=igor.mitsyanko.os@quantenna.com \
--cc=ivecera@redhat.com \
--cc=jiri@resnulli.us \
--cc=netdev@vger.kernel.org \
--cc=sergey.matyukevich.os@quantenna.com \
--cc=smaksimenko@quantenna.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).