summaryrefslogtreecommitdiffstats
path: root/audio_a2dp_hw
Commit message (Collapse)AuthorAgeFilesLines
* Merge tag 'android-6.0.1_r61' into HEADreplicant-6.0-0001stable/cm-13.0-ZNH5YJessica Wagantall2016-08-021-11/+11
|\ | | | | | | | | | | Android 6.0.1 Release 61 (MOB30Z) Change-Id: Icda48d6c36e74365e608d80f0054fc58d8febc26
| * DO NOT MERGE Fix potential DoS caused by delivering signal to BT processSharvil Nanavati2016-06-221-11/+11
| | | | | | | | | | | | | | | | | | | | | | Bug: 28885210 Change-Id: I63866d894bfca47464d6e42e3fb0357c4f94d360 Conflicts: btif/co/bta_hh_co.c btif/src/btif_core.c Merge conflict resolution of ag/1161415 (referencing ag/1164670) - Directly into mnc-mr2-release
* | bt: Don't use CLOCK_BOOTTIME where CLOCK_MONOTONIC was expectedEthan Chen2016-06-221-3/+3
| | | | | | | | | | | | | | | | * Commit c71852721a6c97c020c554639ddea0d0c5b7410c changed several calls to clock_gettime(CLOCK_MONOTONIC, ...) to use time_now_timespec, which uses CLOCK_BOOTTIME. Change-Id: Icad8aecc559db24b34cc188484030865d3458cf2
* | bt: Use the clock functions from libutils instead of clock_gettimeChristopher R. Palmer2016-06-111-1/+1
| | | | | | | | | | | | This uses the android wide best code for getting the current time. Change-Id: Ie810a8ed7dd8045c437c27d608b97c2db2e7105d
* | bt: Unify usage of clock_gettimeChristopher R. Palmer2016-06-111-3/+3
| | | | | | | | | | | | | | This moves all clocks to CLOCK_BOOTTIME and puts this define into a common shared location rather than a smear all over the code. Change-Id: I11dbf557f35f75b3030dc0b6829dbaec70e20a19
* | Merge branch 'LA.BF.1.1.3_rb1.7' of git://codeaurora.org/platform/system/bt ↵Steve Kondik2016-01-082-2/+58
|\ \ | | | | | | | | | | | | | | | into cm-13.0 Change-Id: Ic7851f38b6ca4b82ab9a0b96e7e494849944e5c6
| * | git merge android-6.0.1_r3 on to remote branchSudharma Damgatla2015-12-101-6/+43
| |\| | | | | | | | | | Change-Id: I501838b5f3f9d8bf60ab8df59a322a6f1e9199b9
| * | Split A2dp implementationAyan Ghosh2015-12-012-1/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement Split A2dp to process AVDTP Signalling commands from host and media packet handling from Controller. Host uses vendor specific commands to let controller know the media channel configurations for controller to form the media packets accordingly. Change-Id: I7a98177a8125fd70b057bb514f0d870971a45bcf
| * | Check for valid fd before closing the same.Ayan Ghosh2015-10-211-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | For Audio dump debug feature, dump file's validity is not checked before closing the same. This leads to crash when file could not be created properly. Change-Id: I2a53caa3f86e5fd43431e5421cb79e2f76d79884
* | | a2dp: kill more logspamDan Pasanen2015-11-221-1/+1
| | | | | | | | | | | | | | | | | | * srsly...why? Change-Id: I68d8aa78e2be66a2e9c74801f058c2ec04a53c75
* | | shut a2dp logspam.repo Shareef Ali2015-11-221-1/+1
| | | | | | | | | | | | Change-Id: Id67b672e50f5cfc900622235497150c86f8a4938
* | | bt: Kill some logspamChristopher R. Palmer2015-11-221-2/+2
| | | | | | | | | | | | Change-Id: I652684441160e2f5e806a7053ab9b574b2998356
* | | bluedroid: Remove ALSA check on sample rate settingSteve Kondik2015-11-201-0/+4
| | | | | | | | | | | | | | | | | | | | | * All legacy QC devices using the CodeAurora drivers should be using a 48KHz samplerate for A2DP, since that's the only supported output frequency. Change-Id: I8cec354c5a2dde0f85f19cfee2f75501f2a2d5a3
* | | Bluetooth: Change Sampling Frequency to 48 kHzSunny Kapdi2015-11-201-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | Change Default Sampling Frequency to 48 kHz by default to match Audio Source. CRs-fixed: 436686 Change-Id: I73b6b2fe93df2dcede345e4063383aeab2fa05ae
* | | Merge branch 'LA.BF64.1.2.2_rb4.7' of ↵Steve Kondik2015-11-161-1/+2
|\ \ \ | | | | | | | | | | | | | | | | | | | | git://codeaurora.org/platform/system/bt into cm-13.0 Change-Id: Id03529dec9d120d857b952bbc287df8ef10ef7cc
| * | | Check for valid fd before closing the same.Ayan Ghosh2015-11-031-1/+2
| |/ / | | | | | | | | | | | | | | | | | | | | | For Audio dump debug feature, dump file's validity is not checked before closing the same. This leads to crash when file could not be created properly. Change-Id: I2a53caa3f86e5fd43431e5421cb79e2f76d79884
* | | Merge tag 'android-6.0.0_r26' into cm-13.0Ricardo Cerqueira2015-11-051-8/+44
|\ \ \ | |/ / |/| / | |/ | | | | | | | | | | | | | | | | | | Android 6.0.0 release 26 Conflicts: audio_a2dp_hw/audio_a2dp_hw.c btif/co/bta_hh_co.c btif/src/btif_core.c btif/src/btif_dm.c hci/src/btsnoop_net.c Change-Id: Idc868e4339246f35bc9ac5974c87460bbc6ee3b2
| * DO NOT MERGE - A2DP audio HAL: implement out_get_presentation_position()Eric Laurent2015-09-151-5/+42
| | | | | | | | | | | | | | | | And complete implementation of out_get_render_position() Bug: 21199150 Bug: 24042067 Change-Id: I95038ad68433e401b096a0159282a2ae372570e1
* | Bluetooth: Use correct Avdtp features.Gaurav Asati2015-10-062-6/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use AVDT_GetAllCapReq request only when both remote and local Avdtp version are 1.3 and above. CRs-Fixed: 500730 Change-Id: I7145d8c26b5cc73c35e497c1b54d241e3f2317c8 Bluetooth: Clear Collision mask and send disconnect - clear collision mask during cleanup - send avdt disconnect in opening state. CRs-Fixed: 704728 Change-Id: I7438963694ac52dd995d1322823b791ef1cced44 Bluetooth: Set A2dp L2CAP TX Priority to HIGH Raise a2dp l2cap tx priority from medium to high to resolve audio glitchs during concurrency test. Change-Id: If30c6ba6cd1efc2816c686bdfd66814b8227c7a4 CRs-fixed: 733624 Bluetooth: Perform SDP for TG for SINK and CT role - In case we are A2DP Sink and AVRCP CT, we have to perform SDP for AVRCP_TG role. Change-Id: I9990f785920ad35da96a973139c336fe41e3f91e AVRC: Register for AVRC only connection once - Register for AVRC only connection once Change-Id: Ia85771a75d2b2e34aeb80c985a7eefd0300764c0 Bluetooth: Handle getCapability failure for Incoming Connection This change takes care of handling GetCapability failure event for Incoming Connection. DUT will initiate disconnect if GetCapability response is failed. CRs-fixed: 506864 Change-Id: Icc121739cc3da6f999a09f2e576cbfaec3007155 Bluetooth: update proper suspended state to BluetoothApk - update proper suspended state so as to avoid abandoning focus Change-Id: Ie0b8ffbd086bbce1080b7d7930062d09375b6e61 AVRCP: Delay after uinput open - uinput is not ready immediately after create. Because of this any command sent from remote immediately after connection will be ignored. Delay by 30 ms to give time for initialization. Change-Id: I97f1d960d4f5bc85b5e4ca7e58c728aeb187d01e Bluetooth: Synchronise A2dp HAL and Btif state. During Remote initiate start stream, A2dp HAL and Btif states are not in sync, Audio HAL in Suspend and Btif in Start state hence Audio HAL cannot send Suspend command. Change is made to synchronise A2DP HAL and Btif State by sending a CHECK_STREAM_Ready Command. CRs-Fixed: 549210 Change-Id: I5da46c433ec44b94afc4151facc0894fcb88759a Bluetooth: Handle Open after set_config - handle priority check from idle state - handle open after set_config# - changed queue size to 24 Change-Id: I0317dc5ff0e364d35723d74aa36a03ac42503e26 Bluetooth: Fix Crash due to random Connection While connecting randomly between paired headsets rc_handle was not initialised properly and this was causing crash while trying to retrieve peer device features. Change-Id: I4f93d541f616ca2c2bbb1e7871740264b20e3de4 CRs-Fixed: 465980 Add devices to Avrcp Absolute Volume Whitelist Add devices to absolute volume whitelist as these devices are tested to be functioning fine. Change-Id: I2a0c7ae8fd2ff83320327ee08d6d27025134520d
* | BT: Audio: Enhance default stack logging for AUDIOrakesh reddy2015-10-061-23/+134
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make default logging for upstream events, statemachine state transitions, sco state transitions, call state transitions etc. Change-Id: Ia0dcb22e2efb99f186166ae4af2a8cb73f87616d Bluetooth: A2DP Sink Logging. - logs for state transition. - Latency logs with sequence Number. Change-Id: Iedabccd97d1118406f43b7ba494bdec5935b60b9 Print delay logs during A2dp streaming - Log systrace during A2dp streaming. This logging is not enabled by default.BT_AUDIO_SYSTRACE_LOG needs to be defined in applicable files to turn this logging on. - Properly name threads. - Log A2dp write delays. - Log pcm dump before writing to media socket to mediatask. This logging is not enabled by default. BT_AUDIO_SAMPLE_LOG needs to be dfined to enable this logging Change-Id: If081480b29f02126a1d48b9d0d9f855a3a605cc5 Enable required AVRCP Logging by default Enable required AVRCP Logging by default. Introduce additional logging whereever required. Change-Id: Ie2e88de06254257af3b77b4f8b06401273f29262 CRs-Fixed: 751733
* Override remote suspend flag on local play state changesAnubhav Gupta2015-07-062-13/+19
| | | | | | | | | | | | | | | | | | | | | - Remote device may initiate AVDTP Suspend within 3s of AVRCP pause, which sets remote suspend flag. Later on resumption of local playback A2DP packets can not be processed further as Remote suspend flag remains set. current change overrides remote suspend flag if local suspend is triggered later. - This change covers the usecase where play is pressed from DUT UI before local suspend triggers in such scenarios current change takes care of resetitng remote suspend flag on AVRCP play state change event. - Moreover this change will drop A2DP packets when the setparameter is called with A2dpSuspended=true and resumes when the mentioned parameter is reset. This change along with corresponding app change helps mitigating issues reported due to A2Dp, HFP synchronizations and local and remote device initiated AVDTP suspend handling. Bug: 22028876 Change-Id: I3bb334373414170254744d9233cbd2e66219bfa0
* Delay A2DP HAL out stream open processAnubhav Gupta2015-06-231-0/+3
| | | | | | | | | | | Delay A2DP HAL out stream open process to ensure that the Headset is in proper state when START is initiated from DUT immediately after the connection due to ongoing music playback. Jawbone speaker goes to bad state unless it gets enough time between AVDTP OPEN and START. Bug: 22028876 Change-Id: I79a895a85ac7d37208192acf9064fd5c979dd28b
* A2DP: Use mutex to only to check and set HAL stateAnubhav Gupta2015-06-231-8/+13
| | | | | | | | | | | | | | | In multi-threaded env A2DP state gets updated to suspended after checking and before acquiring mutex lock. A2DP State should be checked inside mutex lock to avoid checking against inconsistent state. Moreover this change prevents overwriting of state from AUDIO_A2DP_STATE_SUSPENDED to AUDIO_A2DP_STATE_STOPPED which would start the data path when there is data inflow from audio in suspended state, which is not intended. This change helps avoiding above wrong actions. Bug: 22028876 Change-Id: I4fb73c1a6851fa97d539860d5fc0b8022b019bc1
* Revert "A2DP audio HAL: implement get_presentation_position()"Eric Laurent2015-06-051-38/+5
| | | | | | This reverts commit 0b6c835cab0391f73a453686f4e665dd02661d77. Bug: 21660426.
* A2DP audio HAL: implement get_presentation_position()Eric Laurent2015-05-261-5/+38
| | | | | Bug: 21199150. Change-Id: If8e95645b636be82a32420cad1ca6a3993e14f1c
* Make unused tagging consistent, using the portable macro.Ian Coolidge2015-04-161-7/+10
| | | | Change-Id: Id3b68bd32edfce13a847eef55ae81cd47e8fc112
* Protect reset of out stream with mutexNitin Srivastava2015-04-131-0/+2
| | | | | | | Protect reset of out stream with mutex so that the access of the same is properly synchronized in multi-threaded environment. Change-Id: I6dd81d8c7fa219ee8d1e4d82aa1e7ec52dcecec8
* Make A2DP audio HAL a shared library againAndre Eisenbach2015-03-271-1/+1
| | | | | | | The audio HAL is loaded separately from the Bluetooth stack and thus needs to stay separate. Change-Id: I8d8601a6e753099f4f058dc0192b93c53be2ffb1
* Demote, cleanup and extend observed loggingChris Manton2015-03-161-1/+1
|
* Add platform-independent logging macros to OSI.Sharvil Nanavati2015-03-162-6/+6
| | | | | | These macros should replace ALOG* and the various trace macros used throughout bluedroid. This change eliminates all uses of the ALOG* macros in favor of the new ones.
* Re-layout Android.mk for single shared libraryChris Manton2015-03-161-2/+2
|
* audio HAL: remove misleading error logEric Laurent2014-10-291-3/+1
| | | | | Bug: 17916028. Change-Id: I4badb9208eeb973a08b4f8463ee287f6bfb3dd01
* audio HAL: add parameters to open stream functionsEric Laurent2014-07-271-2/+5
| | | | | | | | Pass device address (and audio source for inputs) to open_output_stream() and open_input_stream() audio HAL functions. Bug: 14815883. Change-Id: I4f66478606349ab64d880923c53de00a11d74d25
* Add audio_input_flags_t to HAL open_input_streamGlenn Kasten2014-07-171-1/+2
| | | | Change-Id: I5023c0fdb8069668ca2b84096277d6abdbf7d729
* A2DP: Fix audio stuttering in A2DP sink modeMike Lockwood2014-07-111-17/+10
| | | | Change-Id: Ied821aeb14f83e3fd1daa6e175ac995abbfbb198
* audio: deprecate audio_stream_frame_size()Eric Laurent2014-07-031-1/+1
| | | | | Bug: 15000850. Change-Id: I1edcc78561cdc328ae0d91a1d07b0836ca5e1715
* Fix audio HAL build (make it a shared library again)Mike Lockwood2014-07-011-1/+3
| | | | | Bug: 15978121 Change-Id: I23ba30f27b73b48a1d9128d294641367bfffa810
* resolved conflicts for merge of e01b1126 to masterMatthew Xie2014-06-271-13/+6
|\ | | | | | | Change-Id: I7a7b069b1a5f75205e540a578c17a2633e8df18e
| * Re-layout Android.mk for single shared libraryChris Manton2014-06-091-10/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Shared object libraries require complete symbol resolution while archives do not. The hci, btutil and a2dp hbtutil were built as shared, but used the other archive libraries (e.g. gki). To resolve all symbols in each of the so's, they stubbed out data interfaces to the common structures. (e.g. hci/include/utils.h) This will unify all libraries and eliminate multiple definitions of the same structure. Change-Id: I2af9a3e8a87888cd007aaf0809cdfc09039cd460
| * Set out stream to null if control socket fails to connectNitin Srivastava2014-04-291-1/+4
| | | | | | | | | | | | | | | | | | Set out stream to null if control socket fails to connect. This helps in avoiding wrong usage of audio device out stream even after the same is freed as part of control socket connection failure. Change-Id: I8e2a7bbc71d581525b7eef1955e411c220d01627
| * Bluetooth: retry recv in case of EINTRNitin Srivastav2014-04-291-3/+18
| | | | | | | | | | | | | | - retry recv call in HAL, in case socket call fails with EINTR Change-Id: I3ab27752b0ce0a68f6776cf5da340580e7d1f345
| * a2dp audio HAL: use correct interface versionZhihai Xu2014-04-211-1/+1
| | | | | | | | | | | | | | | | Do not use AUDIO_DEVICE_API_VERSION_CURRENT version but AUDIO_DEVICE_API_VERSION_2_0 to reflect the version actually implemeted. Change-Id: I31407af7fc4769be1d259ee739422ce9f598be2e
| * audio: fix set_parameters return value.Zhihai Xu2014-04-211-4/+4
| | | | | | | | | | | | | | | | xxx_set_parameters functions were returning the status returned by str_parms_create_str() which is incorrect. These functions should return 0 when no error occurs. Change-Id: I984d95457c985fbaf1a15baa522f8a84f99dd7c9
* | resolved conflicts for merge of 795bcebc to masterSharvil Nanavati2014-06-181-0/+2
|\| | | | | | | Change-Id: I150d30e1fa69a00b6b264a8478b50de2fd7597e9
| * Compile using C99.Sharvil Nanavati2014-04-161-0/+2
| | | | | | | | | | | | | | | | | | | | | | Change-Id: Ifda03e0b3ee3a915bf7ce5a5dce27e5e215dcce2 Conflicts: bta/Android.mk gki/Android.mk main/Android.mk stack/Android.mk test/bluedroidtest/Android.mk
| * DO NOT MERGE Revert "external/bluetooth/bluedroid: convert LOCAL_MODULE_PATH ↵Matthew Xie2014-03-191-1/+1
| | | | | | | | | | | | | | | | to LOCAL_MODULE_RELATIVE_PATH" This reverts commit 273789bb86ef99f5ce022bb64c601ea4ea6f8bb3. Change-Id: I29e511a8176979a6bf311206427b94a19f06f284
* | More work on A2DP Sink:Mike Lockwood2014-06-122-165/+330
| | | | | | | | | | | | | | | | | | Output audio data through A2DP audio HAL rather than playing directly to native AudioTrack API. Add separate HAL interface for A2DP sink Change-Id: I6c6cb6088c350e104b4a7354f328b29c7178e295
* | Set out stream to null if control socket fails to connectNitin Srivastava2014-05-061-1/+4
| | | | | | | | | | | | | | | | | | Set out stream to null if control socket fails to connect. This helps in avoiding wrong usage of audio device out stream even after the same is freed as part of control socket connection failure. Change-Id: I8e2a7bbc71d581525b7eef1955e411c220d01627
* | Bluetooth: retry recv in case of EINTRNitin Srivastav2014-05-061-3/+18
| | | | | | | | | | | | | | - retry recv call in HAL, in case socket call fails with EINTR Change-Id: I3ab27752b0ce0a68f6776cf5da340580e7d1f345
* | Compile using C99.Sharvil Nanavati2014-05-061-0/+2
| | | | | | | | | | | | | | | | | | | | | | Change-Id: Ifda03e0b3ee3a915bf7ce5a5dce27e5e215dcce2 Conflicts: bta/Android.mk gki/Android.mk main/Android.mk stack/Android.mk test/bluedroidtest/Android.mk