diff options
author | David S. Miller <davem@davemloft.net> | 2016-01-29 23:26:08 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-01-29 23:26:08 -0500 |
commit | 39a4867a9b481afce3f28d2c7e216bdd6ff51417 (patch) | |
tree | e1fa108959a2e6d3877bd621ccd9487bef176535 | |
parent | aa3a022094fac7f6e48050e139fa8a5a2e3265ce (diff) | |
parent | f9ead9beef3f44be0db4b542a8c2ce698fb1530e (diff) |
Merge tag 'wireless-drivers-for-davem-2016-01-29' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers
Kalle Valo says:
====================
iwlwifi
* Fix support for 3168 device:
* NVM version
* firmware file name
* device IDs
* Fix a compilation warning in dvm calibration code
* Fix the TPC (reduced Tx Power) code. This fixes performance issues
* Add device IDs for 8265
rtx2x00
* fix monitor mode regression dating back to 4.1
brcmfmac
* fix sdio initialisation related crash
rtlwifi
* rtl8821ae: Fix 5G failure when EEPROM is incorrectly encoded
ath9k
* ignore eeprom magic mismatch on flash based devices
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
22 files changed, 136 insertions, 80 deletions
diff --git a/MAINTAINERS b/MAINTAINERS index 95eafcc2bc85..a26b9fefa83d 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
@@ -10036,7 +10036,7 @@ F: drivers/net/ethernet/natsemi/sonic.* | |||
10036 | 10036 | ||
10037 | SONICS SILICON BACKPLANE DRIVER (SSB) | 10037 | SONICS SILICON BACKPLANE DRIVER (SSB) |
10038 | M: Michael Buesch <m@bues.ch> | 10038 | M: Michael Buesch <m@bues.ch> |
10039 | L: netdev@vger.kernel.org | 10039 | L: linux-wireless@vger.kernel.org |
10040 | S: Maintained | 10040 | S: Maintained |
10041 | F: drivers/ssb/ | 10041 | F: drivers/ssb/ |
10042 | F: include/linux/ssb/ | 10042 | F: include/linux/ssb/ |
diff --git a/drivers/net/wireless/ath/ath9k/eeprom.c b/drivers/net/wireless/ath/ath9k/eeprom.c index a7afdeee698c..73fb4232f9f2 100644 --- a/drivers/net/wireless/ath/ath9k/eeprom.c +++ b/drivers/net/wireless/ath/ath9k/eeprom.c | |||
@@ -150,18 +150,18 @@ int ath9k_hw_nvram_swap_data(struct ath_hw *ah, bool *swap_needed, int size) | |||
150 | return -EIO; | 150 | return -EIO; |
151 | } | 151 | } |
152 | 152 | ||
153 | if (magic == AR5416_EEPROM_MAGIC) { | 153 | *swap_needed = false; |
154 | *swap_needed = false; | 154 | if (swab16(magic) == AR5416_EEPROM_MAGIC) { |
155 | } else if (swab16(magic) == AR5416_EEPROM_MAGIC) { | ||
156 | if (ah->ah_flags & AH_NO_EEP_SWAP) { | 155 | if (ah->ah_flags & AH_NO_EEP_SWAP) { |
157 | ath_info(common, | 156 | ath_info(common, |
158 | "Ignoring endianness difference in EEPROM magic bytes.\n"); | 157 | "Ignoring endianness difference in EEPROM magic bytes.\n"); |
159 | |||
160 | *swap_needed = false; | ||
161 | } else { | 158 | } else { |
162 | *swap_needed = true; | 159 | *swap_needed = true; |
163 | } | 160 | } |
164 | } else { | 161 | } else if (magic != AR5416_EEPROM_MAGIC) { |
162 | if (ath9k_hw_use_flash(ah)) | ||
163 | return 0; | ||
164 | |||
165 | ath_err(common, | 165 | ath_err(common, |
166 | "Invalid EEPROM Magic (0x%04x).\n", magic); | 166 | "Invalid EEPROM Magic (0x%04x).\n", magic); |
167 | return -EINVAL; | 167 | return -EINVAL; |
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c index 53637399bb99..b98db8a0a069 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c | |||
@@ -879,11 +879,24 @@ int brcmf_sdiod_abort(struct brcmf_sdio_dev *sdiodev, uint fn) | |||
879 | return 0; | 879 | return 0; |
880 | } | 880 | } |
881 | 881 | ||
882 | static void brcmf_sdiod_sgtable_alloc(struct brcmf_sdio_dev *sdiodev) | 882 | void brcmf_sdiod_sgtable_alloc(struct brcmf_sdio_dev *sdiodev) |
883 | { | 883 | { |
884 | struct sdio_func *func; | ||
885 | struct mmc_host *host; | ||
886 | uint max_blocks; | ||
884 | uint nents; | 887 | uint nents; |
885 | int err; | 888 | int err; |
886 | 889 | ||
890 | func = sdiodev->func[2]; | ||
891 | host = func->card->host; | ||
892 | sdiodev->sg_support = host->max_segs > 1; | ||
893 | max_blocks = min_t(uint, host->max_blk_count, 511u); | ||
894 | sdiodev->max_request_size = min_t(uint, host->max_req_size, | ||
895 | max_blocks * func->cur_blksize); | ||
896 | sdiodev->max_segment_count = min_t(uint, host->max_segs, | ||
897 | SG_MAX_SINGLE_ALLOC); | ||
898 | sdiodev->max_segment_size = host->max_seg_size; | ||
899 | |||
887 | if (!sdiodev->sg_support) | 900 | if (!sdiodev->sg_support) |
888 | return; | 901 | return; |
889 | 902 | ||
@@ -1021,9 +1034,6 @@ static void brcmf_sdiod_host_fixup(struct mmc_host *host) | |||
1021 | 1034 | ||
1022 | static int brcmf_sdiod_probe(struct brcmf_sdio_dev *sdiodev) | 1035 | static int brcmf_sdiod_probe(struct brcmf_sdio_dev *sdiodev) |
1023 | { | 1036 | { |
1024 | struct sdio_func *func; | ||
1025 | struct mmc_host *host; | ||
1026 | uint max_blocks; | ||
1027 | int ret = 0; | 1037 | int ret = 0; |
1028 | 1038 | ||
1029 | sdiodev->num_funcs = 2; | 1039 | sdiodev->num_funcs = 2; |
@@ -1054,26 +1064,6 @@ static int brcmf_sdiod_probe(struct brcmf_sdio_dev *sdiodev) | |||
1054 | goto out; | 1064 | goto out; |
1055 | } | 1065 | } |
1056 | 1066 | ||
1057 | /* | ||
1058 | * determine host related variables after brcmf_sdiod_probe() | ||
1059 | * as func->cur_blksize is properly set and F2 init has been | ||
1060 | * completed successfully. | ||
1061 | */ | ||
1062 | func = sdiodev->func[2]; | ||
1063 | host = func->card->host; | ||
1064 | sdiodev->sg_support = host->max_segs > 1; | ||
1065 | max_blocks = min_t(uint, host->max_blk_count, 511u); | ||
1066 | sdiodev->max_request_size = min_t(uint, host->max_req_size, | ||
1067 | max_blocks * func->cur_blksize); | ||
1068 | sdiodev->max_segment_count = min_t(uint, host->max_segs, | ||
1069 | SG_MAX_SINGLE_ALLOC); | ||
1070 | sdiodev->max_segment_size = host->max_seg_size; | ||
1071 | |||
1072 | /* allocate scatter-gather table. sg support | ||
1073 | * will be disabled upon allocation failure. | ||
1074 | */ | ||
1075 | brcmf_sdiod_sgtable_alloc(sdiodev); | ||
1076 | |||
1077 | ret = brcmf_sdiod_freezer_attach(sdiodev); | 1067 | ret = brcmf_sdiod_freezer_attach(sdiodev); |
1078 | if (ret) | 1068 | if (ret) |
1079 | goto out; | 1069 | goto out; |
@@ -1084,7 +1074,7 @@ static int brcmf_sdiod_probe(struct brcmf_sdio_dev *sdiodev) | |||
1084 | ret = -ENODEV; | 1074 | ret = -ENODEV; |
1085 | goto out; | 1075 | goto out; |
1086 | } | 1076 | } |
1087 | brcmf_sdiod_host_fixup(host); | 1077 | brcmf_sdiod_host_fixup(sdiodev->func[2]->card->host); |
1088 | out: | 1078 | out: |
1089 | if (ret) | 1079 | if (ret) |
1090 | brcmf_sdiod_remove(sdiodev); | 1080 | brcmf_sdiod_remove(sdiodev); |
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c index 4265b50faa98..cfee477a6eb1 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c | |||
@@ -17,6 +17,7 @@ | |||
17 | #include <linux/kernel.h> | 17 | #include <linux/kernel.h> |
18 | #include <linux/string.h> | 18 | #include <linux/string.h> |
19 | #include <linux/netdevice.h> | 19 | #include <linux/netdevice.h> |
20 | #include <linux/module.h> | ||
20 | #include <brcmu_wifi.h> | 21 | #include <brcmu_wifi.h> |
21 | #include <brcmu_utils.h> | 22 | #include <brcmu_utils.h> |
22 | #include "core.h" | 23 | #include "core.h" |
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c index dd6614332836..a14d9d9da094 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | |||
@@ -4114,6 +4114,11 @@ struct brcmf_sdio *brcmf_sdio_probe(struct brcmf_sdio_dev *sdiodev) | |||
4114 | goto fail; | 4114 | goto fail; |
4115 | } | 4115 | } |
4116 | 4116 | ||
4117 | /* allocate scatter-gather table. sg support | ||
4118 | * will be disabled upon allocation failure. | ||
4119 | */ | ||
4120 | brcmf_sdiod_sgtable_alloc(bus->sdiodev); | ||
4121 | |||
4117 | /* Query the F2 block size, set roundup accordingly */ | 4122 | /* Query the F2 block size, set roundup accordingly */ |
4118 | bus->blocksize = bus->sdiodev->func[2]->cur_blksize; | 4123 | bus->blocksize = bus->sdiodev->func[2]->cur_blksize; |
4119 | bus->roundup = min(max_roundup, bus->blocksize); | 4124 | bus->roundup = min(max_roundup, bus->blocksize); |
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.h b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.h index 5ec7a6d87672..23f223150cef 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.h +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.h | |||
@@ -342,6 +342,7 @@ int brcmf_sdiod_ramrw(struct brcmf_sdio_dev *sdiodev, bool write, u32 address, | |||
342 | 342 | ||
343 | /* Issue an abort to the specified function */ | 343 | /* Issue an abort to the specified function */ |
344 | int brcmf_sdiod_abort(struct brcmf_sdio_dev *sdiodev, uint fn); | 344 | int brcmf_sdiod_abort(struct brcmf_sdio_dev *sdiodev, uint fn); |
345 | void brcmf_sdiod_sgtable_alloc(struct brcmf_sdio_dev *sdiodev); | ||
345 | void brcmf_sdiod_change_state(struct brcmf_sdio_dev *sdiodev, | 346 | void brcmf_sdiod_change_state(struct brcmf_sdio_dev *sdiodev, |
346 | enum brcmf_sdiod_state state); | 347 | enum brcmf_sdiod_state state); |
347 | #ifdef CONFIG_PM_SLEEP | 348 | #ifdef CONFIG_PM_SLEEP |
diff --git a/drivers/net/wireless/intel/iwlwifi/iwl-7000.c b/drivers/net/wireless/intel/iwlwifi/iwl-7000.c index e60cf141ed79..fa41a5e1c890 100644 --- a/drivers/net/wireless/intel/iwlwifi/iwl-7000.c +++ b/drivers/net/wireless/intel/iwlwifi/iwl-7000.c | |||
@@ -74,16 +74,19 @@ | |||
74 | #define IWL7260_UCODE_API_MAX 17 | 74 | #define IWL7260_UCODE_API_MAX 17 |
75 | #define IWL7265_UCODE_API_MAX 17 | 75 | #define IWL7265_UCODE_API_MAX 17 |
76 | #define IWL7265D_UCODE_API_MAX 20 | 76 | #define IWL7265D_UCODE_API_MAX 20 |
77 | #define IWL3168_UCODE_API_MAX 20 | ||
77 | 78 | ||
78 | /* Oldest version we won't warn about */ | 79 | /* Oldest version we won't warn about */ |
79 | #define IWL7260_UCODE_API_OK 13 | 80 | #define IWL7260_UCODE_API_OK 13 |
80 | #define IWL7265_UCODE_API_OK 13 | 81 | #define IWL7265_UCODE_API_OK 13 |
81 | #define IWL7265D_UCODE_API_OK 13 | 82 | #define IWL7265D_UCODE_API_OK 13 |
83 | #define IWL3168_UCODE_API_OK 20 | ||
82 | 84 | ||
83 | /* Lowest firmware API version supported */ | 85 | /* Lowest firmware API version supported */ |
84 | #define IWL7260_UCODE_API_MIN 13 | 86 | #define IWL7260_UCODE_API_MIN 13 |
85 | #define IWL7265_UCODE_API_MIN 13 | 87 | #define IWL7265_UCODE_API_MIN 13 |
86 | #define IWL7265D_UCODE_API_MIN 13 | 88 | #define IWL7265D_UCODE_API_MIN 13 |
89 | #define IWL3168_UCODE_API_MIN 20 | ||
87 | 90 | ||
88 | /* NVM versions */ | 91 | /* NVM versions */ |
89 | #define IWL7260_NVM_VERSION 0x0a1d | 92 | #define IWL7260_NVM_VERSION 0x0a1d |
@@ -92,6 +95,8 @@ | |||
92 | #define IWL3160_TX_POWER_VERSION 0xffff /* meaningless */ | 95 | #define IWL3160_TX_POWER_VERSION 0xffff /* meaningless */ |
93 | #define IWL3165_NVM_VERSION 0x709 | 96 | #define IWL3165_NVM_VERSION 0x709 |
94 | #define IWL3165_TX_POWER_VERSION 0xffff /* meaningless */ | 97 | #define IWL3165_TX_POWER_VERSION 0xffff /* meaningless */ |
98 | #define IWL3168_NVM_VERSION 0xd01 | ||
99 | #define IWL3168_TX_POWER_VERSION 0xffff /* meaningless */ | ||
95 | #define IWL7265_NVM_VERSION 0x0a1d | 100 | #define IWL7265_NVM_VERSION 0x0a1d |
96 | #define IWL7265_TX_POWER_VERSION 0xffff /* meaningless */ | 101 | #define IWL7265_TX_POWER_VERSION 0xffff /* meaningless */ |
97 | #define IWL7265D_NVM_VERSION 0x0c11 | 102 | #define IWL7265D_NVM_VERSION 0x0c11 |
@@ -109,6 +114,9 @@ | |||
109 | #define IWL3160_FW_PRE "iwlwifi-3160-" | 114 | #define IWL3160_FW_PRE "iwlwifi-3160-" |
110 | #define IWL3160_MODULE_FIRMWARE(api) IWL3160_FW_PRE __stringify(api) ".ucode" | 115 | #define IWL3160_MODULE_FIRMWARE(api) IWL3160_FW_PRE __stringify(api) ".ucode" |
111 | 116 | ||
117 | #define IWL3168_FW_PRE "iwlwifi-3168-" | ||
118 | #define IWL3168_MODULE_FIRMWARE(api) IWL3168_FW_PRE __stringify(api) ".ucode" | ||
119 | |||
112 | #define IWL7265_FW_PRE "iwlwifi-7265-" | 120 | #define IWL7265_FW_PRE "iwlwifi-7265-" |
113 | #define IWL7265_MODULE_FIRMWARE(api) IWL7265_FW_PRE __stringify(api) ".ucode" | 121 | #define IWL7265_MODULE_FIRMWARE(api) IWL7265_FW_PRE __stringify(api) ".ucode" |
114 | 122 | ||
@@ -180,6 +188,12 @@ static const struct iwl_ht_params iwl7000_ht_params = { | |||
180 | .ucode_api_ok = IWL7265_UCODE_API_OK, \ | 188 | .ucode_api_ok = IWL7265_UCODE_API_OK, \ |
181 | .ucode_api_min = IWL7265_UCODE_API_MIN | 189 | .ucode_api_min = IWL7265_UCODE_API_MIN |
182 | 190 | ||
191 | #define IWL_DEVICE_3008 \ | ||
192 | IWL_DEVICE_7000_COMMON, \ | ||
193 | .ucode_api_max = IWL3168_UCODE_API_MAX, \ | ||
194 | .ucode_api_ok = IWL3168_UCODE_API_OK, \ | ||
195 | .ucode_api_min = IWL3168_UCODE_API_MIN | ||
196 | |||
183 | #define IWL_DEVICE_7005D \ | 197 | #define IWL_DEVICE_7005D \ |
184 | IWL_DEVICE_7000_COMMON, \ | 198 | IWL_DEVICE_7000_COMMON, \ |
185 | .ucode_api_max = IWL7265D_UCODE_API_MAX, \ | 199 | .ucode_api_max = IWL7265D_UCODE_API_MAX, \ |
@@ -299,11 +313,11 @@ const struct iwl_cfg iwl3165_2ac_cfg = { | |||
299 | 313 | ||
300 | const struct iwl_cfg iwl3168_2ac_cfg = { | 314 | const struct iwl_cfg iwl3168_2ac_cfg = { |
301 | .name = "Intel(R) Dual Band Wireless AC 3168", | 315 | .name = "Intel(R) Dual Band Wireless AC 3168", |
302 | .fw_name_pre = IWL7265D_FW_PRE, | 316 | .fw_name_pre = IWL3168_FW_PRE, |
303 | IWL_DEVICE_7000, | 317 | IWL_DEVICE_3008, |
304 | .ht_params = &iwl7000_ht_params, | 318 | .ht_params = &iwl7000_ht_params, |
305 | .nvm_ver = IWL3165_NVM_VERSION, | 319 | .nvm_ver = IWL3168_NVM_VERSION, |
306 | .nvm_calib_ver = IWL3165_TX_POWER_VERSION, | 320 | .nvm_calib_ver = IWL3168_TX_POWER_VERSION, |
307 | .pwr_tx_backoffs = iwl7265_pwr_tx_backoffs, | 321 | .pwr_tx_backoffs = iwl7265_pwr_tx_backoffs, |
308 | .dccm_len = IWL7265_DCCM_LEN, | 322 | .dccm_len = IWL7265_DCCM_LEN, |
309 | }; | 323 | }; |
@@ -376,5 +390,6 @@ const struct iwl_cfg iwl7265d_n_cfg = { | |||
376 | 390 | ||
377 | MODULE_FIRMWARE(IWL7260_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); | 391 | MODULE_FIRMWARE(IWL7260_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); |
378 | MODULE_FIRMWARE(IWL3160_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); | 392 | MODULE_FIRMWARE(IWL3160_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); |
393 | MODULE_FIRMWARE(IWL3168_MODULE_FIRMWARE(IWL3168_UCODE_API_OK)); | ||
379 | MODULE_FIRMWARE(IWL7265_MODULE_FIRMWARE(IWL7265_UCODE_API_OK)); | 394 | MODULE_FIRMWARE(IWL7265_MODULE_FIRMWARE(IWL7265_UCODE_API_OK)); |
380 | MODULE_FIRMWARE(IWL7265D_MODULE_FIRMWARE(IWL7265D_UCODE_API_OK)); | 395 | MODULE_FIRMWARE(IWL7265D_MODULE_FIRMWARE(IWL7265D_UCODE_API_OK)); |
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/fw-api-tx.h b/drivers/net/wireless/intel/iwlwifi/mvm/fw-api-tx.h index 0036d18334af..ba3f0bbddde8 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/fw-api-tx.h +++ b/drivers/net/wireless/intel/iwlwifi/mvm/fw-api-tx.h | |||
@@ -510,6 +510,9 @@ struct iwl_mvm_tx_resp { | |||
510 | * @scd_ssn: the index of the last contiguously sent packet | 510 | * @scd_ssn: the index of the last contiguously sent packet |
511 | * @txed: number of Txed frames in this batch | 511 | * @txed: number of Txed frames in this batch |
512 | * @txed_2_done: number of Acked frames in this batch | 512 | * @txed_2_done: number of Acked frames in this batch |
513 | * @reduced_txp: power reduced according to TPC. This is the actual value and | ||
514 | * not a copy from the LQ command. Thus, if not the first rate was used | ||
515 | * for Tx-ing then this value will be set to 0 by FW. | ||
513 | */ | 516 | */ |
514 | struct iwl_mvm_ba_notif { | 517 | struct iwl_mvm_ba_notif { |
515 | __le32 sta_addr_lo32; | 518 | __le32 sta_addr_lo32; |
@@ -524,7 +527,8 @@ struct iwl_mvm_ba_notif { | |||
524 | __le16 scd_ssn; | 527 | __le16 scd_ssn; |
525 | u8 txed; | 528 | u8 txed; |
526 | u8 txed_2_done; | 529 | u8 txed_2_done; |
527 | __le16 reserved1; | 530 | u8 reduced_txp; |
531 | u8 reserved1; | ||
528 | } __packed; | 532 | } __packed; |
529 | 533 | ||
530 | /* | 534 | /* |
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/rs.c b/drivers/net/wireless/intel/iwlwifi/mvm/rs.c index 7bb6fd0e4391..94caa88df442 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/rs.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/rs.c | |||
@@ -2,6 +2,7 @@ | |||
2 | * | 2 | * |
3 | * Copyright(c) 2005 - 2014 Intel Corporation. All rights reserved. | 3 | * Copyright(c) 2005 - 2014 Intel Corporation. All rights reserved. |
4 | * Copyright(c) 2013 - 2015 Intel Mobile Communications GmbH | 4 | * Copyright(c) 2013 - 2015 Intel Mobile Communications GmbH |
5 | * Copyright(c) 2016 Intel Deutschland GmbH | ||
5 | * | 6 | * |
6 | * This program is free software; you can redistribute it and/or modify it | 7 | * This program is free software; you can redistribute it and/or modify it |
7 | * under the terms of version 2 of the GNU General Public License as | 8 | * under the terms of version 2 of the GNU General Public License as |
@@ -724,14 +725,28 @@ static int _rs_collect_tx_data(struct iwl_mvm *mvm, | |||
724 | return 0; | 725 | return 0; |
725 | } | 726 | } |
726 | 727 | ||
727 | static int rs_collect_tx_data(struct iwl_mvm *mvm, | 728 | static int rs_collect_tpc_data(struct iwl_mvm *mvm, |
728 | struct iwl_lq_sta *lq_sta, | 729 | struct iwl_lq_sta *lq_sta, |
729 | struct iwl_scale_tbl_info *tbl, | 730 | struct iwl_scale_tbl_info *tbl, |
730 | int scale_index, int attempts, int successes, | 731 | int scale_index, int attempts, int successes, |
731 | u8 reduced_txp) | 732 | u8 reduced_txp) |
733 | { | ||
734 | struct iwl_rate_scale_data *window = NULL; | ||
735 | |||
736 | if (WARN_ON_ONCE(reduced_txp > TPC_MAX_REDUCTION)) | ||
737 | return -EINVAL; | ||
738 | |||
739 | window = &tbl->tpc_win[reduced_txp]; | ||
740 | return _rs_collect_tx_data(mvm, tbl, scale_index, attempts, successes, | ||
741 | window); | ||
742 | } | ||
743 | |||
744 | static int rs_collect_tlc_data(struct iwl_mvm *mvm, | ||
745 | struct iwl_lq_sta *lq_sta, | ||
746 | struct iwl_scale_tbl_info *tbl, | ||
747 | int scale_index, int attempts, int successes) | ||
732 | { | 748 | { |
733 | struct iwl_rate_scale_data *window = NULL; | 749 | struct iwl_rate_scale_data *window = NULL; |
734 | int ret; | ||
735 | 750 | ||
736 | if (scale_index < 0 || scale_index >= IWL_RATE_COUNT) | 751 | if (scale_index < 0 || scale_index >= IWL_RATE_COUNT) |
737 | return -EINVAL; | 752 | return -EINVAL; |
@@ -745,16 +760,6 @@ static int rs_collect_tx_data(struct iwl_mvm *mvm, | |||
745 | 760 | ||
746 | /* Select window for current tx bit rate */ | 761 | /* Select window for current tx bit rate */ |
747 | window = &(tbl->win[scale_index]); | 762 | window = &(tbl->win[scale_index]); |
748 | |||
749 | ret = _rs_collect_tx_data(mvm, tbl, scale_index, attempts, successes, | ||
750 | window); | ||
751 | if (ret) | ||
752 | return ret; | ||
753 | |||
754 | if (WARN_ON_ONCE(reduced_txp > TPC_MAX_REDUCTION)) | ||
755 | return -EINVAL; | ||
756 | |||
757 | window = &tbl->tpc_win[reduced_txp]; | ||
758 | return _rs_collect_tx_data(mvm, tbl, scale_index, attempts, successes, | 763 | return _rs_collect_tx_data(mvm, tbl, scale_index, attempts, successes, |
759 | window); | 764 | window); |
760 | } | 765 | } |
@@ -1301,17 +1306,30 @@ void iwl_mvm_rs_tx_status(struct iwl_mvm *mvm, struct ieee80211_sta *sta, | |||
1301 | * first index into rate scale table. | 1306 | * first index into rate scale table. |
1302 | */ | 1307 | */ |
1303 | if (info->flags & IEEE80211_TX_STAT_AMPDU) { | 1308 | if (info->flags & IEEE80211_TX_STAT_AMPDU) { |
1304 | /* ampdu_ack_len = 0 marks no BA was received. In this case | 1309 | rs_collect_tpc_data(mvm, lq_sta, curr_tbl, lq_rate.index, |
1305 | * treat it as a single frame loss as we don't want the success | 1310 | info->status.ampdu_len, |
1306 | * ratio to dip too quickly because a BA wasn't received | 1311 | info->status.ampdu_ack_len, |
1312 | reduced_txp); | ||
1313 | |||
1314 | /* ampdu_ack_len = 0 marks no BA was received. For TLC, treat | ||
1315 | * it as a single frame loss as we don't want the success ratio | ||
1316 | * to dip too quickly because a BA wasn't received. | ||
1317 | * For TPC, there's no need for this optimisation since we want | ||
1318 | * to recover very quickly from a bad power reduction and, | ||
1319 | * therefore we'd like the success ratio to get an immediate hit | ||
1320 | * when failing to get a BA, so we'd switch back to a lower or | ||
1321 | * zero power reduction. When FW transmits agg with a rate | ||
1322 | * different from the initial rate, it will not use reduced txp | ||
1323 | * and will send BA notification twice (one empty with reduced | ||
1324 | * txp equal to the value from LQ and one with reduced txp 0). | ||
1325 | * We need to update counters for each txp level accordingly. | ||
1307 | */ | 1326 | */ |
1308 | if (info->status.ampdu_ack_len == 0) | 1327 | if (info->status.ampdu_ack_len == 0) |
1309 | info->status.ampdu_len = 1; | 1328 | info->status.ampdu_len = 1; |
1310 | 1329 | ||
1311 | rs_collect_tx_data(mvm, lq_sta, curr_tbl, lq_rate.index, | 1330 | rs_collect_tlc_data(mvm, lq_sta, curr_tbl, lq_rate.index, |
1312 | info->status.ampdu_len, | 1331 | info->status.ampdu_len, |
1313 | info->status.ampdu_ack_len, | 1332 | info->status.ampdu_ack_len); |
1314 | reduced_txp); | ||
1315 | 1333 | ||
1316 | /* Update success/fail counts if not searching for new mode */ | 1334 | /* Update success/fail counts if not searching for new mode */ |
1317 | if (lq_sta->rs_state == RS_STATE_STAY_IN_COLUMN) { | 1335 | if (lq_sta->rs_state == RS_STATE_STAY_IN_COLUMN) { |
@@ -1344,9 +1362,13 @@ void iwl_mvm_rs_tx_status(struct iwl_mvm *mvm, struct ieee80211_sta *sta, | |||
1344 | else | 1362 | else |
1345 | continue; | 1363 | continue; |
1346 | 1364 | ||
1347 | rs_collect_tx_data(mvm, lq_sta, tmp_tbl, lq_rate.index, | 1365 | rs_collect_tpc_data(mvm, lq_sta, tmp_tbl, |
1348 | 1, i < retries ? 0 : legacy_success, | 1366 | lq_rate.index, 1, |
1349 | reduced_txp); | 1367 | i < retries ? 0 : legacy_success, |
1368 | reduced_txp); | ||
1369 | rs_collect_tlc_data(mvm, lq_sta, tmp_tbl, | ||
1370 | lq_rate.index, 1, | ||
1371 | i < retries ? 0 : legacy_success); | ||
1350 | } | 1372 | } |
1351 | 1373 | ||
1352 | /* Update success/fail counts if not searching for new mode */ | 1374 | /* Update success/fail counts if not searching for new mode */ |
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c index 8bf48a7d0f4e..0914ec2fd574 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c | |||
@@ -1029,7 +1029,6 @@ static void iwl_mvm_rx_tx_cmd_agg(struct iwl_mvm *mvm, | |||
1029 | struct iwl_mvm_sta *mvmsta = iwl_mvm_sta_from_mac80211(sta); | 1029 | struct iwl_mvm_sta *mvmsta = iwl_mvm_sta_from_mac80211(sta); |
1030 | mvmsta->tid_data[tid].rate_n_flags = | 1030 | mvmsta->tid_data[tid].rate_n_flags = |
1031 | le32_to_cpu(tx_resp->initial_rate); | 1031 | le32_to_cpu(tx_resp->initial_rate); |
1032 | mvmsta->tid_data[tid].reduced_tpc = tx_resp->reduced_tpc; | ||
1033 | mvmsta->tid_data[tid].tx_time = | 1032 | mvmsta->tid_data[tid].tx_time = |
1034 | le16_to_cpu(tx_resp->wireless_media_time); | 1033 | le16_to_cpu(tx_resp->wireless_media_time); |
1035 | } | 1034 | } |
@@ -1060,7 +1059,7 @@ static void iwl_mvm_tx_info_from_ba_notif(struct ieee80211_tx_info *info, | |||
1060 | /* TODO: not accounted if the whole A-MPDU failed */ | 1059 | /* TODO: not accounted if the whole A-MPDU failed */ |
1061 | info->status.tx_time = tid_data->tx_time; | 1060 | info->status.tx_time = tid_data->tx_time; |
1062 | info->status.status_driver_data[0] = | 1061 | info->status.status_driver_data[0] = |
1063 | (void *)(uintptr_t)tid_data->reduced_tpc; | 1062 | (void *)(uintptr_t)ba_notif->reduced_txp; |
1064 | info->status.status_driver_data[1] = | 1063 | info->status.status_driver_data[1] = |
1065 | (void *)(uintptr_t)tid_data->rate_n_flags; | 1064 | (void *)(uintptr_t)tid_data->rate_n_flags; |
1066 | } | 1065 | } |
@@ -1133,6 +1132,8 @@ void iwl_mvm_rx_ba_notif(struct iwl_mvm *mvm, struct iwl_rx_cmd_buffer *rxb) | |||
1133 | scd_flow, ba_resp_scd_ssn, ba_notif->txed, | 1132 | scd_flow, ba_resp_scd_ssn, ba_notif->txed, |
1134 | ba_notif->txed_2_done); | 1133 | ba_notif->txed_2_done); |
1135 | 1134 | ||
1135 | IWL_DEBUG_TX_REPLY(mvm, "reduced txp from ba notif %d\n", | ||
1136 | ba_notif->reduced_txp); | ||
1136 | tid_data->next_reclaimed = ba_resp_scd_ssn; | 1137 | tid_data->next_reclaimed = ba_resp_scd_ssn; |
1137 | 1138 | ||
1138 | iwl_mvm_check_ratid_empty(mvm, sta, tid); | 1139 | iwl_mvm_check_ratid_empty(mvm, sta, tid); |
diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/drv.c b/drivers/net/wireless/intel/iwlwifi/pcie/drv.c index 6261a68cae90..00335ea6b3eb 100644 --- a/drivers/net/wireless/intel/iwlwifi/pcie/drv.c +++ b/drivers/net/wireless/intel/iwlwifi/pcie/drv.c | |||
@@ -378,7 +378,10 @@ static const struct pci_device_id iwl_hw_card_ids[] = { | |||
378 | {IWL_PCI_DEVICE(0x3165, 0x8110, iwl3165_2ac_cfg)}, | 378 | {IWL_PCI_DEVICE(0x3165, 0x8110, iwl3165_2ac_cfg)}, |
379 | 379 | ||
380 | /* 3168 Series */ | 380 | /* 3168 Series */ |
381 | {IWL_PCI_DEVICE(0x24FB, 0x2010, iwl3168_2ac_cfg)}, | ||
381 | {IWL_PCI_DEVICE(0x24FB, 0x2110, iwl3168_2ac_cfg)}, | 382 | {IWL_PCI_DEVICE(0x24FB, 0x2110, iwl3168_2ac_cfg)}, |
383 | {IWL_PCI_DEVICE(0x24FB, 0x2050, iwl3168_2ac_cfg)}, | ||
384 | {IWL_PCI_DEVICE(0x24FB, 0x2150, iwl3168_2ac_cfg)}, | ||
382 | {IWL_PCI_DEVICE(0x24FB, 0x0000, iwl3168_2ac_cfg)}, | 385 | {IWL_PCI_DEVICE(0x24FB, 0x0000, iwl3168_2ac_cfg)}, |
383 | 386 | ||
384 | /* 7265 Series */ | 387 | /* 7265 Series */ |
@@ -475,6 +478,7 @@ static const struct pci_device_id iwl_hw_card_ids[] = { | |||
475 | {IWL_PCI_DEVICE(0x24F3, 0x0000, iwl8265_2ac_cfg)}, | 478 | {IWL_PCI_DEVICE(0x24F3, 0x0000, iwl8265_2ac_cfg)}, |
476 | {IWL_PCI_DEVICE(0x24FD, 0x0010, iwl8265_2ac_cfg)}, | 479 | {IWL_PCI_DEVICE(0x24FD, 0x0010, iwl8265_2ac_cfg)}, |
477 | {IWL_PCI_DEVICE(0x24FD, 0x8010, iwl8265_2ac_cfg)}, | 480 | {IWL_PCI_DEVICE(0x24FD, 0x8010, iwl8265_2ac_cfg)}, |
481 | {IWL_PCI_DEVICE(0x24FD, 0x0810, iwl8265_2ac_cfg)}, | ||
478 | 482 | ||
479 | /* 9000 Series */ | 483 | /* 9000 Series */ |
480 | {IWL_PCI_DEVICE(0x9DF0, 0x2A10, iwl5165_2ac_cfg)}, | 484 | {IWL_PCI_DEVICE(0x9DF0, 0x2A10, iwl5165_2ac_cfg)}, |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2400pci.c b/drivers/net/wireless/ralink/rt2x00/rt2400pci.c index 9a3966cd6fbe..155f343981fe 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2400pci.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2400pci.c | |||
@@ -273,8 +273,10 @@ static void rt2400pci_config_filter(struct rt2x00_dev *rt2x00dev, | |||
273 | !(filter_flags & FIF_PLCPFAIL)); | 273 | !(filter_flags & FIF_PLCPFAIL)); |
274 | rt2x00_set_field32(®, RXCSR0_DROP_CONTROL, | 274 | rt2x00_set_field32(®, RXCSR0_DROP_CONTROL, |
275 | !(filter_flags & FIF_CONTROL)); | 275 | !(filter_flags & FIF_CONTROL)); |
276 | rt2x00_set_field32(®, RXCSR0_DROP_NOT_TO_ME, 1); | 276 | rt2x00_set_field32(®, RXCSR0_DROP_NOT_TO_ME, |
277 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags)); | ||
277 | rt2x00_set_field32(®, RXCSR0_DROP_TODS, | 278 | rt2x00_set_field32(®, RXCSR0_DROP_TODS, |
279 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags) && | ||
278 | !rt2x00dev->intf_ap_count); | 280 | !rt2x00dev->intf_ap_count); |
279 | rt2x00_set_field32(®, RXCSR0_DROP_VERSION_ERROR, 1); | 281 | rt2x00_set_field32(®, RXCSR0_DROP_VERSION_ERROR, 1); |
280 | rt2x00mmio_register_write(rt2x00dev, RXCSR0, reg); | 282 | rt2x00mmio_register_write(rt2x00dev, RXCSR0, reg); |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2500pci.c b/drivers/net/wireless/ralink/rt2x00/rt2500pci.c index 1a6740b4d396..2553cdd74066 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2500pci.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2500pci.c | |||
@@ -274,8 +274,10 @@ static void rt2500pci_config_filter(struct rt2x00_dev *rt2x00dev, | |||
274 | !(filter_flags & FIF_PLCPFAIL)); | 274 | !(filter_flags & FIF_PLCPFAIL)); |
275 | rt2x00_set_field32(®, RXCSR0_DROP_CONTROL, | 275 | rt2x00_set_field32(®, RXCSR0_DROP_CONTROL, |
276 | !(filter_flags & FIF_CONTROL)); | 276 | !(filter_flags & FIF_CONTROL)); |
277 | rt2x00_set_field32(®, RXCSR0_DROP_NOT_TO_ME, 1); | 277 | rt2x00_set_field32(®, RXCSR0_DROP_NOT_TO_ME, |
278 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags)); | ||
278 | rt2x00_set_field32(®, RXCSR0_DROP_TODS, | 279 | rt2x00_set_field32(®, RXCSR0_DROP_TODS, |
280 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags) && | ||
279 | !rt2x00dev->intf_ap_count); | 281 | !rt2x00dev->intf_ap_count); |
280 | rt2x00_set_field32(®, RXCSR0_DROP_VERSION_ERROR, 1); | 282 | rt2x00_set_field32(®, RXCSR0_DROP_VERSION_ERROR, 1); |
281 | rt2x00_set_field32(®, RXCSR0_DROP_MCAST, | 283 | rt2x00_set_field32(®, RXCSR0_DROP_MCAST, |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2500usb.c b/drivers/net/wireless/ralink/rt2x00/rt2500usb.c index d26018f30b7d..2d64611de300 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2500usb.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2500usb.c | |||
@@ -437,8 +437,10 @@ static void rt2500usb_config_filter(struct rt2x00_dev *rt2x00dev, | |||
437 | !(filter_flags & FIF_PLCPFAIL)); | 437 | !(filter_flags & FIF_PLCPFAIL)); |
438 | rt2x00_set_field16(®, TXRX_CSR2_DROP_CONTROL, | 438 | rt2x00_set_field16(®, TXRX_CSR2_DROP_CONTROL, |
439 | !(filter_flags & FIF_CONTROL)); | 439 | !(filter_flags & FIF_CONTROL)); |
440 | rt2x00_set_field16(®, TXRX_CSR2_DROP_NOT_TO_ME, 1); | 440 | rt2x00_set_field16(®, TXRX_CSR2_DROP_NOT_TO_ME, |
441 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags)); | ||
441 | rt2x00_set_field16(®, TXRX_CSR2_DROP_TODS, | 442 | rt2x00_set_field16(®, TXRX_CSR2_DROP_TODS, |
443 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags) && | ||
442 | !rt2x00dev->intf_ap_count); | 444 | !rt2x00dev->intf_ap_count); |
443 | rt2x00_set_field16(®, TXRX_CSR2_DROP_VERSION_ERROR, 1); | 445 | rt2x00_set_field16(®, TXRX_CSR2_DROP_VERSION_ERROR, 1); |
444 | rt2x00_set_field16(®, TXRX_CSR2_DROP_MULTICAST, | 446 | rt2x00_set_field16(®, TXRX_CSR2_DROP_MULTICAST, |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c index 9733b31a780d..a26afcab03ed 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c | |||
@@ -1490,7 +1490,8 @@ void rt2800_config_filter(struct rt2x00_dev *rt2x00dev, | |||
1490 | !(filter_flags & FIF_FCSFAIL)); | 1490 | !(filter_flags & FIF_FCSFAIL)); |
1491 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_PHY_ERROR, | 1491 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_PHY_ERROR, |
1492 | !(filter_flags & FIF_PLCPFAIL)); | 1492 | !(filter_flags & FIF_PLCPFAIL)); |
1493 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_NOT_TO_ME, 1); | 1493 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_NOT_TO_ME, |
1494 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags)); | ||
1494 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_NOT_MY_BSSD, 0); | 1495 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_NOT_MY_BSSD, 0); |
1495 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_VER_ERROR, 1); | 1496 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_VER_ERROR, 1); |
1496 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_MULTICAST, | 1497 | rt2x00_set_field32(®, RX_FILTER_CFG_DROP_MULTICAST, |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2x00.h b/drivers/net/wireless/ralink/rt2x00/rt2x00.h index 3282ddb766f4..26427140a963 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h | |||
@@ -669,6 +669,7 @@ enum rt2x00_state_flags { | |||
669 | CONFIG_POWERSAVING, | 669 | CONFIG_POWERSAVING, |
670 | CONFIG_HT_DISABLED, | 670 | CONFIG_HT_DISABLED, |
671 | CONFIG_QOS_DISABLED, | 671 | CONFIG_QOS_DISABLED, |
672 | CONFIG_MONITORING, | ||
672 | 673 | ||
673 | /* | 674 | /* |
674 | * Mark we currently are sequentially reading TX_STA_FIFO register | 675 | * Mark we currently are sequentially reading TX_STA_FIFO register |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2x00config.c b/drivers/net/wireless/ralink/rt2x00/rt2x00config.c index 7e8bb1198ae9..6a1f508d472f 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2x00config.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00config.c | |||
@@ -277,6 +277,11 @@ void rt2x00lib_config(struct rt2x00_dev *rt2x00dev, | |||
277 | else | 277 | else |
278 | clear_bit(CONFIG_POWERSAVING, &rt2x00dev->flags); | 278 | clear_bit(CONFIG_POWERSAVING, &rt2x00dev->flags); |
279 | 279 | ||
280 | if (conf->flags & IEEE80211_CONF_MONITOR) | ||
281 | set_bit(CONFIG_MONITORING, &rt2x00dev->flags); | ||
282 | else | ||
283 | clear_bit(CONFIG_MONITORING, &rt2x00dev->flags); | ||
284 | |||
280 | rt2x00dev->curr_band = conf->chandef.chan->band; | 285 | rt2x00dev->curr_band = conf->chandef.chan->band; |
281 | rt2x00dev->curr_freq = conf->chandef.chan->center_freq; | 286 | rt2x00dev->curr_freq = conf->chandef.chan->center_freq; |
282 | rt2x00dev->tx_power = conf->power_level; | 287 | rt2x00dev->tx_power = conf->power_level; |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c index 3c26ee65a415..13da95a24cf7 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c | |||
@@ -385,11 +385,6 @@ void rt2x00mac_configure_filter(struct ieee80211_hw *hw, | |||
385 | *total_flags |= FIF_PSPOLL; | 385 | *total_flags |= FIF_PSPOLL; |
386 | } | 386 | } |
387 | 387 | ||
388 | /* | ||
389 | * Check if there is any work left for us. | ||
390 | */ | ||
391 | if (rt2x00dev->packet_filter == *total_flags) | ||
392 | return; | ||
393 | rt2x00dev->packet_filter = *total_flags; | 388 | rt2x00dev->packet_filter = *total_flags; |
394 | 389 | ||
395 | rt2x00dev->ops->lib->config_filter(rt2x00dev, *total_flags); | 390 | rt2x00dev->ops->lib->config_filter(rt2x00dev, *total_flags); |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt61pci.c b/drivers/net/wireless/ralink/rt2x00/rt61pci.c index c0e730ea1b69..24a3436ef952 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt61pci.c +++ b/drivers/net/wireless/ralink/rt2x00/rt61pci.c | |||
@@ -530,8 +530,10 @@ static void rt61pci_config_filter(struct rt2x00_dev *rt2x00dev, | |||
530 | !(filter_flags & FIF_PLCPFAIL)); | 530 | !(filter_flags & FIF_PLCPFAIL)); |
531 | rt2x00_set_field32(®, TXRX_CSR0_DROP_CONTROL, | 531 | rt2x00_set_field32(®, TXRX_CSR0_DROP_CONTROL, |
532 | !(filter_flags & (FIF_CONTROL | FIF_PSPOLL))); | 532 | !(filter_flags & (FIF_CONTROL | FIF_PSPOLL))); |
533 | rt2x00_set_field32(®, TXRX_CSR0_DROP_NOT_TO_ME, 1); | 533 | rt2x00_set_field32(®, TXRX_CSR0_DROP_NOT_TO_ME, |
534 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags)); | ||
534 | rt2x00_set_field32(®, TXRX_CSR0_DROP_TO_DS, | 535 | rt2x00_set_field32(®, TXRX_CSR0_DROP_TO_DS, |
536 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags) && | ||
535 | !rt2x00dev->intf_ap_count); | 537 | !rt2x00dev->intf_ap_count); |
536 | rt2x00_set_field32(®, TXRX_CSR0_DROP_VERSION_ERROR, 1); | 538 | rt2x00_set_field32(®, TXRX_CSR0_DROP_VERSION_ERROR, 1); |
537 | rt2x00_set_field32(®, TXRX_CSR0_DROP_MULTICAST, | 539 | rt2x00_set_field32(®, TXRX_CSR0_DROP_MULTICAST, |
diff --git a/drivers/net/wireless/ralink/rt2x00/rt73usb.c b/drivers/net/wireless/ralink/rt2x00/rt73usb.c index 7081e13b4fd6..7bbc86931168 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt73usb.c +++ b/drivers/net/wireless/ralink/rt2x00/rt73usb.c | |||
@@ -480,8 +480,10 @@ static void rt73usb_config_filter(struct rt2x00_dev *rt2x00dev, | |||
480 | !(filter_flags & FIF_PLCPFAIL)); | 480 | !(filter_flags & FIF_PLCPFAIL)); |
481 | rt2x00_set_field32(®, TXRX_CSR0_DROP_CONTROL, | 481 | rt2x00_set_field32(®, TXRX_CSR0_DROP_CONTROL, |
482 | !(filter_flags & (FIF_CONTROL | FIF_PSPOLL))); | 482 | !(filter_flags & (FIF_CONTROL | FIF_PSPOLL))); |
483 | rt2x00_set_field32(®, TXRX_CSR0_DROP_NOT_TO_ME, 1); | 483 | rt2x00_set_field32(®, TXRX_CSR0_DROP_NOT_TO_ME, |
484 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags)); | ||
484 | rt2x00_set_field32(®, TXRX_CSR0_DROP_TO_DS, | 485 | rt2x00_set_field32(®, TXRX_CSR0_DROP_TO_DS, |
486 | !test_bit(CONFIG_MONITORING, &rt2x00dev->flags) && | ||
485 | !rt2x00dev->intf_ap_count); | 487 | !rt2x00dev->intf_ap_count); |
486 | rt2x00_set_field32(®, TXRX_CSR0_DROP_VERSION_ERROR, 1); | 488 | rt2x00_set_field32(®, TXRX_CSR0_DROP_VERSION_ERROR, 1); |
487 | rt2x00_set_field32(®, TXRX_CSR0_DROP_MULTICAST, | 489 | rt2x00_set_field32(®, TXRX_CSR0_DROP_MULTICAST, |
diff --git a/drivers/net/wireless/realtek/rtlwifi/regd.c b/drivers/net/wireless/realtek/rtlwifi/regd.c index a62bf0a65c32..5be34118e0af 100644 --- a/drivers/net/wireless/realtek/rtlwifi/regd.c +++ b/drivers/net/wireless/realtek/rtlwifi/regd.c | |||
@@ -351,7 +351,6 @@ static const struct ieee80211_regdomain *_rtl_regdomain_select( | |||
351 | case COUNTRY_CODE_SPAIN: | 351 | case COUNTRY_CODE_SPAIN: |
352 | case COUNTRY_CODE_FRANCE: | 352 | case COUNTRY_CODE_FRANCE: |
353 | case COUNTRY_CODE_ISRAEL: | 353 | case COUNTRY_CODE_ISRAEL: |
354 | case COUNTRY_CODE_WORLD_WIDE_13: | ||
355 | return &rtl_regdom_12_13; | 354 | return &rtl_regdom_12_13; |
356 | case COUNTRY_CODE_MKK: | 355 | case COUNTRY_CODE_MKK: |
357 | case COUNTRY_CODE_MKK1: | 356 | case COUNTRY_CODE_MKK1: |
@@ -360,6 +359,7 @@ static const struct ieee80211_regdomain *_rtl_regdomain_select( | |||
360 | return &rtl_regdom_14_60_64; | 359 | return &rtl_regdom_14_60_64; |
361 | case COUNTRY_CODE_GLOBAL_DOMAIN: | 360 | case COUNTRY_CODE_GLOBAL_DOMAIN: |
362 | return &rtl_regdom_14; | 361 | return &rtl_regdom_14; |
362 | case COUNTRY_CODE_WORLD_WIDE_13: | ||
363 | case COUNTRY_CODE_WORLD_WIDE_13_5G_ALL: | 363 | case COUNTRY_CODE_WORLD_WIDE_13_5G_ALL: |
364 | return &rtl_regdom_12_13_5g_all; | 364 | return &rtl_regdom_12_13_5g_all; |
365 | default: | 365 | default: |
diff --git a/drivers/ssb/main.c b/drivers/ssb/main.c index cde5ff7529eb..d1a750760cf3 100644 --- a/drivers/ssb/main.c +++ b/drivers/ssb/main.c | |||
@@ -613,9 +613,10 @@ out: | |||
613 | return err; | 613 | return err; |
614 | } | 614 | } |
615 | 615 | ||
616 | static int ssb_bus_register(struct ssb_bus *bus, | 616 | static int __maybe_unused |
617 | ssb_invariants_func_t get_invariants, | 617 | ssb_bus_register(struct ssb_bus *bus, |
618 | unsigned long baseaddr) | 618 | ssb_invariants_func_t get_invariants, |
619 | unsigned long baseaddr) | ||
619 | { | 620 | { |
620 | int err; | 621 | int err; |
621 | 622 | ||