diff options
author | Mattias Agren <magren@broadcom.com> | 2012-03-26 08:25:00 -0700 |
---|---|---|
committer | Matthew Xie <mattx@google.com> | 2012-07-14 11:19:13 -0700 |
commit | 254588bfe6c3e70625b0f725b908598f30f476c8 (patch) | |
tree | 259c87422e70b74abeab96b3e3155c88791e5b6d /bta | |
parent | 3e6f399bdbaca7f8ab0a8b1c6eab7cc1088ab74a (diff) | |
download | external_bluetooth_bluedroid-254588bfe6c3e70625b0f725b908598f30f476c8.zip external_bluetooth_bluedroid-254588bfe6c3e70625b0f725b908598f30f476c8.tar.gz external_bluetooth_bluedroid-254588bfe6c3e70625b0f725b908598f30f476c8.tar.bz2 |
Added new control and data path interface between audioflinger a2dp HAL
and stack. Added support for suspend and a dedicated HAL callback
notifying framework on audiopath events. Cleanup.
Change-Id: I3b738611bc8e1d84794f7207413fd9e7dd1fc668
Diffstat (limited to 'bta')
-rw-r--r-- | bta/av/bta_av_aact.c | 15 | ||||
-rw-r--r--[-rwxr-xr-x] | bta/dm/bta_dm_act.c | 0 | ||||
-rw-r--r--[-rwxr-xr-x] | bta/dm/bta_dm_api.c | 0 | ||||
-rw-r--r--[-rwxr-xr-x] | bta/dm/bta_dm_int.h | 0 | ||||
-rw-r--r--[-rwxr-xr-x] | bta/dm/bta_dm_main.c | 0 | ||||
-rw-r--r--[-rwxr-xr-x] | bta/include/bta_api.h | 0 |
6 files changed, 12 insertions, 3 deletions
diff --git a/bta/av/bta_av_aact.c b/bta/av/bta_av_aact.c index 423c322..2bcbf01 100644 --- a/bta/av/bta_av_aact.c +++ b/bta/av/bta_av_aact.c @@ -1701,7 +1701,7 @@ void bta_av_do_start (tBTA_AV_SCB *p_scb, tBTA_AV_DATA *p_data) { bta_av_start_ok(p_scb, NULL); } - APPL_TRACE_DEBUG1("role:x%x", p_scb->role); + APPL_TRACE_DEBUG2("started %d role:x%x", p_scb->started, p_scb->role); } /******************************************************************************* @@ -1721,7 +1721,9 @@ void bta_av_str_stopped (tBTA_AV_SCB *p_scb, tBTA_AV_DATA *p_data) BT_HDR *p_buf; UINT8 policy = HCI_ENABLE_SNIFF_MODE; - APPL_TRACE_ERROR1("bta_av_str_stopped:audio_open_cnt=%d", bta_av_cb.audio_open_cnt); + APPL_TRACE_ERROR2("bta_av_str_stopped:audio_open_cnt=%d, p_data %x", + bta_av_cb.audio_open_cnt, p_data); + bta_sys_idle(BTA_ID_AV, bta_av_cb.audio_open_cnt, p_scb->peer_addr); if ((bta_av_cb.features & BTA_AV_FEAT_MASTER) == 0 || bta_av_cb.audio_open_cnt == 1) policy |= HCI_ENABLE_MASTER_SLAVE_SWITCH; @@ -1749,6 +1751,7 @@ void bta_av_str_stopped (tBTA_AV_SCB *p_scb, tBTA_AV_DATA *p_data) suspend_rsp.chnl = p_scb->chnl; suspend_rsp.hndl = p_scb->hndl; + if (p_data && p_data->api_stop.suspend) { APPL_TRACE_DEBUG2("suspending: %d, sup:%d", start, p_scb->suspend_sup); @@ -1768,6 +1771,10 @@ void bta_av_str_stopped (tBTA_AV_SCB *p_scb, tBTA_AV_DATA *p_data) } else { + suspend_rsp.status = BTA_AV_SUCCESS; + suspend_rsp.initiator = TRUE; + APPL_TRACE_EVENT1("bta_av_str_stopped status %d", suspend_rsp.status); + (*bta_av_cb.p_cback)(BTA_AV_STOP_EVT, (tBTA_AV *) &suspend_rsp); } } @@ -2075,7 +2082,9 @@ void bta_av_start_ok (tBTA_AV_SCB *p_scb, tBTA_AV_DATA *p_data) p_scb->p_cos->start(p_scb->hndl, p_scb->codec_type); p_scb->co_started = TRUE; - APPL_TRACE_ERROR2("bta_av_start_ok suspending: %d, role:x%x", suspend, p_scb->role); + APPL_TRACE_DEBUG3("bta_av_start_ok suspending: %d, role:x%x, init %d", + suspend, p_scb->role, initiator); + start.suspending = suspend; start.initiator = initiator; start.chnl = p_scb->chnl; diff --git a/bta/dm/bta_dm_act.c b/bta/dm/bta_dm_act.c index 3c93f23..3c93f23 100755..100644 --- a/bta/dm/bta_dm_act.c +++ b/bta/dm/bta_dm_act.c diff --git a/bta/dm/bta_dm_api.c b/bta/dm/bta_dm_api.c index 4c77f37..4c77f37 100755..100644 --- a/bta/dm/bta_dm_api.c +++ b/bta/dm/bta_dm_api.c diff --git a/bta/dm/bta_dm_int.h b/bta/dm/bta_dm_int.h index 6d220e7..6d220e7 100755..100644 --- a/bta/dm/bta_dm_int.h +++ b/bta/dm/bta_dm_int.h diff --git a/bta/dm/bta_dm_main.c b/bta/dm/bta_dm_main.c index 38bf0af..38bf0af 100755..100644 --- a/bta/dm/bta_dm_main.c +++ b/bta/dm/bta_dm_main.c diff --git a/bta/include/bta_api.h b/bta/include/bta_api.h index 57baa4d..57baa4d 100755..100644 --- a/bta/include/bta_api.h +++ b/bta/include/bta_api.h |