Do not open the input device when opening the input stream but
only when the input stream starts. This avoids blocking the thread
executing openInputStream() on the pcm input driver mutex while this mutex
is constantly acquired and released by the high priority audio
input thread.
It also allows an app to open an input stream while another thread is recording
if it does not use it immediately (useful for voice search and VoIP).
Also did some clean up in output and input stream standby logic.
Change-Id: I69c82f5833f7a034d828001f87e02745d7683b65
Remember, the system and main logs are
- Shared resources
- Primarily for recording problems
- To be used only for large grained events during normal operation
Bug: 3104855
Change-Id: I1abde2ae74119ce8ffa69c8b6e8ff278c2c8029e
this wouldn't make sense, since the h/w wouldn't be able
to use the buffer. in this case it it better to fail to
let the caller a change to try again with different usage bits.
Change-Id: Ibecaf069b6b58ee9c026affc95a45512660d5881
PRIV_FLAGS_NEEDS_FLUSH will trigger an ioctl call into the PMEM
driver in unlock(), so it makes not sense to set this flag for
non pmem buffers.
Change-Id: Ie1e077c10df86d3689b82fa6ce5d6c856fc95688
suppression off. This patch is accompanied by updated ACDB files
that define the matching acoustic configuration.
Change-Id: I8cf769c30993e36c4dc07b8df8d234e752d26ffb
This patch causes librpc to abort() when a read() fails on the ONCRPC
device. We're seeing this at bootup when the RIL initializes the WMS
(SMS) service, and we can't get back in sync with the protocol. By
calling abort(), rild will restart and the RIL will work correctly
on the second attempt.
We can remove this after we fix the underlying protocol error, but perhaps
we should keep it in since the original version of the code will
continue on a read() error and corrupt memory, thinking that it
received a new message when the input buffer contains only the
previous message received.
Change-Id: I0deded00f5c38a71aa56ce1859a8fe37d234e11b
- Change debug macros to use Android logcat functions.
- Compile with optimization (remove "-O0" from CFLAGS).
Change-Id: Ibf327513a36730e7667ede45966dba6fd3bc5a5d
The purpose of this change is to add support for allocating gralloc buffers
from either /dev/pmem or /dev/pmem_adsp depending on the usage flags. It does
this by factoring out and abstracting the interactions with the pmem device.
For /dev/pmem allocations, the kernel allocator is not used, so a single master
fd is opened, and all the allocations are sub-allocated from that by gralloc.
For /dev/pmem_adsp the kernel allocator is used, so it simply opens a new fd
for each allocation.
A very basic unit test that can be run on the host is included. It requires
gtest, so to run it on a host system gtest must (currently) be compiled with
BUILD_WITH_ASTL=true.
Change-Id: If2ae0151698fad8107e18e808a3fa012a846263f
The AudioPolicyManager for MSM8K overrides the stream volume computation
even if the volume index is set to minimum, which prevents the system
from ever muting a stream in the car dock.
The change consists in comparing the new volume index against the
minimum authorized index for that stream and if they are equal,
not override the platform's volume computation.
Change-Id: Id3990a3d771d2adb40df56d1b4ee2ddfb37c428d
Enable librpc for MSM7x30 and add missing definition of NULLPROC
and function prototype for xdr_u_int().
Change-Id: I97fe08abbf2d8157a6ce990ebd4dfcec41fce1d5
Merge commit '7f16e88be738d63e33e2e7c652c594379b136a01' into froyo-plus-aosp
* commit '7f16e88be738d63e33e2e7c652c594379b136a01':
Fix bug 2599652 increase attenuation on 3.5mm jack for music
Just retry for up to 5s when this happens. There could be a delay
for surfaceflinger to be notified when a process dies and delay
freeing those resources by that much.
Change-Id: If90d26626f7cbb7d37cdcf471f680c1b17deab50
Just retry for up to 5s when this happens. There could be a delay
for surfaceflinger to be notified when a process dies and delay
freeing those resources by that much.
Change-Id: I324262daab99dd6f16a2c8487c40ffd82f8847d7