Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 224579
b: refs/heads/master
c: 61117f0
h: refs/heads/master
i:
  224577: 01c1460
  224575: 83edc26
v: v3
  • Loading branch information
Felix Fietkau authored and John W. Linville committed Nov 16, 2010
1 parent 1b36704 commit 8067524
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 23 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f0c255a07fe8a4d450cce6355a22b73ee0e9e6e0
refs/heads/master: 61117f01e79f7c0da86c23535bed757370f5885f
3 changes: 2 additions & 1 deletion trunk/drivers/net/wireless/ath/ath9k/ath9k.h
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,7 @@ struct ath_buf_state {
unsigned long bfs_paprd_timestamp;
u32 bfs_keyix;
enum ath9k_key_type bfs_keytype;
enum ath9k_internal_frame_type bfs_ftype;
};

struct ath_buf {
Expand Down Expand Up @@ -711,7 +712,7 @@ void ath9k_ps_restore(struct ath_softc *sc);
void ath9k_set_bssid_mask(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
int ath9k_wiphy_add(struct ath_softc *sc);
int ath9k_wiphy_del(struct ath_wiphy *aphy);
void ath9k_tx_status(struct ieee80211_hw *hw, struct sk_buff *skb);
void ath9k_tx_status(struct ieee80211_hw *hw, struct sk_buff *skb, int ftype);
int ath9k_wiphy_pause(struct ath_wiphy *aphy);
int ath9k_wiphy_unpause(struct ath_wiphy *aphy);
int ath9k_wiphy_select(struct ath_wiphy *aphy);
Expand Down
3 changes: 0 additions & 3 deletions trunk/drivers/net/wireless/ath/ath9k/rc.h
Original file line number Diff line number Diff line change
Expand Up @@ -224,9 +224,6 @@ struct ath_rate_priv {
struct ath_rc_stats rcstats[RATE_TABLE_SIZE];
};

#define ATH_TX_INFO_FRAME_TYPE_INTERNAL (1 << 0)
#define ATH_TX_INFO_FRAME_TYPE_PAUSE (1 << 1)

enum ath9k_internal_frame_type {
ATH9K_IFT_NOT_INTERNAL,
ATH9K_IFT_PAUSE,
Expand Down
5 changes: 2 additions & 3 deletions trunk/drivers/net/wireless/ath/ath9k/virtual.c
Original file line number Diff line number Diff line change
Expand Up @@ -305,13 +305,12 @@ void ath9k_wiphy_chan_work(struct work_struct *work)
* ath9k version of ieee80211_tx_status() for TX frames that are generated
* internally in the driver.
*/
void ath9k_tx_status(struct ieee80211_hw *hw, struct sk_buff *skb)
void ath9k_tx_status(struct ieee80211_hw *hw, struct sk_buff *skb, int ftype)
{
struct ath_wiphy *aphy = hw->priv;
struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb);

if ((tx_info->pad[0] & ATH_TX_INFO_FRAME_TYPE_PAUSE) &&
aphy->state == ATH_WIPHY_PAUSING) {
if (ftype == ATH9K_IFT_PAUSE && aphy->state == ATH_WIPHY_PAUSING) {
if (!(tx_info->flags & IEEE80211_TX_STAT_ACK)) {
printk(KERN_DEBUG "ath9k: %s: no ACK for pause "
"frame\n", wiphy_name(hw->wiphy));
Expand Down
21 changes: 6 additions & 15 deletions trunk/drivers/net/wireless/ath/ath9k/xmit.c
Original file line number Diff line number Diff line change
Expand Up @@ -1580,17 +1580,6 @@ static int ath_tx_setup_buffer(struct ieee80211_hw *hw, struct ath_buf *bf,
int padpos, padsize;
bool use_ldpc = false;

tx_info->pad[0] = 0;
switch (txctl->frame_type) {
case ATH9K_IFT_NOT_INTERNAL:
break;
case ATH9K_IFT_PAUSE:
tx_info->pad[0] |= ATH_TX_INFO_FRAME_TYPE_PAUSE;
/* fall through */
case ATH9K_IFT_UNPAUSE:
tx_info->pad[0] |= ATH_TX_INFO_FRAME_TYPE_INTERNAL;
break;
}
hdrlen = ieee80211_get_hdrlen_from_skb(skb);
fc = hdr->frame_control;

Expand Down Expand Up @@ -1711,6 +1700,7 @@ static void ath_tx_start_dma(struct ath_softc *sc, struct ath_buf *bf,
tid, &bf_head);
}
} else {
bf->bf_state.bfs_ftype = txctl->frame_type;
ath_tx_send_normal(sc, txctl->txq, &bf_head);
}

Expand Down Expand Up @@ -1828,7 +1818,7 @@ void ath_tx_cabq(struct ieee80211_hw *hw, struct sk_buff *skb)
/*****************/

static void ath_tx_complete(struct ath_softc *sc, struct sk_buff *skb,
struct ath_wiphy *aphy, int tx_flags,
struct ath_wiphy *aphy, int tx_flags, int ftype,
struct ath_txq *txq)
{
struct ieee80211_hw *hw = sc->hw;
Expand Down Expand Up @@ -1872,8 +1862,8 @@ static void ath_tx_complete(struct ath_softc *sc, struct sk_buff *skb,
PS_WAIT_FOR_TX_ACK));
}

if (unlikely(tx_info->pad[0] & ATH_TX_INFO_FRAME_TYPE_INTERNAL))
ath9k_tx_status(hw, skb);
if (unlikely(ftype))
ath9k_tx_status(hw, skb, ftype);
else {
q = skb_get_queue_mapping(skb);
if (txq == sc->tx.txq_map[q]) {
Expand Down Expand Up @@ -1917,7 +1907,8 @@ static void ath_tx_complete_buf(struct ath_softc *sc, struct ath_buf *bf,
complete(&sc->paprd_complete);
} else {
ath_debug_stat_tx(sc, bf, ts);
ath_tx_complete(sc, skb, bf->aphy, tx_flags, txq);
ath_tx_complete(sc, skb, bf->aphy, tx_flags,
bf->bf_state.bfs_ftype, txq);
}
/* At this point, skb (bf->bf_mpdu) is consumed...make sure we don't
* accidentally reference it later.
Expand Down

0 comments on commit 8067524

Please sign in to comment.