diff options
author | Bing Zhao <bzhao@marvell.com> | 2014-02-07 19:21:01 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2014-02-12 15:36:11 -0500 |
commit | f25b14315e8084efbcc5c672cec8ee1f691dc2fd (patch) | |
tree | 3aa02bb8a192076a671b118fee681ecdab64a998 | |
parent | 406d702b47a23506b944d8377647352e25f68ea1 (diff) |
mwifiex: remove unsupported code in 11ac
bit12 in fw_cap_info is for testing only.
Remove all related code.
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/mwifiex/cfg80211.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/cfp.c | 5 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/fw.h | 20 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/ioctl.h | 3 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/join.c | 12 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/sta_ioctl.c | 2 |
6 files changed, 17 insertions, 28 deletions
diff --git a/drivers/net/wireless/mwifiex/cfg80211.c b/drivers/net/wireless/mwifiex/cfg80211.c index 0948ebe8942e..c6606288c61e 100644 --- a/drivers/net/wireless/mwifiex/cfg80211.c +++ b/drivers/net/wireless/mwifiex/cfg80211.c | |||
@@ -1416,9 +1416,6 @@ static int mwifiex_cfg80211_start_ap(struct wiphy *wiphy, | |||
1416 | 1416 | ||
1417 | if (params->chandef.width > NL80211_CHAN_WIDTH_20_NOHT) | 1417 | if (params->chandef.width > NL80211_CHAN_WIDTH_20_NOHT) |
1418 | config_bands |= BAND_GN; | 1418 | config_bands |= BAND_GN; |
1419 | |||
1420 | if (params->chandef.width > NL80211_CHAN_WIDTH_40) | ||
1421 | config_bands |= BAND_GAC; | ||
1422 | } else { | 1419 | } else { |
1423 | bss_cfg->band_cfg = BAND_CONFIG_A; | 1420 | bss_cfg->band_cfg = BAND_CONFIG_A; |
1424 | config_bands = BAND_A; | 1421 | config_bands = BAND_A; |
diff --git a/drivers/net/wireless/mwifiex/cfp.c b/drivers/net/wireless/mwifiex/cfp.c index dfb068ba2dbd..2c3226bf86f8 100644 --- a/drivers/net/wireless/mwifiex/cfp.c +++ b/drivers/net/wireless/mwifiex/cfp.c | |||
@@ -438,7 +438,6 @@ u32 mwifiex_get_supported_rates(struct mwifiex_private *priv, u8 *rates) | |||
438 | break; | 438 | break; |
439 | case BAND_G: | 439 | case BAND_G: |
440 | case BAND_G | BAND_GN: | 440 | case BAND_G | BAND_GN: |
441 | case BAND_G | BAND_GN | BAND_GAC: | ||
442 | dev_dbg(adapter->dev, "info: infra band=%d " | 441 | dev_dbg(adapter->dev, "info: infra band=%d " |
443 | "supported_rates_g\n", adapter->config_bands); | 442 | "supported_rates_g\n", adapter->config_bands); |
444 | k = mwifiex_copy_rates(rates, k, supported_rates_g, | 443 | k = mwifiex_copy_rates(rates, k, supported_rates_g, |
@@ -449,10 +448,7 @@ u32 mwifiex_get_supported_rates(struct mwifiex_private *priv, u8 *rates) | |||
449 | case BAND_A | BAND_B: | 448 | case BAND_A | BAND_B: |
450 | case BAND_A | BAND_B | BAND_G | BAND_GN | BAND_AN: | 449 | case BAND_A | BAND_B | BAND_G | BAND_GN | BAND_AN: |
451 | case BAND_A | BAND_B | BAND_G | BAND_GN | BAND_AN | BAND_AAC: | 450 | case BAND_A | BAND_B | BAND_G | BAND_GN | BAND_AN | BAND_AAC: |
452 | case BAND_A | BAND_B | BAND_G | BAND_GN | BAND_AN | | ||
453 | BAND_AAC | BAND_GAC: | ||
454 | case BAND_B | BAND_G | BAND_GN: | 451 | case BAND_B | BAND_G | BAND_GN: |
455 | case BAND_B | BAND_G | BAND_GN | BAND_GAC: | ||
456 | dev_dbg(adapter->dev, "info: infra band=%d " | 452 | dev_dbg(adapter->dev, "info: infra band=%d " |
457 | "supported_rates_bg\n", adapter->config_bands); | 453 | "supported_rates_bg\n", adapter->config_bands); |
458 | k = mwifiex_copy_rates(rates, k, supported_rates_bg, | 454 | k = mwifiex_copy_rates(rates, k, supported_rates_bg, |
@@ -476,7 +472,6 @@ u32 mwifiex_get_supported_rates(struct mwifiex_private *priv, u8 *rates) | |||
476 | sizeof(supported_rates_a)); | 472 | sizeof(supported_rates_a)); |
477 | break; | 473 | break; |
478 | case BAND_GN: | 474 | case BAND_GN: |
479 | case BAND_GN | BAND_GAC: | ||
480 | dev_dbg(adapter->dev, "info: infra band=%d " | 475 | dev_dbg(adapter->dev, "info: infra band=%d " |
481 | "supported_rates_n\n", adapter->config_bands); | 476 | "supported_rates_n\n", adapter->config_bands); |
482 | k = mwifiex_copy_rates(rates, k, supported_rates_n, | 477 | k = mwifiex_copy_rates(rates, k, supported_rates_n, |
diff --git a/drivers/net/wireless/mwifiex/fw.h b/drivers/net/wireless/mwifiex/fw.h index 059bc16adf81..d8014c87d470 100644 --- a/drivers/net/wireless/mwifiex/fw.h +++ b/drivers/net/wireless/mwifiex/fw.h | |||
@@ -50,21 +50,23 @@ struct tx_packet_hdr { | |||
50 | #define HOSTCMD_SUPPORTED_RATES 14 | 50 | #define HOSTCMD_SUPPORTED_RATES 14 |
51 | #define N_SUPPORTED_RATES 3 | 51 | #define N_SUPPORTED_RATES 3 |
52 | #define ALL_802_11_BANDS (BAND_A | BAND_B | BAND_G | BAND_GN | \ | 52 | #define ALL_802_11_BANDS (BAND_A | BAND_B | BAND_G | BAND_GN | \ |
53 | BAND_AN | BAND_GAC | BAND_AAC) | 53 | BAND_AN | BAND_AAC) |
54 | 54 | ||
55 | #define FW_MULTI_BANDS_SUPPORT (BIT(8) | BIT(9) | BIT(10) | BIT(11) | \ | 55 | #define FW_MULTI_BANDS_SUPPORT (BIT(8) | BIT(9) | BIT(10) | BIT(11) | \ |
56 | BIT(12) | BIT(13)) | 56 | BIT(13)) |
57 | #define IS_SUPPORT_MULTI_BANDS(adapter) \ | 57 | #define IS_SUPPORT_MULTI_BANDS(adapter) \ |
58 | (adapter->fw_cap_info & FW_MULTI_BANDS_SUPPORT) | 58 | (adapter->fw_cap_info & FW_MULTI_BANDS_SUPPORT) |
59 | 59 | ||
60 | /* shift bit 12 and bit 13 in fw_cap_info from the firmware to bit 13 and 14 | 60 | /* bit 13: 11ac BAND_AAC |
61 | * for 11ac so that bit 11 is for GN, bit 12 for AN, bit 13 for GAC, and bit | 61 | * bit 12: reserved for lab testing, will be reused for BAND_AN |
62 | * bit 14 for AAC, in order to be compatible with the band capability | 62 | * bit 11: 11n BAND_GN |
63 | * defined in the driver after right shift of 8 bits. | 63 | * bit 10: 11a BAND_A |
64 | * bit 9: 11g BAND_G | ||
65 | * bit 8: 11b BAND_B | ||
66 | * Map these bits to band capability by right shifting 8 bits. | ||
64 | */ | 67 | */ |
65 | #define GET_FW_DEFAULT_BANDS(adapter) \ | 68 | #define GET_FW_DEFAULT_BANDS(adapter) \ |
66 | (((((adapter->fw_cap_info & 0x3000) << 1) | \ | 69 | (((adapter->fw_cap_info & 0x2f00) >> 8) & \ |
67 | (adapter->fw_cap_info & ~0xF000)) >> 8) & \ | ||
68 | ALL_802_11_BANDS) | 70 | ALL_802_11_BANDS) |
69 | 71 | ||
70 | #define HostCmd_WEP_KEY_INDEX_MASK 0x3fff | 72 | #define HostCmd_WEP_KEY_INDEX_MASK 0x3fff |
@@ -226,7 +228,7 @@ enum MWIFIEX_802_11_PRIVACY_FILTER { | |||
226 | 228 | ||
227 | /* HW_SPEC fw_cap_info */ | 229 | /* HW_SPEC fw_cap_info */ |
228 | 230 | ||
229 | #define ISSUPP_11ACENABLED(fw_cap_info) (fw_cap_info & (BIT(12)|BIT(13))) | 231 | #define ISSUPP_11ACENABLED(fw_cap_info) (fw_cap_info & BIT(13)) |
230 | 232 | ||
231 | #define GET_VHTCAP_CHWDSET(vht_cap_info) ((vht_cap_info >> 2) & 0x3) | 233 | #define GET_VHTCAP_CHWDSET(vht_cap_info) ((vht_cap_info >> 2) & 0x3) |
232 | #define GET_VHTNSSMCS(mcs_mapset, nss) ((mcs_mapset >> (2 * (nss - 1))) & 0x3) | 234 | #define GET_VHTNSSMCS(mcs_mapset, nss) ((mcs_mapset >> (2 * (nss - 1))) & 0x3) |
diff --git a/drivers/net/wireless/mwifiex/ioctl.h b/drivers/net/wireless/mwifiex/ioctl.h index 00a95f4c6a6c..48f15906515d 100644 --- a/drivers/net/wireless/mwifiex/ioctl.h +++ b/drivers/net/wireless/mwifiex/ioctl.h | |||
@@ -60,8 +60,7 @@ enum { | |||
60 | BAND_A = 4, | 60 | BAND_A = 4, |
61 | BAND_GN = 8, | 61 | BAND_GN = 8, |
62 | BAND_AN = 16, | 62 | BAND_AN = 16, |
63 | BAND_GAC = 32, | 63 | BAND_AAC = 32, |
64 | BAND_AAC = 64, | ||
65 | }; | 64 | }; |
66 | 65 | ||
67 | #define MWIFIEX_WPA_PASSHPHRASE_LEN 64 | 66 | #define MWIFIEX_WPA_PASSHPHRASE_LEN 64 |
diff --git a/drivers/net/wireless/mwifiex/join.c b/drivers/net/wireless/mwifiex/join.c index 4e4686e6ac09..d3934c6dbd8a 100644 --- a/drivers/net/wireless/mwifiex/join.c +++ b/drivers/net/wireless/mwifiex/join.c | |||
@@ -515,8 +515,7 @@ int mwifiex_cmd_802_11_associate(struct mwifiex_private *priv, | |||
515 | 515 | ||
516 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && | 516 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && |
517 | !bss_desc->disable_11n && !bss_desc->disable_11ac && | 517 | !bss_desc->disable_11n && !bss_desc->disable_11ac && |
518 | (priv->adapter->config_bands & BAND_GAC || | 518 | priv->adapter->config_bands & BAND_AAC) |
519 | priv->adapter->config_bands & BAND_AAC)) | ||
520 | mwifiex_cmd_append_11ac_tlv(priv, bss_desc, &pos); | 519 | mwifiex_cmd_append_11ac_tlv(priv, bss_desc, &pos); |
521 | 520 | ||
522 | /* Append vendor specific IE TLV */ | 521 | /* Append vendor specific IE TLV */ |
@@ -1300,8 +1299,7 @@ int mwifiex_associate(struct mwifiex_private *priv, | |||
1300 | 1299 | ||
1301 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && | 1300 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && |
1302 | !bss_desc->disable_11n && !bss_desc->disable_11ac && | 1301 | !bss_desc->disable_11n && !bss_desc->disable_11ac && |
1303 | (priv->adapter->config_bands & BAND_GAC || | 1302 | priv->adapter->config_bands & BAND_AAC) |
1304 | priv->adapter->config_bands & BAND_AAC)) | ||
1305 | mwifiex_set_11ac_ba_params(priv); | 1303 | mwifiex_set_11ac_ba_params(priv); |
1306 | else | 1304 | else |
1307 | mwifiex_set_ba_params(priv); | 1305 | mwifiex_set_ba_params(priv); |
@@ -1335,8 +1333,7 @@ mwifiex_adhoc_start(struct mwifiex_private *priv, | |||
1335 | priv->curr_bss_params.band); | 1333 | priv->curr_bss_params.band); |
1336 | 1334 | ||
1337 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && | 1335 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && |
1338 | (priv->adapter->config_bands & BAND_GAC || | 1336 | priv->adapter->config_bands & BAND_AAC) |
1339 | priv->adapter->config_bands & BAND_AAC)) | ||
1340 | mwifiex_set_11ac_ba_params(priv); | 1337 | mwifiex_set_11ac_ba_params(priv); |
1341 | else | 1338 | else |
1342 | mwifiex_set_ba_params(priv); | 1339 | mwifiex_set_ba_params(priv); |
@@ -1376,8 +1373,7 @@ int mwifiex_adhoc_join(struct mwifiex_private *priv, | |||
1376 | 1373 | ||
1377 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && | 1374 | if (ISSUPP_11ACENABLED(priv->adapter->fw_cap_info) && |
1378 | !bss_desc->disable_11n && !bss_desc->disable_11ac && | 1375 | !bss_desc->disable_11n && !bss_desc->disable_11ac && |
1379 | (priv->adapter->config_bands & BAND_GAC || | 1376 | priv->adapter->config_bands & BAND_AAC) |
1380 | priv->adapter->config_bands & BAND_AAC)) | ||
1381 | mwifiex_set_11ac_ba_params(priv); | 1377 | mwifiex_set_11ac_ba_params(priv); |
1382 | else | 1378 | else |
1383 | mwifiex_set_ba_params(priv); | 1379 | mwifiex_set_ba_params(priv); |
diff --git a/drivers/net/wireless/mwifiex/sta_ioctl.c b/drivers/net/wireless/mwifiex/sta_ioctl.c index 0bec94351f36..c3d3ea55d605 100644 --- a/drivers/net/wireless/mwifiex/sta_ioctl.c +++ b/drivers/net/wireless/mwifiex/sta_ioctl.c | |||
@@ -290,7 +290,7 @@ int mwifiex_bss_start(struct mwifiex_private *priv, struct cfg80211_bss *bss, | |||
290 | 290 | ||
291 | if (mwifiex_band_to_radio_type(bss_desc->bss_band) == | 291 | if (mwifiex_band_to_radio_type(bss_desc->bss_band) == |
292 | HostCmd_SCAN_RADIO_TYPE_BG) | 292 | HostCmd_SCAN_RADIO_TYPE_BG) |
293 | config_bands = BAND_B | BAND_G | BAND_GN | BAND_GAC; | 293 | config_bands = BAND_B | BAND_G | BAND_GN; |
294 | else | 294 | else |
295 | config_bands = BAND_A | BAND_AN | BAND_AAC; | 295 | config_bands = BAND_A | BAND_AN | BAND_AAC; |
296 | 296 | ||