LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] l2cap info_timer delete fix in hci_conn_del
@ 2008-03-03 2:48 Dave Young
2008-03-03 10:59 ` Marcel Holtmann
0 siblings, 1 reply; 3+ messages in thread
From: Dave Young @ 2008-03-03 2:48 UTC (permalink / raw)
To: marcel; +Cc: tglx, davem, linux-bluetooth, linux-kernel
When the l2cap info_timer is active the info_state will be set to
L2CAP_INFO_FEAT_MASK_REQ_SENT, and it will be unset after the timer
is deleted or timeout triggered.
Here in hci_conn_del only call del_timer_sync when the info_state
is set to L2CAP_INFO_FEAT_MASK_REQ_SENT.
Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
---
net/bluetooth/l2cap.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff -upr linux/net/bluetooth/l2cap.c linux.new/net/bluetooth/l2cap.c
--- linux/net/bluetooth/l2cap.c 2008-03-03 10:35:03.000000000 +0800
+++ linux.new/net/bluetooth/l2cap.c 2008-03-03 10:36:34.000000000 +0800
@@ -417,7 +417,8 @@ static void l2cap_conn_del(struct hci_co
l2cap_sock_kill(sk);
}
- del_timer_sync(&conn->info_timer);
+ if (conn->info_state & L2CAP_INFO_FEAT_MASK_REQ_SENT)
+ del_timer_sync(&conn->info_timer);
hcon->l2cap_data = NULL;
kfree(conn);
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] l2cap info_timer delete fix in hci_conn_del
2008-03-03 2:48 [PATCH] l2cap info_timer delete fix in hci_conn_del Dave Young
@ 2008-03-03 10:59 ` Marcel Holtmann
2008-03-03 20:19 ` David Miller
0 siblings, 1 reply; 3+ messages in thread
From: Marcel Holtmann @ 2008-03-03 10:59 UTC (permalink / raw)
To: Dave Young; +Cc: tglx, davem, linux-bluetooth, linux-kernel
Hi Dave,
> When the l2cap info_timer is active the info_state will be set to
> L2CAP_INFO_FEAT_MASK_REQ_SENT, and it will be unset after the timer
> is deleted or timeout triggered.
>
> Here in hci_conn_del only call del_timer_sync when the info_state
> is set to L2CAP_INFO_FEAT_MASK_REQ_SENT.
>
> Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
the comment should say l2cap_conn_del, but besides that, the patch is
good.
Acked-by: Marcel Holtmann <marcel@holtmann.org>
in case someone is quicker than me getting this to Linus.
Regards
Marcel
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] l2cap info_timer delete fix in hci_conn_del
2008-03-03 10:59 ` Marcel Holtmann
@ 2008-03-03 20:19 ` David Miller
0 siblings, 0 replies; 3+ messages in thread
From: David Miller @ 2008-03-03 20:19 UTC (permalink / raw)
To: marcel; +Cc: hidave.darkstar, tglx, linux-bluetooth, linux-kernel
From: Marcel Holtmann <marcel@holtmann.org>
Date: Mon, 3 Mar 2008 11:59:04 +0100
> the comment should say l2cap_conn_del, but besides that, the patch is
> good.
I've fixed up the changelog message.
> Acked-by: Marcel Holtmann <marcel@holtmann.org>
And applied the patch, thanks everyone.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-03-03 20:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-03 2:48 [PATCH] l2cap info_timer delete fix in hci_conn_del Dave Young
2008-03-03 10:59 ` Marcel Holtmann
2008-03-03 20:19 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).