Search Linux Wireless

Re: mac80211 IPv6 problems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 02, 2007 at 11:46:18PM +0100, David Woodhouse wrote:
> On Thu, 2007-08-02 at 18:30 -0400, Daniel Drake wrote:
> > This may be a stack-level issue. This is one of the issues holding back 
> > zd1211rw-mac80211 going into mainline: we have a report that 
> > zd1211rw-softmac works fine with IPv6 but mac80211 only works 
> > occasionally with the same device on the same system.
> > 
> > Does anyone have any ideas?
> 
> It receives its own neighbour solicitation (multicast) packets when the
> AP sends them back out again. These packets...
> 
> 23:41:56.046939 00:0a:95:f3:99:92 > 33:33:ff:f3:99:92, ethertype IPv6
> (0x86dd), length 78: :: > ff02::1:fff3:9992: ICMP6, neighbor
> solicitation, who has fe80::20a:95ff:fef3:9992, length 24
> 
> You should be able to see this without _any_ IPv6 infrastructure -- and
> you'll see the link-local IPv6 address remains 'tentative'.
> 
> Once you've fixed that, setting up a local route advertisement dæmon
> (radvd) to give you site-local addresses is fairly trivial too -- and
> then you can also check that Ethernet multicast is working properly.

I hacked-up the (untested) patch below -- thoughts?

---

From: John W. Linville <linville@xxxxxxxxxxxxx>

[PATCH] mac80211: filter locally-originated multicast frames

In STA mode, the AP will echo our traffic.  This includes multicast
traffice.

Receiving these frames confuses some protocols and applications,
notably IPv6 Duplicate Address Detection.

Signed-off-by: John W. Linville <linville@xxxxxxxxxxxxx>
---

 net/mac80211/ieee80211.c |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/net/mac80211/ieee80211.c b/net/mac80211/ieee80211.c
index a42e70e..6dc6451 100644
--- a/net/mac80211/ieee80211.c
+++ b/net/mac80211/ieee80211.c
@@ -4263,11 +4263,14 @@ void __ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb,
 					rx.u.rx.ra_match = 0;
 				} else if (!multicast &&
 					   compare_ether_addr(sdata->dev->dev_addr,
-							      hdr->addr1) != 0) {
+							      hdr->addr1)) {
 					if (!sdata->promisc)
 						continue;
 					rx.u.rx.ra_match = 0;
-				}
+				} else if (multicast &&
+					   !compare_ether_addr(sdata->dev->dev_addr,
+							       hdr->addr3))
+					rx.u.rx.ra_match = 0;
 				break;
 			case IEEE80211_IF_TYPE_IBSS:
 				if (!bssid)
-- 
John W. Linville
linville@xxxxxxxxxxxxx
-
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux