Lines Matching full:role
269 /* if start failed, clear role */
270 p_scb->role &= ~BTA_AV_ROLE_START_INT;
297 (p_scb->use_rc == TRUE || (p_scb->role & BTA_AV_ROLE_AD_ACP)) )
674 ** Description Switch role was not started and a timer was started.
675 ** another attempt to switch role now - still opening.
728 ** Description Handle the role changed event
740 APPL_TRACE_DEBUG3("bta_av_role_res q_tag:%d, wait:x%x, role:x%x", p_scb->q_tag, p_scb->wait, p_scb->role);
741 if (p_scb->role & BTA_AV_ROLE_START_INT)
751 p_scb->role &= ~BTA_AV_ROLE_START_INT;
753 /* start failed because of role switch. */
772 p_scb->role &= ~BTA_AV_ROLE_START_INT;
777 /* Open failed because of role switch. */
793 APPL_TRACE_WARNING2 ("Unexpected role switch event: q_tag = %d wait = %d", p_scb->q_tag, p_scb->wait);
797 APPL_TRACE_DEBUG2("wait:x%x, role:x%x", p_scb->wait, p_scb->role);
842 /* waiting for role switch result. save the api to control block */
861 /* continue to open if link role is ok */
881 /* clear the role switch bits */
949 UINT8 role = BTA_AV_ROLE_AD_INT;
965 p_scb->role = role;
1047 p_scb->role |= BTA_AV_ROLE_AD_ACP;
1164 p_scb->role |= BTA_AV_ROLE_SUSPEND_OPT;
1165 APPL_TRACE_ERROR3("bta_av_setconfig_rsp recfg_needed:%d role:x%x num:%d",
1166 p_data->ci_setconfig.recfg_needed, p_scb->role, num);
1779 APPL_TRACE_DEBUG3("bta_av_do_start sco_occupied:%d, role:x%x, started:%d", bta_av_cb.sco_occupied, p_scb->role, p_scb->started);
1786 /* disallow role switch during streaming, only if we are the master role
1787 * i.e. allow role switch, if we are slave.
1797 if ((p_scb->started == FALSE) && ((p_scb->role & BTA_AV_ROLE_START_INT) == 0))
1799 p_scb->role |= BTA_AV_ROLE_START_INT;
1806 p_scb->role |= BTA_AV_ROLE_START_INT;
1808 if (p_scb->role & BTA_AV_ROLE_SUSPEND) {
1815 APPL_TRACE_DEBUG2("started %d role:x%x", p_scb->started, p_scb->role);
2098 UINT8 new_role = p_scb->role;
2103 APPL_TRACE_DEBUG2("bta_av_start_ok wait:x%x, role:x%x", p_scb->wait, p_scb->role);
2116 /* role switch has failed */
2143 /* this could happen if a role switch complete event occurred during reconfig */
2144 /* if we are now master on the link, there is no need to wait for the role switch, */
2145 /* complete anymore so we can clear the wait for role switch flag */
2166 /* tell role manager to check M/S role */
2208 /* If souce is the master role, disable role switch during streaming.
2209 * Otherwise allow role switch, if source is slave.
2220 p_scb->role = new_role;
2221 p_scb->role &= ~BTA_AV_ROLE_AD_ACP;
2222 p_scb->role &= ~BTA_AV_ROLE_SUSPEND_OPT;
2228 APPL_TRACE_DEBUG3("bta_av_start_ok suspending: %d, role:x%x, init %d",
2229 suspend, p_scb->role, initiator);
2240 p_scb->role |= BTA_AV_ROLE_SUSPEND;
2400 if (p_scb->role & BTA_AV_ROLE_SUSPEND)
2402 p_scb->role &= ~BTA_AV_ROLE_SUSPEND;
2451 /* No need to keep the role bits once reconfig is done. */
2452 p_scb->role &= ~BTA_AV_ROLE_AD_ACP;
2453 p_scb->role &= ~BTA_AV_ROLE_SUSPEND_OPT;
2454 p_scb->role &= ~BTA_AV_ROLE_START_INT;
2719 if (!(p_scb->role & BTA_AV_ROLE_SUSPEND_OPT))
2759 APPL_TRACE_DEBUG3("bta_av_open_rc use_rc: %d, wait: x%x role:x%x", p_scb->use_rc, p_scb->wait, p_scb->role);
2762 /* waiting for role switch for some reason & the timer expires */
2765 APPL_TRACE_ERROR0 ("failed to start streaming for role management reasons!!");
2777 /* role switch is done. continue to start streaming */
2785 if(p_scb->use_rc == TRUE || (p_scb->role & BTA_AV_ROLE_AD_ACP) )