PERFORCE change 135683 for review

Andrew Thompson thompsa at FreeBSD.org
Mon Feb 18 23:29:57 UTC 2008


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

Change 135683 by thompsa at thompsa_heff on 2008/02/18 23:29:07

	MF //depot/user/benjsc/wpi/sys/dev/wpi/if_wpi.c at 131090
	Dont try to stop the callout.

Affected files ...

.. //depot/projects/wifi/sys/dev/wpi/if_wpi.c#6 edit

Differences ...

==== //depot/projects/wifi/sys/dev/wpi/if_wpi.c#6 (text+ko) ====

@@ -1333,9 +1333,9 @@
 	int error;
 	WPI_LOCK_DECL;
 
-	WPI_LOCK(sc);
-	callout_stop(&sc->calib_to);
-	WPI_UNLOCK(sc);
+	DPRINTF(("%s: %s -> %s\n", __func__,
+		 ieee80211_state_name[ic->ic_state],
+		 ieee80211_state_name[nstate]));
 
 	switch (nstate) {
 	case IEEE80211_S_SCAN:
@@ -3329,14 +3329,15 @@
 	int temp;
 	WPI_LOCK_DECL;
 
+	if ( ic->ic_state != IEEE80211_S_RUN )
+	    return;
+
 	/* automatic rate control triggered every 500ms */
 	if (ic->ic_fixed_rate == IEEE80211_FIXED_RATE_NONE) {
-		WPI_LOCK(sc);
 		if (ic->ic_opmode == IEEE80211_M_STA)
 			wpi_iter_func(sc, ic->ic_bss);
 		else
 			ieee80211_iterate_nodes(&ic->ic_sta, wpi_iter_func, sc);
-		WPI_UNLOCK(sc);
 	}
 
 	/* update sensor data */


More information about the p4-projects mailing list