During SSR up event handler, if soundwire state is
already up or auto suspend jiffies is not completed,
ensure put in suspend/SSR state.
Change-Id: I853f42d125eb5a60e3f1f065a60516877e3a463c
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
LV Platform use the same LVGVM cause Kbuild mismatch issue
Change-Id: Iad092ebcbd991e52daedb87406920055528e3a1c
Signed-off-by: Hongtao Peng <hongtaop@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>
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>
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>
Check for fifo availability before writing slave registers
during swrm master bulk write so as to prevent swr
overflow, underflow errors.
Change-Id: I97a914cac289b3f1215ccf5c1abec88b959a9f21
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Update sample interval in 4.8MHZ port config table of soundwire
digital mic slave and TX1 soundwire master port.
Update the block offset of soundwire digital mics 0 and 3 to handle
voip/sva dmic concurrency in both handset and speaker mode.
Change-Id: I85480c3609a72d4be3c4643b0123f09d71b97fef
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Add ratelimit to supress the logs flooding at the
time of SSR.In all places defined ratelimit as,
in 1sec one debug msg prints.
Change-Id: I6dfe140848e5cecb1b311c432f8311cdf0615a58
Signed-off-by: Prasad Kumpatla <nkumpat@codeaurora.org>
- Skip audio hm voting during bootup.
- Vote and unvote audio hm vote during swrm_runtime_suspend
and swrm_runtime_resume
Change-Id: I7a9c20f62ba0d87779b26da218bfe7373132b565
When sound wire master suspend is called, it holds the mutex lock
and does lpi_gpio_write, which gets preempted during pr_err_ratelimited.
Any other calls to master suspend will be blocked waiting for the above
mutex lock resulting in timeouts.
Remove pr_err_ratelimited log when device is down.
Change-Id: I148263ddbb89d436b0ce27bdc4519f196d90679a
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
in swrm_runtime_suspend, current_state is not updated and
causes audio_core_vote is not disabled. Update to check
swrm->state to resolve this issue.
Change-Id: I2c5be360fe5ddd964d7bc45696e254579aae5392
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Update Kbuild and header files in msm_audio_ion_vm.c
and apr_vm.c for kernel 5.4 gvm audio bring up.
Change-Id: I6bcd0e49f783aaec43a64ad308b817a474b30dc7
Signed-off-by: Guodong Hu <guodhu@codeaurora.org>
Add slave device address for wcd937x in soundwire master.
Update slave port configuration for wcd937x for holi.
Change-Id: I1f953e47b1520efd99b6f400593242ae5fc6158a
Signed-off-by: Vangala, Amarnath <avangala@codeaurora.org>
LV Platform use the same ARCH cause Kbuild mismatch issue
Change-Id: I803aeb3bbee45566b1f9e66b4a6c8b8c26ba86f3
Signed-off-by: Fei Tong <ftong@codeaurora.org>
Transaction slot is not freed when failure happens. Accumulated
error may lead to breach of transaction slot limit. Free the
transaction slot at failure.
Change-Id: I8588be18a820306d2a596fe2bf4a97346076b9b9
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
Enable component after enabling interrupt to avoid missing
some intterupt during master init.
Change-Id: I0f60c5431a815c58f878d3b9275a046e47939111
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Support 600KHz soundwire bus clock scaling for low power voice
activation usecases.
Change-Id: I81167895cf096a669e1335d3e4a8be6f3e7bf7f4
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Update sample offset's of sound wire digital mics when running
at 4.8 MHZ. This affects single and dual mic usecases.
Change-Id: Id33635debd0444fa93d183dacd8d6419b23394fd
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Headset is not detected sometimes due to master.num_dev not being
updated when we call GET_ENUM_SLAVE_STATUS as get_logical address
may not have been called. Also enable slave irq only when
swr wokeup from clk stop and not when master is already up.
This will prevent valid irq to be discarded as spurious irq.
Change-Id: I00284e9340668c853d0bd604fe66801118982780
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>