Subject: Re: likely bug in ieee80211_encap for IBSS/AHDEMO unicast output
To: None <current-users@netbsd.org>
From: Greg Troxel <gdt@ir.bbn.com>
List: current-users
Date: 10/17/2003 10:31:11
The following patch (in sys/net80211) makes a Lucent Gold card be able
interwork in both IBSS and ad-hoc demo mode with an identical card in
a 1.6-stable system.

I now realize (thanks to Sam and David for pointing this out to me,
offlist) that this change is in general incorrect, because other
non-Lucent, or perhaps non-PRISM cards require the use of a node table
in IBSS mode.  But I post it in case any -current users depend on IBSS
or ad-hoc demo mode with Lucent cards - I had to boot an old kernel to
be on the net until I made the change.

--- ieee80211_output.c.~1.7.~	2003-10-16 18:59:52.000000000 -0400
+++ ieee80211_output.c	2003-10-16 19:30:38.000000000 -0400
@@ -194,7 +194,7 @@
 	}
 	memcpy(&eh, mtod(m, caddr_t), sizeof(struct ether_header));
 
-	if (ic->ic_opmode != IEEE80211_M_STA) {
+	if (ic->ic_opmode == IEEE80211_M_HOSTAP) {
 		ni = ieee80211_find_node(ic, eh.ether_dhost);
 		if (ni == NULL) {
 			/*


-- 
        Greg Troxel <gdt@ir.bbn.com>