Add range check for ucontrol value to avoid array
overflow.
Change-Id: I7b699519bec6f605e5ca5ece8f67badbefc7a094
Signed-off-by: Meng Wang <mengw@codeaurora.org>
* Add additional proxy port frontend and pcm backend to support dual proxy port
* Add channel configuration mixer control for second proxy port
Change-Id: Iba7e21f17122926d27acc58be653351b4d0ea37a
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
Signed-off-by: Tahir Dawson <dawson@codeaurora.org>
VoLTE in power mode doesn't support to configure bit-width of
AFE port with 24bit.
Fix it by use default bit-width when start VoLTE in power mode.
Change-Id: Ic429ea317c71c9a4436705663185fc69cb885166
Signed-off-by: Kunlei Zhang <kunleiz@codeaurora.org>
add retry logic to ensure adsp is up before registering custom
topologies
Change-Id: Ib88c06ae8c64cd0784319f40e3746ccbbce0cdf7
Signed-off-by: Akhil Karuturi <akarutur@codeaurora.org>
Update the typo to fix failure in afe_get_port_idx during RX usecase.
Change-Id: I2026cbce0165e6f5e4059945183a09feaee89b45
Signed-off-by: Nirav Khatri <khatri@codeaurora.org>
Add change to properly handle the pointers by setting them to
NULL after free and adding some null checks before dereferencing.
Change-Id: Ic2f3ef5631d0f4e4191bf772eb0b3f0b825044a6
Race condition is observed when sending afe cmd
and afe nowait cmd one after other resulting
in incorrect interpretation of the adsp responses
received back to back.
Handle this by adding a new data token for nowait
commands to indentify the response recevied is for
the same.
Change-Id: I76bf810c23d1fd572cb496c62cbfaac1a5c349b5
Signed-off-by: Soumya Managoli <smanag@codeaurora.org>
Add count check before enabling/disabling regulator for swr
haptics. This is to ensure that count dosent get mismatched.
Change-Id: I73bb9f8ef459eea4327b9db09c430e8c2ec87adb
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
When SSR happens, set substream state to SNDRV_PCM_STATE_DISCONNECTED
to avoid userspace keeping waiting for substream state and causing
deadlock.
Change-Id: Iaa4d76101204652742c55d13da5c770c418a16bc
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Remove static definitions of rx swr slave physical addresses.
Add support to read swr slave physical addresses from device
tree and store it within respective master data structure.
Revert addition of slave device address for wcd937x in soundwire
master.
Change-Id: I0eb2597b8e40a54d476cd2662bbe4f2008af899a
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Auto suspend timer for core vote is triggering before read write complete.
Move the auto suspend of core vote to post read write operation.
Change-Id: Ib0f6b026fe0e7fd3fbe052691db492915e436a78
Signed-off-by: Vangala, Amarnath <avangala@codeaurora.org>
Enable interrupt request only when the interrupt is
in disabled state.
Change-Id: I67795bf0ee344661e02b0fec3181cd7980d56652
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
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.
Change-Id: I505fcf349b45bd6f2374e5cfee83473f032e4ad7
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Some soundwire register dump is skipped with current logic.
Update ppos logic to dump all soundwire registers correctly.
Change-Id: Id053e2b71705ca17caf2de2bb85f8c987790099a
Signed-off-by: Meng Wang <mengw@codeaurora.org>
At bootup device wakeup enable is called for all masters
causing issue for wsa on lahaina. This is because wsa
supports interrupts on lahaina. Thus enable device wakeup
only for tx master.
Change-Id: Ia53df31427e54d5fd981cd650e1b0f06cb2d47b5
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
When multiple slave ports are configured to a single master port,
the offset1 of master is the minimum of all slave port's offset1.
Change-Id: I102269806048ecf9982489164a7651a2cdd0661c
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
tinycap test can attempt with different size to
read from driver and need to avoid access more
than period size.
Change-Id: Ifa4ddfb086bd83aa981da62e88da3a9395f5aabc
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
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: I57cc860e69d75385434822b1975d869d12717de4
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Add condition control to avoid mixer being added twice,
to avoid kernel error printing.
Change-Id: I832e4c08ac06fe885c1497bce4bd4ada96ef83fb
Signed-off-by: Guodong Hu <guodhu@codeaurora.org>
SWR overflow, underflow interrupts are seen sometimes on bootup.
Check whether devnum is 0 during fifo read and write. Also assign
read and write fifo depth before master init to resolve errors.
Change-Id: Id7b687985e320396d2f9dab69db56cc7f5426b04
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>