Author: adrian
Date: Fri Aug 19 15:21:13 2011
New Revision: 225013
URL: http://svn.freebsd.org/changeset/base/225013

Log:
  Correctly handle BAR TX failures.
  
  On a TX failure, ic_raw_xmit will still call ieee80211_node_free().
  There's no need to call it here.
  
  Submitted by: [email protected]
  Approved by:  re (kib)

Modified:
  head/sys/net80211/ieee80211_ht.c

Modified: head/sys/net80211/ieee80211_ht.c
==============================================================================
--- head/sys/net80211/ieee80211_ht.c    Fri Aug 19 15:14:13 2011        
(r225012)
+++ head/sys/net80211/ieee80211_ht.c    Fri Aug 19 15:21:13 2011        
(r225013)
@@ -2309,11 +2309,15 @@ ieee80211_send_bar(struct ieee80211_node
            ni, "send BAR: tid %u ctl 0x%x start %u (attempt %d)",
            tid, barctl, seq, tap->txa_attempts);
 
+       /*
+        * ic_raw_xmit will free the node reference
+        * regardless of queue/TX success or failure.
+        */
        ret = ic->ic_raw_xmit(ni, m, NULL);
        if (ret != 0) {
                /* xmit failed, clear state flag */
                tap->txa_flags &= ~IEEE80211_AGGR_BARPEND;
-               goto bad;
+               return ret;
        }
        /* XXX hack against tx complete happening before timer is started */
        if (tap->txa_flags & IEEE80211_AGGR_BARPEND)
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "[email protected]"

Reply via email to