提交图

3858 次代码提交

作者 SHA1 备注 提交日期
Meng Wang
322f08f457 asoc: lpass-cdc: reset RX_TX_CORE_CLK and WSA_TX_CORE_CLK during SSR/PDR
Sometimes after SSR/DPR is triggered, RX_TX_CORE_CLK, WSA_TX_CORE_CLK
and WSA2_TX_CORE_CLK are not reset which causes WSA or WCD not
detected. Make this change to add reset during SSR.

Change-Id: I343f2f92244de3eee844e220a6201b389dc647b4
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-09-28 14:23:52 +08:00
qctecmdr
316b9557b3 Merge "asoc: waipio: Parse and Set reg info for UPD." 2021-09-19 10:04:30 -07:00
qctecmdr
590d8a9823 Merge "wsa: soundwire: Add support for 4p8MHz DAC rate" 2021-09-19 10:04:30 -07:00
Zhou Song
49f8dbd278 asoc: waipio: Parse and Set reg info for UPD.
Parsing the reg info from devicetree and pack
the reg values to enabl/disable EAR PA and
send to dsp.

Change-Id: I463750c00d592adcea77551259994a2dfb5e4cf9
Signed-off-by: Zhou Song <zhous@codeaurora.org>
2021-09-15 22:25:42 -07:00
Laxminath Kasam
001ba433b2 wsa: soundwire: Add support for 4p8MHz DAC rate
Add support to use 4p8MHz DAC rate for receiver over WSA.

Change-Id: Ia0811670326be8131687fbdff70464da063902b2
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2021-09-15 22:22:09 -07:00
sarath varma ganapahiraju
6b039c6b85 asoc: dsp: prm: Add support to send reg info to PRM for UPD
Send codec register's and its value to enable/disable EAR PA
when codec duty cycling is enabled.

Change-Id: I6ce7183bda3dd2d02829d280d27e5a5573e3efcc
signed-off-by: sarath varma ganapahiraju <ganavarm@codeaurora.org>
2021-09-15 22:21:07 -07:00
Laxminath Kasam
ae258cb2f8 asoc: wsa883x: Update low_noise gain for receiver
Add changes to use wsa883x for receiver with
low_noise mode settings.

Change-Id: Icfa43ebbdb1e366f365053535f541bee03751ca3
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2021-09-15 22:19:46 -07:00
Meng Wang
3fa91843c7 asoc: lpass-cdc: add mixer control to indicate if swr_dmic is used
When SWR MIC is used, lpass-cdc doesn't know if it's amic
or dmic on WCD. Add new mixer control to indicate if
swr_dmic is used or not.

Change-Id: I2910053d1da9110edfe9b021df744f9d1662d158
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-09-15 22:19:40 -07:00
sarath varma ganapathiraju
2db2fd8857 asoc: codec: wcd938x: Get swr device number
add wcd938x_codec_get_dev_num to return
swr device number

Change-Id: I45f4324645643b4edc6182cee508ce1e647c3612
signed-off-by: sarath varma ganapahiraju <ganavarm@codeaurora.org>
2021-09-15 22:19:33 -07:00
qctecmdr
4a24723e3d Merge "msm_hdmi_codec_rx: lower min sample rate for DP_DAI1" 2021-09-14 04:33:06 -07:00
Prasad Kumpatla
adf32e6429 msm: common: retrieve clk attribute for tdm and mi2s from dtsi
retrieve clk attribute for tdm and mi2s from dtsi.

Change-Id: Ie00ac5cf7c2e1d7ca56e27d291dfd6af3feb8d8f
Signed-off-by: Prasad Kumpatla <pkumpatl@codeaurora.org>
2021-09-06 23:44:21 -07:00
Aditya Bavanari
c46348987c asoc: common: Modify the logic for interface index check
Check if the interface index is either of TDM/MI2S/AUXPCM
to implement the common ops as the current index is valid
for other interfaces like CDC DMA as well.

Change-Id: I345a2b47185d6d56198061a17921fdfc2f5e3290
2021-09-06 22:09:36 +05:30
Srinivas Marka
c315833fa3 asoc: set card state to online after snd card registration
AGM might get initialized before sound card is populated
with all pcm nodes. This will lead to AGM parsing fewer
nodes and forms incomplete list of backends.

To avoid this, kernel module sets card status to ONLINE,
and AGM waits till the card status is ONLINE before parsing
for the pcm nodes.

Change-Id: I4b7f7085645706ba4351efe23ba048d3a177312c
Signed-off-by: Srinivas Marka <smarka@codeaurora.org>
2021-09-06 09:35:23 -07:00
Harold Tan
4ace4a9197 msm_hdmi_codec_rx: lower min sample rate for DP_DAI1
Lower rate_min to 32kHz to support more clips of
different sample rate for DP use case.

Change-Id: Idab284ac0cfe9248ae417ba9c25e5154f0658d69
2021-09-05 23:23:48 -07:00
Meng Wang
642659b2a3 soc: swr-mstr-ctrl: ignore interrupt when master is in clk stop mode
When swr master is in clk stop mode, the value of interrupt_status
is not actual interrupt value. Add check for pm_runtime status to
avoid endless interrupt handler.

Change-Id: I4cd7fe5f01ffdca2a441521088ea39f8804d6b51
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-09-03 22:10:54 -07:00
qctecmdr
b61e1747a5 Merge "dsp: audio_prm: check if gpr is ready" 2021-09-03 01:46:33 -07:00
qctecmdr
7923c5e04e Merge "asoc: lpass-cdc: update logic to disable VA_MCLK" 2021-09-03 01:46:33 -07:00
qctecmdr
509134e708 Merge "ASoC: mbhc-adc: Enable BCS if plug type already reported" 2021-09-03 01:46:33 -07:00
Junkai Cai
30fbd08bca soc: reduce the auto suspend timeout when swr event finished
the APSS would suspend within ~120ms after audio off, if system suspend
swrm_suspend() is called before swrm_runtime_suspend. The clock stop
sequence require writing IPC and expect interrupt, which would stop
the APSS to be suspended. Reduce the auto suspend time specifically when
swr event is done can call the swrm_runtime_suspend

Change-Id: Iee0c9143d65e5a8e68a8e20ab73bea9def1920bd
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-09-01 21:49:25 -07:00
qctecmdr
165cf0933e Merge "dsp: audio_notify: add soft dependency on qcom_q6v5_pas" 2021-09-01 20:29:23 -07:00
Vatsal Bucha
6527fdb4e6 ASoC: mbhc-adc: Enable BCS if plug type already reported
BCS is not enabled sometimes after inserting headset if
plug is already reported and we dont report it again.
Enable BCS if plug type already reported.

Change-Id: I8c9f15ced66a21bda169d3479da96168ebec26a7
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2021-08-31 05:40:54 -07:00
qctecmdr
ced79f58d3 Merge "soc: swr-mstr: Avoid underflow due to CPS spkr prot enabled" 2021-08-28 21:21:19 -07:00
qctecmdr
0753a3433e Merge "ASoC: codecs: add null check before use" 2021-08-28 21:21:19 -07:00
qctecmdr
7c5ab24608 Merge "asoc: common: add lpass hw core request" 2021-08-28 21:21:19 -07:00
qctecmdr
8bd420897b Merge "asoc: lpass-cdc: return error when requesting incorrect state" 2021-08-28 21:21:19 -07:00
qctecmdr
7b4b4ffcd7 Merge "Kalama-BU: add QMAA compliance to audio dlkms" 2021-08-28 21:21:19 -07:00
qctecmdr
0afaac609c Merge "asoc: Add virtual node for WSA RX0" 2021-08-28 21:21:19 -07:00
Meng Wang
ffefd0f046 dsp: audio_prm: check if gpr is ready
During SSR, GPR will receive adsp down notification
first and set to SUBSYS_DOWN mode. Sometimes before
audio_prm received adsp down notification, prm_gpr_send_pkt
is called but it will get stucked in spf_core_is_apm_ready
for 30s and device crash happens. In audio_prm, before
checking if spf is ready, check if both prm and gpr are ready
to avoid getting stucked.

Change-Id: I851c140a07162e4fcf20353002ef0130441ca1db
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-08-27 16:57:09 +08:00
Junkai Cai
c1fe3f72c2 soc: swr-mstr: Avoid underflow due to CPS spkr prot enabled
Underflow is observed sometimes with CPS spkr prot enabled.
Reduce no of retry count for wsa to 1 so as to optimize delay
between reads on wsa and prevent underflow.

Propagated from the 5.0 branch.

Change-Id: I9b20a242ad4e8375718844c9dfeb0e4996588a19
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-25 23:14:49 -07:00
Junkai Cai
319e140119 soc: swr-mstr: Update soundwire state to SSR during UP
During SSR up event handler, if soundwire state is
already up or auto suspend jiffies is not completed,
ensure put in suspend/SSR state.

Propagated from the 5.0 branch.

Change-Id: I2a8a995399e7844cbc1d6a5676f0d57d97577862
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-25 23:12:47 -07:00
Junkai Cai
16acb739c4 soc: swr-mstr: Enable device wakeup only for tx macro
At bootup device wakeup enable is called for all masters
causing issue for wsa. This is because wsa
supports interrupts. Thus enable device wakeup
only for tx master.

Propagated this change from previous target.

Change-Id: Iade70defc599952b77b664b752cc55570b4aed27
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-25 23:12:05 -07:00
Meng Wang
f62a7f3e92 asoc: lpass-cdc: update logic to disable VA_MCLK
When adsp SSR happens, VA_MCLK enabled by VA_SWR_PWR widget will
not be disabled as ADSP is down and it cannot enable TX_MCLk before
disabling VA_MCLK. After disabling SVA, VA_MCLk is left open.
Add dev_up flag to indicate SSR and close VA_MCLK during SSR.

Change-Id: Ic544ce32c46054c7362d3eb07a4a47ec115d2651
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-08-25 13:44:52 +08:00
Prasad Kumpatla
7277bb1171 asoc: common: add lpass hw core request
add lpass hw core request before request for the
set clk cfg in the case of primary and tertiary
interface along with fractional sample rate related
clock request.

Change-Id: I273e6963ee39e350c44e5bcf35427327b7189cd1
Signed-off-by: Prasad Kumpatla <pkumpatl@codeaurora.org>
2021-08-25 10:45:43 +05:30
Meng Wang
df743705b4 dsp: audio_notify: add soft dependency on qcom_q6v5_pas
if remoteproc for qcom_q6v5_pas is not ready and audio_notify_probe
is called, it will call EPROBE_DEFER. Sometimes audio_notify_probe
is called again very late even after gpr/audio_prm/pinctrl_lpi probe
which causes it doesn't receive the adsp_up notidication and soundcard
is not registered. Add soft dependency for audio_nofity to make sure
audio_notify_probe is called after qcom_q6v5_pas is ready.

Change-Id: I5a25f8d47dc2e7694a8078ad0052e7889a28b11d
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-08-25 08:01:23 +08:00
Vatsal Bucha
47942f03ae ASoC: mbhc-adc: Resolve headset removal detected because of elec irq
When SVA is enabled and headset is inserted and playback is started
on headset, sometimes electrical irq is triggered resulting in
headset removal being reported. This happens because of high mic
voltage being reported. Enable micbias before checking for adc
voltage to resolve issue.

Change-Id: If7445c906b2e62f12b48548a2d435db01f184587
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2021-08-24 14:16:38 +05:30
Junkai Cai
5b9a1dab00 Kalama-BU: add QMAA compliance to audio dlkms
Change-Id: Ia4ab7cb78afc49da30ad888aad5557fba4969216
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-23 14:27:25 -07:00
Junkai Cai
7880ae6993 audio-kernel: Update for kalama
Change-Id: I9b949cc2c03991d94311831dd7250693bb02815a
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-21 16:56:42 -07:00
Junkai Cai
1f7c8acba3 soc: add check condition before enabling irq
propagated from component audio-drivers.lnx.5.0 with same time.
However, original 5.10 code includes the change functionally already.
Adding check when irq_get_irq_data returns NULL.

Original comments:
Enable interrupt request only when the interrupt is
in disabled state.

Change-Id: Ic5048d2fbddf53bd0e42536677bf5d935f4e0683
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-21 15:52:04 -07:00
Junkai Cai
cc1ce15fb7 ASoC: codecs: add null check before use
Add null check for swr dmic component and swr_dmic_priv
before use.
Add array bounds check for slave port index before
accessing the array.

Change-Id: I6f1976e98e41e513a9a9db83d4e804a5cb1fe79b
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-21 15:08:00 -07:00
Rohit kumar
a9873e4b9d asoc: Add virtual node for WSA RX0
Change-Id: I49a300ab37610c325178517147189d96422297af
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
2021-08-20 01:26:26 -07:00
Junkai Cai
63db490176 asoc: lpass-cdc: return error when requesting incorrect state
Thermal framework is expected an error to be returned if the requested
cur_state exceed the max_state.

Change-Id: I1e0d8124a1aa6c0d755b35225207638aefdcb464
Signed-off-by: Junkai Cai <junkai@codeaurora.org>
2021-08-19 14:25:57 -07:00
qctecmdr
fa58ae98f9 Merge "asoc: codecs: update cb decode register control" 2021-08-15 08:15:12 -07:00
qctecmdr
6c5d480fb1 Merge "asoc: lpass-cdc: add put_autosuspend to pair with pm_runtime_get_sync" 2021-08-15 08:15:12 -07:00
Prasad Kumpatla
d8f2af06e6 asoc: common: configure mi2s interface clocks
Add support for mi2s interface clock configuration.

Change-Id: I439de17670d9521898d8bde893255025eceab84d
Signed-off-by: Prasad Kumpatla <pkumpatl@codeaurora.org>
2021-08-11 13:51:01 +05:30
Vignesh Kulothungan
1065b55645 asoc: codecs: update cb decode register control
Update central broadcast register control to enable bcl path.

Change-Id: Ibc05289d9cdd41e81369c6ef2547eceffa36d73a
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2021-08-09 12:17:38 -07:00
Meng Wang
a8bd9abc48 asoc: lpass-cdc: add put_autosuspend to pair with pm_runtime_get_sync
When reading/writing lpass codec registers, pm_runtime_put_autosuspend
is missed when vote fails and it causes device fails suspending after
ssr. Add pm_runtime_put_autosuspend to pair with pm_runtime_get_sync.
When LPASS_CDC_MACRO_EVT_PRE_SSR_UP comes, core vote is needed before
resetting GFMUX reg and dev_up is not set to true yet. Add pre_dev_up
flag to indicate PRE_SSR_UP and be used in lpass_cdc_check_core_votes
to avoid false alarm.

Change-Id: Ic12ecd9645f291078e32f4921f9f77c2d85e4b8c
Signed-off-by: Meng Wang <mengw@codeaurora.org>
2021-08-08 19:49:27 -07:00
qctecmdr
043966829b Merge "asoc: lpass-cdc: Disable clk when core vote fails." 2021-08-06 21:14:44 -07:00
qctecmdr
3df9593b07 Merge "asoc: common: fix null pointer access." 2021-08-06 21:08:44 -07:00
qctecmdr
786300e8a0 Merge "asoc: Return the correct clk_div value" 2021-08-06 21:02:43 -07:00
qctecmdr
a33aaa01f5 Merge "ASoC: mbhc-adc: Resolve bcs not enabled for us headset" 2021-08-06 20:56:50 -07:00