Lines Matching refs:p_tbl
81 AvdtpTransportChannel* p_tbl; in avdt_sec_check_complete_term() local
86 p_tbl = avdt_ad_tc_tbl_by_st(AVDT_CHAN_SIG, p_ccb, AVDT_AD_ST_SEC_ACP); in avdt_sec_check_complete_term()
87 if (p_tbl == NULL) return; in avdt_sec_check_complete_term()
91 L2CA_ConnectRsp(*bd_addr, p_tbl->id, p_tbl->lcid, L2CAP_CONN_OK, in avdt_sec_check_complete_term()
95 avdtp_cb.ad.lcid_tbl[p_tbl->lcid - L2CAP_BASE_APPL_CID] = in avdt_sec_check_complete_term()
96 avdt_ad_tc_tbl_to_idx(p_tbl); in avdt_sec_check_complete_term()
97 avdtp_cb.ad.rt_tbl[avdt_ccb_to_idx(p_ccb)][p_tbl->tcid].lcid = p_tbl->lcid; in avdt_sec_check_complete_term()
100 p_tbl->state = AVDT_AD_ST_CFG; in avdt_sec_check_complete_term()
105 cfg.mtu = p_tbl->my_mtu; in avdt_sec_check_complete_term()
107 cfg.flush_to = p_tbl->my_flush_to; in avdt_sec_check_complete_term()
108 L2CA_ConfigReq(p_tbl->lcid, &cfg); in avdt_sec_check_complete_term()
110 L2CA_ConnectRsp(*bd_addr, p_tbl->id, p_tbl->lcid, L2CAP_CONN_SECURITY_BLOCK, in avdt_sec_check_complete_term()
112 avdt_ad_tc_close_ind(p_tbl, L2CAP_CONN_SECURITY_BLOCK); in avdt_sec_check_complete_term()
132 AvdtpTransportChannel* p_tbl; in avdt_sec_check_complete_orig() local
136 p_tbl = avdt_ad_tc_tbl_by_st(AVDT_CHAN_SIG, p_ccb, AVDT_AD_ST_SEC_INT); in avdt_sec_check_complete_orig()
137 if (p_tbl == NULL) return; in avdt_sec_check_complete_orig()
141 p_tbl->state = AVDT_AD_ST_CFG; in avdt_sec_check_complete_orig()
146 cfg.mtu = p_tbl->my_mtu; in avdt_sec_check_complete_orig()
148 cfg.flush_to = p_tbl->my_flush_to; in avdt_sec_check_complete_orig()
149 L2CA_ConfigReq(p_tbl->lcid, &cfg); in avdt_sec_check_complete_orig()
151 L2CA_DisconnectReq(p_tbl->lcid); in avdt_sec_check_complete_orig()
152 avdt_ad_tc_close_ind(p_tbl, L2CAP_CONN_SECURITY_BLOCK); in avdt_sec_check_complete_orig()
168 AvdtpTransportChannel* p_tbl = NULL; in avdt_l2c_connect_ind_cback() local
189 p_tbl = avdt_ad_tc_tbl_alloc(p_ccb); in avdt_l2c_connect_ind_cback()
190 p_tbl->my_mtu = avdtp_cb.rcb.ctrl_mtu; in avdt_l2c_connect_ind_cback()
191 p_tbl->my_flush_to = L2CAP_DEFAULT_FLUSH_TO; in avdt_l2c_connect_ind_cback()
192 p_tbl->tcid = AVDT_CHAN_SIG; in avdt_l2c_connect_ind_cback()
193 p_tbl->lcid = lcid; in avdt_l2c_connect_ind_cback()
194 p_tbl->id = id; in avdt_l2c_connect_ind_cback()
195 p_tbl->state = AVDT_AD_ST_SEC_ACP; in avdt_l2c_connect_ind_cback()
196 p_tbl->cfg_flags = AVDT_L2C_CFG_CONN_ACP; in avdt_l2c_connect_ind_cback()
212 L2CA_ConnectRsp(p_ccb->peer_addr, p_tbl->id, lcid, L2CAP_CONN_PENDING, in avdt_l2c_connect_ind_cback()
219 p_tbl = avdt_ad_tc_tbl_by_st(AVDT_CHAN_SIG, p_ccb, AVDT_AD_ST_CONN); in avdt_l2c_connect_ind_cback()
220 if (p_tbl != NULL) { in avdt_l2c_connect_ind_cback()
227 p_tbl = avdt_ad_tc_tbl_by_st(AVDT_CHAN_MEDIA, p_ccb, AVDT_AD_ST_ACP); in avdt_l2c_connect_ind_cback()
228 if (p_tbl != NULL) { in avdt_l2c_connect_ind_cback()
235 p_tbl = avdt_ad_tc_tbl_by_st(AVDT_CHAN_REPORT, p_ccb, AVDT_AD_ST_ACP); in avdt_l2c_connect_ind_cback()
236 if (p_tbl != NULL) { in avdt_l2c_connect_ind_cback()
254 avdt_ad_tc_tbl_to_idx(p_tbl); in avdt_l2c_connect_ind_cback()
255 avdtp_cb.ad.rt_tbl[avdt_ccb_to_idx(p_ccb)][p_tbl->tcid].lcid = lcid; in avdt_l2c_connect_ind_cback()
258 p_tbl->state = AVDT_AD_ST_CFG; in avdt_l2c_connect_ind_cback()
263 cfg.mtu = p_tbl->my_mtu; in avdt_l2c_connect_ind_cback()
265 cfg.flush_to = p_tbl->my_flush_to; in avdt_l2c_connect_ind_cback()
281 AvdtpTransportChannel* p_tbl; in avdt_l2c_connect_cfm_cback() local
288 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_connect_cfm_cback()
289 if (p_tbl != NULL) { in avdt_l2c_connect_cfm_cback()
291 if (p_tbl->state == AVDT_AD_ST_CONN) { in avdt_l2c_connect_cfm_cback()
294 if (p_tbl->tcid != AVDT_CHAN_SIG) { in avdt_l2c_connect_cfm_cback()
296 p_tbl->state = AVDT_AD_ST_CFG; in avdt_l2c_connect_cfm_cback()
301 cfg.mtu = p_tbl->my_mtu; in avdt_l2c_connect_cfm_cback()
303 cfg.flush_to = p_tbl->my_flush_to; in avdt_l2c_connect_cfm_cback()
306 p_ccb = avdt_ccb_by_idx(p_tbl->ccb_idx); in avdt_l2c_connect_cfm_cback()
311 p_tbl->state = AVDT_AD_ST_SEC_INT; in avdt_l2c_connect_cfm_cback()
312 p_tbl->lcid = lcid; in avdt_l2c_connect_cfm_cback()
313 p_tbl->cfg_flags = AVDT_L2C_CFG_CONN_INT; in avdt_l2c_connect_cfm_cback()
337 avdt_ad_tc_close_ind(p_tbl, result); in avdt_l2c_connect_cfm_cback()
354 AvdtpTransportChannel* p_tbl; in avdt_l2c_config_cfm_cback() local
359 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_config_cfm_cback()
360 if (p_tbl != NULL) { in avdt_l2c_config_cfm_cback()
361 p_tbl->lcid = lcid; in avdt_l2c_config_cfm_cback()
364 if (p_tbl->state == AVDT_AD_ST_CFG) { in avdt_l2c_config_cfm_cback()
368 p_tbl->cfg_flags |= AVDT_L2C_CFG_CFM_DONE; in avdt_l2c_config_cfm_cback()
371 if (p_tbl->cfg_flags & AVDT_L2C_CFG_IND_DONE) { in avdt_l2c_config_cfm_cback()
372 avdt_ad_tc_open_ind(p_tbl); in avdt_l2c_config_cfm_cback()
395 AvdtpTransportChannel* p_tbl; in avdt_l2c_config_ind_cback() local
400 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_config_ind_cback()
401 if (p_tbl != NULL) { in avdt_l2c_config_ind_cback()
404 p_tbl->peer_mtu = p_cfg->mtu; in avdt_l2c_config_ind_cback()
406 p_tbl->peer_mtu = L2CAP_DEFAULT_MTU; in avdt_l2c_config_ind_cback()
408 AVDT_TRACE_DEBUG("%s: peer_mtu: %d, lcid: %d", __func__, p_tbl->peer_mtu, in avdt_l2c_config_ind_cback()
417 if ((p_tbl->cfg_flags & AVDT_L2C_CFG_IND_DONE) == 0) { in avdt_l2c_config_ind_cback()
419 p_tbl->cfg_flags |= AVDT_L2C_CFG_IND_DONE; in avdt_l2c_config_ind_cback()
422 if (p_tbl->cfg_flags & AVDT_L2C_CFG_CFM_DONE) { in avdt_l2c_config_ind_cback()
423 avdt_ad_tc_open_ind(p_tbl); in avdt_l2c_config_ind_cback()
440 AvdtpTransportChannel* p_tbl; in avdt_l2c_disconnect_ind_cback() local
445 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_disconnect_ind_cback()
446 if (p_tbl != NULL) { in avdt_l2c_disconnect_ind_cback()
452 avdt_ad_tc_close_ind(p_tbl, 0); in avdt_l2c_disconnect_ind_cback()
467 AvdtpTransportChannel* p_tbl; in avdt_l2c_disconnect_cfm_cback() local
472 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_disconnect_cfm_cback()
473 if (p_tbl != NULL) { in avdt_l2c_disconnect_cfm_cback()
474 avdt_ad_tc_close_ind(p_tbl, result); in avdt_l2c_disconnect_cfm_cback()
489 AvdtpTransportChannel* p_tbl; in avdt_l2c_congestion_ind_cback() local
492 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_congestion_ind_cback()
493 if (p_tbl != NULL) { in avdt_l2c_congestion_ind_cback()
494 avdt_ad_tc_cong_ind(p_tbl, is_congested); in avdt_l2c_congestion_ind_cback()
509 AvdtpTransportChannel* p_tbl; in avdt_l2c_data_ind_cback() local
512 p_tbl = avdt_ad_tc_tbl_by_lcid(lcid); in avdt_l2c_data_ind_cback()
513 if (p_tbl != NULL) { in avdt_l2c_data_ind_cback()
514 avdt_ad_tc_data_ind(p_tbl, p_buf); in avdt_l2c_data_ind_cback()