aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00dev.c
diff options
context:
space:
mode:
authorRA-Jay Hung <Jay_Hung@ralinktech.com>2010-11-13 13:12:54 -0500
committerJohn W. Linville <linville@tuxdriver.com>2010-11-17 16:18:57 -0500
commitf8eaec659f8a7a4e0086fca7c5d5c5e0fbc76d1a (patch)
tree8dec5dc25ec39c34d6513b03c14e9d98fd91a4e9 /drivers/net/wireless/rt2x00/rt2x00dev.c
parentb43d63bd69ae5464a52bf1796e84097607917b2f (diff)
rt2x00: Fix header_length in rt2x00lib_txdone
Put the assignment of header_length after pull out extra tx headroom Signed-off-by: RA-Jay Hung <jay_hung@ralinktech.com> Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00dev.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00dev.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c
index 3afa2a3ebee4..c879f9a7037c 100644
--- a/drivers/net/wireless/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/rt2x00/rt2x00dev.c
@@ -250,10 +250,9 @@ void rt2x00lib_txdone(struct queue_entry *entry,
250 struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(entry->skb); 250 struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(entry->skb);
251 struct skb_frame_desc *skbdesc = get_skb_frame_desc(entry->skb); 251 struct skb_frame_desc *skbdesc = get_skb_frame_desc(entry->skb);
252 enum data_queue_qid qid = skb_get_queue_mapping(entry->skb); 252 enum data_queue_qid qid = skb_get_queue_mapping(entry->skb);
253 unsigned int header_length = ieee80211_get_hdrlen_from_skb(entry->skb); 253 unsigned int header_length, i;
254 u8 rate_idx, rate_flags, retry_rates; 254 u8 rate_idx, rate_flags, retry_rates;
255 u8 skbdesc_flags = skbdesc->flags; 255 u8 skbdesc_flags = skbdesc->flags;
256 unsigned int i;
257 bool success; 256 bool success;
258 257
259 /* 258 /*
@@ -272,6 +271,11 @@ void rt2x00lib_txdone(struct queue_entry *entry,
272 skbdesc->flags &= ~SKBDESC_DESC_IN_SKB; 271 skbdesc->flags &= ~SKBDESC_DESC_IN_SKB;
273 272
274 /* 273 /*
274 * Determine the length of 802.11 header.
275 */
276 header_length = ieee80211_get_hdrlen_from_skb(entry->skb);
277
278 /*
275 * Remove L2 padding which was added during 279 * Remove L2 padding which was added during
276 */ 280 */
277 if (test_bit(DRIVER_REQUIRE_L2PAD, &rt2x00dev->flags)) 281 if (test_bit(DRIVER_REQUIRE_L2PAD, &rt2x00dev->flags))