Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 29 Jan 2009 23:11:18 +0000 (UTC)
From:      Sam Leffler <sam@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r187898 - head/sys/net80211
Message-ID:  <200901292311.n0TNBI5Q067732@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: sam
Date: Thu Jan 29 23:11:18 2009
New Revision: 187898
URL: http://svn.freebsd.org/changeset/base/187898

Log:
  set ni_txparms for static turbo mode

Modified:
  head/sys/net80211/ieee80211_node.c

Modified: head/sys/net80211/ieee80211_node.c
==============================================================================
--- head/sys/net80211/ieee80211_node.c	Thu Jan 29 23:09:12 2009	(r187897)
+++ head/sys/net80211/ieee80211_node.c	Thu Jan 29 23:11:18 2009	(r187898)
@@ -227,20 +227,25 @@ static void
 node_setuptxparms(struct ieee80211_node *ni)
 {
 	struct ieee80211vap *vap = ni->ni_vap;
+	enum ieee80211_phymode mode;
 
 	if (ni->ni_flags & IEEE80211_NODE_HT) {
 		if (IEEE80211_IS_CHAN_5GHZ(ni->ni_chan))
-			ni->ni_txparms = &vap->iv_txparms[IEEE80211_MODE_11NA];
+			mode = IEEE80211_MODE_11NA;
 		else
-			ni->ni_txparms = &vap->iv_txparms[IEEE80211_MODE_11NG];
+			mode = IEEE80211_MODE_11NG;
 	} else {				/* legacy rate handling */
-		if (IEEE80211_IS_CHAN_A(ni->ni_chan))
-			ni->ni_txparms = &vap->iv_txparms[IEEE80211_MODE_11A];
+		/* NB: 108A/108G should be handled as 11a/11g respectively */
+		if (IEEE80211_IS_CHAN_ST(ni->ni_chan))
+			mode = IEEE80211_MODE_STURBO_A;
+		else if (IEEE80211_IS_CHAN_A(ni->ni_chan))
+			mode = IEEE80211_MODE_11A;
 		else if (ni->ni_flags & IEEE80211_NODE_ERP)
-			ni->ni_txparms = &vap->iv_txparms[IEEE80211_MODE_11G];
+			mode = IEEE80211_MODE_11G;
 		else
-			ni->ni_txparms = &vap->iv_txparms[IEEE80211_MODE_11B];
+			mode = IEEE80211_MODE_11B;
 	}
+	ni->ni_txparms = &vap->iv_txparms[mode];
 }
 
 /*



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901292311.n0TNBI5Q067732>