summaryrefslogtreecommitdiffstats
path: root/services
Commit message (Collapse)AuthorAgeFilesLines
* audio policy: protect capture from telephony RX path.Eric Laurent2015-08-073-0/+5
| | | | | | | | Add permission check if the capture device selected is telephony RX path. Bug: 23017158. Change-Id: Iaa34d836e6cf46b7cbbf2483fcd4306dcd27ce90
* audio policy: populate attributes for attached capture devicesEric Laurent2015-08-061-2/+6
| | | | | | | | | | Populate supported sampling rates, channel masks and formats when enumerating attached build in capture devices. Having this information for build-in mic is important for some applications. Bug: 22729461. Change-Id: I93f03296447a87c10f2615fa1b1c45e9879b4aa7
* AudioFlinger: tell HAL the PCM is non-audioPhil Burk2015-08-041-1/+2
| | | | | | | | | | | Add a bit to tell the HAL that the PCM data is really encoded audio wrapped in a data burst. Otherwise the device may try to play the encoded data directly which will sound like modulated white noise. Bug: 22576112 Change-Id: Ib140da96876e849023858fe2510612310501d1ee Signed-off-by: Phil Burk <philburk@google.com>
* Merge "Fix capture overruns at non-primary sample rate" into mnc-devGlenn Kasten2015-07-243-20/+7
|\
| * Fix capture overruns at non-primary sample rateGlenn Kasten2015-07-223-20/+7
| | | | | | | | | | | | | | | | | | and small buffer size. Also: Pull out the magic number "12 ms" to a named constant. Remove obsolete AudioFlinger::mPrimaryOutputSampleRate. Bug: 22662814 Change-Id: I261f75a222c4505a84aad2493d251bd2dea59f68
* | Merge "Fix record memory buffer allocation for legacy upmix/downmix" into ↵Andy Hung2015-07-231-1/+1
|\ \ | | | | | | | | | mnc-dev
| * | Fix record memory buffer allocation for legacy upmix/downmixAndy Hung2015-07-221-1/+1
| |/ | | | | | | | | Bug: 22173057 Change-Id: I8f5056ff5a1252c71a3d3b354440551bcd9fd466
* | Prevent notifications from muting accessibility promptsJean-Michel Trivi2015-07-211-6/+6
|/ | | | | | | | | | | | | | | When evaluating on which device a sound is to be played, the policy must consider which current routing strategy, if any, has priority for overriding the choice. Here the playback of notifications, when duplicated over speaker and headphones, was causing the accessibility prompt to be muted because the it was of a higher priority, and incompatible with the accessibility routing. The fix consists in assigning a higher priority to the accessbility routing strategy over the notification routing strategy. Bug 18834451 Change-Id: I8228b30a7d80bd61d1c223afb030d9421d4f33cf
* Merge "mediaresourcemanager: add pid to removeResource method" into mnc-devRonghua Wu2015-07-183-27/+33
|\
| * mediaresourcemanager: add pid to removeResource methodRonghua Wu2015-07-173-27/+33
| | | | | | | | | | Bug: 22496209 Change-Id: I73311573e8d1ac15fec668a9ef6e6af7a07a1d30
* | Merge "Fix UAF error in CameraModule." into mnc-devRuben Brunk2015-07-181-2/+3
|\ \
| * | Fix UAF error in CameraModule.Ruben Brunk2015-07-171-2/+3
| | | | | | | | | | | | | | | Bug: 22542551 Change-Id: I2fe5791a6554a8e2f7fd94593d552d8af18257db
* | | Merge "AudioFlinger: fix repeated underruns for compressed audio" into mnc-devPhil Burk2015-07-175-16/+79
|\ \ \
| * | | AudioFlinger: fix repeated underruns for compressed audioPhil Burk2015-07-175-16/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The AudioFlinger kept pausing the audio when playing compressed AC3 or DTS. This caused pause/resume loops that were hard to break out of. The AudioFlinger was thinking that the compressed audio was PCM because the HAL was in PCM mode playing SPDIF data bursts. It also thought that EAC3 was at 192000 Hz instead of 48000 Hz because the data bursts are played at a higher rate. This CL adds more calls to the shim that separates the AudioFlinger. Now the AudioFlinger gets information about the HAL sample rate, channel masks and format from the shim instead of calling the HAL directly. The AudioFlinger now uses a different threshold for detecting underruns when the audio is compressed. Bug: 19938315 Bug: 20891646 Change-Id: Ib16f539346d1c7a273ea4feb3d3afcc3dc60237d Signed-off-by: Phil Burk <philburk@google.com>
* | | | Merge "Camera2Client: handle slower jpeg stream sensor" into mnc-devYin-Chia Yeh2015-07-175-18/+154
|\ \ \ \
| * | | | Camera2Client: handle slower jpeg stream sensorYin-Chia Yeh2015-07-165-18/+154
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If largest jpeg stream cannot sustain 30 FPS, don't create jpeg stream until takePicture is called and remove it after still capture is done. Also, disable video snapshot for such sensors so video snapshot won't slow down video recording. Bug: 22231605 Change-Id: I2b34d2537c224694ae10f2006b5a46be45a1b1a6
* | | | | Merge "Camera: Add hidden experimental tearDown method." into mnc-devEino-Ville Talvala2015-07-1710-1/+164
|\ \ \ \ \ | |_|/ / / |/| | | |
| * | | | Camera: Add hidden experimental tearDown method.Eino-Ville Talvala2015-07-1610-1/+164
| | |_|/ | |/| | | | | | | | | | | | | | Bug: 18949148 Change-Id: Ie86ec7d1ec3db54e1154563b2339a208a935f849
* | | | Update Policy PFW plugin makefile for PFW release 2.6.0François Gaffie2015-07-151-6/+1
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch updates the Policy PFW plugin with latest change within PFW. It makes use of the dynamic xmlserializer library and does not need anymore to link against xmlserializer library dependencies. Change-Id: Ic7b912929a69d3906a34999c1ae25ddb9ac800e5 Signed-off-by: François Gaffie <francois.gaffie@intel.com> Bug 246391
* | | Merge "mediaresourcemanager: handle the case when there's no client holding ↵Ronghua Wu2015-07-143-103/+128
|\ \ \ | |_|/ |/| | | | | resource with the same type" into mnc-dev
| * | mediaresourcemanager: handle the case when there's no client holding ↵Ronghua Wu2015-07-133-103/+128
| | | | | | | | | | | | | | | | | | | | | resource with the same type Bug: 21171205 Change-Id: Id4aa6ccc7ee7daba25fd295399235c5b463ccd83
* | | Merge "audioflinger: flush HAL when transitioning to next direct track" into ↵Eric Laurent2015-07-131-9/+12
|\ \ \ | | | | | | | | | | | | mnc-dev
| * | | audioflinger: flush HAL when transitioning to next direct trackEric Laurent2015-07-071-9/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Send flush command to the audio HAL when transtioning to next track on direct output thread, even if both tracks are in the same audio session. Commit 43b4dcc to fix issue 21145353 did only flush the HAL if the audio session was different for the new track because the logic was copied from the offload thread. Bug: 22019044. Change-Id: I89b217580023ed7449a58e9bf3dc068ce7a84487
* | | | audio: several fixes in audio routing callbacksEric Laurent2015-07-106-40/+52
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - audio policy: Force device change to ensure new audio patch creation upon first track activity on a given output. Fix function device_distinguishes_on_address() which could mistake some output device with remote submix input device. - audio flinger: Reduce number of binder calls upon new client registration by only sending ioConfigChanged() callbacks to newly registered client. Fix first patch after output thread creation not triggering an ioConfigChanged() callback. -audio system: Force client registration upon routing callback installation to force new ioConfigChanged() callback from audio flinger. Bug: 22381136. Change-Id: Ieb0d9f92f563a40552eb31bc0499c8ac65f78ce4
* | | audio policy: session route: move SessionRoute to commonFrançois Gaffie2015-07-095-179/+244
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the SessionRoute and SessionRouteMap inner class from policy manager to common policy pillars as initiated by the refactor. This code was added at teh wrong place by commit aa981194. Bug: 22376521. Change-Id: I29aca21614e409c59aae4b7b14163552fb0bffb1 Signed-off-by: François Gaffie <francois.gaffie@intel.com>
* | | Merge "audio policy: add support for device combo with speaker safe" into ↵Eric Laurent2015-07-092-4/+12
|\ \ \ | | | | | | | | | | | | mnc-dev
| * | | audio policy: add support for device combo with speaker safeEric Laurent2015-07-072-4/+12
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | combo devices with AUDIO_DEVICE_OUT_SPEAKER_SAFE were not supported by audio policy manager causing selection of speaker+headphone when spekaer_safe+headphone would be the right selection. Bug: 21537010. Change-Id: I9865352559c9d32c6754ad3d2b84bddfe2dc8aac
* | | Merge "AudioFlinger: reset frame position on standby" into mnc-devPhil Burk2015-07-084-67/+87
|\ \ \ | |/ / |/| |
| * | AudioFlinger: reset frame position on standbyPhil Burk2015-07-074-67/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The HAL does not reset the frame position on standby(). But applications expect the frame position to be reset. So we subtract the position at standby from the current position. Bug: 21724210 Bug: 21930805 Change-Id: I0c4520ba1c6c06a580f45f6bafc8cf1d56969f07 Signed-off-by: Phil Burk <philburk@google.com>
* | | Merge "camera2: Fix native binder interface and add tests." into mnc-devRuben Brunk2015-07-071-1/+1
|\ \ \
| * | | camera2: Fix native binder interface and add tests.Ruben Brunk2015-07-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Add CameraBinderTests for limited coverage of native camera2 binder interfaces for the camera service. - Fix several bugs in the native binder interfaces. Bug: 18468810 Change-Id: Iab2d81a5cacd20daf7454aeeed033cc13d88452c
* | | | Merge "CameraModule: fix getCameraInfo()" into mnc-devChien-Yu Chen2015-07-072-6/+15
|\ \ \ \
| * | | | CameraModule: fix getCameraInfo()Chien-Yu Chen2015-07-062-6/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove mCameraCharacteristicsMap. CameraModule kept a CameraMetadata in mCameraCharacteristicsMap and kept its camera_metadata in mCameraInfoMap. When CameraMetadata gets moved in mCameraCharacteristicsMap, it may clone a new camera_metadata and free the old one. So the original camera_metadata stored in mCameraCharacteristicsMap becomes invalid. Bug: 22171288 Change-Id: Ia8e99fe42989946bc952ad23abb296aeac60da83
* | | | | audio: Do not delete PatchRecord before Peer is stoppedEric Laurent2015-07-061-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PatchPanel::clearPatchConnections deletes PatchRecord before the peer PatchTrack is stopped. This can cause an access to already free'ed memory leading to a crash in PatchTrack::getNextBuffer. Fix is to delete PatchRecord and PatchTrack only after removing both of them from active tracks list Bug: 22304526. Change-Id: I7003756d3d2dd8912ce5e3b2fc31f5e82f455888
* | | | | Merge "audio policy: fix regression in incall notification management" into ↵Eric Laurent2015-07-061-2/+5
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | mnc-dev
| * | | | | audio policy: fix regression in incall notification managementEric Laurent2015-07-021-2/+5
| | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 2110e04c introduced a regression preventing ongoing alarms to be restored when exiting a call and leaving the replacement tone playing for ever. Also add missing management of accessibility prompts when entering a call. Bug: 21857005. Change-Id: I4295c791c003db42c0fba9f618e51f60438158d1
* | | | | Merge "audio: add definitions for devices connected over IP" into mnc-devEric Laurent2015-07-062-0/+6
|\ \ \ \ \ | |_|/ / / |/| | | |
| * | | | audio: add definitions for devices connected over IPEric Laurent2015-07-062-0/+6
| |/ / / | | | | | | | | | | | | | | | | Bug: 22068684. Change-Id: Idde0eaf7121d2e43f32eee3e6b10e99d8cff4912
* | | | Fix build warningGlenn Kasten2015-07-061-0/+1
| | | | | | | | | | | | | | | | Change-Id: I876edc37fb2093ee13c876c2af5c46512763154d
* | | | Merge "audiopolicy: Update flag enum tables for the new flags" into mnc-devGlenn Kasten2015-07-061-0/+4
|\ \ \ \ | |/ / / |/| | |
| * | | audiopolicy: Update flag enum tables for the new flagsRavi Kumar Alamanda2015-07-021-0/+4
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | Without an entry in sOutputFlagNameToEnumTable or sInputFlagNameToEnumTable, a profile with specific output/input flag in the audio_policy.conf will not be detected by AudioPolicyManager. Bug: 19230391 Change-Id: I94bb3594e2eb8b57747b474a253da3551263c59a
* | | Camera3-Device: Fix AE lock availableChien-Yu Chen2015-06-302-16/+16
|/ / | | | | | | | | | | | | | | | | Pass whether AE lock is available when creating the request thread because when the request thread was created, its parent's info was not set yet. Bug: 20494782 Change-Id: I11ed3f99c473955c437e81f3e1d704c15a9ca1a4
* | Merge "reduce number of binder calls from mediaserver" into mnc-devEric Laurent2015-06-274-6/+38
|\ \
| * | reduce number of binder calls from mediaserverEric Laurent2015-06-264-6/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce the number of audio port, audio patch and IO config changed binder calls from mediaserver to client processes: - Do not call IO config changed callback if selected device is the same as previously selected one on a given audio flinger playback or capture thread. - Do not call the audio port or audo patch list update callback on a client if this client as no listener registered. Bug: 22045560. Change-Id: If780e105404de79b7cb5c80c27b793ceb6b1c423
* | | audio policy: fix several device descriptor issues.Eric Laurent2015-06-255-20/+20
|/ / | | | | | | | | | | | | | | | | | | | | | | - checkOutputsForDevice() should only clear device descriptor attributes if the device is digital. - checkInputsForDevice() did not clear device descriptor attributes at all. - AudioPort::clearCapabilities() and importAudioPort() should not manage gains as these are device specific. - importAudioPort() should load a default port config. Bug: 21990937. Change-Id: Ida762ed8f9baaabae392cb4291eff1a8d3009751
* | Merge "Camera3: Support AE precapture trigger CANCEL" into mnc-devChien-Yu Chen2015-06-242-31/+124
|\ \
| * | Camera3: Support AE precapture trigger CANCELChien-Yu Chen2015-06-242-31/+124
| | | | | | | | | | | | | | | | | | | | | | | | Support AE precapture trigger CANCEL for devices <= API version 3.2. Bug: 20494782 Change-Id: I6003ba8057ca4ec9e8dfda47b8411ae6be913d22
* | | Merge "Add default for pre-distortion active array." into mnc-devRuben Brunk2015-06-231-0/+9
|\ \ \ | | |/ | |/|
| * | Add default for pre-distortion active array.Ruben Brunk2015-06-221-0/+9
| | | | | | | | | | | | | | | Bug: 20491394 Change-Id: I53b0539b37cc7a042e6765c97775b8c2bbba7159
* | | Merge "Using centralized isAudioPlaybackRateValid to validate parameters" ↵Ricardo Garcia2015-06-233-10/+9
|\ \ \ | |/ / |/| | | | | into mnc-dev