| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| | |
Change-Id: Ifd30546c11def40ad483f27c9d7baa4008fcbac3
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add binder calls to register and unregister dynamic mixes
to AudioPolicyManager.
Bug: 16009464.
Change-Id: I4ef38166d0cfc88c984970969380d0cd6eb083ac
|
|\ \
| |/
| |
| |
| |
| |
| | |
into lmp-mr1-dev
* commit 'c49d9cda49dab8b7dd0376cf56476b3e1895d5c6':
audio policy: add support for custom mixes
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add support for custom mixes in AudioPolicyManager.
Two methods are added to register or unregister a list of custom mixes
with their attributes and format.
getOutputForAttr() and getInputForAttr() first look for a match in
registered mixes before defaulting to normal output/input selection
Remote submix device connection disconnection now takes address into
account to identify the correspnoding custom mix.
Bug: 16009464.
Change-Id: I3f1c2a485a0fb71b1f984ed0adc9b68aa971e408
|
|\ \
| |/
| |
| |
| | |
* commit 'c1b0d49cacde26c2420528169d157d2c778a9b0d':
Prevent ANR when AudioTrack is paused or re-routed
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If ClientProxy was interrupted by AudioTrack::pause() just before futex syscall() in obtainBuffer() was called,
It will not call releaseBuffer to wake up AudioTrackThread.
It puts the AudioTrackThread to sleep and then a deadlock occurs.
In this case, CBLK_INTERRUPT flags can't prevent a deadlock,
so this patch set mFutex to FUTEX_WAKE during interrupt() to avoid deadlock.
A similar problem could occur due to re-route or recovery after mediaserver death.
Bug: 18641665
Change-Id: I66fcae43af9a91eb55f6cdb52c644ee6c0999772
|
| |
| |
| |
| |
| |
| |
| |
| | |
If track is restored when it set its volume to a non-unity value (such as mute),
the volume was forced to unity again. Now, the previous volume is restored.
Bug: 18570664
Change-Id: I79f34c6c7d6f535baba813fd3b8ba8e55cac8ad7
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | | |
track is restored"
* commit 'bde85d05414cdd3888071635dd05e9ff78679d5e':
Track volume should be maintained even if track is restored
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If track is restored when it set its volume to a non-unity value (such as mute),
the volume was forced to unity again. Now, the previous volume is restored.
Bug: 18570664
Change-Id: I79f34c6c7d6f535baba813fd3b8ba8e55cac8ad7
|
|\ \ \
| | |/
| |/|
| | |
| | |
| | |
| | | |
of audio source." into lmp-mr1-dev
* commit '390ef84373b7edd1397381f780ca235326357094':
AudioRecord: use audio attributes instead of audio source.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Added AudioRecord constructor with audio attributes.
Replaced AudioPolicymanager::getInput() by getInputForAttr().
No new functionality for now.
Also:
- Fixed warnings in AudioPolicyManager
- Allocate audio session ID before calling getOutputForAttr() in
AudioTrack.
Bug: 16006090.
Change-Id: I15df21e4411db688e3096dd801cf579d76d81711
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | | |
prototype." into lmp-mr1-dev
* commit 'bf14c62e7973ed793a3b00c2c67beca4484c1c7a':
audio policy: new getOutputForAttr() prototype.
|
| |\ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Update getOutputForAttr() prototype and group all logic
dealing with audio attributes to stream type conversion in
audio policy manager.
getOutputForAttr():
- specifies the audio session (for future use)
- returns a status code
- receives either stream type (for legacy) or audio attributes
- returns an updated streamtype
Remove logic dealing with legacy stream types to attributes conversion
from AudioTrack.
Use correct type for audio sessions in other APIs (startOutput() ...).
releaseOutput() specifies the audio session (for future use).
Bug: 18067208.
Change-Id: I1bfbe9626c04c7955d77f8a70aecfad2cb204817
|
|\ \ \ \
| |/ / /
| | | |
| | | |
| | | |
| | | |
| | | | |
buffer start" into lmp-mr1-dev
* commit '1e18795a4847e9368baa7ecee146d3901b283cd0':
Fix AudioTrack loop mode to play audio from buffer start
|
| |\ \ \
| | |/ /
| |/| |
| | | | |
lmp-mr1-dev
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Bug: 18217633
Change-Id: Ica77acf0a32832d9b04eb657ef2f4f5329f8fbda
|
|\ \ \ \
| |/ / /
| | | |
| | | |
| | | | |
* commit '1a475921c0577a4650d1bbe40a85b732d1766939':
audio: new routing strategies and stream types
|
| |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Added new routing strategies and stream type for internal use
by audio policy manager and audio flinger:
- One for accessibility to allow different routing than media
- One for re-routing (remote submix) in preparation of dynamic
policies
- Added stream type for "internal" audio flinger tracks used
for audio patches and duplication.
Bug: 18067208.
Change-Id: I88f884b552e51e4a49c29125e5a1204cf58ff434
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | | |
into lmp-mr1-dev
* commit 'f8c2d1665393d8e0620a7129ef3865f34489e6ef':
Fix missing loop count for static tracks.
|
| |\ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
StaticAudioTrackServerProxy::framesReady() previously returned
only the contiguous frames, update to return the total
available frames. This resolves short-count looping in
SoundPool for FastTracks.
Also (1) Removes the racy condition of reading two variables
and (2) Fixes buffer->mNonContig to return the correct value
and (3) Restores behavior that loop count of 1 goes back to
loopStart once during playback.
Bug: 11830751
Bug: 12070295
Bug: 17456842
Change-Id: I64906e6036bb00a1d7375b03efe6deb69d6478ca
|
|\ \ \ \
| |/ / /
| | | |
| | | |
| | | |
| | | |
| | | | |
lmp-mr1-dev
* commit '568689b169d8b0ae2cc252b88602db5e5acaa604':
AudioSystem: fix cross deadlock
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Do not hold gLockAPS when calling
AudioPolicyService::registerClient() in get_audio_policy_service().
registerClient() will need to acquire the AudioPolicyService mutex and
if at the same time a method called from AudioPolicyService
(with mutex held) calls back into AudioSystem and get_audio_policy_service()
a cross deadlock occurs.
Same preventive fix for get_audio_flinger().
Use a separate mutex for notification client list in AudioPolicyService.
This prevents deadlocking if registerClient() is called as a consequence of
AudioFlinger calling back into AudioPolicyManager while executing a method
with AudioPolicyService locked
Bug: 18403952.
Bug: 18450065.
Change-Id: Ia832e41aede8bc6c843fc615508fbdd74e0863b5
|
|\ \ \ \
| | |_|/
| |/| |
| | | |
| | | | |
* commit 'cd370c790a9017560874a2588da46d4538087cad':
Use standard syntax to initialize fields.
|
| |\ \ \ |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Clang compiler gives warning to old gnu syntax.
BUG: 18193625
Change-Id: I1b5237d60866fc357fc808f6a6955ab20418a7d8
|
|\ \ \ \ \
| | |_|/ /
| |/| | |
| | | | |
| | | | |
| | | | |
| | | | | |
into lmp-mr1-dev
* commit '4fd641be9fed70743ca4fe823b69e74c258ce275':
AudioSystem: Add mutex for output cache
|
| |\ \ \ \ |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Fix cross deadlock with AudioFlinger by adding
a dedicated mutex to protect access to cached output list
and parameters.
Bug: 18410728.
Change-Id: Ia31283b1972d8865a46e84e63695173c187eb781
|
|\ \ \ \ \ \
| |/ / / / /
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
A2DP when suspended." into lmp-mr1-dev
* commit 'bfa77b5c687f217e26267693306aaa6cc8a63672':
audio policy: do not prevent routing to A2DP when suspended.
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Allow A2DP sink selection even if A2DP is suspended.
It is not because use of A2DP is temporarily disabled by SCO
selection that the policy rule routing a given use case
to A2DP should be altered. The source will be routed to A2DP
but it will remain silent until suspend condition is cleared
which is the purpose of suspend mode.
Also make sure that accessibility prompts are audible while in call
by forcing stream type to STREAM_VOICE_CALL.
Fix inconsistent logic between AudioTrack::setStreamTypeFromAttributes()
and AudioPolicyManager::getStrategyForAttr()
Bug: 18095151.
Change-Id: I1c75dd8288ed3dd494eb942060eac9c9660dca50
|
|\ \ \ \ \
| | |/ / /
| |/| | |
| | | | |
| | | | |
| | | | |
| | | | | |
have atomic.h."
* commit '26d92768d6dac505903c96e842673ee9a57a0989':
No need to #include atomic-inline.h if you have atomic.h.
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I79f9a53b95dcf84dff62ed4b3c0661c7c1e1fc64
|
|\ \ \ \ \
| |/ / / /
| | | | |
| | | | |
| | | | | |
* commit '2716969d2b88e85a6ed5a766b54a0a34dc137118':
libcutils no longer requires that its users configure ANDROID_SMP.
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Ib91ff0696ab2472c62168eb5261bbda5d22f623e
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | | |
Change-Id: If10a9cc17245f95d5e10b1507445abbb4020670e
|
| |\ \ \ \ \
| | |/ / / /
| | | | | |
| | | | | |
| | | | | | |
* commit '9b77083e582a8b6088ac6a2cb4151dfbdd324557':
Update calls to IInterface::asBinder()
|
| | | |/ /
| | |/| |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
to use the new static version.
Change-Id: Ia7b10eb38ca55b72278bfd33d3bf647f338b4e6a
Conflicts:
media/libmedia/IAudioFlinger.cpp
media/libmedia/IMediaPlayer.cpp
media/libstagefright/CameraSource.cpp
|
| | |\ \ \ |
|
|\ \ \ \ \ \
| | |_|_|/ /
| |/| | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
lmp-mr1-dev
automerge: 0e8a328
* commit '0e8a3284c6828e561f58e66a014c3b7ee37325cf':
remove AudioSystem::getOutputSamplingRateForAttr()
|
| | |_|_|/
| |/| | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
It is safer to query the output sampling rate once the output
have been acquired by calling getOutputForAttr().
Bug: 16009464.
Change-Id: Ib561facd19fba5359a6b837d75f1a1cd2dc51b29
|
|\ \ \ \ \
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
lmp-mr1-dev automerge: e662cd5
* commit 'b177468bb1647c79ba48cd0a172cf3306b31ad69':
Improve AudioTrack recovery from mediaserver death
|
| |\ \ \ \ |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
1. Fix race condition in handling of binder death notifications.
AudioSystem has a mixture of APIs for both ordinary app clients,
and the AudioFlinger and AudioPolicy services within mediaserver.
Due to this mix of uses, it is possible for there to be "surprising"
sequences of calls on the call stack.
Previously, we used a single mutex for all global variables, but
this caused a deadlock. To avoid the deadlock, we unlocked the mutex
during the critical sequence of calls. But this was a a
crucial place where it should have stayed locked;
see Change-Id I315c1c5066f62b05e1c13b04fae1272b5fbce977
Now we use separate mutexes for the AudioFlinger, AudioPolicy, and audio port
related global variables. This allows us to correctly hold each mutex
throughout the atomic region, even when AudioFlinger calls AudioPolicy
via AudioSystem, or vice-versa.
2. AudioSystem::clearAudioConfigCache now clears the IAudioFlinger reference.
3. Make AudioSystem::get_audio_policy_service more like get_audio_flinger.
Bug: 18242291
Change-Id: I9761443d8337df5bf66d4ca2316a9fd0bd11be94
|
|\ \ \ \ \ \
| |/ / / / /
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
automerge: c339a92
* commit '7e88fac080e3bb1cdc95667f82727ea6c19fb173':
AudioSystem: remove obsolete method.
|
| |\ \ \ \ \ |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Bug: 18067208.
Change-Id: I9bbf9088485f5162c765ca504d9b784b956234c6
|
|\ \ \ \ \ \ \
| |/ / / / / /
|/| | | / / /
| | |_|/ / /
| |/| | | | |
* commit '113adbbc652874360332caa0c9df68e6b1e25fde':
Fix definining of ANDROID_SMP.
|
| |\ \ \ \ \
| | | |_|/ /
| | |/| | /
| | |_|_|/
| |/| | | |
Change-Id: I545e15dde7774624139717e0b23bd96c444cb1bc
|