Lines Matching refs:session

39 	struct bt_avctp *session;  in avctp_l2cap_connected()  local
46 session = AVCTP_CHAN(chan); in avctp_l2cap_connected()
47 LOG_DBG("chan %p session %p", chan, session); in avctp_l2cap_connected()
49 if (session->ops && session->ops->connected) { in avctp_l2cap_connected()
50 session->ops->connected(session); in avctp_l2cap_connected()
56 struct bt_avctp *session; in avctp_l2cap_disconnected() local
63 session = AVCTP_CHAN(chan); in avctp_l2cap_disconnected()
64 LOG_DBG("chan %p session %p", chan, session); in avctp_l2cap_disconnected()
65 session->br_chan.chan.conn = NULL; in avctp_l2cap_disconnected()
67 if (session->ops && session->ops->disconnected) { in avctp_l2cap_disconnected()
68 session->ops->disconnected(session); in avctp_l2cap_disconnected()
80 struct bt_avctp *session = AVCTP_CHAN(chan); in avctp_l2cap_recv() local
114 rsp = bt_avctp_create_pdu(session, BT_AVCTP_RESPONSE, in avctp_l2cap_recv()
120 return bt_avctp_send(session, rsp); in avctp_l2cap_recv()
125 return session->ops->recv(session, buf); in avctp_l2cap_recv()
128 int bt_avctp_connect(struct bt_conn *conn, struct bt_avctp *session) in bt_avctp_connect() argument
137 if (!session) { in bt_avctp_connect()
141 session->br_chan.rx.mtu = BT_L2CAP_RX_MTU; in bt_avctp_connect()
142 session->br_chan.chan.ops = &ops; in bt_avctp_connect()
143 session->br_chan.required_sec_level = BT_SECURITY_L2; in bt_avctp_connect()
145 return bt_l2cap_chan_connect(conn, &session->br_chan.chan, BT_L2CAP_PSM_AVCTP); in bt_avctp_connect()
148 int bt_avctp_disconnect(struct bt_avctp *session) in bt_avctp_disconnect() argument
150 if (!session) { in bt_avctp_disconnect()
154 LOG_DBG("session %p", session); in bt_avctp_disconnect()
156 return bt_l2cap_chan_disconnect(&session->br_chan.chan); in bt_avctp_disconnect()
159 struct net_buf *bt_avctp_create_pdu(struct bt_avctp *session, bt_avctp_cr_t cr, in bt_avctp_create_pdu() argument
190 int bt_avctp_send(struct bt_avctp *session, struct net_buf *buf) in bt_avctp_send() argument
194 err = bt_l2cap_chan_send(&session->br_chan.chan, buf); in bt_avctp_send()