Author: bschmidt
Date: Tue Jan  3 09:42:31 2012
New Revision: 229375
URL: http://svn.freebsd.org/changeset/base/229375

Log:
  Don't rely on MCS7 being at index 7 while determining the amount
  of antennas to use. Not all APs enable all MCS rates.
  
  Poked by:     Lucius Windschuh <lwindschuh at googlemail dot com>
  MFC after:    1 week

Modified:
  head/sys/dev/iwn/if_iwn.c

Modified: head/sys/dev/iwn/if_iwn.c
==============================================================================
--- head/sys/dev/iwn/if_iwn.c   Tue Jan  3 09:42:08 2012        (r229374)
+++ head/sys/dev/iwn/if_iwn.c   Tue Jan  3 09:42:31 2012        (r229375)
@@ -2128,7 +2128,7 @@ iwn_newassoc(struct ieee80211_node *ni, 
                                        plcp |= IWN_RFLAG_SGI;
                        } else if (ni->ni_htcap & IEEE80211_HTCAP_SHORTGI20)
                                plcp |= IWN_RFLAG_SGI;
-                       if (i > 7)
+                       if (RV(ni->ni_htrates.rs_rates[i]) > 7)
                                plcp |= IWN_RFLAG_ANT(txant1 | txant2);
                        else
                                plcp |= IWN_RFLAG_ANT(txant1);
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to