]> err.no Git - linux-2.6/blobdiff - drivers/net/wireless/rt2x00/rt2x00usb.c
rt2x00: Fix TX status reporting
[linux-2.6] / drivers / net / wireless / rt2x00 / rt2x00usb.c
index 98aafc2d584a051c0a52df7c129f2f048c5cdf1f..caee65e821986ce4caebec5a71d4fb067f9f73b3 100644 (file)
@@ -147,8 +147,17 @@ static void rt2x00usb_interrupt_txdone(struct urb *urb)
 
        /*
         * Obtain the status about this packet.
+        * Note that when the status is 0 it does not mean the
+        * frame was send out correctly. It only means the frame
+        * was succesfully pushed to the hardware, we have no
+        * way to determine the transmission status right now.
+        * (Only indirectly by looking at the failed TX counters
+        * in the register).
         */
-       txdesc.status = !urb->status ? TX_SUCCESS : TX_FAIL_RETRY;
+       if (!urb->status)
+               __set_bit(TXDONE_UNKNOWN, &txdesc.flags);
+       else
+               __set_bit(TXDONE_FAILURE, &txdesc.flags);
        txdesc.retry = 0;
        txdesc.control = &priv_tx->control;