Remove unused mic widgets and add new mic widgets
required for msmnile target.
Change-Id: I5e5ed56a80324b48599a00a196d99ed4ab386412
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
WSA8815 requires default boost state of MAX_STATE_2, when
speaker protection feature is disabled. Set boost state to
MAX_STATE_2 in all cases for WSA8815.
Change-Id: Ic700d9a206e94a4cdd1d99f8547bed9df1e759e8
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
After applying calibration on DSP, cal block
is marked stale to ensure same calibration is not
reused for future usecase.
Change-Id: I9f446c0602f4ab34ca71b9d2611319624fb19cd2
Signed-off-by: Vikram Panduranga <vpandura@codeaurora.org>
After headset removal disable button current source
to not have any voltages output in micbias after
headset removal from extension cable.
Change-Id: I2a751c16c704176381bb26f375aebf351686e911
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Null check is needed before accessing swr control data
to ensure proper error handling in case speaker path
is issued when swr is not enabled.
Change-Id: I5037a912652189b3ae58f1119d0534777a9c264a
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Devm clean up functions are removed to avoid calling twice
as these are excuted during removal of device.
Change-Id: Ifddde69d189b59456ef7627f32532198654e40d3
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Add pahu-slim-ngd under wcd_slim_device_id list to
register pahu codec with slimbus driver.
Change-Id: I87a9a56087fd1520fe592b39eb142297c2f176e0
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Update register default values before post SSR to avoid codec nack issue.
Change-Id: Ibf1e3275d27c4b65ab179b9ddc5a51621c89eab7
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Add change to parse fsa handle in machine driver
to use it to call gnd/mic swap api of fsa driver.
Change-Id: Ie9c2aede45138b0d4e3bf94f11feccab47874223
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Add support for usbc analog audio for msmnile platform
by adding fsa driver calls in mbhc driver to make
any switching orientation changes of gnd/mic.
Change-Id: Iab7511907325a24345734402c10a4cf5f8ebfa23
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
In Tavil driver, both ANC0 and ANC1 channel registers are written when
each ANC channel is enabled. This logic results in high latency during
ANC enablement on Tavil codec. Optimize this logic by only writing the
corresponding channel registers when enabling ANC0 or ANC1.
Change-Id: I62e8572967e6ca6c851cbaaad5f1b8c19e5b1a5f
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
Update module symbol folder from PRODUCT_OUT to OUT.
Change-Id: I4542c3d2b5e9e39b69f15954ef425c1915a58456
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Euro usb-c analog support is not present in machine driver
for sdm670. Add support for corresponding gpio
so that usb-c analog headset is reported correctly.
CRs-Fixed: 2164436
Change-Id: I4bf73a9f13b7b8193289706ac21f96c557503fd8
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
During Tx path enablement, amic information is needed for proper
power level settings and for better performance. Existing API returns
incorrect amic information. Changes provide the correct amic information.
Change-Id: I18f3f35212cae47e5d944c2e075f03889147722b
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Fix hardware sequence for AQT1000 as per hardware
requirements to bring codec out of reset for playback
and capture usecases on headset.
Change-Id: I7419aec36aefc2887583308a60d1ea246d000469
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add frontend and backend dailinks for playback and capture paths
of WCD934x codec and runtime detection support of WCD934x codec
and WCD9360 codec on msmnile target.
Change-Id: Iff189a89c6515a6196714a00d21a0fb4de939e3f
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add support to set and get audio effects module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.
CRs-Fixed: 2151551
Change-Id: I0fdba2560950c931a2ec6f152499fd4bb9f59086
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Add support to set and get dap modules params with
Instance ID support for both Dolby and DS2.
Maintain support for non Instance ID set and get param
structures as well. Use common pack and set param
functions to set and get parameters to DSP instead of
handling them at an individual module level.
CRs-Fixed: 2151551
Change-Id: I1633b63a1a598c0e4ea874d00655b09a240a47e3
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Add support to set and get ADM module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.
CRs-Fixed: 2151551
Change-Id: I5ef920448dd827d8a315e248087997f703061263
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Enablement of WCD934x and WCD9360 codecs for dynamic detection
results in redefinition errors due to same enums and API definition
in WCD934x and WCD9360 codec drivers. Resolve the same.
Change-Id: Ifed50dc1df0562ba62b14187597cad2bed6c1115
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add new dais to support multiple record session in
compress path.
CRs-Fixed: 2167556
Change-Id: I2020adc2fd2e56e7ad76529e53a772963a64cdd9
Signed-off-by: Sachin Mohan Gadag <sgadag@codeaurora.org>
Add new dais to support compress record usecase.
Update media_encoder_format api to v4 version in
compress driver.
CRs-Fixed: 2167556
Change-Id: I8a2f8a4cdcec4bb31ad94730eb4f1259e800c70c
Signed-off-by: Sachin Mohan Gadag <sgadag@codeaurora.org>
As CONFIG_SND_HWDEP is defined by default
in kernel tree, msm-pcm-routing-devdep.c file
in audio drivers gets compiled always.
Use CONFIG_SND_HWDEP_ROUTING config instead of
CONFIG_SND_HWDEP to compile msm-pcm-routing-devdep.c
file.
Change-Id: I19c4b0a56dbe6c4890ece645fcf100687f762f5d
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Add support to set and get voice module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.
CRs-Fixed: 2151551
Change-Id: I045e27710d69304f234ace1ff6c80afdd4a4041c
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Expose APIs to get and set instance ID support by exposing a
mixer control for userspace to set the support status as well
as APIs for kernel components to querry for instance ID support.
CRs-Fixed: 2151551
Change-Id: I3b462a4c0f31152a2865af8f4e9664a6c4d324c3
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
Add support for WCD934x codec on msmnile target for audio
playback and capture usecases.
Change-Id: Ia91fd532fcb3a127941f8dc7ba42aecea17a5ec2
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add delay after LDO_RXTX supply is enabled as per
hardware register sequence.
Change-Id: I588d36c6c13ae8f545aba2b2cf6d1c73fde08d0a
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Use kmalloc instead of dma_alloc_coherent for slim buffers
to support dma_mapping api in interrupt context.
Change-Id: Idf06832b6a3bb30f6a16c168b4e5e5f13ad0a0ab
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Signed-off-by: Meng Wang <mwang@codeaurora.org>
For remove module(rmmod), update drivers
to cleanup resources and allow insert module
again without any issue.
Change-Id: Iddc6e5e11d986359afd3100bf3c5eab70cb1c1eb
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Defer probe of soundcard registration until codec
driver registration is complete to fix detection of
codec version by machine driver.
Change-Id: Ia93404a85c98bd50e63015073284d5bf290a3f9f
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Observe mute issue when PDR triggered while music playback
on HPH. As per HW recommendation, ensure OCP is turned off
before PA enable/disable. During PA enablement, turn off OCP
to avoid false OCP interrupts.
CRs-Fixed: 2167007
Change-Id: I0dc2cc6ded3416b635d14dc3b7aafa7997fe9a4d
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Add a missing function pointer null check condition in
mbhc driver to avoid null access during fast
insertion-removal.
Change-Id: I6aa64325cea6f7aa551115969d1e6ba184ec8d14
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
It is possible that the spi transfer that clears the clock request
on the slave may fail. In such case, it is not safe to assume that
the clock request is still enabled as it can cause failures for
further spi transfers if the clock request is cleared. Fix such
issues by resetting the clock state in the driver even the clock
request clearing fails.
CRs-Fixed: 2169087
Change-Id: I699e72b59b4cb049dfacaa190823796a545f2dbb
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
Currently IIR coefficient values are written to HW everytime when
digital core comes out of power collapse. This increases playback
cold start latency. So update IIR coefficient values before IIR
band enable.
Change-Id: I57ad54b4674ed0a49fdfc55d77c519568f5a7893
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Add size check to make sure the data sizes from WDSP
ELF metadata and the split firmware ELF are the same.
Change-Id: I913087bc352850ceac2fcc07067ea8f480563ae2
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
Add size check to make sure the data sizes from WDSP
ELF metadata and the split firmware ELF are the same.
Change-Id: I7a1404cd15601d8d503e3355e6dc70e2949df72d
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
Update routing driver with port mixer commands between
primary and secondary interfaces to enable AFE lopback
between them. Update FE DAI driver to add hostless FEs
for primary/secondary Auxpcm and secondary MI2S.
Change-Id: I792e1cf4e0600d3b4726624e29e73e67828a3935
Signed-off-by: Viraja Kommaraju <virajak@codeaurora.org>
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Change i2s max rate supported for tavil to 384000Hz.
Cleanup usage of intf_type to optimize differentiation
between slim and i2s.
Change-Id: If6451dae7c61e8f61be3d5a13549f98b382e5054
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Add support for tavil i2c access. Add audio
routings dapm widgets for data and control.
Change-Id: I96ebf7a5700b10f294f4fadfeeb21dab490a9313
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Add i2c driver node for tavil codec for
i2c communication with the codec.
Change-Id: Ie28dfeca102251265a5f50153c3ba98dae84dde2
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Change mic bias enum names to be specific to codec
to avoid conflict with mbhc mic bias enum.
Change-Id: I7bae83aafd72753eaedebd533364ec404a54977a
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Limit size of val to WCD_MISCDEV_CMD_MAX_LEN to avoid stack overflow.
CRs-Fixed: 2177167
Change-Id: Ia0f5e3c5a786d06dbb7f0523a1d1919e93081f69
Signed-off-by: Vaishnavi Kommaraju <vkommara@codeaurora.org>
Limit size of val to WCD_MISCDEV_CMD_MAX_LEN to avoid stack overflow.
CRs-Fixed: 2177167
Change-Id: I5d2b91e92305d6a485b2e8f959036504f0f55b13
Signed-off-by: Vaishnavi Kommaraju <vkommara@codeaurora.org>
Add support for quinary mi2s/auxpcm/tdm for msmnile target.
Change-Id: I0cbfa98129e6181662f7555735173eded12a0bf7
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Fix return value in aqt_codec_info_create_codec_entry function
to return proper value and add target config to include files
Change-Id: I063e199b1bf0e672b5afc20ed7de8447eed35dd4
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add ALSA dailinks for supporting various audio/voice
use cases for msmnile target.
Change-Id: If300b2c94e72414a657f30691cdfcb0d0a3b9a13
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Add stub function for msm pinctrl get function
when msm pinctrl configuration is not defined.
Change-Id: I5229dd804025e328471f0fd35cff33a69d47b2dd
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
WCD9360 codec acts as an interface between AQT codec and
msmnile CPU DAI. Add AQT based playback and capture dais in
WCD9360 codec driver.
Change-Id: Ic780dd336a775dbb48a1d3ada90029763ac7a657
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>