Skip to content

Commit

Permalink
iwlwifi: don't stop queue in the middle of fragmented packet
Browse files Browse the repository at this point in the history
This patch avoids stopping queue in the middle of the fragmented packet.
It is required that there will be ~10 (max packet/min fragment) or 16
(4 bits of frag number) free tfds all the time.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Tomas Winkler authored and John W. Linville committed Aug 1, 2008
1 parent 8de394f commit 143b09e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions drivers/net/wireless/iwlwifi/iwl-tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -962,16 +962,16 @@ int iwl_tx_skb(struct iwl_priv *priv, struct sk_buff *skb)
if (ret)
return ret;

if ((iwl_queue_space(q) < q->high_mark)
&& priv->mac80211_registered) {
if ((iwl_queue_space(q) < q->high_mark) && priv->mac80211_registered) {
if (wait_write_ptr) {
spin_lock_irqsave(&priv->lock, flags);
txq->need_update = 1;
iwl_txq_update_write_ptr(priv, txq);
spin_unlock_irqrestore(&priv->lock, flags);
} else {
ieee80211_stop_queue(priv->hw,
skb_get_queue_mapping(skb));
}

ieee80211_stop_queue(priv->hw, skb_get_queue_mapping(skb));
}

return 0;
Expand Down

0 comments on commit 143b09e

Please sign in to comment.