Bluetooth: Move clean up code and set of SOCK_ZAPPED to l2cap_sock.c

This remove a bit more of socket code from l2cap core, this calls set the
SOCK_ZAPPED and do some clean up depending on the socket state.

Reported-by: Mat Martineau <mathewm@codeaurora.org>
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
This commit is contained in:
Andrei Emeltchenko
2012-05-27 22:27:52 -03:00
committed by Johan Hedberg
parent 80b9802795
commit c0df7f6e06
3 changed files with 71 additions and 46 deletions

View File

@@ -530,6 +530,7 @@ struct l2cap_ops {
struct l2cap_chan *(*new_connection) (struct l2cap_chan *chan);
int (*recv) (struct l2cap_chan * chan,
struct sk_buff *skb);
void (*teardown) (struct l2cap_chan *chan, int err);
void (*close) (struct l2cap_chan *chan);
void (*state_change) (struct l2cap_chan *chan,
int state);