Hi Andrei, On Tue, Feb 21, 2012 at 12:34 PM, Andrei Emeltchenko <Andrei.Emeltchenko.news@xxxxxxxxx> wrote: > From: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx> > > There are several places in the code where l2cap_state_change and > l2cap_chan_set_err used together. With combining them we remove > socket lock in l2cap_send_disconn_req and simplify code in couple > of other places with a price of adding extra parameter err to > state_change. > > Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx> > --- > include/net/bluetooth/l2cap.h | 3 +- > net/bluetooth/l2cap_core.c | 58 ++++++++++++++++++---------------------- > net/bluetooth/l2cap_sock.c | 9 +++++- > 3 files changed, 36 insertions(+), 34 deletions(-) While I see the benefit of removing function calls and also some code I'm not sure about this change now. We need to think of moving sock handling to l2cap_sock.c and for that we may have to work more on l2cap_ops indeed. However, we need to change ERTM state machine handling first, I'd say. Regards, -- Ulisses Furquim ProFUSION embedded systems http://profusion.mobi Mobile: +55 19 9250 0942 Skype: ulissesffs -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html