On Tuesday, May 10, 2016 18:41:25 Linus Lüssing wrote:
With this patch we are finally able to support multicast optimizations in bridged setups, too. So far, if a bridge was added on top of a soft-interface (e.g. bat0) the batman-adv multicast optimizations needed to be disabled to avoid packetloss.
Current Linux bridge implementations and API can now provide us with the so far missing information about interested but "remote" multicast receivers behind bridge ports.
The Linux bridge performs the detection of remote participants interested in multicast packets with its own and mature so called IGMP and MLD snooping code and stores that in its database. With the new API provided by the bridge batman-adv can now simply hook into this database.
We then reliably announce the gathered multicast listeners to other nodes through the batman-adv translation table.
Additionally, the Linux bridge provides us with the information about whether an IGMP/MLD querier exists. If there is none then we need to disable multicast optimizations as we cannot learn about multicast listeners on external, bridged-in host then.
Tested-by: Simon Wunderlich sw@simonwunderlich.de Signed-off-by: Linus Lüssing linus.luessing@c0d3.blue
compat-include/linux/etherdevice.h | 9 ++ compat-include/linux/if_bridge.h | 68 ++++++++++++++ net/batman-adv/multicast.c | 181 ++++++++++++++++++++++++++++++++---- net/batman-adv/types.h | 13 +++ 4 files changed, 253 insertions(+), 18 deletions(-) create mode 100644 compat-include/linux/if_bridge.h
Applied in revision 391b59c.
Thanks, Marek