diff options
author | Helmut Schaa <helmut.schaa@googlemail.com> | 2011-03-03 13:42:01 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-03-04 14:06:47 -0500 |
commit | 7fe7ee77765161217f60ec9facabd9d2b38d98fe (patch) | |
tree | 6533fb9309b8b6c2d8914c1574b807c2b71bedab /drivers/net/wireless/rt2x00/rt2x00queue.c | |
parent | 208f19dceeeebcae2f9fb8f88953e2f66949b0f0 (diff) |
rt2x00: Generate sw sequence numbers only for devices that need it
Newer devices like rt2800* own a hardware sequence counter and thus
don't need to use a software sequence counter at all. Add a new driver
flag to shortcut the software sequence number generation on devices that
don't need it.
rt61pci, rt73usb and rt2800* seem to make use of a hw sequence counter
while rt2400pci and rt2500* need to do it in software.
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.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/rt2x00queue.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00queue.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.c b/drivers/net/wireless/rt2x00/rt2x00queue.c index b32ca31de7e8..eebb564ee4da 100644 --- a/drivers/net/wireless/rt2x00/rt2x00queue.c +++ b/drivers/net/wireless/rt2x00/rt2x00queue.c | |||
@@ -224,10 +224,14 @@ static void rt2x00queue_create_tx_descriptor_seq(struct queue_entry *entry, | |||
224 | if (!(tx_info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ)) | 224 | if (!(tx_info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ)) |
225 | return; | 225 | return; |
226 | 226 | ||
227 | __set_bit(ENTRY_TXD_GENERATE_SEQ, &txdesc->flags); | ||
228 | |||
229 | if (!test_bit(DRIVER_REQUIRE_SW_SEQNO, &entry->queue->rt2x00dev->flags)) | ||
230 | return; | ||
231 | |||
227 | /* | 232 | /* |
228 | * Hardware should insert sequence counter. | 233 | * The hardware is not able to insert a sequence number. Assign a |
229 | * FIXME: We insert a software sequence counter first for | 234 | * software generated one here. |
230 | * hardware that doesn't support hardware sequence counting. | ||
231 | * | 235 | * |
232 | * This is wrong because beacons are not getting sequence | 236 | * This is wrong because beacons are not getting sequence |
233 | * numbers assigned properly. | 237 | * numbers assigned properly. |
@@ -245,7 +249,6 @@ static void rt2x00queue_create_tx_descriptor_seq(struct queue_entry *entry, | |||
245 | 249 | ||
246 | spin_unlock_irqrestore(&intf->seqlock, irqflags); | 250 | spin_unlock_irqrestore(&intf->seqlock, irqflags); |
247 | 251 | ||
248 | __set_bit(ENTRY_TXD_GENERATE_SEQ, &txdesc->flags); | ||
249 | } | 252 | } |
250 | 253 | ||
251 | static void rt2x00queue_create_tx_descriptor_plcp(struct queue_entry *entry, | 254 | static void rt2x00queue_create_tx_descriptor_plcp(struct queue_entry *entry, |