diff options
| author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-24 18:56:45 -0500 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-24 18:56:45 -0500 |
| commit | 8301bb240d0f1b1521b83342f3af8edab7131361 (patch) | |
| tree | b866e77863d534d2447f4aaeeba77ea6b307e2bd /drivers/net/wireless/iwlwifi/mvm/mac80211.c | |
| parent | 12f287878afc39acea00b3e62baf72c79878c427 (diff) | |
| parent | cfbf8d4857c26a8a307fb7cd258074c9dcd8c691 (diff) | |
Merge 3.14-rc4 into tty-next
We want the tty revert here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/mvm/mac80211.c')
| -rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/mac80211.c | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/iwlwifi/mvm/mac80211.c index 6bf9766e5982..c35b8661b395 100644 --- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c +++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c | |||
| @@ -328,6 +328,24 @@ static void iwl_mvm_mac_tx(struct ieee80211_hw *hw, | |||
| 328 | ieee80211_free_txskb(hw, skb); | 328 | ieee80211_free_txskb(hw, skb); |
| 329 | } | 329 | } |
| 330 | 330 | ||
| 331 | static inline bool iwl_enable_rx_ampdu(const struct iwl_cfg *cfg) | ||
| 332 | { | ||
| 333 | if (iwlwifi_mod_params.disable_11n & IWL_DISABLE_HT_RXAGG) | ||
| 334 | return false; | ||
| 335 | return true; | ||
| 336 | } | ||
| 337 | |||
| 338 | static inline bool iwl_enable_tx_ampdu(const struct iwl_cfg *cfg) | ||
| 339 | { | ||
| 340 | if (iwlwifi_mod_params.disable_11n & IWL_DISABLE_HT_TXAGG) | ||
| 341 | return false; | ||
| 342 | if (iwlwifi_mod_params.disable_11n & IWL_ENABLE_HT_TXAGG) | ||
| 343 | return true; | ||
| 344 | |||
| 345 | /* enabled by default */ | ||
| 346 | return true; | ||
| 347 | } | ||
| 348 | |||
| 331 | static int iwl_mvm_mac_ampdu_action(struct ieee80211_hw *hw, | 349 | static int iwl_mvm_mac_ampdu_action(struct ieee80211_hw *hw, |
| 332 | struct ieee80211_vif *vif, | 350 | struct ieee80211_vif *vif, |
| 333 | enum ieee80211_ampdu_mlme_action action, | 351 | enum ieee80211_ampdu_mlme_action action, |
| @@ -347,7 +365,7 @@ static int iwl_mvm_mac_ampdu_action(struct ieee80211_hw *hw, | |||
| 347 | 365 | ||
| 348 | switch (action) { | 366 | switch (action) { |
| 349 | case IEEE80211_AMPDU_RX_START: | 367 | case IEEE80211_AMPDU_RX_START: |
| 350 | if (iwlwifi_mod_params.disable_11n & IWL_DISABLE_HT_RXAGG) { | 368 | if (!iwl_enable_rx_ampdu(mvm->cfg)) { |
| 351 | ret = -EINVAL; | 369 | ret = -EINVAL; |
| 352 | break; | 370 | break; |
| 353 | } | 371 | } |
| @@ -357,7 +375,7 @@ static int iwl_mvm_mac_ampdu_action(struct ieee80211_hw *hw, | |||
| 357 | ret = iwl_mvm_sta_rx_agg(mvm, sta, tid, 0, false); | 375 | ret = iwl_mvm_sta_rx_agg(mvm, sta, tid, 0, false); |
| 358 | break; | 376 | break; |
| 359 | case IEEE80211_AMPDU_TX_START: | 377 | case IEEE80211_AMPDU_TX_START: |
| 360 | if (iwlwifi_mod_params.disable_11n & IWL_DISABLE_HT_TXAGG) { | 378 | if (!iwl_enable_tx_ampdu(mvm->cfg)) { |
| 361 | ret = -EINVAL; | 379 | ret = -EINVAL; |
| 362 | break; | 380 | break; |
| 363 | } | 381 | } |
