summaryrefslogtreecommitdiff
path: root/net/bluetooth/l2cap_core.c
diff options
context:
space:
mode:
authorGustavo F. Padovan <padovan@profusion.mobi>2011-05-04 19:35:27 -0300
committerJaikumar Ganesh <jaikumar@google.com>2011-07-11 11:59:13 -0700
commit1eb5ad7859c58ad6ba073860f57989048f2e2dfe (patch)
treeec35ed2d4499fd49fca75177aed0e8c4f00d3b9d /net/bluetooth/l2cap_core.c
parent13003e04ed891cdfa52ccc7023867c896e1ca611 (diff)
Bluetooth: Remove export of l2cap_chan_clear_timer()
The call to l2cap_chan_clear_timer() is not really needed in l2cap_sock.c. This patch also adds a call to l2cap_chan_clear_timer() to the only place in __l2cap_sock_close() that wasn't calling it. It's safe call it there because l2cap_chan_clear_timer() check first for timer_peding(). Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Diffstat (limited to 'net/bluetooth/l2cap_core.c')
-rw-r--r--net/bluetooth/l2cap_core.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index a81d68911b2..07d80ffd60e 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -216,7 +216,7 @@ static void l2cap_chan_set_timer(struct l2cap_chan *chan, long timeout)
sock_hold(chan->sk);
}
-void l2cap_chan_clear_timer(struct l2cap_chan *chan)
+static void l2cap_chan_clear_timer(struct l2cap_chan *chan)
{
BT_DBG("chan %p state %d", chan, chan->sk->sk_state);
@@ -423,6 +423,7 @@ void __l2cap_chan_close(struct l2cap_chan *chan, int reason)
case BT_CONFIG:
if (chan->chan_type == L2CAP_CHAN_CONN_ORIENTED &&
conn->hcon->type == ACL_LINK) {
+ l2cap_chan_clear_timer(chan);
l2cap_chan_set_timer(chan, sk->sk_sndtimeo);
l2cap_send_disconn_req(conn, chan, reason);
} else