PERFORCE change 137129 for review

Sam Leffler sam at FreeBSD.org
Fri Mar 7 23:05:25 UTC 2008


http://perforce.freebsd.org/chv.cgi?CH=137129

Change 137129 by sam at sam_ebb on 2008/03/07 23:04:40

	call ath_newassoc explicitly for sta mode operation so we setup
	driver private rate state

Affected files ...

.. //depot/projects/vap/sys/dev/ath/if_ath.c#42 edit

Differences ...

==== //depot/projects/vap/sys/dev/ath/if_ath.c#42 (text+ko) ====

@@ -5601,12 +5601,9 @@
 			break;
 		case IEEE80211_M_STA:
 			/*
-			 * Allocate a key cache slot to the station.
+			 * Fakeup since we're not called by net80211.
 			 */
-			if ((vap->iv_flags & IEEE80211_F_PRIVACY) == 0 &&
-			    sc->sc_hasclrkey &&
-			    ni->ni_ucastkey.wk_keyix == IEEE80211_KEYIX_NONE)
-				ath_setup_stationkey(ni);
+			ath_newassoc(ni, 1);
 			/*
 			 * Defer beacon timer configuration to the next
 			 * beacon frame so we have a current TSF to use
@@ -5731,13 +5728,10 @@
 	an->an_mgmtrix = ath_tx_findrix(sc->sc_rates[mode], tp->mgmtrate);
 
 	ath_rate_newassoc(sc, an, isnew);
-	if (isnew &&
-	    (vap->iv_flags & IEEE80211_F_PRIVACY) == 0 && sc->sc_hasclrkey) {
-		KASSERT(ni->ni_ucastkey.wk_keyix == IEEE80211_KEYIX_NONE,
-		    ("new assoc with a unicast key already setup (keyix %u)",
-		    ni->ni_ucastkey.wk_keyix));
+	if (isnew && 
+	    (vap->iv_flags & IEEE80211_F_PRIVACY) == 0 && sc->sc_hasclrkey &&
+	    ni->ni_ucastkey.wk_keyix == IEEE80211_KEYIX_NONE)
 		ath_setup_stationkey(ni);
-	}
 }
 
 static int


More information about the p4-projects mailing list