Index: sys/net80211/ieee80211_scan_sta.c
===================================================================
--- sys/net80211/ieee80211_scan_sta.c	(revision 276192)
+++ sys/net80211/ieee80211_scan_sta.c	(working copy)
@@ -589,30 +589,26 @@
 	 */
 	for (scan = table; scan->list != NULL; scan++) {
 		mode = scan->mode;
-		if (vap->iv_des_mode != IEEE80211_MODE_AUTO) {
+
+		/* Skip the G check */
+		if (vap->iv_des_mode == IEEE80211_MODE_11G &&
+		    mode == IEEE80211_MODE_11G)
+			continue;
+
+		if (mode == IEEE80211_MODE_11B) {
 			/*
-			 * If a desired mode was specified, scan only 
-			 * channels that satisfy that constraint.
+			 * The scan table marks 2.4Ghz channels as b
+			 * so if the desired mode is 11g, then use
+			 * the 11b channel list but upgrade the mode.
 			 */
-			if (vap->iv_des_mode != mode) {
-				/*
-				 * The scan table marks 2.4Ghz channels as b
-				 * so if the desired mode is 11g, then use
-				 * the 11b channel list but upgrade the mode.
-				 */
-				if (vap->iv_des_mode == IEEE80211_MODE_11G) {
-					if (mode == IEEE80211_MODE_11G) /* Skip the G check */
-						continue;
-					else if (mode == IEEE80211_MODE_11B)
-						mode = IEEE80211_MODE_11G;	/* upgrade */
-				}
-			}
-		} else {
+			if (vap->iv_des_mode == IEEE80211_MODE_11G)
+				mode = IEEE80211_MODE_11G;	/* upgrade */
+
 			/*
 			 * This lets add_channels upgrade an 11b channel
 			 * to 11g if available.
 			 */
-			if (mode == IEEE80211_MODE_11B)
+			else if (vap->iv_des_mode == IEEE80211_MODE_AUTO)
 				mode = IEEE80211_MODE_AUTO;
 		}
 #ifdef IEEE80211_F_XR