Home | History | Annotate | Download | only in ag

Lines Matching refs:bta_ag_cb

124   if (bta_ag_cb.sco.p_curr_scb != nullptr && bta_ag_cb.sco.p_curr_scb->in_use) {
125 handle = bta_ag_scb_to_idx(bta_ag_cb.sco.p_curr_scb);
141 bta_ag_cb.sco.p_curr_scb = nullptr;
142 bta_ag_cb.sco.state = BTA_AG_SCO_SHUTDOWN_ST;
163 sco_idx, bta_ag_cb.sco.p_curr_scb, bta_ag_cb.sco.state);
168 &bta_ag_cb.scb[0], bta_ag_cb.scb[0].in_use, bta_ag_cb.scb[0].sco_idx,
169 bta_ag_cb.scb[0].state);
173 &bta_ag_cb.scb[1], bta_ag_cb.scb[1].in_use, bta_ag_cb.scb[1].sco_idx,
174 bta_ag_cb.scb[1].state);
177 if (bta_ag_cb.sco.p_curr_scb != nullptr && bta_ag_cb.sco.p_curr_scb->in_use) {
179 if (bta_ag_cb.sco.p_curr_scb->sco_idx != sco_idx) {
180 if (bta_ag_cb.sco.p_curr_scb->sco_idx != 0xFFFF) return;
182 handle = bta_ag_scb_to_idx(bta_ag_cb.sco.p_curr_scb);
188 if (bta_ag_cb.sco.p_curr_scb->inuse_codec == BTA_AG_CODEC_MSBC) {
197 if (bta_ag_sco_is_opening(bta_ag_cb.sco.p_curr_scb)) {
198 bta_ag_cb.sco.p_curr_scb->state = BTA_AG_SCO_CODEC_ST;
199 if (bta_ag_cb.sco.p_curr_scb->codec_msbc_settings ==
204 bta_ag_cb.sco.p_curr_scb->codec_msbc_settings =
209 bta_ag_cb.sco.p_curr_scb->codec_fallback = true;
212 } else if (bta_ag_sco_is_opening(bta_ag_cb.sco.p_curr_scb)) {
217 bta_ag_cb.sco.p_curr_scb->inuse_codec = BTA_AG_CODEC_NONE;
227 if (bta_ag_cb.sco.p_curr_scb != nullptr) {
228 bta_ag_cb.sco.p_curr_scb->sco_idx = BTM_INVALID_SCO_INDEX;
229 bta_ag_cb.sco.p_curr_scb = nullptr;
230 bta_ag_cb.sco.state = BTA_AG_SCO_SHUTDOWN_ST;
248 if (!only_active || p_scb->sco_idx == bta_ag_cb.sco.cur_idx) {
254 bta_ag_cb.sco.p_curr_scb = p_scb;
287 if (!bta_ag_cb.sco.p_curr_scb) {
292 bta_ag_cb.sco.state = BTA_AG_SCO_OPENING_ST;
293 bta_ag_cb.sco.p_curr_scb = p_scb;
294 bta_ag_cb.sco.cur_idx = p_scb->sco_idx;
298 bta_ag_cb.sco.p_xfer_scb = p_scb;
299 bta_ag_cb.sco.conn_data = p_data->conn_evt;
300 bta_ag_cb.sco.state = BTA_AG_SCO_OPEN_XFER_ST;
302 if (!bta_ag_remove_sco(bta_ag_cb.sco.p_curr_scb, true)) {
306 bta_ag_cb.sco.p_xfer_scb = nullptr;
307 bta_ag_cb.sco.state = BTA_AG_SCO_LISTEN_ST;
347 (*bta_ag_cb.p_cback)(event, (tBTA_AG*)&sco);
421 bta_ag_cb.sco.is_local = true;
424 bta_ag_cb.sco.p_curr_scb = p_scb;
432 bta_ag_create_pending_sco(p_scb, bta_ag_cb.sco.is_local);
471 bta_ag_cb.sco.p_curr_scb = p_scb;
472 bta_ag_cb.sco.cur_idx = p_scb->sco_idx;
504 bta_ag_cb.sco.cur_idx = p_scb->sco_idx;
554 bta_ag_cb.sco.p_curr_scb = p_scb;
588 tBTA_AG_SCO_CB* p_sco = &bta_ag_cb.sco;
1096 return ((bta_ag_cb.sco.state == BTA_AG_SCO_OPEN_ST) &&
1097 (bta_ag_cb.sco.p_curr_scb == p_scb));
1112 return ((bta_ag_cb.sco.state == BTA_AG_SCO_OPENING_ST) &&
1113 (bta_ag_cb.sco.p_curr_scb == p_scb));
1148 if (bta_ag_cb.sco.p_curr_scb && bta_ag_cb.sco.p_curr_scb != p_scb) {
1149 LOG(INFO) << __func__ << ": tranfer " << bta_ag_cb.sco.p_curr_scb->peer_addr
1175 (bta_ag_cb.sco.state == BTA_AG_SCO_CODEC_ST)) {
1257 bta_ag_cb.sco.p_curr_scb = nullptr;
1299 bta_ag_cb.sco.is_local = false;
1304 bta_ag_cb.sco.state);
1306 if (bta_ag_cb.sco.state == BTA_AG_SCO_LISTEN_ST ||
1307 bta_ag_cb.sco.state == BTA_AG_SCO_CLOSE_XFER_ST ||
1308 bta_ag_cb.sco.state == BTA_AG_SCO_OPEN_XFER_ST) {
1317 bta_ag_create_pending_sco(p_scb, bta_ag_cb.sco.is_local);