/external/bluetooth/bluedroid/stack/l2cap/ |
D | l2c_csm.c | 42 static void l2c_csm_closed (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 43 static void l2c_csm_orig_w4_sec_comp (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 44 static void l2c_csm_term_w4_sec_comp (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 45 static void l2c_csm_w4_l2cap_connect_rsp (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 46 static void l2c_csm_w4_l2ca_connect_rsp (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 47 static void l2c_csm_config (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 48 static void l2c_csm_open (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 49 static void l2c_csm_w4_l2cap_disconnect_rsp (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 50 static void l2c_csm_w4_l2ca_disconnect_rsp (tL2C_CCB *p_ccb, UINT16 event, void *p_data); 65 void l2c_csm_execute (tL2C_CCB *p_ccb, UINT16 event, void *p_data) in l2c_csm_execute() argument [all …]
|
D | l2c_fcr.c | 89 static BOOLEAN process_reqseq (tL2C_CCB *p_ccb, UINT16 ctrl_word); 90 static void process_s_frame (tL2C_CCB *p_ccb, BT_HDR *p_buf, UINT16 ctrl_word); 91 static void process_i_frame (tL2C_CCB *p_ccb, BT_HDR *p_buf, UINT16 ctrl_word, BOOLEAN delay_ack… 92 static BOOLEAN retransmit_i_frames (tL2C_CCB *p_ccb, UINT8 tx_seq); 93 static void prepare_I_frame (tL2C_CCB *p_ccb, BT_HDR *p_buf, BOOLEAN is_retransmission); 94 static void process_stream_frame (tL2C_CCB *p_ccb, BT_HDR *p_buf); 95 static BOOLEAN do_sar_reassembly (tL2C_CCB *p_ccb, BT_HDR *p_buf, UINT16 ctrl_word); 98 static BOOLEAN l2c_corrupt_the_fcr_packet (tL2C_CCB *p_ccb, BT_HDR *p_buf, 100 static BOOLEAN l2c_bypass_sframe_packet (tL2C_CCB *p_ccb); 104 static void l2c_fcr_collect_ack_delay (tL2C_CCB *p_ccb, UINT8 num_bufs_acked); [all …]
|
D | l2c_ucd.c | 267 tL2C_CCB *p_ccb; in L2CA_UcdDeregister() local 297 p_ccb = l2cb.ccb_pool; in L2CA_UcdDeregister() 300 if (( p_ccb->in_use ) in L2CA_UcdDeregister() 301 &&( p_ccb->local_cid == L2CAP_CONNECTIONLESS_CID )) in L2CA_UcdDeregister() 303 l2cu_release_ccb (p_ccb); in L2CA_UcdDeregister() 305 p_ccb++; in L2CA_UcdDeregister() 329 tL2C_CCB *p_ccb; in L2CA_UcdDiscover() local 347 ||((p_ccb = l2cu_find_ccb_by_cid (p_lcb, L2CAP_CONNECTIONLESS_CID)) == NULL)) in L2CA_UcdDiscover() 366 if (!p_ccb) in L2CA_UcdDiscover() 368 p_ccb = l2cu_find_ccb_by_cid (p_lcb, L2CAP_CONNECTIONLESS_CID); in L2CA_UcdDiscover() [all …]
|
D | l2c_utils.c | 118 tL2C_CCB *p_ccb; in l2cu_release_lcb() local 186 for (p_ccb = p_lcb->ccb_queue.p_first_ccb; p_ccb; p_ccb = p_lcb->ccb_queue.p_first_ccb) in l2cu_release_lcb() 188 l2cu_release_ccb (p_ccb); in l2cu_release_lcb() 405 void l2cu_send_peer_connect_req (tL2C_CCB *p_ccb) in l2cu_send_peer_connect_req() argument 411 p_ccb->p_lcb->id++; in l2cu_send_peer_connect_req() 412 l2cu_adj_id(p_ccb->p_lcb, L2CAP_ADJ_ID); in l2cu_send_peer_connect_req() 414 p_ccb->local_id = p_ccb->p_lcb->id; in l2cu_send_peer_connect_req() 416 if ((p_buf = l2cu_build_header (p_ccb->p_lcb, L2CAP_CONN_REQ_LEN, L2CAP_CMD_CONN_REQ, in l2cu_send_peer_connect_req() 417 p_ccb->local_id)) == NULL) in l2cu_send_peer_connect_req() 426 UINT16_TO_STREAM (p, p_ccb->p_rcb->real_psm); in l2cu_send_peer_connect_req() [all …]
|
D | l2c_api.c | 124 tL2C_CCB *p_ccb; in L2CA_Deregister() local 137 if (((p_ccb = p_lcb->ccb_queue.p_first_ccb) == NULL) in L2CA_Deregister() 141 if ((p_ccb->in_use) && in L2CA_Deregister() 142 ((p_ccb->chnl_state == CST_W4_L2CAP_DISCONNECT_RSP) || in L2CA_Deregister() 143 (p_ccb->chnl_state == CST_W4_L2CA_DISCONNECT_RSP))) in L2CA_Deregister() 146 if (p_ccb->p_rcb == p_rcb) in L2CA_Deregister() 147 l2c_csm_execute (p_ccb, L2CEVT_L2CA_DISCONNECT_REQ, NULL); in L2CA_Deregister() 232 tL2C_CCB *p_ccb; in L2CA_ErtmConnectReq() local 266 if ((p_ccb = l2cu_allocate_ccb (p_lcb, 0)) == NULL) in L2CA_ErtmConnectReq() 273 p_ccb->p_rcb = p_rcb; in L2CA_ErtmConnectReq() [all …]
|
D | l2c_link.c | 158 tL2C_CCB *p_ccb; in l2c_link_hci_conn_comp() local 223 for (p_ccb = p_lcb->ccb_queue.p_first_ccb; p_ccb; p_ccb = p_ccb->p_next_ccb) in l2c_link_hci_conn_comp() 225 l2c_csm_execute (p_ccb, L2CEVT_LP_CONNECT_CFM, &ci); in l2c_link_hci_conn_comp() 252 for (p_ccb = p_lcb->ccb_queue.p_first_ccb; p_ccb; ) in l2c_link_hci_conn_comp() 254 tL2C_CCB *pn = p_ccb->p_next_ccb; in l2c_link_hci_conn_comp() 256 l2c_csm_execute (p_ccb, L2CEVT_LP_CONNECT_CFM_NEG, &ci); in l2c_link_hci_conn_comp() 258 p_ccb = pn; in l2c_link_hci_conn_comp() 296 tL2C_CCB *p_ccb; in l2c_link_sec_comp() local 319 for (p_ccb = p_lcb->ccb_queue.p_first_ccb; p_ccb; p_ccb = p_next_ccb) in l2c_link_sec_comp() 321 p_next_ccb = p_ccb->p_next_ccb; in l2c_link_sec_comp() [all …]
|
D | l2c_main.c | 125 tL2C_CCB *p_ccb = NULL; in l2c_rcv_acl_data() local 197 if ((p_ccb = l2cu_find_ccb_by_cid (p_lcb, rcv_cid)) == NULL) in l2c_rcv_acl_data() 272 p_ccb = p_lcb->p_fixed_ccbs[rcv_cid - L2CAP_FIRST_FIXED_CHNL]; in l2c_rcv_acl_data() 274 if (p_ccb->peer_cfg.fcr.mode != L2CAP_FCR_BASIC_MODE) in l2c_rcv_acl_data() 275 l2c_fcr_proc_pdu (p_ccb, p_msg); in l2c_rcv_acl_data() 286 if (p_ccb == NULL) in l2c_rcv_acl_data() 291 if (p_ccb->peer_cfg.fcr.mode == L2CAP_FCR_BASIC_MODE) in l2c_rcv_acl_data() 292 l2c_csm_execute (p_ccb, L2CEVT_L2CAP_DATA, p_msg); in l2c_rcv_acl_data() 296 if ((p_ccb->chnl_state == CST_OPEN) || (p_ccb->chnl_state == CST_CONFIG)) in l2c_rcv_acl_data() 297 l2c_fcr_proc_pdu (p_ccb, p_msg); in l2c_rcv_acl_data() [all …]
|
D | l2c_int.h | 591 extern void l2cu_enqueue_ccb (tL2C_CCB *p_ccb); 592 extern void l2cu_dequeue_ccb (tL2C_CCB *p_ccb); 593 extern void l2cu_change_pri_ccb (tL2C_CCB *p_ccb, tL2CAP_CHNL_PRIORITY priority); 596 extern void l2cu_release_ccb (tL2C_CCB *p_ccb); 603 extern void l2cu_send_peer_connect_req (tL2C_CCB *p_ccb); 604 extern void l2cu_send_peer_connect_rsp (tL2C_CCB *p_ccb, UINT16 result, UINT16 status); 605 extern void l2cu_send_peer_config_req (tL2C_CCB *p_ccb, tL2CAP_CFG_INFO *p_cfg); 606 extern void l2cu_send_peer_config_rsp (tL2C_CCB *p_ccb, tL2CAP_CFG_INFO *p_cfg); 607 extern void l2cu_send_peer_config_rej (tL2C_CCB *p_ccb, UINT8 *p_data, UINT16 data_len, UINT16 … 608 extern void l2cu_send_peer_disc_req (tL2C_CCB *p_ccb); [all …]
|
/external/bluetooth/bluedroid/stack/gap/ |
D | gap_conn.c | 43 static void gap_release_ccb (tGAP_CCB *p_ccb); 125 tGAP_CCB *p_ccb; in GAP_ConnOpen() local 132 if ((p_ccb = gap_allocate_ccb()) == NULL) in GAP_ConnOpen() 140 p_ccb->rem_addr_specified = TRUE; in GAP_ConnOpen() 142 memcpy (&p_ccb->rem_dev_address[0], p_rem_bda, BD_ADDR_LEN); in GAP_ConnOpen() 151 if (!p_ccb->rem_addr_specified && !is_server) in GAP_ConnOpen() 153 gap_release_ccb (p_ccb); in GAP_ConnOpen() 160 p_ccb->cfg = *p_cfg; in GAP_ConnOpen() 162 p_ccb->p_callback = p_cb; in GAP_ConnOpen() 178 …if ((p_ccb->psm = L2CA_REGISTER (psm, &gap_cb.conn.reg_info, AMP_AUTOSWITCH_ALLOWED|AMP_USE_AMP_IF… in GAP_ConnOpen() [all …]
|
/external/bluetooth/bluedroid/stack/avdt/ |
D | avdt_ccb_act.c | 47 static void avdt_ccb_clear_ccb(tAVDT_CCB *p_ccb) in avdt_ccb_clear_ccb() argument 52 p_ccb->cong = FALSE; in avdt_ccb_clear_ccb() 53 p_ccb->ret_count = 0; in avdt_ccb_clear_ccb() 56 if (p_ccb->p_curr_msg != NULL) in avdt_ccb_clear_ccb() 58 GKI_freebuf(p_ccb->p_curr_msg); in avdt_ccb_clear_ccb() 59 p_ccb->p_curr_msg = NULL; in avdt_ccb_clear_ccb() 63 if (p_ccb->p_rx_msg != NULL) in avdt_ccb_clear_ccb() 65 GKI_freebuf(p_ccb->p_rx_msg); in avdt_ccb_clear_ccb() 66 p_ccb->p_rx_msg = NULL; in avdt_ccb_clear_ccb() 70 while ((p_buf = (BT_HDR *) GKI_dequeue(&p_ccb->rsp_q)) != NULL) in avdt_ccb_clear_ccb() [all …]
|
D | avdt_ccb.c | 297 void avdt_ccb_event(tAVDT_CCB *p_ccb, UINT8 event, tAVDT_CCB_EVT *p_data) in avdt_ccb_event() argument 304 …("CCB ccb=%d event=%s state=%s", avdt_ccb_to_idx(p_ccb), avdt_ccb_evt_str[event], avdt_ccb_st_str[… in avdt_ccb_event() 306 BTTRC_AVDT_CCB_EVENT(event, p_ccb->state); in avdt_ccb_event() 309 state_table = avdt_ccb_st_tbl[p_ccb->state]; in avdt_ccb_event() 312 if (p_ccb->state != state_table[event][AVDT_CCB_NEXT_STATE]) in avdt_ccb_event() 314 p_ccb->state = state_table[event][AVDT_CCB_NEXT_STATE]; in avdt_ccb_event() 322 (*avdt_cb.p_ccb_act[action])(p_ccb, p_data); in avdt_ccb_event() 344 tAVDT_CCB *p_ccb = &avdt_cb.ccb[0]; in avdt_ccb_by_bd() local 347 for (i = 0; i < AVDT_NUM_LINKS; i++, p_ccb++) in avdt_ccb_by_bd() 350 if (p_ccb->allocated && (!memcmp(p_ccb->peer_addr, bd_addr, BD_ADDR_LEN))) in avdt_ccb_by_bd() [all …]
|
D | avdt_ad.c | 133 tAVDT_TC_TBL *avdt_ad_tc_tbl_by_st(UINT8 type, tAVDT_CCB *p_ccb, UINT8 state) in avdt_ad_tc_tbl_by_st() argument 139 if (p_ccb == NULL) in avdt_ad_tc_tbl_by_st() 154 ccb_idx = avdt_ccb_to_idx(p_ccb); in avdt_ad_tc_tbl_by_st() 229 tAVDT_TC_TBL *avdt_ad_tc_tbl_by_type(UINT8 type, tAVDT_CCB *p_ccb, tAVDT_SCB *p_scb) in avdt_ad_tc_tbl_by_type() argument 234 UINT8 ccb_idx = avdt_ccb_to_idx(p_ccb); in avdt_ad_tc_tbl_by_type() 263 tAVDT_TC_TBL *avdt_ad_tc_tbl_alloc(tAVDT_CCB *p_ccb) in avdt_ad_tc_tbl_alloc() argument 283 p_tbl->ccb_idx = avdt_ccb_to_idx(p_ccb); in avdt_ad_tc_tbl_alloc() 322 tAVDT_CCB *p_ccb; in avdt_ad_tc_close_ind() local 337 p_ccb = avdt_ccb_by_idx(p_tbl->ccb_idx); in avdt_ad_tc_close_ind() 338 avdt_ccb_event(p_ccb, AVDT_CCB_LL_CLOSE_EVT, NULL); in avdt_ad_tc_close_ind() [all …]
|
D | avdt_int.h | 450 typedef void (*tAVDT_CCB_ACTION)(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); 490 tAVDT_CCB *p_ccb; /* ccb associated with this scb */ member 561 extern void avdt_ccb_event(tAVDT_CCB *p_ccb, UINT8 event, tAVDT_CCB_EVT *p_data); 564 extern void avdt_ccb_dealloc(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); 565 extern UINT8 avdt_ccb_to_idx(tAVDT_CCB *p_ccb); 569 extern void avdt_ccb_chan_open(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); 570 extern void avdt_ccb_chan_close(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); 571 extern void avdt_ccb_chk_close(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); 572 extern void avdt_ccb_hdl_discover_cmd(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); 573 extern void avdt_ccb_hdl_discover_rsp(tAVDT_CCB *p_ccb, tAVDT_CCB_EVT *p_data); [all …]
|
D | avdt_msg.c | 1186 BOOLEAN avdt_msg_send(tAVDT_CCB *p_ccb, BT_HDR *p_msg) in avdt_msg_send() argument 1200 p_tbl = avdt_ad_tc_tbl_by_type(AVDT_CHAN_SIG, p_ccb, NULL); in avdt_msg_send() 1205 p_ccb->p_curr_msg = p_msg; in avdt_msg_send() 1209 curr_msg_len = p_ccb->p_curr_msg->len; in avdt_msg_send() 1212 while ((!p_ccb->cong) && (p_ccb->p_curr_msg != NULL)) in avdt_msg_send() 1219 if ((p_ccb->p_curr_msg->offset == AVDT_MSG_OFFSET) && in avdt_msg_send() 1220 (p_ccb->p_curr_msg->len <= p_tbl->peer_mtu - AVDT_LEN_TYPE_SINGLE)) in avdt_msg_send() 1224 p_buf = p_ccb->p_curr_msg; in avdt_msg_send() 1227 else if ((p_ccb->p_curr_msg->offset == AVDT_MSG_OFFSET) && in avdt_msg_send() 1228 (p_ccb->p_curr_msg->len > p_tbl->peer_mtu - AVDT_LEN_TYPE_SINGLE)) in avdt_msg_send() [all …]
|
/external/bluetooth/bluedroid/stack/sdp/ |
D | sdp_main.c | 174 tCONN_CB *p_ccb; in sdp_connect_ind() local 177 if ((p_ccb = sdpu_allocate_ccb()) == NULL) in sdp_connect_ind() 181 p_ccb->con_state = SDP_STATE_CFG_SETUP; in sdp_connect_ind() 184 memcpy (&p_ccb->device_address[0], bd_addr, sizeof (BD_ADDR)); in sdp_connect_ind() 185 p_ccb->connection_id = l2cap_cid; in sdp_connect_ind() 209 SDP_TRACE_EVENT1 ("SDP - Rcvd L2CAP conn ind, sent config req, CID 0x%x", p_ccb->connection_id); in sdp_connect_ind() 230 tCONN_CB *p_ccb; in sdp_connect_cfm() local 234 if ((p_ccb = sdpu_find_ccb_by_cid (l2cap_cid)) == NULL) in sdp_connect_cfm() 242 if ((result == L2CAP_CONN_OK) && (p_ccb->con_state == SDP_STATE_CONN_SETUP)) in sdp_connect_cfm() 244 p_ccb->con_state = SDP_STATE_CFG_SETUP; in sdp_connect_cfm() [all …]
|
D | sdp_server.c | 52 static void process_service_search (tCONN_CB *p_ccb, UINT16 trans_num, 56 static void process_service_attr_req (tCONN_CB *p_ccb, UINT16 trans_num, 60 static void process_service_search_attr_req (tCONN_CB *p_ccb, UINT16 trans_num, 110 void sdp_server_handle_client_req (tCONN_CB *p_ccb, BT_HDR *p_msg) in sdp_server_handle_client_req() argument 119 btu_start_timer (&p_ccb->timer_entry, BTU_TTYPE_SDP, SDP_INACT_TIMEOUT); in sdp_server_handle_client_req() 130 sdpu_build_n_send_error (p_ccb, trans_num, SDP_INVALID_PDU_SIZE, SDP_TEXT_BAD_HEADER); in sdp_server_handle_client_req() 137 process_service_search (p_ccb, trans_num, param_len, p_req, p_req_end); in sdp_server_handle_client_req() 141 process_service_attr_req (p_ccb, trans_num, param_len, p_req, p_req_end); in sdp_server_handle_client_req() 145 process_service_search_attr_req (p_ccb, trans_num, param_len, p_req, p_req_end); in sdp_server_handle_client_req() 149 sdpu_build_n_send_error (p_ccb, trans_num, SDP_INVALID_REQ_SYNTAX, SDP_TEXT_BAD_PDU); in sdp_server_handle_client_req() [all …]
|
D | sdp_discovery.c | 48 static void process_service_search_rsp (tCONN_CB *p_ccb, UINT8 *p_reply, UINT16 len); 49 static void process_service_attr_rsp (tCONN_CB *p_ccb, UINT8 *p_reply, UINT16 len); 50 static void process_service_search_attr_rsp (tCONN_CB *p_ccb, UINT8 *p_reply, UINT16 len); 51 static UINT8 *save_attr_seq (tCONN_CB *p_ccb, UINT8 *p, UINT8 *p_msg_end); 119 static void sdp_snd_service_search_req(tCONN_CB *p_ccb, UINT8 cont_len, UINT8 * p_cont) in sdp_snd_service_search_req() argument 128 sdp_disconnect (p_ccb, SDP_NO_RESOURCES); in sdp_snd_service_search_req() 137 UINT16_TO_BE_STREAM (p, p_ccb->transaction_id); in sdp_snd_service_search_req() 138 p_ccb->transaction_id++; in sdp_snd_service_search_req() 146 p = sdpu_build_uuid_seq (p, 1, &p_ccb->p_db->uuid_filters[p_ccb->cur_uuid_idx]); in sdp_snd_service_search_req() 148 p = sdpu_build_uuid_seq (p, p_ccb->p_db->num_uuid_filters, p_ccb->p_db->uuid_filters); in sdp_snd_service_search_req() [all …]
|
/external/bluetooth/bluedroid/stack/mcap/ |
D | mca_cact.c | 47 void mca_ccb_rsp_tout(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data) in mca_ccb_rsp_tout() argument 50 mca_ccb_report_event(p_ccb, MCA_RSP_TOUT_IND_EVT, &evt_data); in mca_ccb_rsp_tout() 62 void mca_ccb_report_event(tMCA_CCB *p_ccb, UINT8 event, tMCA_CTRL *p_data) in mca_ccb_report_event() argument 64 if (p_ccb && p_ccb->p_rcb && p_ccb->p_rcb->p_cback) in mca_ccb_report_event() 65 … (*p_ccb->p_rcb->p_cback)(mca_rcb_to_handle(p_ccb->p_rcb), mca_ccb_to_hdl(p_ccb), event, p_data); in mca_ccb_report_event() 77 void mca_ccb_free_msg(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data) in mca_ccb_free_msg() argument 91 void mca_ccb_snd_req(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data) in mca_ccb_snd_req() argument 99 MCA_TRACE_DEBUG2 ("mca_ccb_snd_req cong=%d req=%d", p_ccb->cong, p_msg->op_code); in mca_ccb_snd_req() 101 if ((p_ccb->status == MCA_CCB_STAT_PENDING) && (p_msg->op_code == MCA_OP_MDL_ABORT_REQ)) in mca_ccb_snd_req() 103 p_dcb = mca_dcb_by_hdl(p_ccb->p_tx_req->dcb_idx); in mca_ccb_snd_req() [all …]
|
D | mca_csm.c | 167 void mca_stop_timer(tMCA_CCB *p_ccb) in mca_stop_timer() argument 169 if (p_ccb->timer_entry.event == BTU_TTYPE_MCA_CCB_RSP) in mca_stop_timer() 171 btu_stop_timer(&p_ccb->timer_entry); in mca_stop_timer() 172 p_ccb->timer_entry.event = 0; in mca_stop_timer() 187 void mca_ccb_event(tMCA_CCB *p_ccb, UINT8 event, tMCA_CCB_EVT *p_data) in mca_ccb_event() argument 193 …T3("CCB ccb=%d event=%s state=%s", mca_ccb_to_hdl(p_ccb), mca_ccb_evt_str[event], mca_ccb_st_str[p… in mca_ccb_event() 195 MCA_TRACE_EVENT3("CCB ccb=%d event=%d state=%d", mca_ccb_to_hdl(p_ccb), event, p_ccb->state); in mca_ccb_event() 199 state_table = mca_ccb_st_tbl[p_ccb->state - 1]; in mca_ccb_event() 202 p_ccb->state = state_table[event][MCA_CCB_NEXT_STATE]; in mca_ccb_event() 207 (*mca_ccb_action[action])(p_ccb, p_data); in mca_ccb_event() [all …]
|
D | mca_api.c | 339 tMCA_CCB *p_ccb; in MCA_ConnectReq() local 343 if ((p_ccb = mca_ccb_by_bd(handle, bd_addr)) == NULL) in MCA_ConnectReq() 344 p_ccb = mca_ccb_alloc(handle, bd_addr); in MCA_ConnectReq() 351 if (p_ccb) in MCA_ConnectReq() 353 p_ccb->ctrl_vpsm = L2CA_Register (ctrl_psm, (tL2CAP_APPL_INFO *)&mca_l2c_int_appl); in MCA_ConnectReq() 355 if (p_ccb->ctrl_vpsm) in MCA_ConnectReq() 358 p_ccb->ctrl_vpsm, BTM_SEC_PROTO_MCA, MCA_CTRL_TCID); in MCA_ConnectReq() 359 p_ccb->lcid = mca_l2c_open_req(bd_addr, p_ccb->ctrl_vpsm, NULL); in MCA_ConnectReq() 360 if (p_ccb->lcid) in MCA_ConnectReq() 362 p_tbl = mca_tc_tbl_calloc(p_ccb); in MCA_ConnectReq() [all …]
|
D | mca_int.h | 219 typedef void (*tMCA_CCB_ACTION)(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data); 241 tMCA_CCB *p_ccb; /* the associated control control block */ member 252 typedef void (*tMCA_DCB_ACTION)(tMCA_DCB *p_ccb, tMCA_DCB_EVT *p_data); 264 extern void mca_ccb_event(tMCA_CCB *p_ccb, UINT8 event, tMCA_CCB_EVT *p_data); 267 extern void mca_ccb_rsp_tout(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data); 268 extern void mca_ccb_dealloc(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data); 269 extern tMCA_CL mca_ccb_to_hdl(tMCA_CCB *p_ccb); 271 extern BOOLEAN mca_ccb_uses_mdl_id(tMCA_CCB *p_ccb, UINT16 mdl_id); 274 extern void mca_ccb_report_event(tMCA_CCB *p_ccb, UINT8 event, tMCA_CTRL *p_data); 275 extern void mca_ccb_free_msg(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data); [all …]
|
/external/bluetooth/bluedroid/stack/avct/ |
D | avct_ccb.c | 44 tAVCT_CCB *p_ccb = &avct_cb.ccb[0]; in avct_ccb_alloc() local 47 for (i = 0; i < AVCT_NUM_CONN; i++, p_ccb++) in avct_ccb_alloc() 49 if (!p_ccb->allocated) in avct_ccb_alloc() 51 p_ccb->allocated = AVCT_ALOC_LCB; in avct_ccb_alloc() 52 memcpy(&p_ccb->cc, p_cc, sizeof(tAVCT_CC)); in avct_ccb_alloc() 61 p_ccb = NULL; in avct_ccb_alloc() 64 return p_ccb; in avct_ccb_alloc() 78 void avct_ccb_dealloc(tAVCT_CCB *p_ccb, UINT8 event, UINT16 result, BD_ADDR bd_addr) in avct_ccb_dealloc() argument 80 tAVCT_CTRL_CBACK *p_cback = p_ccb->cc.p_ctrl_cback; in avct_ccb_dealloc() 82 AVCT_TRACE_DEBUG1("avct_ccb_dealloc %d", avct_ccb_to_idx(p_ccb)); in avct_ccb_dealloc() [all …]
|
D | avct_api.c | 133 tAVCT_CCB *p_ccb; in AVCT_CreateConn() local 139 if ((p_ccb = avct_ccb_alloc(p_cc)) == NULL) in AVCT_CreateConn() 146 *p_handle = avct_ccb_to_idx(p_ccb); in AVCT_CreateConn() 157 avct_ccb_dealloc(p_ccb, AVCT_NO_EVT, 0, NULL); in AVCT_CreateConn() 164 avct_ccb_dealloc(p_ccb, AVCT_NO_EVT, 0, NULL); in AVCT_CreateConn() 171 p_ccb->p_lcb = p_lcb; in AVCT_CreateConn() 173 avct_lcb_event(p_lcb, AVCT_LCB_UL_BIND_EVT, (tAVCT_LCB_EVT *) &p_ccb); in AVCT_CreateConn() 196 tAVCT_CCB *p_ccb; in AVCT_RemoveConn() local 201 if ((p_ccb = avct_ccb_by_idx(handle)) == NULL) in AVCT_RemoveConn() 206 else if (p_ccb->p_lcb == NULL) in AVCT_RemoveConn() [all …]
|
D | avct_lcb_act.c | 196 avct_ccb_dealloc(p_data->p_ccb, AVCT_DISCONNECT_CFM_EVT, 0, NULL); in avct_lcb_unbind_disc() 214 tAVCT_CCB *p_ccb = &avct_cb.ccb[0]; in avct_lcb_open_ind() local 218 for (i = 0; i < AVCT_NUM_CONN; i++, p_ccb++) in avct_lcb_open_ind() 221 if (p_ccb->allocated) in avct_lcb_open_ind() 224 if (p_ccb->p_lcb == p_lcb) in avct_lcb_open_ind() 228 p_ccb->cc.p_ctrl_cback(avct_ccb_to_idx(p_ccb), AVCT_CONNECT_CFM_EVT, in avct_lcb_open_ind() 232 else if ((p_ccb->p_lcb == NULL) && (p_ccb->cc.role == AVCT_ACP) && in avct_lcb_open_ind() 233 (avct_lcb_has_pid(p_lcb, p_ccb->cc.pid) == NULL)) in avct_lcb_open_ind() 237 p_ccb->p_lcb = p_lcb; in avct_lcb_open_ind() 239 p_ccb->cc.p_ctrl_cback(avct_ccb_to_idx(p_ccb), AVCT_CONNECT_IND_EVT, in avct_lcb_open_ind() [all …]
|
D | avct_lcb.c | 93 typedef void (*tAVCT_LCB_ACTION)(tAVCT_LCB *p_ccb, tAVCT_LCB_EVT *p_data); 351 tAVCT_CCB *p_ccb = &avct_cb.ccb[0]; in avct_lcb_dealloc() local 357 for (i = 0; i < AVCT_NUM_CONN; i++, p_ccb++) in avct_lcb_dealloc() 360 if (p_ccb->allocated) in avct_lcb_dealloc() 362 if (p_ccb->p_lcb == p_lcb) in avct_lcb_dealloc() 429 tAVCT_CCB *p_ccb = &avct_cb.ccb[0]; in avct_lcb_has_pid() local 432 for (i = 0; i < AVCT_NUM_CONN; i++, p_ccb++) in avct_lcb_has_pid() 434 if (p_ccb->allocated && (p_ccb->p_lcb == p_lcb) && (p_ccb->cc.pid == pid)) in avct_lcb_has_pid() 436 return p_ccb; in avct_lcb_has_pid() 454 tAVCT_CCB *p_ccb = &avct_cb.ccb[0]; in avct_lcb_last_ccb() local [all …]
|