diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2018-05-17 10:44:20 +0300 |
---|---|---|
committer | Luca Coelho <luciano.coelho@intel.com> | 2018-05-30 09:55:34 +0300 |
commit | 5dd9f6c703e8161bf69fb9d004528bfb639548ce (patch) | |
tree | 6f7cde9cbc8760037b9e4d6b5ccb354c429ef3be /drivers/net/wireless | |
parent | d94c5a820d107fdde711ec72c16848876027713d (diff) | |
download | lwn-5dd9f6c703e8161bf69fb9d004528bfb639548ce.tar.gz lwn-5dd9f6c703e8161bf69fb9d004528bfb639548ce.zip |
iwlwifi: mvm: honor the max_amsdu_subframes limit
A peer can limit the number of subframes it can handle in a
single A-MSDU. Honor this limit.
Note that the smallest limit is 8, and we are very unlikely to reach
that limit. So this isn't really a big deal.
Fixes: a6d5e32f247c ("iwlwifi: mvm: send large SKBs to the transport")
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c index 0b7f98d00298..cf2591f2ac23 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c @@ -844,6 +844,10 @@ static int iwl_mvm_tx_tso(struct iwl_mvm *mvm, struct sk_buff *skb, */ num_subframes = (max_amsdu_len + pad) / (subf_len + pad); + if (sta->max_amsdu_subframes && + num_subframes > sta->max_amsdu_subframes) + num_subframes = sta->max_amsdu_subframes; + tcp_payload_len = skb_tail_pointer(skb) - skb_transport_header(skb) - tcp_hdrlen(skb) + skb->data_len; |