Thread (1 message) 1 message, 1 author, 2011-11-21

Re: [PATCH 1/3] mac80211: add tx agg session timer to timeout inactive tids in way similar to rx agg sessions are being timed out

From: Johannes Berg <johannes@sipsolutions.net>
Date: 2011-11-21 16:03:32

On Mon, 2011-11-21 at 10:57 -0500, Nikolay Martynov wrote:
quoted
quoted
@@ -689,6 +716,8 @@ void ieee80211_stop_tx_ba_cb(struct ieee80211_vif *vif, u8 *ra, u8 tid)
       * more.
       */

+     del_timer_sync(&tid_tx->session_timer);
+
      ieee80211_agg_splice_packets(local, tid_tx, tid);
This is a deadlock waiting to happen.
  I'd really appreciate if you could be a bit more specific on why
this could lead to deadlock. Thanks!
It's within the spinlock, and you take the spinlock in the timer. So
this can happen:

cpu 1				cpu 2
stop_tx_ba_cb
  spin_lock_bh(&sta->lock);
				start your timer function
  del_timer_sync
    wait for timer to finish
				spin_lock_bh(&sta->lock);

johannes
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help