308 Commits

Author SHA1 Message Date
Eric Laurent
aa54a1d39b am cda6ed31: Fix issue 2304701: Media streams can remain muted on A2DP output.
Merge commit 'cda6ed314ac73ffaeb0350056c84fc0d8b7b58ea' into eclair-mr2

* commit 'cda6ed314ac73ffaeb0350056c84fc0d8b7b58ea':
  Fix issue 2304701: Media streams can remain muted on A2DP output.
2009-12-04 10:39:33 -08:00
Eric Laurent
5cc6387254 Fix issue 2304701: Media streams can remain muted on A2DP output.
The problem comes from the fact that when a notification is played on both headsets + speaker,
the media strategy is muted. It is only unmuted when a new device is selected on hardwate output
(for instance headset only when music starts).
If an A2DP output is created while music is muted, AudioFlinger with use the last value received
for music volume to initialize the music stream volume on the newly created A2DP output, which in
this case is 0. The code in audio policy manager that applies stream volumes after the A2DP output
has been created is inefficient here, because as music stream is muted, the request to change the
volume is ignored.
As next time music starts it is now played over A2DP output and not on HW output,
no device modification is done on HW output and the music streams remains muted.
This is also applicatble to SYSTEM and TTS streams.

The fix consists in keeping a stream mute count on each output separately instead of a global stream mute count.
Thus when the music volume is re applied after A2DP output creation, the request is not ignored as the music stream is not
muted on A2DP output.
2009-12-04 07:01:06 -08:00
Dima Zavin
936ac4f834 am 49a5c99a: libgralloc-qsd8k: Do not use the physical address of surfaces/framebuffer
Merge commit '49a5c99a84626b5b1db4eda5239307e3366e28fa' into eclair-mr2

* commit '49a5c99a84626b5b1db4eda5239307e3366e28fa':
  libgralloc-qsd8k: Do not use the physical address of surfaces/framebuffer
2009-12-03 02:16:39 -08:00
Dima Zavin
be6f97aad3 libgralloc-qsd8k: Do not use the physical address of surfaces/framebuffer
The GPU now correctly maps everything throug hthe MMU so physical addresses
are no longer needed.

Change-Id: Id16a690f63d7141c8ee6694b246b1955f450b8ed
Signed-off-by: Dima Zavin <dima@android.com>
2009-12-02 21:15:33 -08:00
Jean-Michel Trivi
5d4176a70a am fea8b9e5: Merge change I14a54ae2 into eclair
Merge commit 'fea8b9e5641e1bdf8498b39cf108971c6fd130f8' into eclair-mr2

* commit 'fea8b9e5641e1bdf8498b39cf108971c6fd130f8':
  Patch from HTC: changes in libaudio
2009-12-01 17:15:26 -08:00
Eric Laurent
6fd07bc2e5 am 0a656145: Fix issue 2192673: Music Pausing Even when notifications are set to silent.
Merge commit '0a6561450eddb6b13f56392fb116d6ed2ef3694f' into eclair-mr2

* commit '0a6561450eddb6b13f56392fb116d6ed2ef3694f':
  Fix issue 2192673: Music Pausing Even when notifications are set to silent.
2009-12-01 17:04:30 -08:00
Android (Google) Code Review
3b81370104 Merge change I14a54ae2 into eclair
* changes:
  Patch from HTC: changes in libaudio - remove redundant ACDB updates for audio playback and recording. - remove redundant ACDB updates for audio route changes during playback or recording. Along with the matching audio driver change, this fixes b/2275992 and click before playback and AudioHardware is going to standby.
2009-11-30 16:24:27 -08:00
Eric Laurent
b65217ffe2 Fix issue 2192673: Music Pausing Even when notifications are set to silent.
If a stream cannot be muted (ENFORCED_AUDIBLE stream in some countries), make sure that getStreamVolumeIndex()
returns the actual stream volume.
2009-11-27 05:06:23 -08:00
Jean-Michel Trivi
e204be3647 Patch from HTC: changes in libaudio
- remove redundant ACDB updates for audio playback and recording.
- remove redundant ACDB updates for audio route changes during playback or recording.
Along with the matching audio driver change, this fixes b/2275992
and click before playback and AudioHardware is going to standby.
2009-11-24 16:40:49 -08:00
Mathias Agopian
46d61081aa am bd94d9af: part of fix [2186418] switch qsd8k devices to 24-bits framebuffer
Merge commit 'bd94d9af5cc7067b0e849af076183626b4c32e4e' into eclair-mr2

* commit 'bd94d9af5cc7067b0e849af076183626b4c32e4e':
  part of fix [2186418] switch qsd8k devices to 24-bits framebuffer
2009-11-24 14:43:43 -08:00
Mathias Agopian
1e1a87f0a5 part of fix [2186418] switch qsd8k devices to 24-bits framebuffer
Add support for 32 bits framebuffers
2009-11-23 23:19:54 -08:00
Eric Laurent
45c3c9be98 am 8a5a107a: Improvement for issue 2197683: English IME key-press latency is noticeably higher on passion than sholes.
Merge commit '8a5a107a014f94e6335b88f1942c82d23ceb6b04' into eclair-mr2

* commit '8a5a107a014f94e6335b88f1942c82d23ceb6b04':
  Improvement for issue 2197683: English IME key-press latency is noticeably higher on passion than sholes.
2009-11-23 08:16:12 -08:00
Eric Laurent
bbb5f58f76 Improvement for issue 2197683: English IME key-press latency is noticeably higher on passion than sholes.
Change audio buffer count to match number of buffers used by audio dsp.
Change buffer size from 4800 bytes to 3072 bytes to reduce output latency.
2009-11-21 00:45:02 -08:00
Eric Laurent
e339ff0e60 am a4fe0167: Issue 2276684: Kernel audio driver should fully support AUDIO_SET_CONFIG.
Merge commit 'a4fe0167c6cad83d88b3bc56efa1ffad85b345b5' into eclair-mr2

* commit 'a4fe0167c6cad83d88b3bc56efa1ffad85b345b5':
  Issue 2276684: Kernel audio driver should fully support AUDIO_SET_CONFIG.
2009-11-20 12:23:03 -08:00
Eric Laurent
d8c81ab5d3 Issue 2276684: Kernel audio driver should fully support AUDIO_SET_CONFIG.
Align HAL audio input buffer size with kernel driver for the time being.

For mr2 release the driver shall support AUDIO_SET_CONFIG.
2009-11-20 09:57:40 -08:00
Jean-Michel Trivi
075640c97d am 58cf88a5: Patch from HTC related to use of camcorder with wired headset plugged in: - libaudio: incorrect ACDB setting was used when starting to record with wired headset. - libaudio: remove unnecessary audio path switch when camcorder is started with wired he
Merge commit '58cf88a5a91d82ae2fb3e23365eaa4524a9cd089' into eclair-mr2

* commit '58cf88a5a91d82ae2fb3e23365eaa4524a9cd089':
  Patch from HTC related to use of camcorder with wired headset plugged in:
2009-11-19 11:41:10 -08:00
Jean-Michel Trivi
e00f5f2bb9 Patch from HTC related to use of camcorder with wired headset plugged in:
- libaudio: incorrect ACDB setting was used when starting to record
   with wired headset.
- libaudio: remove unnecessary audio path switch when camcorder is started
  with wired headset.
Submitted on behalf of HK Chen <hk_chen@htc.com>
2009-11-18 19:32:44 -08:00
Jean-Michel Trivi
78028e9769 am f8d3aebe: Remove workaround introduced in 956f7ba5ee0f087c91b5fefd2718dae30f8c1e29 to fix issue 2229040. This workaround is considered no longer useful by HTC since the changes in the A1026 configuration. Removing workaround on behalf of HK Chen (HTC).
Merge commit 'f8d3aebe4c19283eb34fb89e5932b3399d3bd753' into eclair-mr2

* commit 'f8d3aebe4c19283eb34fb89e5932b3399d3bd753':
  Remove workaround introduced in 956f7ba5ee0f087c91b5fefd2718dae30f8c1e29
2009-11-16 10:43:55 -08:00
Eric Laurent
8dbccbb73f am 979de023: Fix issue 2245963: incoming call rings in ringtone-volume level through a wired headset is while listening to music.
Merge commit '979de023050ebe82680c665259fc833b0a17d3f5' into eclair-mr2

* commit '979de023050ebe82680c665259fc833b0a17d3f5':
  Fix issue 2245963: incoming call rings in ringtone-volume level through a wired headset is while listening to music.
2009-11-16 10:43:52 -08:00
Jean-Michel Trivi
b5f536cb89 Remove workaround introduced in 956f7ba5ee0f087c91b5fefd2718dae30f8c1e29
to fix issue 2229040. This workaround is considered no longer useful
by HTC since the changes in the A1026 configuration.
Removing workaround on behalf of HK Chen (HTC).
2009-11-15 13:48:42 -08:00
Eric Laurent
dc2b08fd2a Fix issue 2245963: incoming call rings in ringtone-volume level through a wired headset is while listening to music.
When the ringtone is not looped (non factory ringtone), a new AudioTrack is started every time the ringtone is repeated. The second time the track is started, the condition that triggers volume limitation is not true any more as music has been stopped for more than SONIFICATION_HEADSET_MUSIC_DELAY seconds and ringtone volume is not limited.

The fix consists in checking the condition (music playing or stopped for less than SONIFICATION_HEADSET_MUSIC_DELAY) when entering ringtone mode and latch it until we exit ringtone mode.
2009-11-13 02:57:12 -08:00
Eric Laurent
b89ce69b11 am dd65e389: Fix issue 2242614: Wired headset not recognized: bogus "state" in ACTION_HEADSET_PLUG broadcast.
Merge commit 'dd65e38951ed174f9d3d34886795438440f7eea0' into eclair-mr2

* commit 'dd65e38951ed174f9d3d34886795438440f7eea0':
  Fix issue 2242614: Wired headset not recognized: bogus "state" in ACTION_HEADSET_PLUG broadcast.
2009-11-12 23:10:22 -08:00
Eric Laurent
b0987a90f9 Fix issue 2242614: Wired headset not recognized: bogus "state" in ACTION_HEADSET_PLUG broadcast.
Removed platform specific devices from the list of devices listed in AudioSystem.
2009-11-12 12:18:31 -08:00
Mathias Agopian
619e0358c9 am 072b5f0d: Merge change I42e2860a into eclair
Merge commit '072b5f0df424b2a0c50cdb7b605d3a749dcac7cf' into eclair-mr2

* commit '072b5f0df424b2a0c50cdb7b605d3a749dcac7cf':
  should help [2223746] qsd8k MDP locks up, logs show copyBits failed (Connection timed out) in Passion camera zoom level 1
2009-11-11 17:16:09 -08:00
Eric Laurent
419618500a am 956f7ba5: Workaround for issue 2229040: [Passion] Audio driver stuck when changing input routing while recording is active.
Merge commit '956f7ba5ee0f087c91b5fefd2718dae30f8c1e29' into eclair-mr2

* commit '956f7ba5ee0f087c91b5fefd2718dae30f8c1e29':
  Workaround for issue 2229040: 	[Passion] Audio driver stuck when changing input routing while recording is active.
2009-11-11 17:16:05 -08:00
Android (Google) Code Review
e961f58156 Merge change I42e2860a into eclair
* changes:
  should help [2223746] qsd8k MDP locks up, logs show copyBits failed (Connection timed out) in Passion camera zoom level 1
2009-11-11 16:45:41 -08:00
Mathias Agopian
ef686c51fd should help [2223746] qsd8k MDP locks up, logs show copyBits failed (Connection timed out) in Passion camera zoom level 1
make sure to return an error when mdp limits are exceeded
2009-11-11 16:28:21 -08:00
Eric Laurent
e210a8ccce Workaround for issue 2229040: [Passion] Audio driver stuck when changing input routing while recording is active.
This change avoids the audio driver lockup when changing audio input path configuration. It does not solve the root cause in audio driver or dsp.
When applied lockups observed in the folling use cases are eliminated:
- use back mic for camcorder recording (issue 2194140)
- switch input device when headset is plugged in or out during record (issue 2226658).

Also removes warnings.

	Submitted on behalf of H.K Chen <hk_chen@htc.com>
2009-11-11 10:49:32 -08:00
Iliyan Malchev
63100efee5 am d74adff0: Merge change I08516fe5 into eclair
Merge commit 'd74adff01615816857b075325ffa01eb8a58e854' into eclair-mr2

* commit 'd74adff01615816857b075325ffa01eb8a58e854':
  libaudio-qsd8k: update a1026.h header and improve firmware-loading code
2009-11-10 18:07:07 -08:00
Android (Google) Code Review
a6675bb910 Merge change I08516fe5 into eclair
* changes:
  libaudio-qsd8k: update a1026.h header and improve firmware-loading code
2009-11-10 15:20:02 -08:00
Eric Laurent
2dd94cf938 am f06a9889: Merge change I108ada59 into eclair
Merge commit 'f06a9889288034e9bd3e54fbae3bb48ad7bd3f89' into eclair-mr2

* commit 'f06a9889288034e9bd3e54fbae3bb48ad7bd3f89':
  Fix issue 2226658: Audio path not updated when a headset is plugged or unplugged while recording.
2009-11-09 22:42:16 -08:00
Android (Google) Code Review
05a1ef9930 Merge change I108ada59 into eclair
* changes:
  Fix issue 2226658: Audio path not updated when a headset is plugged or unplugged while recording.
2009-11-09 22:39:39 -08:00
Mathias Agopian
8e72981f86 am b7f7f038: enable mdp debugging on error, also check for invalid inputs
Merge commit 'b7f7f038529135a5c21234ae89e4b87a1c56854a' into eclair-mr2

* commit 'b7f7f038529135a5c21234ae89e4b87a1c56854a':
  enable mdp debugging on error, also check for invalid inputs
2009-11-09 20:19:58 -08:00
Mathias Agopian
9e8b8a119d enable mdp debugging on error, also check for invalid inputs 2009-11-09 20:15:50 -08:00
Jean-Michel Trivi
b1ab17ff35 am ba36d4fa: When configuring the A10026 for microphone input outside of a call, always use the A1026_xx_RECEIVER paths. This prevents the use of the A1026_xx_SPEAKER paths for voice reco modes for which the gain is too high.
Merge commit 'ba36d4fa33072ef14183365fffd289762c26905e' into eclair-mr2

* commit 'ba36d4fa33072ef14183365fffd289762c26905e':
  When configuring the A10026 for microphone input outside of a call,
2009-11-09 16:16:41 -08:00
Jean-Michel Trivi
cbff02d902 am 63af0f3c: Use new acoustic parameters when recording in voice recognition mode or for camcorder mode.
Merge commit '63af0f3cbd387e97bcaca82d1e22787c224d6430' into eclair-mr2

* commit '63af0f3cbd387e97bcaca82d1e22787c224d6430':
  Use new acoustic parameters when recording in voice recognition mode
2009-11-09 16:16:38 -08:00
Iliyan Malchev
84abafaf65 libaudio-qsd8k: update a1026.h header and improve firmware-loading code
-- new a1026.h kernel header that contains just the user-space API and is
   sanitized through bionic/libc/kernel/tools/clean_header.py
-- AudioHardware.cpp:
	-- replace vr_mode with vr_mode_enabled, and use 0 and 1 instead of
	   A1026_VR_MODE_DISABLED/ENABLED, which is not defined in the kernel
	   header;
	-- in doA1026_init(), replace a fread() of 1 byte with a read that as
	   much as possible from the firmware file in as few as possible passes
	   before we call into the kernel
	-- Replace the size of the on-stack f/w buffer with A1026_MAX_FW_SIZE,
	   which now comes from the kernel header
	-- Fix up some signed-unsigned comparison warnings on mBluetoothIdTx

Signed-off-by: Iliyan Malchev <malchev@google.com>
2009-11-09 16:06:57 -08:00
Eric Laurent
920fea9258 Fix issue 2226658: Audio path not updated when a headset is plugged or unplugged while recording.
Modified AudioPolicyManager::setDeviceConnectionState() so that the device on active audio input is updated when a device is connected or disconnected.
2009-11-09 11:57:59 -08:00
Jean-Michel Trivi
af1701fa98 When configuring the A10026 for microphone input outside of a call,
always use the A1026_xx_RECEIVER paths.
This prevents the use of the A1026_xx_SPEAKER paths for voice reco
modes for which the gain is too high.
2009-11-08 18:50:57 -08:00
Jean-Michel Trivi
2cf344031b Use new acoustic parameters when recording in voice recognition mode
or for camcorder mode.
2009-11-08 14:03:59 -08:00
Eric Laurent
9f93f2655b am 255bdedb: Fix issue 2243808: Audio input routing broken.
Merge commit '255bdedb2d7ebf4b14690776ff652df1de97fe95' into eclair-mr2

* commit '255bdedb2d7ebf4b14690776ff652df1de97fe95':
  Fix issue 2243808: Audio input routing broken.
2009-11-06 08:28:17 -08:00
Eric Laurent
420a78df14 Fix issue 2243808: Audio input routing broken.
The wrong key was used when removing the voice recognition mode from parameters list after handling it in AudioStreamInMSM72xx::setParameters() causing the set routing parameter to be removed and ignored.
2009-11-06 03:02:05 -08:00
Jean-Michel Trivi
2e71954441 am ee9fa1a5: Fix typo in AudioPolicyManager log for voice recognition mode. This fixes a build error when the log for AudioPolicyManager for QSD8K is enabled.
Merge commit 'ee9fa1a5e85cb4a4bffea3bca901fa828f7012fb' into eclair-mr2

* commit 'ee9fa1a5e85cb4a4bffea3bca901fa828f7012fb':
  Fix typo in AudioPolicyManager log for voice recognition mode.
2009-11-05 20:27:38 -08:00
Eric Olsen
6423acfc2b am dbef679f: Merge change Id27d9e35 into eclair
Merge commit 'dbef679fccd8d44881642564c54baafa41da6c55' into eclair-mr2

* commit 'dbef679fccd8d44881642564c54baafa41da6c55':
  Update lights to support the change in parameters passed by the framework
2009-11-05 19:10:05 -08:00
Jean-Michel Trivi
8ea88d0389 Fix typo in AudioPolicyManager log for voice recognition mode.
This fixes a build error when the log for AudioPolicyManager for
QSD8K is enabled.
2009-11-05 17:58:40 -08:00
Android (Google) Code Review
9059d84a60 Merge change Id27d9e35 into eclair
* changes:
  Update lights to support the change in parameters passed by the framework
2009-11-05 19:23:58 -05:00
Eric Olsen
1220be4e5e Update lights to support the change in parameters passed by the framework
Signed-off-by: Eric Olsen <eolsen@android.com>
2009-11-05 15:32:32 -08:00
Jean-Michel Trivi
7fc84adfaa am 4bcd5b16: Use new A1026 header to us 1026 presets that match the driver. Update record configuration to use those presets.
Merge commit '4bcd5b16c66bc5c2bffe232f15f5cb83aea18318' into eclair-mr2

* commit '4bcd5b16c66bc5c2bffe232f15f5cb83aea18318':
  Use new A1026 header to us 1026 presets that match the driver.
2009-11-05 13:54:02 -08:00
Jean-Michel Trivi
c932adcc2c Use new A1026 header to us 1026 presets that match the driver.
Update record configuration to use those presets.
2009-11-05 12:44:31 -08:00
Jean-Michel Trivi
86d444df00 am 739de5f3: Fix bug 2194140 Add support for the voice recognition mode. The voice recognition mode is enabled when using the AUDIO_SOURCE_VOICE_RECOGNITION audio recording source. The intended behavior is to use the same microphone input as the default input, but to
Merge commit '739de5f36523862a7caa15590bd6b680b6cd2854' into eclair-mr2

* commit '739de5f36523862a7caa15590bd6b680b6cd2854':
  Fix bug 2194140 Add support for the voice recognition mode.
2009-11-05 10:51:53 -08:00