• Home
  • Raw
  • Download

Lines Matching refs:p_scb

98   tBTA_AV_SCB* p_scb;  in bta_av_del_rc()  local
101 p_scb = NULL; in bta_av_del_rc()
106 p_scb = bta_av_cb.p_scb[p_rcb->shdl - 1]; in bta_av_del_rc()
108 if (p_scb) { in bta_av_del_rc()
110 p_rcb->shdl, p_scb->rc_handle, p_rcb->handle); in bta_av_del_rc()
111 if (p_scb->rc_handle == p_rcb->handle) in bta_av_del_rc()
112 p_scb->rc_handle = BTA_AV_RC_HANDLE_NONE; in bta_av_del_rc()
116 alarm_cancel(p_scb->avrc_ct_timer); in bta_av_del_rc()
323 tBTA_AV_SCB* p_scb = p_cb->p_scb[shdl - 1]; in bta_av_rc_create() local
324 bda = p_scb->PeerAddress(); in bta_av_rc_create()
482 tBTA_AV_SCB* p_scb; in bta_av_rc_opened() local
492 p_scb = p_cb->p_scb[i]; in bta_av_rc_opened()
493 if (p_scb && p_scb->PeerAddress() == p_data->rc_conn_chg.peer_addr) { in bta_av_rc_opened()
494 p_scb->rc_handle = p_data->rc_conn_chg.handle; in bta_av_rc_opened()
496 p_scb->rc_handle); in bta_av_rc_opened()
499 p_scb->use_rc); in bta_av_rc_opened()
500 alarm_cancel(p_scb->avrc_ct_timer); in bta_av_rc_opened()
501 disc = p_scb->hndl; in bta_av_rc_opened()
1020 tBTA_AV_SCB* p_scb; in bta_av_rc_close() local
1030 p_scb = bta_av_cb.p_scb[p_rcb->shdl - 1]; in bta_av_rc_close()
1031 if (p_scb) { in bta_av_rc_close()
1035 alarm_cancel(p_scb->avrc_ct_timer); in bta_av_rc_close()
1064 static uint8_t bta_av_get_shdl(tBTA_AV_SCB* p_scb) { in bta_av_get_shdl() argument
1069 if (p_scb == bta_av_cb.p_scb[i]) { in bta_av_get_shdl()
1086 void bta_av_stream_chg(tBTA_AV_SCB* p_scb, bool started) { in bta_av_stream_chg() argument
1087 uint8_t started_msk = BTA_AV_HNDL_TO_MSK(p_scb->hdi); in bta_av_stream_chg()
1090 p_scb->PeerAddress().ToString().c_str(), in bta_av_stream_chg()
1095 L2CA_SetAclPriority(p_scb->PeerAddress(), L2CAP_PRIORITY_HIGH); in bta_av_stream_chg()
1098 L2CA_SetAclPriority(p_scb->PeerAddress(), L2CAP_PRIORITY_NORMAL); in bta_av_stream_chg()
1114 tBTA_AV_SCB* p_scb = NULL; in bta_av_conn_chg() local
1128 p_scb = p_cb->p_scb[index]; in bta_av_conn_chg()
1135 if (p_scb) { in bta_av_conn_chg()
1178 p_scb->rc_handle = p_cb->rc_acp_handle; in bta_av_conn_chg()
1180 p_rcb->shdl = bta_av_get_shdl(p_scb); in bta_av_conn_chg()
1182 index + 1, p_rcb->shdl, p_scb->rc_handle); in bta_av_conn_chg()
1211 if (p_scb) { in bta_av_conn_chg()
1213 p_scb->OnDisconnected(); in bta_av_conn_chg()
1214 if (p_scb->chnl == BTA_AV_CHNL_AUDIO) { in bta_av_conn_chg()
1221 { alarm_cancel(p_scb->avrc_ct_timer); } in bta_av_conn_chg()
1271 p_scbi = bta_av_cb.p_scb[i]; in bta_av_conn_chg()
1307 if (p_cb->p_scb[xx] != NULL) { in bta_av_disable()
1309 alarm_free(p_cb->p_scb[xx]->link_signalling_timer); in bta_av_disable()
1310 p_cb->p_scb[xx]->link_signalling_timer = NULL; in bta_av_disable()
1311 alarm_free(p_cb->p_scb[xx]->accept_signalling_timer); in bta_av_disable()
1312 p_cb->p_scb[xx]->accept_signalling_timer = NULL; in bta_av_disable()
1336 tBTA_AV_SCB* p_scb = in bta_av_api_disconnect() local
1338 AVDT_DisconnectReq(p_scb->PeerAddress(), bta_av_conn_cback); in bta_av_api_disconnect()
1339 alarm_cancel(p_scb->link_signalling_timer); in bta_av_api_disconnect()
1365 tBTA_AV_SCB* p_scb = bta_av_cb.p_scb[index]; in bta_av_find_lcb_index_by_scb_and_address() local
1366 if (p_scb == nullptr) { in bta_av_find_lcb_index_by_scb_and_address()
1369 if (p_scb->PeerAddress() == peer_address) { in bta_av_find_lcb_index_by_scb_and_address()
1380 tBTA_AV_SCB* p_scb = bta_av_cb.p_scb[index]; in bta_av_find_lcb_index_by_scb_and_address() local
1381 if (p_scb == nullptr) { in bta_av_find_lcb_index_by_scb_and_address()
1384 if (!p_scb->IsAssigned()) { in bta_av_find_lcb_index_by_scb_and_address()
1430 tBTA_AV_SCB* p_scb = p_cb->p_scb[xx]; in bta_av_sig_chg() local
1446 p_scb->OnConnected(p_data->str_msg.bd_addr); in bta_av_sig_chg()
1447 p_scb->use_rc = true; /* allowing RC for incoming connection */ in bta_av_sig_chg()
1448 bta_av_ssm_execute(p_scb, BTA_AV_ACP_CONNECT_EVT, p_data); in bta_av_sig_chg()
1457 if (!p_scb->link_signalling_timer) { in bta_av_sig_chg()
1458 p_scb->link_signalling_timer = alarm_new("link_signalling_timer"); in bta_av_sig_chg()
1461 hdr.layer_specific = p_scb->hndl; in bta_av_sig_chg()
1465 bta_sys_conn_open(BTA_ID_AV, p_scb->app_id, p_scb->PeerAddress()); in bta_av_sig_chg()
1468 p_scb->coll_mask = BTA_AV_COLL_INC_TMR; in bta_av_sig_chg()
1469 if (!p_scb->accept_signalling_timer) { in bta_av_sig_chg()
1470 p_scb->accept_signalling_timer = alarm_new("accept_signalling_timer"); in bta_av_sig_chg()
1473 p_scb->accept_signalling_timer, BTA_AV_ACCEPT_SIGNALLING_TIMEOUT_MS, in bta_av_sig_chg()
1480 alarm_cancel(p_cb->p_scb[scb_index]->link_signalling_timer); in bta_av_sig_chg()
1492 if (p_cb->p_scb[xx] && in bta_av_sig_chg()
1493 p_cb->p_scb[xx]->PeerAddress() == p_data->str_msg.bd_addr) { in bta_av_sig_chg()
1495 bta_sys_conn_close(BTA_ID_AV, p_cb->p_scb[xx]->app_id, in bta_av_sig_chg()
1496 p_cb->p_scb[xx]->PeerAddress()); in bta_av_sig_chg()
1500 p_cb->p_scb[xx] && in bta_av_sig_chg()
1501 p_cb->p_scb[xx]->PeerAddress() == p_data->str_msg.bd_addr) { in bta_av_sig_chg()
1504 p_cb->p_scb[xx]->PeerAddress().ToString().c_str()); in bta_av_sig_chg()
1505 bta_av_ssm_execute(p_cb->p_scb[xx], BTA_AV_AVDT_DISCONNECT_EVT, NULL); in bta_av_sig_chg()
1528 tBTA_AV_SCB* p_scb = bta_av_hndl_to_scb(hndl); in bta_av_signalling_timer() local
1546 APPL_TRACE_DEBUG("%s hndl 0x%x", __func__, p_scb->hndl); in bta_av_signalling_timer()
1547 bta_sys_start_timer(p_scb->link_signalling_timer, in bta_av_signalling_timer()
1577 tBTA_AV_SCB* p_scb = NULL; in bta_av_accept_signalling_timer_cback() local
1579 p_scb = p_cb->p_scb[inx]; in bta_av_accept_signalling_timer_cback()
1581 if (p_scb) { in bta_av_accept_signalling_timer_cback()
1582 APPL_TRACE_DEBUG("%s: coll_mask=0x%02x", __func__, p_scb->coll_mask); in bta_av_accept_signalling_timer_cback()
1584 if (p_scb->coll_mask & BTA_AV_COLL_INC_TMR) { in bta_av_accept_signalling_timer_cback()
1585 p_scb->coll_mask &= ~BTA_AV_COLL_INC_TMR; in bta_av_accept_signalling_timer_cback()
1587 if (bta_av_is_scb_opening(p_scb)) { in bta_av_accept_signalling_timer_cback()
1589 p_scb->sdp_discovery_started); in bta_av_accept_signalling_timer_cback()
1590 if (p_scb->sdp_discovery_started) { in bta_av_accept_signalling_timer_cback()
1592 p_scb->coll_mask |= BTA_AV_COLL_INC_TMR; in bta_av_accept_signalling_timer_cback()
1594 alarm_set_on_mloop(p_scb->accept_signalling_timer, in bta_av_accept_signalling_timer_cback()
1600 bta_av_discover_req(p_scb, NULL); in bta_av_accept_signalling_timer_cback()
1602 } else if (bta_av_is_scb_incoming(p_scb)) { in bta_av_accept_signalling_timer_cback()
1607 if (p_scb->coll_mask & BTA_AV_COLL_API_CALLED) { in bta_av_accept_signalling_timer_cback()
1608 p_scb->coll_mask &= ~BTA_AV_COLL_API_CALLED; in bta_av_accept_signalling_timer_cback()
1613 memcpy(p_buf, &(p_scb->open_api), sizeof(tBTA_AV_API_OPEN)); in bta_av_accept_signalling_timer_cback()
1883 tBTA_AV_SCB* p_scb = NULL; in bta_av_rc_disc_done() local
1900 p_scb = p_cb->p_scb[(p_cb->disc & BTA_AV_HNDL_MSK) - 1]; in bta_av_rc_disc_done()
1902 if (p_scb) { in bta_av_rc_disc_done()
1903 rc_handle = p_scb->rc_handle; in bta_av_rc_disc_done()
1968 if (p_scb) { in bta_av_rc_disc_done()
1974 p_lcb = bta_av_find_lcb(p_scb->PeerAddress(), BTA_AV_LCB_FIND); in bta_av_rc_disc_done()
1977 (uint8_t)(p_scb->hdi + 1), p_lcb->lidx); in bta_av_rc_disc_done()
1983 } else if (p_scb->use_rc) { in bta_av_rc_disc_done()
1985 p_scb->use_rc = false; in bta_av_rc_disc_done()
1987 rc_open.peer_addr = p_scb->PeerAddress(); in bta_av_rc_disc_done()
2001 if (p_scb == NULL) { in bta_av_rc_disc_done()
2009 rc_feat.peer_addr = p_scb->PeerAddress(); in bta_av_rc_disc_done()
2022 if (p_scb == NULL) { in bta_av_rc_disc_done()
2025 rc_psm.peer_addr = p_scb->PeerAddress(); in bta_av_rc_disc_done()
2050 tBTA_AV_SCB* p_scb; in bta_av_rc_closed() local
2056 p_scb = NULL; in bta_av_rc_closed()
2071 p_scb = bta_av_cb.p_scb[p_rcb->shdl - 1]; in bta_av_rc_closed()
2073 if (p_scb) { in bta_av_rc_closed()
2074 rc_close.peer_addr = p_scb->PeerAddress(); in bta_av_rc_closed()
2075 if (p_scb->rc_handle == p_rcb->handle) in bta_av_rc_closed()
2076 p_scb->rc_handle = BTA_AV_RC_HANDLE_NONE; in bta_av_rc_closed()
2078 p_scb->rc_handle); in bta_av_rc_closed()
2192 tBTA_AV_SCB* p_scb; in bta_av_rc_disc() local
2208 p_scb = p_cb->p_scb[hdi]; in bta_av_rc_disc()
2210 if (p_scb) { in bta_av_rc_disc()
2211 APPL_TRACE_DEBUG("%s: rc_handle %d", __func__, p_scb->rc_handle); in bta_av_rc_disc()
2212 peer_addr = p_scb->PeerAddress(); in bta_av_rc_disc()
2248 tBTA_AV_SCB* p_scb; in bta_av_dereg_comp() local
2254 p_scb = bta_av_hndl_to_scb(p_data->hdr.layer_specific); in bta_av_dereg_comp()
2256 if (p_scb) { in bta_av_dereg_comp()
2257 APPL_TRACE_DEBUG("%s: deregistered %d(h%d)", __func__, p_scb->chnl, in bta_av_dereg_comp()
2258 p_scb->hndl); in bta_av_dereg_comp()
2259 mask = BTA_AV_HNDL_TO_MSK(p_scb->hdi); in bta_av_dereg_comp()
2267 if (p_scb->q_tag == BTA_AV_Q_TAG_STREAM && p_scb->a2dp_list) { in bta_av_dereg_comp()
2269 while (!list_is_empty(p_scb->a2dp_list)) { in bta_av_dereg_comp()
2270 p_buf = (BT_HDR*)list_front(p_scb->a2dp_list); in bta_av_dereg_comp()
2271 list_remove(p_scb->a2dp_list, p_buf); in bta_av_dereg_comp()
2304 bta_av_free_scb(p_scb); in bta_av_dereg_comp()