aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorGustavo F. Padovan <padovan@profusion.mobi>2011-04-01 14:13:36 -0400
committerGustavo F. Padovan <padovan@profusion.mobi>2011-04-07 17:06:28 -0400
commit2ead70b8390d199ca04cd35311b51f5f3676079e (patch)
tree320bbac4a45e2b4557c039feb928537e0e6c45c9 /net
parent311bb895e325e5f4d708c1ed2206da8a3885c83a (diff)
Bluetooth: Fix lockdep warning with skb list lock
This is a regression acctually, caused by the first patch series for creating a formal strcut l2cap_chan. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Diffstat (limited to 'net')
-rw-r--r--net/bluetooth/l2cap_core.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index d3b5d6489a80..7264119b64a6 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -236,6 +236,10 @@ void l2cap_chan_del(struct l2cap_chan *chan, int err)
236 } else 236 } else
237 sk->sk_state_change(sk); 237 sk->sk_state_change(sk);
238 238
239 if (!(l2cap_pi(sk)->conf_state & L2CAP_CONF_OUTPUT_DONE &&
240 l2cap_pi(sk)->conf_state & L2CAP_CONF_INPUT_DONE))
241 goto free;
242
239 skb_queue_purge(TX_QUEUE(sk)); 243 skb_queue_purge(TX_QUEUE(sk));
240 244
241 if (l2cap_pi(sk)->mode == L2CAP_MODE_ERTM) { 245 if (l2cap_pi(sk)->mode == L2CAP_MODE_ERTM) {
@@ -254,6 +258,7 @@ void l2cap_chan_del(struct l2cap_chan *chan, int err)
254 } 258 }
255 } 259 }
256 260
261free:
257 kfree(chan); 262 kfree(chan);
258} 263}
259 264