Re: [PATCHv2 02/19] Bluetooth: Add ready to L2CAP channel ops

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Mat,

On Wed, May 23, 2012 at 04:16:37PM -0700, Mat Martineau wrote:
> >+static void l2cap_sock_chan_ready_cb(struct l2cap_chan *chan)
> >+{
> >+	struct sock *sk = chan->sk;
> >+	struct sock *parent;
> >+
> >+	lock_sock(sk);
> >+
> >+	parent = bt_sk(sk)->parent;
> >+
> >+	BT_DBG("sk %p, parent %p", sk, parent);
> >+
> >+	__clear_chan_timer(chan);
> >+
> >+	/* This clears all conf flags, including CONF_NOT_COMPLETE */
> >+	chan->conf_state = 0;
> >+
> >+	chan->state = BT_CONNECTED;
> 
> Similar to patch 1, would there be some benefit to leaving the chan
> code (timer clearing, state and conf_state modification) in
> l2cap_core?  These things need to happen even if chan->ops->ready is
> NULL.

This can be done, then I would need to create new function like
l2cap_chan_ready which do chan code and calls ready callback. I will try
to come out with some solution later today.

Best regards 
Andrei Emeltchenko 

--
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


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux