Search Linux Wireless

Re: Locking problem reported for mainline

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Monday 10 January 2011 20:11:38 Larry Finger wrote:
> On 01/10/2011 12:13 PM, Christian Lamparter wrote:
> > Does this patch help?
> > 
> > ---
> > diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
> > index a6701ed..8f13a83 100644
> > --- a/net/mac80211/rx.c
> > +++ b/net/mac80211/rx.c
> 
> Did not compile. In ieee80211_release_reorder_frame at lines 552 and 554, rx is
> not defined.
> 
Oops,

you are right. Fixed the copy&paste error, so this one should compile.
---
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index a6701ed..936b932 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -549,7 +549,9 @@ static void ieee80211_release_reorder_frame(struct ieee80211_hw *hw,
 	tid_agg_rx->reorder_buf[index] = NULL;
 	status = IEEE80211_SKB_RXCB(skb);
 	status->rx_flags |= IEEE80211_RX_DEFERRED_RELEASE;
-	skb_queue_tail(&local->rx_skb_queue, skb);
+	spin_lock(&local->rx_skb_queue.lock);
+	__skb_queue_tail(&local->rx_skb_queue, skb);
+	spin_unlock(&local->rx_skb_queue.lock);
 
 no_frame:
 	tid_agg_rx->head_seq_num = seq_inc(tid_agg_rx->head_seq_num);
@@ -780,7 +782,9 @@ static void ieee80211_rx_reorder_ampdu(struct ieee80211_rx_data *rx)
 		return;
 
  dont_reorder:
-	skb_queue_tail(&local->rx_skb_queue, skb);
+	spin_lock(&local->rx_skb_queue.lock);
+	__skb_queue_tail(&local->rx_skb_queue, skb);
+	spin_unlock(&local->rx_skb_queue.lock);
 }
 
 static ieee80211_rx_result debug_noinline
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux