svn commit: r219456 - head/sys/net80211
Bernhard Schmidt
bschmidt at FreeBSD.org
Thu Mar 10 18:17:24 UTC 2011
Author: bschmidt
Date: Thu Mar 10 18:17:24 2011
New Revision: 219456
URL: http://svn.freebsd.org/changeset/base/219456
Log:
Complete the MCS rate table based on the final 802.11n std. While here
adjust the IEEE80211_HTRATE_MAXSIZE constant, only MCS0 - 76 are valid
the other bits in the mcsset IE (77 - 127) are either reserved or used
for TX parameters.
Modified:
head/sys/net80211/_ieee80211.h
head/sys/net80211/ieee80211.c
head/sys/net80211/ieee80211_ht.c
head/sys/net80211/ieee80211_ht.h
Modified: head/sys/net80211/_ieee80211.h
==============================================================================
--- head/sys/net80211/_ieee80211.h Thu Mar 10 18:00:47 2011 (r219455)
+++ head/sys/net80211/_ieee80211.h Thu Mar 10 18:17:24 2011 (r219456)
@@ -335,7 +335,7 @@ struct ieee80211_rateset {
* the structure such that it can be used interchangeably
* with an ieee80211_rateset (modulo structure size).
*/
-#define IEEE80211_HTRATE_MAXSIZE 127
+#define IEEE80211_HTRATE_MAXSIZE 77
struct ieee80211_htrateset {
uint8_t rs_nrates;
Modified: head/sys/net80211/ieee80211.c
==============================================================================
--- head/sys/net80211/ieee80211.c Thu Mar 10 18:00:47 2011 (r219455)
+++ head/sys/net80211/ieee80211.c Thu Mar 10 18:17:24 2011 (r219456)
@@ -1513,6 +1513,67 @@ ieee80211_rate2media(struct ieee80211com
{ 13, IFM_IEEE80211_MCS },
{ 14, IFM_IEEE80211_MCS },
{ 15, IFM_IEEE80211_MCS },
+ { 16, IFM_IEEE80211_MCS },
+ { 17, IFM_IEEE80211_MCS },
+ { 18, IFM_IEEE80211_MCS },
+ { 19, IFM_IEEE80211_MCS },
+ { 20, IFM_IEEE80211_MCS },
+ { 21, IFM_IEEE80211_MCS },
+ { 22, IFM_IEEE80211_MCS },
+ { 23, IFM_IEEE80211_MCS },
+ { 24, IFM_IEEE80211_MCS },
+ { 25, IFM_IEEE80211_MCS },
+ { 26, IFM_IEEE80211_MCS },
+ { 27, IFM_IEEE80211_MCS },
+ { 28, IFM_IEEE80211_MCS },
+ { 29, IFM_IEEE80211_MCS },
+ { 30, IFM_IEEE80211_MCS },
+ { 31, IFM_IEEE80211_MCS },
+ { 32, IFM_IEEE80211_MCS },
+ { 33, IFM_IEEE80211_MCS },
+ { 34, IFM_IEEE80211_MCS },
+ { 35, IFM_IEEE80211_MCS },
+ { 36, IFM_IEEE80211_MCS },
+ { 37, IFM_IEEE80211_MCS },
+ { 38, IFM_IEEE80211_MCS },
+ { 39, IFM_IEEE80211_MCS },
+ { 40, IFM_IEEE80211_MCS },
+ { 41, IFM_IEEE80211_MCS },
+ { 42, IFM_IEEE80211_MCS },
+ { 43, IFM_IEEE80211_MCS },
+ { 44, IFM_IEEE80211_MCS },
+ { 45, IFM_IEEE80211_MCS },
+ { 46, IFM_IEEE80211_MCS },
+ { 47, IFM_IEEE80211_MCS },
+ { 48, IFM_IEEE80211_MCS },
+ { 49, IFM_IEEE80211_MCS },
+ { 50, IFM_IEEE80211_MCS },
+ { 51, IFM_IEEE80211_MCS },
+ { 52, IFM_IEEE80211_MCS },
+ { 53, IFM_IEEE80211_MCS },
+ { 54, IFM_IEEE80211_MCS },
+ { 55, IFM_IEEE80211_MCS },
+ { 56, IFM_IEEE80211_MCS },
+ { 57, IFM_IEEE80211_MCS },
+ { 58, IFM_IEEE80211_MCS },
+ { 59, IFM_IEEE80211_MCS },
+ { 60, IFM_IEEE80211_MCS },
+ { 61, IFM_IEEE80211_MCS },
+ { 62, IFM_IEEE80211_MCS },
+ { 63, IFM_IEEE80211_MCS },
+ { 64, IFM_IEEE80211_MCS },
+ { 65, IFM_IEEE80211_MCS },
+ { 66, IFM_IEEE80211_MCS },
+ { 67, IFM_IEEE80211_MCS },
+ { 68, IFM_IEEE80211_MCS },
+ { 69, IFM_IEEE80211_MCS },
+ { 70, IFM_IEEE80211_MCS },
+ { 71, IFM_IEEE80211_MCS },
+ { 72, IFM_IEEE80211_MCS },
+ { 73, IFM_IEEE80211_MCS },
+ { 74, IFM_IEEE80211_MCS },
+ { 75, IFM_IEEE80211_MCS },
+ { 76, IFM_IEEE80211_MCS },
};
int m;
Modified: head/sys/net80211/ieee80211_ht.c
==============================================================================
--- head/sys/net80211/ieee80211_ht.c Thu Mar 10 18:00:47 2011 (r219455)
+++ head/sys/net80211/ieee80211_ht.c Thu Mar 10 18:17:24 2011 (r219456)
@@ -54,24 +54,84 @@ __FBSDID("$FreeBSD$");
#define MS(_v, _f) (((_v) & _f) >> _f##_S)
#define SM(_v, _f) (((_v) << _f##_S) & _f)
-const struct ieee80211_mcs_rates ieee80211_htrates[16] = {
- /* 20Mhz SGI 40Mhz SGI */
- { 13, 14, 27, 30 }, /* MCS 0 */
- { 26, 29, 54, 60 }, /* MCS 1 */
- { 39, 43, 81, 90 }, /* MCS 2 */
- { 52, 58, 108, 120 }, /* MCS 3 */
- { 78, 87, 162, 180 }, /* MCS 4 */
- { 104, 116, 216, 240 }, /* MCS 5 */
- { 117, 130, 243, 270 }, /* MCS 6 */
- { 130, 144, 270, 300 }, /* MCS 7 */
- { 26, 29, 54, 60 }, /* MCS 8 */
- { 52, 58, 108, 120 }, /* MCS 9 */
- { 78, 87, 162, 180 }, /* MCS 10 */
- { 104, 116, 216, 240 }, /* MCS 11 */
- { 156, 173, 324, 360 }, /* MCS 12 */
- { 208, 231, 432, 480 }, /* MCS 13 */
- { 234, 260, 486, 540 }, /* MCS 14 */
- { 260, 289, 540, 600 } /* MCS 15 */
+const struct ieee80211_mcs_rates ieee80211_htrates[IEEE80211_HTRATE_MAXSIZE] = {
+ { 13, 14, 27, 30 }, /* MCS 0 */
+ { 26, 29, 54, 60 }, /* MCS 1 */
+ { 39, 43, 81, 90 }, /* MCS 2 */
+ { 52, 58, 108, 120 }, /* MCS 3 */
+ { 78, 87, 162, 180 }, /* MCS 4 */
+ { 104, 116, 216, 240 }, /* MCS 5 */
+ { 117, 130, 243, 270 }, /* MCS 6 */
+ { 130, 144, 270, 300 }, /* MCS 7 */
+ { 26, 29, 54, 60 }, /* MCS 8 */
+ { 52, 58, 108, 120 }, /* MCS 9 */
+ { 78, 87, 162, 180 }, /* MCS 10 */
+ { 104, 116, 216, 240 }, /* MCS 11 */
+ { 156, 173, 324, 360 }, /* MCS 12 */
+ { 208, 231, 432, 480 }, /* MCS 13 */
+ { 234, 260, 486, 540 }, /* MCS 14 */
+ { 260, 289, 540, 600 }, /* MCS 15 */
+ { 39, 43, 81, 90 }, /* MCS 16 */
+ { 78, 87, 162, 180 }, /* MCS 17 */
+ { 117, 130, 243, 270 }, /* MCS 18 */
+ { 156, 173, 324, 360 }, /* MCS 19 */
+ { 234, 260, 486, 540 }, /* MCS 20 */
+ { 312, 347, 648, 720 }, /* MCS 21 */
+ { 351, 390, 729, 810 }, /* MCS 22 */
+ { 390, 433, 810, 900 }, /* MCS 23 */
+ { 52, 58, 108, 120 }, /* MCS 24 */
+ { 104, 116, 216, 240 }, /* MCS 25 */
+ { 156, 173, 324, 360 }, /* MCS 26 */
+ { 208, 231, 432, 480 }, /* MCS 27 */
+ { 312, 347, 648, 720 }, /* MCS 28 */
+ { 416, 462, 864, 960 }, /* MCS 29 */
+ { 468, 520, 972, 1080 }, /* MCS 30 */
+ { 520, 578, 1080, 1200 }, /* MCS 31 */
+ { 0, 0, 12, 13 }, /* MCS 32 */
+ { 78, 87, 162, 180 }, /* MCS 33 */
+ { 104, 116, 216, 240 }, /* MCS 34 */
+ { 130, 144, 270, 300 }, /* MCS 35 */
+ { 117, 130, 243, 270 }, /* MCS 36 */
+ { 156, 173, 324, 360 }, /* MCS 37 */
+ { 195, 217, 405, 450 }, /* MCS 38 */
+ { 104, 116, 216, 240 }, /* MCS 39 */
+ { 130, 144, 270, 300 }, /* MCS 40 */
+ { 130, 144, 270, 300 }, /* MCS 41 */
+ { 156, 173, 324, 360 }, /* MCS 42 */
+ { 182, 202, 378, 420 }, /* MCS 43 */
+ { 182, 202, 378, 420 }, /* MCS 44 */
+ { 208, 231, 432, 480 }, /* MCS 45 */
+ { 156, 173, 324, 360 }, /* MCS 46 */
+ { 195, 217, 405, 450 }, /* MCS 47 */
+ { 195, 217, 405, 450 }, /* MCS 48 */
+ { 234, 260, 486, 540 }, /* MCS 49 */
+ { 273, 303, 567, 630 }, /* MCS 50 */
+ { 273, 303, 567, 630 }, /* MCS 51 */
+ { 312, 347, 648, 720 }, /* MCS 52 */
+ { 130, 144, 270, 300 }, /* MCS 53 */
+ { 156, 173, 324, 360 }, /* MCS 54 */
+ { 182, 202, 378, 420 }, /* MCS 55 */
+ { 156, 173, 324, 360 }, /* MCS 56 */
+ { 182, 202, 378, 420 }, /* MCS 57 */
+ { 208, 231, 432, 480 }, /* MCS 58 */
+ { 234, 260, 486, 540 }, /* MCS 59 */
+ { 208, 231, 432, 480 }, /* MCS 60 */
+ { 234, 260, 486, 540 }, /* MCS 61 */
+ { 260, 289, 540, 600 }, /* MCS 62 */
+ { 260, 289, 540, 600 }, /* MCS 63 */
+ { 286, 318, 594, 660 }, /* MCS 64 */
+ { 195, 217, 405, 450 }, /* MCS 65 */
+ { 234, 260, 486, 540 }, /* MCS 66 */
+ { 273, 303, 567, 630 }, /* MCS 67 */
+ { 234, 260, 486, 540 }, /* MCS 68 */
+ { 273, 303, 567, 630 }, /* MCS 69 */
+ { 312, 347, 648, 720 }, /* MCS 70 */
+ { 351, 390, 729, 810 }, /* MCS 71 */
+ { 312, 347, 648, 720 }, /* MCS 72 */
+ { 351, 390, 729, 810 }, /* MCS 73 */
+ { 390, 433, 810, 900 }, /* MCS 74 */
+ { 390, 433, 810, 900 }, /* MCS 75 */
+ { 429, 477, 891, 990 }, /* MCS 76 */
};
static const struct ieee80211_htrateset ieee80211_rateset_11n =
Modified: head/sys/net80211/ieee80211_ht.h
==============================================================================
--- head/sys/net80211/ieee80211_ht.h Thu Mar 10 18:00:47 2011 (r219455)
+++ head/sys/net80211/ieee80211_ht.h Thu Mar 10 18:17:24 2011 (r219456)
@@ -159,7 +159,7 @@ struct ieee80211_mcs_rates {
uint16_t ht40_rate_800ns;
uint16_t ht40_rate_400ns;
};
-extern const struct ieee80211_mcs_rates ieee80211_htrates[16];
+extern const struct ieee80211_mcs_rates ieee80211_htrates[];
const struct ieee80211_htrateset *ieee80211_get_suphtrates(
struct ieee80211com *, const struct ieee80211_channel *);
More information about the svn-src-head
mailing list