Commit Graph

151 Commits

Author SHA1 Message Date
qctecmdr
c8c7d94214 Merge "ASoC: bolero: tx-macro: Update VA macro clock sequence" 2019-06-22 11:15:10 -07:00
qctecmdr
644ead80f7 Merge "ASoC: bolero: Remove unused audio map routings in bolero" 2019-06-21 03:33:04 -07:00
Sudheer Papothi
296867b416 ASoC: bolero: tx-macro: Update VA macro clock sequence
Update VA macro clock sequence for headset detection during
voice activation usecase to avoid soundwire bus clash interrupts.

Change-Id: Ic004d43aef9c8a9003b3028c122e6fb6a06fa58d
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2019-06-21 08:25:29 +05:30
qctecmdr
1dffa77438 Merge "asoc: bolero: reset all clks after SSR/PDR" 2019-06-17 21:04:15 -07:00
qctecmdr
45b4733d63 Merge "asoc: codecs: defer probe if soundwire pin is not ready" 2019-06-17 20:25:32 -07:00
Karthikeyan Mani
326536d1d6 asoc: codecs: defer probe if soundwire pin is not ready
Defer codec macro probes if soundwire pins are not
ready to be accessed yet during boot up.

Change-Id: I20173e49043a076d73cdbb811863afbff87d4a3b
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2019-06-11 17:48:35 -07:00
Karthikeyan Mani
3bd80a59b2 asoc: codecs: add support to disable soundwire devices
Add changes to support disabling of soundwire devices
so that soundwire pins can be freed for other purposes
if needed.

Change-Id: Iae14d43c2c3d5380347be4c3b443c209b2612a97
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2019-06-10 17:14:36 -07:00
Sudheer Papothi
324b495656 ASoC: bolero: Remove unused audio map routings in bolero
Remove unused audio map routing from bolero codec to avoid
index mismatch for mic path enablement.

Change-Id: I09365f54ac5906df9568c78db902000a2dd790eb
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2019-06-11 04:18:39 +05:30
Meng Wang
8ef0cc2ed4 asoc: bolero: reset all clks after SSR/PDR
After SSR/PDR, the lpass clocks will be in off state. Force restart
clocks after SSR/PDR, if enabled before SSR/PDR, to reenable the clocks.

Change-Id: I3d850d92bdc6324aa7a64a83a9066f388a85c7f7
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2019-06-06 08:45:19 +08:00
qctecmdr
da4b9b30ca Merge "asoc: bolero: do not disable tx macro clk during SSR/PDR" 2019-05-31 08:55:12 -07:00
qctecmdr
c2cab39530 Merge "ASoC: bolero: Fix issue in clock sequence during VA concurrency" 2019-05-31 08:51:17 -07:00
Meng Wang
69b55c855b asoc: bolero: do not disable tx macro clk during SSR/PDR
Do not disable tx macro clk when it's not enabled during
SSR/PDR to avoid clk count mismatch.

Change-Id: I69a59cff9cb57ef3dea366c73629c3eddcb19abe
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2019-05-29 11:04:45 +08:00
qctecmdr
34b7d3b2fd Merge "ASoC: hide bind/unbind in sysfs" 2019-05-21 20:33:23 -07:00
Xiaojun Sang
53cd13a1ab ASoC: hide bind/unbind in sysfs
Exposure of driver bind/unbind to userspace via sysfs may
lead to unexpected behavior.
Hide bind and unbind by driver attribute.

Change-Id: I20d6ee653bcc16af15d6368664aaf240c6645cd0
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
2019-05-17 15:00:33 +08:00
Ramprasad Katkam
14efed6eb7 asoc: Ratelimit error logs
Ratelimit error logs to avoid excessive logging during
ssr/pdr.

Change-Id: Icdc9823cef5b070ed70cdd002bb3cd00d482a869
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2019-05-14 17:42:22 +08:00
Sudheer Papothi
cf3b406a5f ASoC: bolero: Fix issue in clock sequence during VA concurrency
Fix issue in clock sequence when switching between VA clock to
TX clock and viceversa during VA usecase.

Change-Id: I4a7d423916b70b4b3c54d0d9a28b8ea874584525
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2019-05-09 22:45:25 -07:00
Sudheer Papothi
7601cc6db6 ASoC: Bolero: Vote for LPASS HW core during register access
Vote for LPASS HW core in soundwire clock request before
soundwire register access to avoid LPASS going to sleep.

Change-Id: I1e54ece19130cf6bd63fbf75a8a0716856c3b73e
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2019-04-10 12:45:29 -07:00
Sudheer Papothi
a7397947d3 ASoC: bolero: Enable RCO for VA usecase
Add support to enable RCO during VA usecase.

Change-Id: Ic6b640f62a8a88b5d5b616fc05798917913356ed
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2019-04-11 01:14:19 +05:30
Linux Build Service Account
088ff5589b Merge "ASoC: boloero: Add DAPM widgets for soundwire clock" into audio-drivers.lnx.4.0 2019-04-09 01:35:26 -07:00
Vidyakumar Athota
5d45f4c865 asoc: codecs: bolero: add clk resource manager driver
Add Bolero clock resource manager driver to handle/manage
bolero clocks for all the concurrency usecases like record
+ voice activation.

Change-Id: I970a05d96fc9060b44bfe670d465f0b9d72cc53b
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
2019-04-05 08:00:03 -07:00
Sudheer Papothi
e456c2ca41 ASoC: boloero: Add DAPM widgets for soundwire clock
Add DAPM widgets for soundwire clock on Tx path and
VA path to enable the desired clock source based on
the usecase.

Change-Id: I48b04e63317cefd8bf12d58b002efb37087f8dc2
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2019-04-01 11:34:10 -07:00
Mangesh Kunchamwar
3d4eec47ef asoc: codecs: bolero: Reduce hpf corner freq delay to 50ms
Reduce hpf corner freq delay from 300ms to 50ms
to avoid initial mute in recorded audio.

Change-Id: Ibd6e7d60f836e866d73899d3f691c0e8070a3527
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2019-03-25 10:44:21 +05:30
Karthikeyan Mani
01f1ba49be asoc: codecs: bolero: enable gpio and clk in right sequence
Enable soundwire gpio before enabling soundwire clock
so that bus clash does not happen when interrupts are
received.

Change-Id: I40983b8837373f1ea7ac8fa6add7c56225ff0592
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2019-03-01 19:17:12 -08:00
Karthikeyan Mani
2797084510 asoc: codecs: bolero: leave frame sync to default value
Frame sync of bolero macros need to be at 4KHz default
value.

Change-Id: Ia5399a3c4bee7e0f74115e5ffcb1ed51cbd07639
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2019-02-26 13:30:23 -08:00
Karthikeyan Mani
1475b5915b asoc: codecs: bolero: update mic paths
Add all combination of routes between adc and
available mic paths.

Change-Id: If5781509bdc667d94ca1ad991388a8d57af75b94
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2019-02-15 14:18:48 -08:00
Ramprasad Katkam
452772abf9 asoc: bolero: Do not disable mclk in widget power down upon enable failure
If mclk enable is failed during mclk widget power up event, it would
still send a power down event for the widget during disable, which could
disable the mclk voted by other client like soundwire. Do not disable
mclk during power down if enable is failed during power up.

Change-Id: If782b34f9ef414501590ed8cf681bbe58f1dda76
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2019-01-22 12:51:39 +08:00
Linux Build Service Account
a0b8337922 Merge "asoc: bolero: Call swr device down before setting ssr down" 2019-01-08 05:31:57 -08:00
Linux Build Service Account
e7d0905375 Merge "soc: swr-mstr: Reset swr only during init or ssr" 2019-01-08 05:31:56 -08:00
Ramprasad Katkam
5ee54aee41 asoc: bolero: Call swr device down before setting ssr down
Invoke swr device down callback to set soundwire master
to reset state before setting ssr down flag. This is to
ensure master is reset to proper state after ssr/pdr.

Change-Id: Ifb5548f603ac03b772006314f4723c0ac0176928
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2019-01-02 01:37:06 -08:00
Ramprasad Katkam
a4c747b6d5 soc: swr-mstr: Reset swr only during init or ssr
Reset swr only during init or ssr-pdr scenarios.
Do not reset swr during clock stop, which would
result in bad state of master and cause error
interrupts.

Change-Id: I88e071921409a5b5797aeedb8e7cb57cb5d5bb9a
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2019-01-02 17:31:14 +08:00
Vatsal Bucha
39ead2c1e8 ASoC: bolero: Remove unwanted logs at bootup
Correct name of widgets for tx macro from
TX SWR_MIC to TX SWR_DMIC. Also assign codec pointer
to rx_priv before calling rx_macro_init_bcl_pmic_reg.

Change-Id: I268d79413c53bcd2d8e7a391859b71b7a7e3f64e
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2019-01-02 17:16:23 +08:00
Linux Build Service Account
50840ecb1b Merge "asoc: update relative header files" 2018-12-18 11:22:16 -08:00
Meng Wang
11a25cf657 asoc: update relative header files
Move all relative header files to include folder.

Change-Id: Ic61a61a88823b4749dbe8c1f680d08201a3b4a48
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2018-12-18 10:50:27 +08:00
Sudheer Papothi
a3e969d6f0 ASoC: bolero: Add support to retrieve soundwire port configuration
Add support to get the platform specific soundwire port configuration
for soundwire master ports.

Change-Id: Ie1d32a77d534f6c3f397936b85c025b14d01f321
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2018-12-17 14:30:55 -08:00
Meng Wang
43bbb87652 asoc: Update file header to GPL-2.0-only
Update file header to GPL-2.0-only.

Change-Id: Ic1542a3209a5fe73c937a5b36491ede4a451936d
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2018-12-10 14:49:34 +08:00
Meng Wang
15c825d077 ASoC: codec: Update codec driver to component driver
Some alsa API are removed in kernel-4.19 which would cause
codec driver compile failure. Update codec driver to fix it.

Change-Id: Ie358ec1863082166958059c179300b453d2a03ad
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2018-12-08 03:15:55 -08:00
Meng Wang
61af6849e9 ASoC: switch audio drivers to SPDX identifier
Switch audio drivers to SPDX identifier on msm-4.19.

Change-Id: Ic3f0230a516db251b8d81e8a7e73dbc04d66fe1b
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2018-12-07 15:47:32 +08:00
Aditya Bavanari
c4e96121c5 asoc: bolero: Add support to register wake irq
Add reg_wake_irq macro callback and issue an event
from Tx macro to Tx sound wire master instance
in order to register for wake irq and to handle
the ipc wake up interrupt.

Change-Id: Iefddc1f85173ce267c0b00c9d06be3a4a2fe29fe
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-11-14 17:06:38 +05:30
Xiaojun Sang
d155fdcb2f asoc: bolero: avoid TX distortion by runtime HPF param change
Runtime HPF param change leads to TX distortion at the beginning.
Unmute HPF after param change.

Change-Id: I7683ca047123dd004fb2dd019365305edfc72ea5
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
2018-10-11 15:24:10 +08:00
Laxminath Kasam
638b56027e asoc: codecs: add ignore suspend for bolero and wcd937x widgets
Update ignore suspend for AIF in/out and dapm input/output
widgets for bolero and wcd937x codecs to avoid suspend
of codec during active usecase running even after APSS
goes to suspend.

CRs-Fixed: 2321226
Change-Id: I277129e8e657485c56414a385150c4da55382770
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-10-01 11:31:22 +05:30
Laxminath Kasam
fb0d683b37 asoc: bolero: add SSR changes support on bolero codec
Add changes for audio SSR and PDR on bolero codec
and respective macro drivers.

Change-Id: I146de15022cebb788ccb52ed6b8ab85b7cba2ba0
Signed-off-by: Vaishnavi Kommaraju <vkommara@codeaurora.org>
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-09-25 11:57:49 +05:30
Laxminath Kasam
497a651ef8 asoc: codecs: Add parent child relation for bolero and tanggu
In bolero and tanggu combination, make bolero parent of tanggu.
Bolero and tanggu can communicate mutually using notifier and
plat_data callback APIs.

Change-Id: Iecd119df7f0ad1ba225c0427f3f42f217146b092
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-09-25 11:31:37 +05:30
Tanya Dixit
8530fb9b5d asoc: codecs: Add proper null checks and initialize variables
Add proper null checks and initialize variables
in rx-macro, tx-macro, va-macro and wcd937x drivers.

Change-Id: I90899c84d3391305b9a24d4b043adc08b7c0332a
Signed-off-by: Tanya Dixit <tdixit@codeaurora.org>
2018-09-17 06:25:33 -07:00
Laxminath Kasam
9eb80226a0 asoc: bolero: fix pop issue at start of record
Observe pop at start of recording. Change the
order of HPF setting in decimator enable path
and update freq_change bit for HPF corner frequency change.

Change-Id: I6257671224a792a2afd71209fdc4e0102a83ced8
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-09-03 16:41:43 +05:30
Ramprasad Katkam
9c2394a6e4 asoc: Talos-tanggu bringup fixes
Bringup fixes to enumerate tanggu codec on talos.

Change-Id: Ic9c43ec0b870f6fec3c6d21fd4d77606c7ed94b1
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-08-29 11:04:43 +05:30
Ramprasad Katkam
f83acfb0f2 asoc: Binrgup fixes for talos
Add fixes related to audio bringup

Change-Id: I46fa0bb9c6f914fe9034f4fb78ef2248de7ebd50
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-08-11 23:28:57 +05:30
Linux Build Service Account
fc9ba4e933 Merge "asoc: bolero: Update route map to enable MCLK for adie loopback" 2018-08-11 02:52:55 -07:00
Laxminath Kasam
59c7a1de15 asoc: bolero: Update AIF dai-id to start with value 1
ASoC core assigns dai id value to num_dais if
AIF dai-id passed is 0. Since we have different macros
passing AIF dai-id as 0, they are replaced in ASoC core.
To handle this, update AIF dai-id in respective macros
to start with value 1.

Change-Id: I222c088289292aa226c90710e56a8c94af5615cd
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-08-09 16:13:44 +05:30
Laxminath Kasam
fc281adbdd asoc: bolero: Update route map to enable MCLK for adie loopback
For ADIE loopback, MCLK needs to be enabled.
Associate the macro MCLK widgets to respective
rx and tx paths in route map.

Change-Id: I5632c3016146c5c5d822ae6fe438010904cf434b
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-08-07 22:20:10 +05:30
Laxminath Kasam
b7f823c4d1 asoc: bolero: Fix compile errors on rx/tx macro
Fix compilation issue on bolero rx/tx macros.

Change-Id: I1bb9da552d4719ed3417a56fe77f147cab92dc1d
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-08-02 13:23:11 +05:30