Commit graph

289 commits

Author SHA1 Message Date
Aditya Bavanari
b68d102764 ASoC: sdm670: fix clock refcount for MI2S shutdown
For MI2S shutdown, if clock disable is failed,
do not bother to re-increment clock reference. Otherwise,
next time when startup is called, clock enable will not
be called again, so use case will not work.

CRs-Fixed: 2166356
Change-Id: Ic7a93a5f20eaabed93d0cd94d76d09f0f1c869fd
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-01-10 23:09:33 -08:00
Aditya Bavanari
140a80a114 asoc: sdm670: add/remove flag ignore_pmdown_time for RX/TX DAIs
- During PCM close, the AIF power down will be delayed if
ignore_pmdown_time flag is not set. Set this flag for ultrasound RX DAI
to avoid delay in PCM close which causes slimbus overflow.
- Flag ignore_pmdown_time is only required to be set for RX DAIs.
Add this flag for RX DAIs that don't have it and remove this
flag for TX DAIs that have it in sdm670 machine driver.

CRs-Fixed: 2166356
Change-Id: I794ee96fb96fe04091ce73f0b48f84ebf119256c
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-01-10 23:08:58 -08:00
Aditya Bavanari
d61b84dec1 asoc: sdm670: check sound card status before sending AFE config
WCD codec must be enumerated before AFE configuration for
some of the features can be sent to DSP. This is because
as part of setting up this configuration, DSP tries to
access some codec register. These register accesses will
fail if codec is not enumerated already.
Add a check for sound card online state to confirm that WCD
codec has already enumerated before sending AFE configs.

CRs-Fixed: 2166356
Change-Id: Ie5883f3543872d7a049a00a4c70445232360f2f9
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-01-10 22:52:32 -08:00
Aditya Bavanari
9ae2ddedee dsp: fix NULL pointer exception in core driver
NULL pointer dereference occurs while getting version size
when version info memory allocation fails.
Add NULL check to avoid this NULL pointer exception.

CRs-Fixed: 2142971
Change-Id: I47a905a9b4e767d54b406a279626369f18a861d9
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-01-09 21:32:20 -08:00
Vignesh Kulothungan
65b7a17e0f dsp: Update ADSP status to reflect failure
Update the adsp status to log failures during
AVCS_CMDRSP_GET_FWK_VERSION callback.
Set q6core_avcs_ver_info status to VER_QUERY_SUPPORTED
only when there is a valid ADSP response for framework
version.

Change-Id: Ie2c6db2842c0b89c9d1a3807bcb49d413a639988
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-01-09 21:28:03 -08:00
Linux Build Service Account
c5ac151c8e Merge "sdm670: Add mixer control and update affine qos value" 2018-01-09 08:41:46 -08:00
Linux Build Service Account
153e58c732 Merge "ASoC: wcd934x: WDSP debug enhancement" 2018-01-09 08:41:45 -08:00
Linux Build Service Account
1f5ff4b6f0 Merge "audio: Enable audio compile for 8953" 2018-01-09 03:08:39 -08:00
Linux Build Service Account
bf300152d6 Merge "ASoC: sdm660_cdc: Fix ear_pa_gain control" 2018-01-04 06:39:53 -08:00
Linux Build Service Account
2ba9dc5714 Merge "audio-lnx: Correct mutex usage during error handling" 2018-01-03 13:08:45 -08:00
Linux Build Service Account
e241554a95 Merge "ASoC: wcd: Avoid multiple insertion/removals for aux cable" 2018-01-03 13:08:44 -08:00
Revathi Uddaraju
30feb0d4a0 sdm670: Add mixer control and update affine qos value
Add mixer control for MultiMedia5_RX QOS Vote and
update affine qos value.

Change-Id: Id027ea4c708d0827a24ca655d0f1810331100cee
Signed-off-by: Revathi Uddaraju <revathiu@codeaurora.org>
2018-01-02 03:21:49 -08:00
Laxminath Kasam
942d1c6ed1 audio: Enable audio compile for 8953
Add support for audio compile for 8953.

Change-Id: I37ef20b44aecba8ffc9a7d1d346bf83a9115ad1b
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-12-29 16:44:10 +05:30
Laxminath Kasam
817af9a7f1 ASoC: sdm660_cdc: Fix ear_pa_gain control
In analog codec, EAR PA gain control get
function is updated with input value again
resulting in override. Remove the override
of control value again.

CRs-Fixed: 2161617
Change-Id: I7ddd252adf53666a6c9adc1bc92e840067fa932c
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-12-28 11:43:06 +05:30
Karthikeyan Mani
82597ffeec asoc: codecs: Fix device switch pop issue
With AANC enabled, and when the device switches
from speaker path to handset path there is a audible
pop. Add more delay to the aanc enable work function
to resolve the pop issue.

CRs-Fixed: 2137607
Change-Id: Icaf381179b0a81440b21ab4280cb6fc95e6fe6ba
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2017-12-26 21:31:29 -08:00
Walter Yang
83b0584703 ASoC: wcd934x: WDSP debug enhancement
Add interface to trigger WDSP dumps for debug use.
Important register dump and WDSP ramdump are both collected when
DEBUG_DUMP string is sent from userspace via WDSP misc node or
when WDSP boot timeout happens.

CRs-Fixed: 2117755
Change-Id: I8b91a8939201a54512a5e3557ce771b4ff2ff075
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2017-12-25 11:21:20 +08:00
Linux Build Service Account
05cae9910f Merge "asoc: add multiple sampling rates support for a2dp" 2017-12-21 21:53:36 -08:00
Ramprasad Katkam
f6d89a5094 audio-lnx: Correct mutex usage during error handling
Release the acquired mutex when there is failure
in enabling the soundwire clock.

Change-Id: I2e10ed7f0bd86524998a67d62e85754f7989eca2
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2017-12-21 20:31:43 -08:00
Vatsal Bucha
d6d62b8d3c ASoC: wcd: Avoid multiple insertion/removals for aux cable
High impedance aux cable when inserted causes jack to change to
lineout. This causes removal event to be called which results
in pause during music playback because jack value is not updated.
Do not change current plug while plug is marked as lineout.

CRs-Fixed: 2151012
Change-Id: I99797b58c48be00185a352094e32e8623faee491
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2017-12-21 20:30:38 -08:00
Linux Build Service Account
18d2731639 Merge "msm: Array bounds check for buffer index" 2017-12-20 00:31:40 -08:00
Linux Build Service Account
344329b79c Merge "ASoC: remove error prints and warning at bootup log" 2017-12-20 00:31:39 -08:00
Linux Build Service Account
6b6dae7320 Merge "asoc: vote for Glink Rx thread priority upgrade" 2017-12-20 00:31:38 -08:00
Linux Build Service Account
8640fa521a Merge "ipc: add api to vote for upgrading thread priority" 2017-12-20 00:31:37 -08:00
Aditya Bavanari
6348e87415 dsp: export adm_set_lsm_port_id for platform
For audio modules DLKM support, export the ADM API
to external modules.

CRs-Fixed: 2160337
Change-Id: Ieaf88b2c1d99f5fc42a7a3f1900887702323f18b
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-12-18 13:20:54 +05:30
Linux Build Service Account
b809b3b9d7 Merge "ASoC: dsp: add spin lock to protect ac" 2017-12-16 03:09:30 -08:00
Linux Build Service Account
a35c30a54f Merge "ASoC: sdm845: update MI2S supported sampling rates" 2017-12-16 03:09:29 -08:00
Linux Build Service Account
6f3eeba8d2 Merge "asoc: set freed pointers to NULL" 2017-12-16 03:09:29 -08:00
Linux Build Service Account
3db4f18b0e Merge "dsp: send spkr prot calibration after default acdb" 2017-12-16 03:09:28 -08:00
Linux Build Service Account
bb979ce209 Merge "autoconf: sdm845: remove unused configs" 2017-12-16 03:09:27 -08:00
Linux Build Service Account
9c81253780 Merge "dsp: add support for new ADM LSM cal types" 2017-12-16 03:09:26 -08:00
Linux Build Service Account
3a6d24603e Merge "asoc: sdm845: check sound card status before sending AFE config" 2017-12-16 03:09:25 -08:00
Linux Build Service Account
0055984340 Merge "asoc: codecs: modify gnd mic swap threshold for usb-c analog" 2017-12-16 03:09:24 -08:00
Linux Build Service Account
7bae55be7c Merge "dsp: add LDAC encoder support" 2017-12-16 03:09:23 -08:00
Linux Build Service Account
68b1ed3dc2 Merge "dsp: add scrambler support in DSP over split a2dp" 2017-12-16 03:09:22 -08:00
Linux Build Service Account
b4e447d3e0 Merge "dsp: codecs: add support to enable multiaac 5.1 channel playback" 2017-12-16 03:09:21 -08:00
Linux Build Service Account
24a9908ba2 Merge "asoc: add multiple sampling rates support for a2dp" 2017-12-16 03:09:20 -08:00
Linux Build Service Account
5492c58b13 Merge "ASoC: qdsp6v2: Add Audio EC Ref routing to LSM FEs" 2017-12-16 03:09:20 -08:00
Linux Build Service Account
463b274f59 Merge "dsp: assign channel mapping to three channel voice Tx devices" 2017-12-16 03:09:17 -08:00
Linux Build Service Account
26c91d4488 Merge "audio-lnx: Fix re-compile issue for dlkm" 2017-12-15 12:47:37 -08:00
Vignesh Kulothungan
3817b1847e msm: Array bounds check for buffer index
Check the ASM buffer index boundary before using it
to access the buffer to avoid out of array bounds error.

CRs-Fixed: 2145996
Change-Id: I5492941dfd9e7c3fa90af6caec14f9ff7e75d248
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2017-12-15 10:03:25 -08:00
Banajit Goswami
616e68cd4a asoc: vote for Glink Rx thread priority upgrade
For Low-latency audio playback usecase, vote for a priority
upgrade for Glink Rx thread, to avoid any performance issue.

Change-Id: I8332c80eedd7325700e695f341fc4b92f65fd77c
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2017-12-14 12:10:58 -08:00
Banajit Goswami
8832732009 ipc: add api to vote for upgrading thread priority
For some time critical tasks, the thread priority
might need to be upgraded to Real-Time Thread
priority level. Expose an interface from APR layer
so that clients can vote for a priority upgrade
whenever needed.

Change-Id: Ieb4afa914905750eccdf7672020a8751fdcf6462
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2017-12-14 12:10:42 -08:00
Linux Build Service Account
3f2ab3aa80 Merge "asoc: remove deprecated dummy functions in DAP modules" 2017-12-14 06:27:57 -08:00
Aditya Bavanari
9deef91554 asoc: set freed pointers to NULL
Set freed pointers to NULL to avoid double free
in msm_compr_playback_open and msm_compr_playback_free
functions of the compress driver.

CRs-Fixed: 2142216
Change-Id: Ifd011dd85dd9f610c7b69dd460f73d26e006cd66
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-12-13 04:59:45 -08:00
Laxminath Kasam
94815dae7e audio-lnx: Fix re-compile issue for dlkm
On incremental build, Module.symver used
will be older. Add commands to delete symver
files before recompile starts for audio kernel.

Change-Id: I1e90ad4543a7a06b5940f0a2612d18ed722ecd55
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-12-13 01:09:30 -08:00
Meng Wang
9730cdd47e ASoC: dsp: add spin lock to protect ac
There is a possible use after free for the ac variable
that causes kernel panic. Add spinlock to fix race
condition to avoid this issue.

Change-Id: I71638c269f572ff1eaad87682fa000cd1dad407d
Signed-off-by: Meng Wang <mwang@codeaurora.org>
2017-12-12 23:44:08 -08:00
Aditya Bavanari
a8349a42c7 dsp: assign channel mapping to three channel voice Tx devices
Assign default channel mapping to three channel voice Tx
devices when the topology specific info cal data is NULL.

Change-Id: Ic9d572edc1d7de07a2bd5e11d82f875368c35854
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-12-12 22:20:10 -08:00
Linux Build Service Account
5643be1804 Merge "ASoC: allow drivers to compile both static and dynamic" 2017-12-12 09:56:54 -08:00
Linux Build Service Account
6d3d8cf5e5 Merge "dsp: unlock the mutex before return to avoid potential deadlock" 2017-12-12 09:56:53 -08:00
Linux Build Service Account
f8ee2d26bf Merge "ipc: add validity check to APR port" 2017-12-12 09:56:52 -08:00