diff options
| author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-06-20 19:24:02 -0400 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-06-20 19:24:02 -0400 |
| commit | ff446f2001cf9b5ed97c6256c4ee3549d3b7abed (patch) | |
| tree | ec5fd60a8b9c21ae85eaa99003f26e6c342e2234 /drivers/net/wireless/rt2x00/rt2x00queue.c | |
| parent | 78091dc2f6f04b03131218df590c877cadcd9379 (diff) | |
| parent | 485802a6c524e62b5924849dd727ddbb1497cc71 (diff) | |
Merge 3.5-rc3 into usb-next
This lets us catch the USB fixes that went into 3.5-rc3 into this branch,
as we want them here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00queue.c')
| -rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00queue.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.c b/drivers/net/wireless/rt2x00/rt2x00queue.c index 4c662eccf53c..2fd830103415 100644 --- a/drivers/net/wireless/rt2x00/rt2x00queue.c +++ b/drivers/net/wireless/rt2x00/rt2x00queue.c | |||
| @@ -207,6 +207,7 @@ static void rt2x00queue_create_tx_descriptor_seq(struct rt2x00_dev *rt2x00dev, | |||
| 207 | struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb); | 207 | struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb); |
| 208 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; | 208 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; |
| 209 | struct rt2x00_intf *intf = vif_to_intf(tx_info->control.vif); | 209 | struct rt2x00_intf *intf = vif_to_intf(tx_info->control.vif); |
| 210 | u16 seqno; | ||
| 210 | 211 | ||
| 211 | if (!(tx_info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ)) | 212 | if (!(tx_info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ)) |
| 212 | return; | 213 | return; |
| @@ -238,15 +239,13 @@ static void rt2x00queue_create_tx_descriptor_seq(struct rt2x00_dev *rt2x00dev, | |||
| 238 | * sequence counting per-frame, since those will override the | 239 | * sequence counting per-frame, since those will override the |
| 239 | * sequence counter given by mac80211. | 240 | * sequence counter given by mac80211. |
| 240 | */ | 241 | */ |
| 241 | spin_lock(&intf->seqlock); | ||
| 242 | |||
| 243 | if (test_bit(ENTRY_TXD_FIRST_FRAGMENT, &txdesc->flags)) | 242 | if (test_bit(ENTRY_TXD_FIRST_FRAGMENT, &txdesc->flags)) |
| 244 | intf->seqno += 0x10; | 243 | seqno = atomic_add_return(0x10, &intf->seqno); |
| 245 | hdr->seq_ctrl &= cpu_to_le16(IEEE80211_SCTL_FRAG); | 244 | else |
| 246 | hdr->seq_ctrl |= cpu_to_le16(intf->seqno); | 245 | seqno = atomic_read(&intf->seqno); |
| 247 | |||
| 248 | spin_unlock(&intf->seqlock); | ||
| 249 | 246 | ||
| 247 | hdr->seq_ctrl &= cpu_to_le16(IEEE80211_SCTL_FRAG); | ||
| 248 | hdr->seq_ctrl |= cpu_to_le16(seqno); | ||
| 250 | } | 249 | } |
| 251 | 250 | ||
| 252 | static void rt2x00queue_create_tx_descriptor_plcp(struct rt2x00_dev *rt2x00dev, | 251 | static void rt2x00queue_create_tx_descriptor_plcp(struct rt2x00_dev *rt2x00dev, |
