Add support for audio over MI2S and AUX PCM interfaces
so that applications have flexibility to select MI2S/AUX
PCM interfaces in addition to Slimbus.
CRs-Fixed: 1047362 1047365
Change-Id: I48e6680b026391d8e77bbdcba4fb59ed90b13581
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
Device state is updated incorrectly during codec probe when
the wsa881x soundwire slave device is in suspend state, resulting
in register read/write failures. Update the device state during
device probe instead of codec probe.
Change-Id: I46afe2a08495c2ed06806b0568b1c44a6ffd947f
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add support for tertiary and quaternary audio PCM interface
to msm platform.
Change-Id: I985200bbff55583ac09bf7444ecbc5cf6ab7eb41
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
It is required the buffer size to ADSP are multiple of 4kB. Update
the buffer size to be 4kB alignment before passing to ADSP.
CRs-Fixed: 1040066
Change-Id: I34f1b611000f5d9e4ae4c13a89b8571faa0f3393
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
On msmcobalt reference platform, earpiece path is not connected
to receiver, instead speaker path is used as receiver. So handset
AANC(Adaptive Active Noise cancellation) needs to be supported
on speaker path. Change enables ANC support on speaker path.
Change-Id: I8104994adc30810085cce73662f5abd5e15106ad
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
In msmcobalt platform, speaker path is used for handset mode also.
Add the mixer control to change gain in handset mode.
Change-Id: Ia291f7449cd04a855102a03324f7cdcb6f13dad0
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Dynamic detection between wcd9335 and wcd934x codecs is supported on
msmcobalt. Probe sequence of the two codec drivers can occur in any
order. MCLK initialization is common for the two codecs which gets
called twice. Avoid wcd934x codec's probe sequence from resetting
wcd9335 codec's native mclk pinctrl if the pinctrl is already
initialized.
CRs-Fixed: 1066167
Change-Id: Idf65e15e08bb856d65b992b996cffa6ef2e6f974
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Update the DMIC CLK and DATA registers to use the correct
settings required for DMIC High-Z on wcd934x. Registers
should be set to 0x6 for Slimbus mode and 0xD for I2C mode.
CRs-Fixed: 1059712
Change-Id: Ibe8ca2e40ee56708e8c84c174d12ce5841e6b1ce
Signed-off-by: Meng Wang <mwang@codeaurora.org>
WCD934X codec supports adaptive ANC(Active noise cancellation)
on ear and speaker path. Add the required changes to support
this feature.
Change-Id: I2a069fc208b080c1251f7aa473ae75ad02e883c8
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Headphones support classH and classAB. Add support for
hifi, lowhifi, low power and ultra low power modes for classH.
Support hifi and lowhifi power modes for classAB.
CRs-Fixed: 1066331
Change-Id: I846f9704a5bf800583682f8dc2ec385a0ec64c61
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
TASHA_IS_1_1 macro checks only for version number.
This macro returns true for tavil codec. So modify
tasha macros to check for codec and version.
CRs-Fixed: 1066331
Change-Id: I5240e0ee888187a8185974ea288ce2cad62bd776
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
On msm-4.4, conditional paths are not supported for
supply widgets. Using SND_SOC_DAPM_MUX instead of
using Switches to connect to the native supply.
CRs-Fixed: 1066167
Change-Id: If015dbad0e168e41f1c8c86b502d4cf5fb592045
Signed-off-by: Meng Wang <mwang@codeaurora.org>
WCD934X audio codec supports idle detection over headphone
path to reduce power consumption when the audio signal
level is low. Add support to enable headphone idle detection
in the wcd934x codec driver.
CRs-fixed: 1066588
Change-Id: I8d67fa4055898db31b47f87b6659484aeb08f58f
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
Explicitly send device disconnect notification to client
so that client can disable audio streams. This will in turn
enable sound usb driver to release usb device and notify device
removal to user-space. User-space will clean up audio session.
Without this change sound usb driver is blocking usb device
release till audio streams are disabled. However, audio streams
are only disabled when user-space cleans up audio session on usb
device removal which is blocked. This change is trying to fix
this deadlock condition by notifying device disconnect to clients
explicitly.
Change-Id: I7e5a8aca84a7a620bb61eb0ace8a6b6c622f89de
Signed-off-by: Vamsi Krishna Samavedam <vskrishn@codeaurora.org>
Create codec entry for wcd934x codec so that userspace can retrieve
the codec info.
CRs-Fixed: 1063367
Change-Id: Ie846b5edf1d8aaecce5140986dad8da69d608d5a
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
As there are many hardware version of wcd934x codec. Add version
check in the code so that userspace can get the version info.
CRs-Fixed: 1063367
Change-Id: Ia320380d568426c2d7a414a832980a556ff27f0f
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
The overflow check is required to ensure that user space data
in kernel may not go beyond buffer boundary.
CRs-Fixed: 1064411
Change-Id: I54c28a8942cf1a6a47a4e8272f3159b35d753ead
Signed-off-by: Karthik Reddy Katta <a_katta@codeaurora.org>
Change adds call to arch_setup_dma_ops to make sure the dma ops
are initialized before dma allocations are done.
CRs-fixed: 1065339
Change-Id: I5658598032f151c9293b3c4f6cf2311df8d3a634
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>