From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH] macvlan: transmit multicast as unicast in source mode Date: Mon, 23 Mar 2015 16:50:46 -0400 (EDT) Message-ID: <20150323.165046.44048598018869192.davem@davemloft.net> References: <1427027389-9691-1-git-send-email-michael-dev@fami-braun.de> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, projekt-wlan@fem.tu-ilmenau.de To: michael-dev@fami-braun.de Return-path: Received: from shards.monkeyblade.net ([149.20.54.216]:58178 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752512AbbCWUus (ORCPT ); Mon, 23 Mar 2015 16:50:48 -0400 In-Reply-To: <1427027389-9691-1-git-send-email-michael-dev@fami-braun.de> Sender: netdev-owner@vger.kernel.org List-ID: From: Michael Braun Date: Sun, 22 Mar 2015 13:29:49 +0100 > When having multiple remote mac addresses assigned to different macvlan > source devices created on top of the same other netdev, multicast packets > send on one interface will be also received by the remote machines > asssigned to the other macvlan device. > > This is because multicast packets are transmitted as layer-2 multicast. > Thought, not all protocols need their multicast packets to be transmitted > as layer-2 multicast, esp. ARP, IPv4 and IPv6. Most importantly, IPv6 > router advertisments will be processed even if received as layer-2 unicast. > > So this patch adds support for replicating multicast packets and sending > them out as unicast by changing the destination mac address. > This fixes IPv6 autoconf addresses and routes on the remote stations > assigned to different macvlan devices. > > There are two new flags: UNICAST and UNICAST_ALL. The first only rewrites > ARP, IPv4 and IPv6 (and their 802.1Q tagged variant), the latter rewrites > all multicast packets. > > Signed-off-by: Michael Braun I want someone who understands macvlans better to review this before I apply it. Thanks.