diff options
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/wireless/iwlwifi/Kconfig | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/dvm/power.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/dvm/rxon.c | 12 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-7000.c | 20 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-8000.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-config.h | 3 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-nvm-parse.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/coex.c | 9 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/debugfs-vif.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/fw-api.h | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c | 10 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/mac80211.c | 25 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/power.c | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/rx.c | 6 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/sf.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/tx.c | 8 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/pcie/drv.c | 7 |
17 files changed, 80 insertions, 44 deletions
diff --git a/drivers/net/wireless/iwlwifi/Kconfig b/drivers/net/wireless/iwlwifi/Kconfig index 760e96f63bb0..267e48a2915e 100644 --- a/drivers/net/wireless/iwlwifi/Kconfig +++ b/drivers/net/wireless/iwlwifi/Kconfig | |||
@@ -51,7 +51,6 @@ config IWLWIFI_LEDS | |||
51 | 51 | ||
52 | config IWLDVM | 52 | config IWLDVM |
53 | tristate "Intel Wireless WiFi DVM Firmware support" | 53 | tristate "Intel Wireless WiFi DVM Firmware support" |
54 | depends on m | ||
55 | default IWLWIFI | 54 | default IWLWIFI |
56 | help | 55 | help |
57 | This is the driver that supports the DVM firmware which is | 56 | This is the driver that supports the DVM firmware which is |
@@ -60,7 +59,6 @@ config IWLDVM | |||
60 | 59 | ||
61 | config IWLMVM | 60 | config IWLMVM |
62 | tristate "Intel Wireless WiFi MVM Firmware support" | 61 | tristate "Intel Wireless WiFi MVM Firmware support" |
63 | depends on m | ||
64 | help | 62 | help |
65 | This is the driver that supports the MVM firmware which is | 63 | This is the driver that supports the MVM firmware which is |
66 | currently only available for 7260 and 3160 devices. | 64 | currently only available for 7260 and 3160 devices. |
diff --git a/drivers/net/wireless/iwlwifi/dvm/power.c b/drivers/net/wireless/iwlwifi/dvm/power.c index 760c45c34ef3..1513dbc79c14 100644 --- a/drivers/net/wireless/iwlwifi/dvm/power.c +++ b/drivers/net/wireless/iwlwifi/dvm/power.c | |||
@@ -40,7 +40,7 @@ | |||
40 | #include "commands.h" | 40 | #include "commands.h" |
41 | #include "power.h" | 41 | #include "power.h" |
42 | 42 | ||
43 | static bool force_cam; | 43 | static bool force_cam = true; |
44 | module_param(force_cam, bool, 0644); | 44 | module_param(force_cam, bool, 0644); |
45 | MODULE_PARM_DESC(force_cam, "force continuously aware mode (no power saving at all)"); | 45 | MODULE_PARM_DESC(force_cam, "force continuously aware mode (no power saving at all)"); |
46 | 46 | ||
diff --git a/drivers/net/wireless/iwlwifi/dvm/rxon.c b/drivers/net/wireless/iwlwifi/dvm/rxon.c index 6dc5dd3ced44..ed50de6362ed 100644 --- a/drivers/net/wireless/iwlwifi/dvm/rxon.c +++ b/drivers/net/wireless/iwlwifi/dvm/rxon.c | |||
@@ -1068,6 +1068,13 @@ int iwlagn_commit_rxon(struct iwl_priv *priv, struct iwl_rxon_context *ctx) | |||
1068 | /* recalculate basic rates */ | 1068 | /* recalculate basic rates */ |
1069 | iwl_calc_basic_rates(priv, ctx); | 1069 | iwl_calc_basic_rates(priv, ctx); |
1070 | 1070 | ||
1071 | /* | ||
1072 | * force CTS-to-self frames protection if RTS-CTS is not preferred | ||
1073 | * one aggregation protection method | ||
1074 | */ | ||
1075 | if (!priv->hw_params.use_rts_for_aggregation) | ||
1076 | ctx->staging.flags |= RXON_FLG_SELF_CTS_EN; | ||
1077 | |||
1071 | if ((ctx->vif && ctx->vif->bss_conf.use_short_slot) || | 1078 | if ((ctx->vif && ctx->vif->bss_conf.use_short_slot) || |
1072 | !(ctx->staging.flags & RXON_FLG_BAND_24G_MSK)) | 1079 | !(ctx->staging.flags & RXON_FLG_BAND_24G_MSK)) |
1073 | ctx->staging.flags |= RXON_FLG_SHORT_SLOT_MSK; | 1080 | ctx->staging.flags |= RXON_FLG_SHORT_SLOT_MSK; |
@@ -1473,6 +1480,11 @@ void iwlagn_bss_info_changed(struct ieee80211_hw *hw, | |||
1473 | else | 1480 | else |
1474 | ctx->staging.flags &= ~RXON_FLG_TGG_PROTECT_MSK; | 1481 | ctx->staging.flags &= ~RXON_FLG_TGG_PROTECT_MSK; |
1475 | 1482 | ||
1483 | if (bss_conf->use_cts_prot) | ||
1484 | ctx->staging.flags |= RXON_FLG_SELF_CTS_EN; | ||
1485 | else | ||
1486 | ctx->staging.flags &= ~RXON_FLG_SELF_CTS_EN; | ||
1487 | |||
1476 | memcpy(ctx->staging.bssid_addr, bss_conf->bssid, ETH_ALEN); | 1488 | memcpy(ctx->staging.bssid_addr, bss_conf->bssid, ETH_ALEN); |
1477 | 1489 | ||
1478 | if (vif->type == NL80211_IFTYPE_AP || | 1490 | if (vif->type == NL80211_IFTYPE_AP || |
diff --git a/drivers/net/wireless/iwlwifi/iwl-7000.c b/drivers/net/wireless/iwlwifi/iwl-7000.c index 446654aed017..8e99dffa88e8 100644 --- a/drivers/net/wireless/iwlwifi/iwl-7000.c +++ b/drivers/net/wireless/iwlwifi/iwl-7000.c | |||
@@ -69,8 +69,8 @@ | |||
69 | #include "iwl-agn-hw.h" | 69 | #include "iwl-agn-hw.h" |
70 | 70 | ||
71 | /* Highest firmware API version supported */ | 71 | /* Highest firmware API version supported */ |
72 | #define IWL7260_UCODE_API_MAX 9 | 72 | #define IWL7260_UCODE_API_MAX 10 |
73 | #define IWL3160_UCODE_API_MAX 9 | 73 | #define IWL3160_UCODE_API_MAX 10 |
74 | 74 | ||
75 | /* Oldest version we won't warn about */ | 75 | /* Oldest version we won't warn about */ |
76 | #define IWL7260_UCODE_API_OK 9 | 76 | #define IWL7260_UCODE_API_OK 9 |
@@ -85,6 +85,8 @@ | |||
85 | #define IWL7260_TX_POWER_VERSION 0xffff /* meaningless */ | 85 | #define IWL7260_TX_POWER_VERSION 0xffff /* meaningless */ |
86 | #define IWL3160_NVM_VERSION 0x709 | 86 | #define IWL3160_NVM_VERSION 0x709 |
87 | #define IWL3160_TX_POWER_VERSION 0xffff /* meaningless */ | 87 | #define IWL3160_TX_POWER_VERSION 0xffff /* meaningless */ |
88 | #define IWL3165_NVM_VERSION 0x709 | ||
89 | #define IWL3165_TX_POWER_VERSION 0xffff /* meaningless */ | ||
88 | #define IWL7265_NVM_VERSION 0x0a1d | 90 | #define IWL7265_NVM_VERSION 0x0a1d |
89 | #define IWL7265_TX_POWER_VERSION 0xffff /* meaningless */ | 91 | #define IWL7265_TX_POWER_VERSION 0xffff /* meaningless */ |
90 | 92 | ||
@@ -94,6 +96,9 @@ | |||
94 | #define IWL3160_FW_PRE "iwlwifi-3160-" | 96 | #define IWL3160_FW_PRE "iwlwifi-3160-" |
95 | #define IWL3160_MODULE_FIRMWARE(api) IWL3160_FW_PRE __stringify(api) ".ucode" | 97 | #define IWL3160_MODULE_FIRMWARE(api) IWL3160_FW_PRE __stringify(api) ".ucode" |
96 | 98 | ||
99 | #define IWL3165_FW_PRE "iwlwifi-3165-" | ||
100 | #define IWL3165_MODULE_FIRMWARE(api) IWL3165_FW_PRE __stringify(api) ".ucode" | ||
101 | |||
97 | #define IWL7265_FW_PRE "iwlwifi-7265-" | 102 | #define IWL7265_FW_PRE "iwlwifi-7265-" |
98 | #define IWL7265_MODULE_FIRMWARE(api) IWL7265_FW_PRE __stringify(api) ".ucode" | 103 | #define IWL7265_MODULE_FIRMWARE(api) IWL7265_FW_PRE __stringify(api) ".ucode" |
99 | 104 | ||
@@ -215,6 +220,16 @@ static const struct iwl_pwr_tx_backoff iwl7265_pwr_tx_backoffs[] = { | |||
215 | {0}, | 220 | {0}, |
216 | }; | 221 | }; |
217 | 222 | ||
223 | const struct iwl_cfg iwl3165_2ac_cfg = { | ||
224 | .name = "Intel(R) Dual Band Wireless AC 3165", | ||
225 | .fw_name_pre = IWL3165_FW_PRE, | ||
226 | IWL_DEVICE_7000, | ||
227 | .ht_params = &iwl7000_ht_params, | ||
228 | .nvm_ver = IWL3165_NVM_VERSION, | ||
229 | .nvm_calib_ver = IWL3165_TX_POWER_VERSION, | ||
230 | .pwr_tx_backoffs = iwl7265_pwr_tx_backoffs, | ||
231 | }; | ||
232 | |||
218 | const struct iwl_cfg iwl7265_2ac_cfg = { | 233 | const struct iwl_cfg iwl7265_2ac_cfg = { |
219 | .name = "Intel(R) Dual Band Wireless AC 7265", | 234 | .name = "Intel(R) Dual Band Wireless AC 7265", |
220 | .fw_name_pre = IWL7265_FW_PRE, | 235 | .fw_name_pre = IWL7265_FW_PRE, |
@@ -247,4 +262,5 @@ const struct iwl_cfg iwl7265_n_cfg = { | |||
247 | 262 | ||
248 | MODULE_FIRMWARE(IWL7260_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); | 263 | MODULE_FIRMWARE(IWL7260_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); |
249 | MODULE_FIRMWARE(IWL3160_MODULE_FIRMWARE(IWL3160_UCODE_API_OK)); | 264 | MODULE_FIRMWARE(IWL3160_MODULE_FIRMWARE(IWL3160_UCODE_API_OK)); |
265 | MODULE_FIRMWARE(IWL3165_MODULE_FIRMWARE(IWL3160_UCODE_API_OK)); | ||
250 | MODULE_FIRMWARE(IWL7265_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); | 266 | MODULE_FIRMWARE(IWL7265_MODULE_FIRMWARE(IWL7260_UCODE_API_OK)); |
diff --git a/drivers/net/wireless/iwlwifi/iwl-8000.c b/drivers/net/wireless/iwlwifi/iwl-8000.c index 90388e70db9b..23a67bfc086f 100644 --- a/drivers/net/wireless/iwlwifi/iwl-8000.c +++ b/drivers/net/wireless/iwlwifi/iwl-8000.c | |||
@@ -69,7 +69,7 @@ | |||
69 | #include "iwl-agn-hw.h" | 69 | #include "iwl-agn-hw.h" |
70 | 70 | ||
71 | /* Highest firmware API version supported */ | 71 | /* Highest firmware API version supported */ |
72 | #define IWL8000_UCODE_API_MAX 9 | 72 | #define IWL8000_UCODE_API_MAX 10 |
73 | 73 | ||
74 | /* Oldest version we won't warn about */ | 74 | /* Oldest version we won't warn about */ |
75 | #define IWL8000_UCODE_API_OK 8 | 75 | #define IWL8000_UCODE_API_OK 8 |
diff --git a/drivers/net/wireless/iwlwifi/iwl-config.h b/drivers/net/wireless/iwlwifi/iwl-config.h index 8da596db9abe..3d7cc37420ae 100644 --- a/drivers/net/wireless/iwlwifi/iwl-config.h +++ b/drivers/net/wireless/iwlwifi/iwl-config.h | |||
@@ -120,6 +120,8 @@ enum iwl_led_mode { | |||
120 | #define IWL_LONG_WD_TIMEOUT 10000 | 120 | #define IWL_LONG_WD_TIMEOUT 10000 |
121 | #define IWL_MAX_WD_TIMEOUT 120000 | 121 | #define IWL_MAX_WD_TIMEOUT 120000 |
122 | 122 | ||
123 | #define IWL_DEFAULT_MAX_TX_POWER 22 | ||
124 | |||
123 | /* Antenna presence definitions */ | 125 | /* Antenna presence definitions */ |
124 | #define ANT_NONE 0x0 | 126 | #define ANT_NONE 0x0 |
125 | #define ANT_A BIT(0) | 127 | #define ANT_A BIT(0) |
@@ -335,6 +337,7 @@ extern const struct iwl_cfg iwl7260_n_cfg; | |||
335 | extern const struct iwl_cfg iwl3160_2ac_cfg; | 337 | extern const struct iwl_cfg iwl3160_2ac_cfg; |
336 | extern const struct iwl_cfg iwl3160_2n_cfg; | 338 | extern const struct iwl_cfg iwl3160_2n_cfg; |
337 | extern const struct iwl_cfg iwl3160_n_cfg; | 339 | extern const struct iwl_cfg iwl3160_n_cfg; |
340 | extern const struct iwl_cfg iwl3165_2ac_cfg; | ||
338 | extern const struct iwl_cfg iwl7265_2ac_cfg; | 341 | extern const struct iwl_cfg iwl7265_2ac_cfg; |
339 | extern const struct iwl_cfg iwl7265_2n_cfg; | 342 | extern const struct iwl_cfg iwl7265_2n_cfg; |
340 | extern const struct iwl_cfg iwl7265_n_cfg; | 343 | extern const struct iwl_cfg iwl7265_n_cfg; |
diff --git a/drivers/net/wireless/iwlwifi/iwl-nvm-parse.c b/drivers/net/wireless/iwlwifi/iwl-nvm-parse.c index 8e7af798abd1..40718f814f8d 100644 --- a/drivers/net/wireless/iwlwifi/iwl-nvm-parse.c +++ b/drivers/net/wireless/iwlwifi/iwl-nvm-parse.c | |||
@@ -148,8 +148,6 @@ static const u8 iwl_nvm_channels_family_8000[] = { | |||
148 | #define LAST_2GHZ_HT_PLUS 9 | 148 | #define LAST_2GHZ_HT_PLUS 9 |
149 | #define LAST_5GHZ_HT 161 | 149 | #define LAST_5GHZ_HT 161 |
150 | 150 | ||
151 | #define DEFAULT_MAX_TX_POWER 16 | ||
152 | |||
153 | /* rate data (static) */ | 151 | /* rate data (static) */ |
154 | static struct ieee80211_rate iwl_cfg80211_rates[] = { | 152 | static struct ieee80211_rate iwl_cfg80211_rates[] = { |
155 | { .bitrate = 1 * 10, .hw_value = 0, .hw_value_short = 0, }, | 153 | { .bitrate = 1 * 10, .hw_value = 0, .hw_value_short = 0, }, |
@@ -297,7 +295,7 @@ static int iwl_init_channel_map(struct device *dev, const struct iwl_cfg *cfg, | |||
297 | * Default value - highest tx power value. max_power | 295 | * Default value - highest tx power value. max_power |
298 | * is not used in mvm, and is used for backwards compatibility | 296 | * is not used in mvm, and is used for backwards compatibility |
299 | */ | 297 | */ |
300 | channel->max_power = DEFAULT_MAX_TX_POWER; | 298 | channel->max_power = IWL_DEFAULT_MAX_TX_POWER; |
301 | is_5ghz = channel->band == IEEE80211_BAND_5GHZ; | 299 | is_5ghz = channel->band == IEEE80211_BAND_5GHZ; |
302 | IWL_DEBUG_EEPROM(dev, | 300 | IWL_DEBUG_EEPROM(dev, |
303 | "Ch. %d [%sGHz] %s%s%s%s%s%s%s(0x%02x %ddBm): Ad-Hoc %ssupported\n", | 301 | "Ch. %d [%sGHz] %s%s%s%s%s%s%s(0x%02x %ddBm): Ad-Hoc %ssupported\n", |
diff --git a/drivers/net/wireless/iwlwifi/mvm/coex.c b/drivers/net/wireless/iwlwifi/mvm/coex.c index 2262d6dc61ae..6e8f3e2aef74 100644 --- a/drivers/net/wireless/iwlwifi/mvm/coex.c +++ b/drivers/net/wireless/iwlwifi/mvm/coex.c | |||
@@ -587,8 +587,6 @@ int iwl_send_bt_init_conf(struct iwl_mvm *mvm) | |||
587 | lockdep_assert_held(&mvm->mutex); | 587 | lockdep_assert_held(&mvm->mutex); |
588 | 588 | ||
589 | if (unlikely(mvm->bt_force_ant_mode != BT_FORCE_ANT_DIS)) { | 589 | if (unlikely(mvm->bt_force_ant_mode != BT_FORCE_ANT_DIS)) { |
590 | u32 mode; | ||
591 | |||
592 | switch (mvm->bt_force_ant_mode) { | 590 | switch (mvm->bt_force_ant_mode) { |
593 | case BT_FORCE_ANT_BT: | 591 | case BT_FORCE_ANT_BT: |
594 | mode = BT_COEX_BT; | 592 | mode = BT_COEX_BT; |
@@ -758,7 +756,8 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac, | |||
758 | struct iwl_bt_iterator_data *data = _data; | 756 | struct iwl_bt_iterator_data *data = _data; |
759 | struct iwl_mvm *mvm = data->mvm; | 757 | struct iwl_mvm *mvm = data->mvm; |
760 | struct ieee80211_chanctx_conf *chanctx_conf; | 758 | struct ieee80211_chanctx_conf *chanctx_conf; |
761 | enum ieee80211_smps_mode smps_mode; | 759 | /* default smps_mode is AUTOMATIC - only used for client modes */ |
760 | enum ieee80211_smps_mode smps_mode = IEEE80211_SMPS_AUTOMATIC; | ||
762 | u32 bt_activity_grading; | 761 | u32 bt_activity_grading; |
763 | int ave_rssi; | 762 | int ave_rssi; |
764 | 763 | ||
@@ -766,8 +765,6 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac, | |||
766 | 765 | ||
767 | switch (vif->type) { | 766 | switch (vif->type) { |
768 | case NL80211_IFTYPE_STATION: | 767 | case NL80211_IFTYPE_STATION: |
769 | /* default smps_mode for BSS / P2P client is AUTOMATIC */ | ||
770 | smps_mode = IEEE80211_SMPS_AUTOMATIC; | ||
771 | break; | 768 | break; |
772 | case NL80211_IFTYPE_AP: | 769 | case NL80211_IFTYPE_AP: |
773 | if (!mvmvif->ap_ibss_active) | 770 | if (!mvmvif->ap_ibss_active) |
@@ -799,7 +796,7 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac, | |||
799 | else if (bt_activity_grading >= BT_LOW_TRAFFIC) | 796 | else if (bt_activity_grading >= BT_LOW_TRAFFIC) |
800 | smps_mode = IEEE80211_SMPS_DYNAMIC; | 797 | smps_mode = IEEE80211_SMPS_DYNAMIC; |
801 | 798 | ||
802 | /* relax SMPS contraints for next association */ | 799 | /* relax SMPS constraints for next association */ |
803 | if (!vif->bss_conf.assoc) | 800 | if (!vif->bss_conf.assoc) |
804 | smps_mode = IEEE80211_SMPS_AUTOMATIC; | 801 | smps_mode = IEEE80211_SMPS_AUTOMATIC; |
805 | 802 | ||
diff --git a/drivers/net/wireless/iwlwifi/mvm/debugfs-vif.c b/drivers/net/wireless/iwlwifi/mvm/debugfs-vif.c index d919b4ebc83c..9aa2311a776c 100644 --- a/drivers/net/wireless/iwlwifi/mvm/debugfs-vif.c +++ b/drivers/net/wireless/iwlwifi/mvm/debugfs-vif.c | |||
@@ -76,8 +76,7 @@ static void iwl_dbgfs_update_pm(struct iwl_mvm *mvm, | |||
76 | 76 | ||
77 | switch (param) { | 77 | switch (param) { |
78 | case MVM_DEBUGFS_PM_KEEP_ALIVE: { | 78 | case MVM_DEBUGFS_PM_KEEP_ALIVE: { |
79 | struct ieee80211_hw *hw = mvm->hw; | 79 | int dtimper = vif->bss_conf.dtim_period ?: 1; |
80 | int dtimper = hw->conf.ps_dtim_period ?: 1; | ||
81 | int dtimper_msec = dtimper * vif->bss_conf.beacon_int; | 80 | int dtimper_msec = dtimper * vif->bss_conf.beacon_int; |
82 | 81 | ||
83 | IWL_DEBUG_POWER(mvm, "debugfs: set keep_alive= %d sec\n", val); | 82 | IWL_DEBUG_POWER(mvm, "debugfs: set keep_alive= %d sec\n", val); |
diff --git a/drivers/net/wireless/iwlwifi/mvm/fw-api.h b/drivers/net/wireless/iwlwifi/mvm/fw-api.h index 9c975f9ecfcb..541b844c6b5d 100644 --- a/drivers/net/wireless/iwlwifi/mvm/fw-api.h +++ b/drivers/net/wireless/iwlwifi/mvm/fw-api.h | |||
@@ -1603,14 +1603,14 @@ enum iwl_sf_scenario { | |||
1603 | 1603 | ||
1604 | /** | 1604 | /** |
1605 | * Smart Fifo configuration command. | 1605 | * Smart Fifo configuration command. |
1606 | * @state: smart fifo state, types listed in iwl_sf_sate. | 1606 | * @state: smart fifo state, types listed in enum %iwl_sf_sate. |
1607 | * @watermark: Minimum allowed availabe free space in RXF for transient state. | 1607 | * @watermark: Minimum allowed availabe free space in RXF for transient state. |
1608 | * @long_delay_timeouts: aging and idle timer values for each scenario | 1608 | * @long_delay_timeouts: aging and idle timer values for each scenario |
1609 | * in long delay state. | 1609 | * in long delay state. |
1610 | * @full_on_timeouts: timer values for each scenario in full on state. | 1610 | * @full_on_timeouts: timer values for each scenario in full on state. |
1611 | */ | 1611 | */ |
1612 | struct iwl_sf_cfg_cmd { | 1612 | struct iwl_sf_cfg_cmd { |
1613 | enum iwl_sf_state state; | 1613 | __le32 state; |
1614 | __le32 watermark[SF_TRANSIENT_STATES_NUMBER]; | 1614 | __le32 watermark[SF_TRANSIENT_STATES_NUMBER]; |
1615 | __le32 long_delay_timeouts[SF_NUM_SCENARIO][SF_NUM_TIMEOUT_TYPES]; | 1615 | __le32 long_delay_timeouts[SF_NUM_SCENARIO][SF_NUM_TIMEOUT_TYPES]; |
1616 | __le32 full_on_timeouts[SF_NUM_SCENARIO][SF_NUM_TIMEOUT_TYPES]; | 1616 | __le32 full_on_timeouts[SF_NUM_SCENARIO][SF_NUM_TIMEOUT_TYPES]; |
diff --git a/drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c b/drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c index 9cbb192f680e..158aed501473 100644 --- a/drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c +++ b/drivers/net/wireless/iwlwifi/mvm/mac-ctxt.c | |||
@@ -727,11 +727,6 @@ static int iwl_mvm_mac_ctxt_cmd_sta(struct iwl_mvm *mvm, | |||
727 | !force_assoc_off) { | 727 | !force_assoc_off) { |
728 | u32 dtim_offs; | 728 | u32 dtim_offs; |
729 | 729 | ||
730 | /* Allow beacons to pass through as long as we are not | ||
731 | * associated, or we do not have dtim period information. | ||
732 | */ | ||
733 | cmd.filter_flags |= cpu_to_le32(MAC_FILTER_IN_BEACON); | ||
734 | |||
735 | /* | 730 | /* |
736 | * The DTIM count counts down, so when it is N that means N | 731 | * The DTIM count counts down, so when it is N that means N |
737 | * more beacon intervals happen until the DTIM TBTT. Therefore | 732 | * more beacon intervals happen until the DTIM TBTT. Therefore |
@@ -765,6 +760,11 @@ static int iwl_mvm_mac_ctxt_cmd_sta(struct iwl_mvm *mvm, | |||
765 | ctxt_sta->is_assoc = cpu_to_le32(1); | 760 | ctxt_sta->is_assoc = cpu_to_le32(1); |
766 | } else { | 761 | } else { |
767 | ctxt_sta->is_assoc = cpu_to_le32(0); | 762 | ctxt_sta->is_assoc = cpu_to_le32(0); |
763 | |||
764 | /* Allow beacons to pass through as long as we are not | ||
765 | * associated, or we do not have dtim period information. | ||
766 | */ | ||
767 | cmd.filter_flags |= cpu_to_le32(MAC_FILTER_IN_BEACON); | ||
768 | } | 768 | } |
769 | 769 | ||
770 | ctxt_sta->bi = cpu_to_le32(vif->bss_conf.beacon_int); | 770 | ctxt_sta->bi = cpu_to_le32(vif->bss_conf.beacon_int); |
diff --git a/drivers/net/wireless/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/iwlwifi/mvm/mac80211.c index 8d1d4b40b0a3..069bb8e81c36 100644 --- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c +++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c | |||
@@ -398,12 +398,14 @@ int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm) | |||
398 | else | 398 | else |
399 | hw->wiphy->flags &= ~WIPHY_FLAG_PS_ON_BY_DEFAULT; | 399 | hw->wiphy->flags &= ~WIPHY_FLAG_PS_ON_BY_DEFAULT; |
400 | 400 | ||
401 | /* TODO: enable that only for firmwares that don't crash */ | 401 | if (IWL_UCODE_API(mvm->fw->ucode_ver) >= 10) { |
402 | /* hw->wiphy->flags |= WIPHY_FLAG_SUPPORTS_SCHED_SCAN; */ | 402 | hw->wiphy->flags |= WIPHY_FLAG_SUPPORTS_SCHED_SCAN; |
403 | hw->wiphy->max_sched_scan_ssids = PROBE_OPTION_MAX; | 403 | hw->wiphy->max_sched_scan_ssids = PROBE_OPTION_MAX; |
404 | hw->wiphy->max_match_sets = IWL_SCAN_MAX_PROFILES; | 404 | hw->wiphy->max_match_sets = IWL_SCAN_MAX_PROFILES; |
405 | /* we create the 802.11 header and zero length SSID IE. */ | 405 | /* we create the 802.11 header and zero length SSID IE. */ |
406 | hw->wiphy->max_sched_scan_ie_len = SCAN_OFFLOAD_PROBE_REQ_SIZE - 24 - 2; | 406 | hw->wiphy->max_sched_scan_ie_len = |
407 | SCAN_OFFLOAD_PROBE_REQ_SIZE - 24 - 2; | ||
408 | } | ||
407 | 409 | ||
408 | hw->wiphy->features |= NL80211_FEATURE_P2P_GO_CTWIN | | 410 | hw->wiphy->features |= NL80211_FEATURE_P2P_GO_CTWIN | |
409 | NL80211_FEATURE_LOW_PRIORITY_SCAN | | 411 | NL80211_FEATURE_LOW_PRIORITY_SCAN | |
@@ -1544,11 +1546,6 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm, | |||
1544 | */ | 1546 | */ |
1545 | iwl_mvm_remove_time_event(mvm, mvmvif, | 1547 | iwl_mvm_remove_time_event(mvm, mvmvif, |
1546 | &mvmvif->time_event_data); | 1548 | &mvmvif->time_event_data); |
1547 | } else if (changes & (BSS_CHANGED_PS | BSS_CHANGED_P2P_PS | | ||
1548 | BSS_CHANGED_QOS)) { | ||
1549 | ret = iwl_mvm_power_update_mac(mvm); | ||
1550 | if (ret) | ||
1551 | IWL_ERR(mvm, "failed to update power mode\n"); | ||
1552 | } | 1549 | } |
1553 | 1550 | ||
1554 | if (changes & BSS_CHANGED_BEACON_INFO) { | 1551 | if (changes & BSS_CHANGED_BEACON_INFO) { |
@@ -1556,6 +1553,12 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm, | |||
1556 | WARN_ON(iwl_mvm_enable_beacon_filter(mvm, vif, 0)); | 1553 | WARN_ON(iwl_mvm_enable_beacon_filter(mvm, vif, 0)); |
1557 | } | 1554 | } |
1558 | 1555 | ||
1556 | if (changes & (BSS_CHANGED_PS | BSS_CHANGED_P2P_PS | BSS_CHANGED_QOS)) { | ||
1557 | ret = iwl_mvm_power_update_mac(mvm); | ||
1558 | if (ret) | ||
1559 | IWL_ERR(mvm, "failed to update power mode\n"); | ||
1560 | } | ||
1561 | |||
1559 | if (changes & BSS_CHANGED_TXPOWER) { | 1562 | if (changes & BSS_CHANGED_TXPOWER) { |
1560 | IWL_DEBUG_CALIB(mvm, "Changing TX Power to %d\n", | 1563 | IWL_DEBUG_CALIB(mvm, "Changing TX Power to %d\n", |
1561 | bss_conf->txpower); | 1564 | bss_conf->txpower); |
diff --git a/drivers/net/wireless/iwlwifi/mvm/power.c b/drivers/net/wireless/iwlwifi/mvm/power.c index e7a6626fe839..5a29c193b72a 100644 --- a/drivers/net/wireless/iwlwifi/mvm/power.c +++ b/drivers/net/wireless/iwlwifi/mvm/power.c | |||
@@ -290,7 +290,6 @@ static void iwl_mvm_power_build_cmd(struct iwl_mvm *mvm, | |||
290 | struct ieee80211_vif *vif, | 290 | struct ieee80211_vif *vif, |
291 | struct iwl_mac_power_cmd *cmd) | 291 | struct iwl_mac_power_cmd *cmd) |
292 | { | 292 | { |
293 | struct ieee80211_hw *hw = mvm->hw; | ||
294 | struct ieee80211_chanctx_conf *chanctx_conf; | 293 | struct ieee80211_chanctx_conf *chanctx_conf; |
295 | struct ieee80211_channel *chan; | 294 | struct ieee80211_channel *chan; |
296 | int dtimper, dtimper_msec; | 295 | int dtimper, dtimper_msec; |
@@ -301,7 +300,7 @@ static void iwl_mvm_power_build_cmd(struct iwl_mvm *mvm, | |||
301 | 300 | ||
302 | cmd->id_and_color = cpu_to_le32(FW_CMD_ID_AND_COLOR(mvmvif->id, | 301 | cmd->id_and_color = cpu_to_le32(FW_CMD_ID_AND_COLOR(mvmvif->id, |
303 | mvmvif->color)); | 302 | mvmvif->color)); |
304 | dtimper = hw->conf.ps_dtim_period ?: 1; | 303 | dtimper = vif->bss_conf.dtim_period; |
305 | 304 | ||
306 | /* | 305 | /* |
307 | * Regardless of power management state the driver must set | 306 | * Regardless of power management state the driver must set |
@@ -963,7 +962,7 @@ int iwl_mvm_update_d0i3_power_mode(struct iwl_mvm *mvm, | |||
963 | iwl_mvm_power_build_cmd(mvm, vif, &cmd); | 962 | iwl_mvm_power_build_cmd(mvm, vif, &cmd); |
964 | if (enable) { | 963 | if (enable) { |
965 | /* configure skip over dtim up to 300 msec */ | 964 | /* configure skip over dtim up to 300 msec */ |
966 | int dtimper = mvm->hw->conf.ps_dtim_period ?: 1; | 965 | int dtimper = vif->bss_conf.dtim_period ?: 1; |
967 | int dtimper_msec = dtimper * vif->bss_conf.beacon_int; | 966 | int dtimper_msec = dtimper * vif->bss_conf.beacon_int; |
968 | 967 | ||
969 | if (WARN_ON(!dtimper_msec)) | 968 | if (WARN_ON(!dtimper_msec)) |
diff --git a/drivers/net/wireless/iwlwifi/mvm/rx.c b/drivers/net/wireless/iwlwifi/mvm/rx.c index 48144e3ad527..a6cb84ed653f 100644 --- a/drivers/net/wireless/iwlwifi/mvm/rx.c +++ b/drivers/net/wireless/iwlwifi/mvm/rx.c | |||
@@ -151,13 +151,13 @@ static void iwl_mvm_get_signal_strength(struct iwl_mvm *mvm, | |||
151 | le32_to_cpu(phy_info->non_cfg_phy[IWL_RX_INFO_ENERGY_ANT_ABC_IDX]); | 151 | le32_to_cpu(phy_info->non_cfg_phy[IWL_RX_INFO_ENERGY_ANT_ABC_IDX]); |
152 | energy_a = (val & IWL_RX_INFO_ENERGY_ANT_A_MSK) >> | 152 | energy_a = (val & IWL_RX_INFO_ENERGY_ANT_A_MSK) >> |
153 | IWL_RX_INFO_ENERGY_ANT_A_POS; | 153 | IWL_RX_INFO_ENERGY_ANT_A_POS; |
154 | energy_a = energy_a ? -energy_a : -256; | 154 | energy_a = energy_a ? -energy_a : S8_MIN; |
155 | energy_b = (val & IWL_RX_INFO_ENERGY_ANT_B_MSK) >> | 155 | energy_b = (val & IWL_RX_INFO_ENERGY_ANT_B_MSK) >> |
156 | IWL_RX_INFO_ENERGY_ANT_B_POS; | 156 | IWL_RX_INFO_ENERGY_ANT_B_POS; |
157 | energy_b = energy_b ? -energy_b : -256; | 157 | energy_b = energy_b ? -energy_b : S8_MIN; |
158 | energy_c = (val & IWL_RX_INFO_ENERGY_ANT_C_MSK) >> | 158 | energy_c = (val & IWL_RX_INFO_ENERGY_ANT_C_MSK) >> |
159 | IWL_RX_INFO_ENERGY_ANT_C_POS; | 159 | IWL_RX_INFO_ENERGY_ANT_C_POS; |
160 | energy_c = energy_c ? -energy_c : -256; | 160 | energy_c = energy_c ? -energy_c : S8_MIN; |
161 | max_energy = max(energy_a, energy_b); | 161 | max_energy = max(energy_a, energy_b); |
162 | max_energy = max(max_energy, energy_c); | 162 | max_energy = max(max_energy, energy_c); |
163 | 163 | ||
diff --git a/drivers/net/wireless/iwlwifi/mvm/sf.c b/drivers/net/wireless/iwlwifi/mvm/sf.c index d1922afe06f4..f88410c7cbfb 100644 --- a/drivers/net/wireless/iwlwifi/mvm/sf.c +++ b/drivers/net/wireless/iwlwifi/mvm/sf.c | |||
@@ -174,7 +174,7 @@ static int iwl_mvm_sf_config(struct iwl_mvm *mvm, u8 sta_id, | |||
174 | enum iwl_sf_state new_state) | 174 | enum iwl_sf_state new_state) |
175 | { | 175 | { |
176 | struct iwl_sf_cfg_cmd sf_cmd = { | 176 | struct iwl_sf_cfg_cmd sf_cmd = { |
177 | .state = new_state, | 177 | .state = cpu_to_le32(new_state), |
178 | }; | 178 | }; |
179 | struct ieee80211_sta *sta; | 179 | struct ieee80211_sta *sta; |
180 | int ret = 0; | 180 | int ret = 0; |
diff --git a/drivers/net/wireless/iwlwifi/mvm/tx.c b/drivers/net/wireless/iwlwifi/mvm/tx.c index 963edb8656ad..ed0919465e0e 100644 --- a/drivers/net/wireless/iwlwifi/mvm/tx.c +++ b/drivers/net/wireless/iwlwifi/mvm/tx.c | |||
@@ -170,10 +170,14 @@ static void iwl_mvm_set_tx_cmd_rate(struct iwl_mvm *mvm, | |||
170 | 170 | ||
171 | /* | 171 | /* |
172 | * for data packets, rate info comes from the table inside the fw. This | 172 | * for data packets, rate info comes from the table inside the fw. This |
173 | * table is controlled by LINK_QUALITY commands | 173 | * table is controlled by LINK_QUALITY commands. Exclude ctrl port |
174 | * frames like EAPOLs which should be treated as mgmt frames. This | ||
175 | * avoids them being sent initially in high rates which increases the | ||
176 | * chances for completion of the 4-Way handshake. | ||
174 | */ | 177 | */ |
175 | 178 | ||
176 | if (ieee80211_is_data(fc) && sta) { | 179 | if (ieee80211_is_data(fc) && sta && |
180 | !(info->control.flags & IEEE80211_TX_CTRL_PORT_CTRL_PROTO)) { | ||
177 | tx_cmd->initial_rate_index = 0; | 181 | tx_cmd->initial_rate_index = 0; |
178 | tx_cmd->tx_flags |= cpu_to_le32(TX_CMD_FLG_STA_RATE); | 182 | tx_cmd->tx_flags |= cpu_to_le32(TX_CMD_FLG_STA_RATE); |
179 | return; | 183 | return; |
diff --git a/drivers/net/wireless/iwlwifi/pcie/drv.c b/drivers/net/wireless/iwlwifi/pcie/drv.c index dbbbf23082a2..b9d5049e52da 100644 --- a/drivers/net/wireless/iwlwifi/pcie/drv.c +++ b/drivers/net/wireless/iwlwifi/pcie/drv.c | |||
@@ -354,11 +354,17 @@ static const struct pci_device_id iwl_hw_card_ids[] = { | |||
354 | {IWL_PCI_DEVICE(0x08B3, 0x8060, iwl3160_2n_cfg)}, | 354 | {IWL_PCI_DEVICE(0x08B3, 0x8060, iwl3160_2n_cfg)}, |
355 | {IWL_PCI_DEVICE(0x08B3, 0x8062, iwl3160_n_cfg)}, | 355 | {IWL_PCI_DEVICE(0x08B3, 0x8062, iwl3160_n_cfg)}, |
356 | {IWL_PCI_DEVICE(0x08B4, 0x8270, iwl3160_2ac_cfg)}, | 356 | {IWL_PCI_DEVICE(0x08B4, 0x8270, iwl3160_2ac_cfg)}, |
357 | {IWL_PCI_DEVICE(0x08B4, 0x8370, iwl3160_2ac_cfg)}, | ||
358 | {IWL_PCI_DEVICE(0x08B4, 0x8272, iwl3160_2ac_cfg)}, | ||
357 | {IWL_PCI_DEVICE(0x08B3, 0x8470, iwl3160_2ac_cfg)}, | 359 | {IWL_PCI_DEVICE(0x08B3, 0x8470, iwl3160_2ac_cfg)}, |
358 | {IWL_PCI_DEVICE(0x08B3, 0x8570, iwl3160_2ac_cfg)}, | 360 | {IWL_PCI_DEVICE(0x08B3, 0x8570, iwl3160_2ac_cfg)}, |
359 | {IWL_PCI_DEVICE(0x08B3, 0x1070, iwl3160_2ac_cfg)}, | 361 | {IWL_PCI_DEVICE(0x08B3, 0x1070, iwl3160_2ac_cfg)}, |
360 | {IWL_PCI_DEVICE(0x08B3, 0x1170, iwl3160_2ac_cfg)}, | 362 | {IWL_PCI_DEVICE(0x08B3, 0x1170, iwl3160_2ac_cfg)}, |
361 | 363 | ||
364 | /* 3165 Series */ | ||
365 | {IWL_PCI_DEVICE(0x3165, 0x4010, iwl3165_2ac_cfg)}, | ||
366 | {IWL_PCI_DEVICE(0x3165, 0x4210, iwl3165_2ac_cfg)}, | ||
367 | |||
362 | /* 7265 Series */ | 368 | /* 7265 Series */ |
363 | {IWL_PCI_DEVICE(0x095A, 0x5010, iwl7265_2ac_cfg)}, | 369 | {IWL_PCI_DEVICE(0x095A, 0x5010, iwl7265_2ac_cfg)}, |
364 | {IWL_PCI_DEVICE(0x095A, 0x5110, iwl7265_2ac_cfg)}, | 370 | {IWL_PCI_DEVICE(0x095A, 0x5110, iwl7265_2ac_cfg)}, |
@@ -380,6 +386,7 @@ static const struct pci_device_id iwl_hw_card_ids[] = { | |||
380 | {IWL_PCI_DEVICE(0x095B, 0x5202, iwl7265_n_cfg)}, | 386 | {IWL_PCI_DEVICE(0x095B, 0x5202, iwl7265_n_cfg)}, |
381 | {IWL_PCI_DEVICE(0x095A, 0x9010, iwl7265_2ac_cfg)}, | 387 | {IWL_PCI_DEVICE(0x095A, 0x9010, iwl7265_2ac_cfg)}, |
382 | {IWL_PCI_DEVICE(0x095A, 0x9012, iwl7265_2ac_cfg)}, | 388 | {IWL_PCI_DEVICE(0x095A, 0x9012, iwl7265_2ac_cfg)}, |
389 | {IWL_PCI_DEVICE(0x095A, 0x900A, iwl7265_2ac_cfg)}, | ||
383 | {IWL_PCI_DEVICE(0x095A, 0x9110, iwl7265_2ac_cfg)}, | 390 | {IWL_PCI_DEVICE(0x095A, 0x9110, iwl7265_2ac_cfg)}, |
384 | {IWL_PCI_DEVICE(0x095A, 0x9112, iwl7265_2ac_cfg)}, | 391 | {IWL_PCI_DEVICE(0x095A, 0x9112, iwl7265_2ac_cfg)}, |
385 | {IWL_PCI_DEVICE(0x095A, 0x9210, iwl7265_2ac_cfg)}, | 392 | {IWL_PCI_DEVICE(0x095A, 0x9210, iwl7265_2ac_cfg)}, |