On some devices, certain input and output mixer controls share the same
endpoint, which means that if an input stream is disabled (and the mixer
is updated), that shared endpoint may be disabled as well.
This would result in no audio, because no one is aware that the output
stream in fact does still need the shared endpoint to be enabled.
We prevent this by enabling the output mixers after disabling input mixers,
if any.
Change-Id: I4d80fcd0648a11099f27177da3cd29095b6a8c34
(cherry picked from commit 507e8ce5bffb36fae8b1cd4e5498fa19a6273ee6)
This should now support both old and new headsets,
as we rely on codec negotiation in the bluetooth
stack for narrow/wide band switching.
Change-Id: Ie9d308dfc55726fd1591a7d158f610bd267340e6
(cherry picked from commit d462f7b86e957f858959ef5d80fd1744689ee6ea)
Previously, we would only end the voice call once the next output
stream happened (and parameters would be set).
Change-Id: Id0d2711605e57ad69d9b26b36afb562444349358
(cherry picked from commit 5169e86c10b7429b01d6ab0500a0509141dcbfe1)
The whole code block was no-op, since we would override
(in|out)_snd_device at a later point anyways.
Change-Id: Ieb2b0918c9c72f18d195d6b34b5c9768fce130b3
(cherry picked from commit f33a728b205f7656ca6211a07e3dd69c623b75ca)
Some devices (often T-Mobile variants) have extra hardware for
incall audio processing.
Audio must be routed to the ES IC properly so it can be passed to
ALSA, otherwise the RX/TX streams are lost.
Change-Id: Ib29c747d5728a09726e14bab00f26ad273400aba
When we change the device during a phone call we need to completely
restart it. This is required by the modem.
Change-Id: I902c78bf50dfb5dc3da51fca0fb862f872df86ca
* if (usecase == NULL) should actually be if (vc_usecase == NULL)
* Avoid unnecessary if-block indentation by updating the control
flow
Change-Id: If00ac405a1eac429862b953580e8614227015134
This was intentionally left enabled and does not spam anyways,
but allows users to extract helpful information without
recompiling.
This reverts commit e06577dc81.
Change-Id: I604ee674a1db466b3d3e364cb95f5688edd4947c
* abs() accepts ints as parameters,
but this breaks compile since
the times are longs, not ints
* Use labs() instead, which accepts
longs as parameters, to fix compile
Change-Id: I8f980a78380cdae18abd5b9602e281beae3ee4d3
Signed-off-by: Paul Keith <javelinanddart@aidenswann.com>
We have a value for SND_DEVICE_NONE so we should use that. There is no
field for SND_DEVICE_MIN so we need to check it is bigger.
Change-Id: I041930c8c4b552d45804a178aeb1aa981ae7c13f
When a voice call is stopped we switch back to the default primary
output (speaker). Then this function gets executed and as ther was
no active PCM because voice_session is handling that it segfaults
because the PCM is NULL.
Change-Id: I927504b7962b096c0d4c3642b48aee55c85ec013
The unused functions have just been commented out.
This also sets the CFLAGS to -Wall and -Werror.
Change-Id: Iea097426313a68a01a074627115853fccc680579
We want that to avoid an error message in the log, so revert the
revomal.
This reverts commit cdad20da45.
Change-Id: Ic90cd6b02e5b3e8aae73d824153c3084643a8acc
This just allocates the structre and creates the RIL connection. This is
per audio_device structure to make sure we to not run into issues with
audioserver threading.
Change-Id: I42e1b7ae57579f39c5f76566ef5b67d4e2c13e3f