diff options
author | Malcolm Priestley <tvboxspy@gmail.com> | 2014-07-05 19:24:27 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-07-08 16:03:57 -0700 |
commit | 71d764aefeb6010b496f2c47ea06d9389fa9b780 (patch) | |
tree | 786c836fed7a09f981bd938d0170e18ef40c7b92 /drivers/staging/vt6656/usbpipe.c | |
parent | f5283274ccf531a7bb9231c777352f4852e2ded1 (diff) |
stagingL vt6656: implement fall back rates reporting.
The driver reports the rate tried in struct vnt_interrupt_data tsr* variables
which is available in INTnsProcessData via interrupt urb context.
Instead of closing apTD tx context in s_nsBulkOutIoCompleteWrite by setting
in_use to false. Keep the context open and allow vnt_int_report_rate to
close it.
If the tx_retry value is correct it will report back the sucessful RATE tried.
struct vnt_usb_send_context add pkt_no which is index of apTD
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vt6656/usbpipe.c')
-rw-r--r-- | drivers/staging/vt6656/usbpipe.c | 23 |
1 files changed, 6 insertions, 17 deletions
diff --git a/drivers/staging/vt6656/usbpipe.c b/drivers/staging/vt6656/usbpipe.c index a7af4f58898e..c8b0ed5adf7a 100644 --- a/drivers/staging/vt6656/usbpipe.c +++ b/drivers/staging/vt6656/usbpipe.c @@ -398,7 +398,6 @@ static void s_nsBulkOutIoCompleteWrite(struct urb *urb) { struct vnt_usb_send_context *context = urb->context; struct vnt_private *priv = context->priv; - struct ieee80211_tx_info *info; switch (urb->status) { case 0: @@ -415,25 +414,15 @@ static void s_nsBulkOutIoCompleteWrite(struct urb *urb) break; } - if (context->skb) { - s8 idx; - - info = IEEE80211_SKB_CB(context->skb); - - idx = info->control.rates[0].idx; - - ieee80211_tx_info_clear_status(info); - info->status.rates[0].idx = idx; - info->status.rates[0].count = 0; - if (!urb->status) - info->flags |= IEEE80211_TX_STAT_ACK; - ieee80211_tx_status_irqsafe(priv->hw, context->skb); - } - if (context->type == CONTEXT_DATA_PACKET) ieee80211_wake_queues(priv->hw); - context->in_use = false; + if (urb->status || context->type == CONTEXT_BEACON_PACKET) { + if (context->skb) + ieee80211_free_txskb(priv->hw, context->skb); + + context->in_use = false; + } return; } |