Age | Commit message (Collapse) | Author |
|
|
|
force pcm_open to open device with the non-blocking flag
|
|
When a client opens a PCM device whose substreams are all occupied
without the non-blocking flag, the open function would be blocked in
the kernel until the previous opened ones are closed. This would
cause deadlock if they try to hold the same lock. Most of the ALSA
PCM drivers on embedded systems are implemented with the ALSA SOC
framework. Each PCM device has only one substream. This problem would
happen frequently. To force pcm_open to open PCM devices with
non-blocking flag is beneficial to resolve this problem. It returns
the control to clients to try again later.
The reason why we don't call pcm_open with PCM_NONBLOCK is that the
PCM_NONBLOCK also affects the read and write behaviors.
I also add a test case to test whether the pcm_open would be blocked.
|
|
Fix compatible issue and refine null parameters checking
|
|
There are some drivers assigning wrong ranges of mixer control's values.
Let ALSA drivers to check whether values are in ranges.
|
|
|
|
|
|
fix a variable name in tests
|
|
|
|
floating-point PCM support
|
|
This change also fixes overwriting the appl_ptr and avail_min when calling
the pcm_state function.
|
|
|
|
|
|
Sync AOSP: [LSC] Add LOCAL_LICENSE_KINDS to external/tinyalsa_new
|
|
https://android.googlesource.com/platform/external/tinyalsa_new/+/535e6ea3edcb6e119d465073facc3b2a338bdcb1
[LSC] Add LOCAL_LICENSE_KINDS to external/tinyalsa_new
Added SPDX-license-identifier-BSD SPDX-license-identifier-Unlicense to:
Android.bp
Bug: 68860345
Bug: 151177513
Bug: 151953481
Test: m all
Exempt-From-Owner-Approval: janitorial work
Change-Id: I21fe326f57f35b252901cf1423c4af149694fb51
|
|
fix bugs
|
|
|
|
|
|
The pcm_readi and pcm_writei also can deal with the mmap read/write.
Also mark the pcm_mmap_read/write functions as deprecated functions and
update the test case.
Add mmap playback support to tinyplay
|
|
|
|
add LICENSE file and rename modules in Android.bp
|
|
|
|
|
|
For the dynamic pcm device, it is valid to specify the backend after
opening it. However, it is invalid to call prepare on a dynamic pcm
device without connecting any backend device. We should not do
pcm_prepare in pcm_open.
See also: Issue #197
|
|
1. sync hw ptr before calculating the avail
2. return zero when reading or writing successfully
|
|
1. Align the document and the code.
2. Copy error messages to bad_pcm object for client to get more info
when opening failed.
|
|
Fix tinymix bugs and support setting negative values
|
|
|
|
|
|
|
|
|
|
|
|
tinymix_detail_control took controls' name as its parameter to
identify which control is that we want to print data of. However,
if there are some controls with same name, we will always print
the data of the first one.
|
|
fix build breakage in Android
|
|
Tests for libtinyalsa
|
|
1. Add a missing field and a function
2. Disable the deprecated attribute in Android temporarily to
allow us to use "pcm_read/write" which are deprecated upstream
3. Remove an unused define and an include in mixer.h
4. Add mixer_ctl_event and copy the snd_ctl_event to mixer_ctl_event
5. Add pcm_ioctl function and mark as deprecated function
|
|
|
|
|
|
1. add mixer event test
2. add pcm capturing test
3. add pcm loopback test
|
|
|
|
|
|
Backward compatible for pcm_write() pcm_read()
|
|
Fix tinyplay bugs
|
|
The period size and count may be changed after options parsing. We need
to set proper threshoulds.
|
|
|
|
Synchronize the changes on AOSP repo
|
|
Current return value of pcm_write()/pcm_read()
comes from pcm_writei()/pcm_readi() which is the
actual frames written/read. But the old pcm_write()
/pcm_read() just returns 0 on success and a nagative
value on error.
This change will keep the pcm_write()/pcm_read() as
the old behavior which has been already used by
many applications, and is also matching the comment
above each function.
Signed-off-by: Kui Wang <wangkuisuper@hotmail.com>
|
|
https://android.googlesource.com/platform/external/tinyalsa/+/f2d93a540297e75815eeb6644bf675cdae3be909
commit f2d93a540297e75815eeb6644bf675cdae3be909
author HW Lee <hwlee@google.com>
tinymix: fix setting enum str started with digits
For those value strings which are started with digits, they must be set
as enum instead of index value.
Test: with mixer control values started with digits like '48KHz'
Change-Id: I1c70f5613a48d020d3248b71c1e4384f83e33d25
Signed-off-by: HW Lee <hwlee@google.com>
|
|
reference: https://android.googlesource.com/platform/external/tinyalsa/+/8b7274b2ec686c87673bf39328381acbdea1a333
commit 8b7274b2ec686c87673bf39328381acbdea1a333
author Haynes Mathew George <hgeorge@codeaurora.org>
tinyplay: play PCM up to size specified in the header
tinyplay plays to the end of file without checking whether playback
goes beyond end of data section which its size is specified in the
RIFF wave header. This could lead to playing out unwanted data which
is placed at the end of file.
authored-by: Patrick Lai <plai@codeaurora.org>
Change-Id: I17bd3f6ebca4813f8987585472208c1f52696cae
|
|
https://android.googlesource.com/platform/external/tinyalsa/+/62644f7a3c4cfa18d7935f731cf59b675669d17a
commit 62644f7a3c4cfa18d7935f731cf59b675669d17a
author Phil Burk <philburk@google.com>
tinyalsa: check for NULL mmap_status
pcm_mmap_get_hw_ptr() was not checking pcm->mmap_status and
crashed when it was NULL.
Bug: 64346189
Test: input_monitor.cpp, see bug report for repro steps
Change-Id: I8436686a231eb01a82dd28ca2cce561d5460bcd6
|