Defer the probe when the msm cdc pinctrl driver is not
proded.
Change-Id: Ia6aaaca7c55b60b53008ffda0fc40e5db407cd2a
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
Add conditional check before calling wcd usb api
Change-Id: I9046ece531ea009e8b8cd5db98675960d928c1c6
Signed-off-by: Sarath Varma Ganapathiraju <quic_ganavarm@quicinc.com>
Change default OVP threshold to 4.2V, but set
to 4.0V during CODEC reset.
Change-Id: I4aa8accf7466e144902a2f6a250c1aad91084e95
Signed-off-by: Sam Rainey <quic_rainey@quicinc.com>
Update zdet and xtalk to support high voltage microphones
with improved accuracy.
Change-Id: I4b0af5ade7f653de4a938162302ec21c4a09891f
Signed-off-by: Sam Rainey <quic_rainey@quicinc.com>
When codec goes into suspend, disable vdd-px which
will cause an unvote in PM.
Change-Id: Ia9f958d67fc57dbf3932733797bce7b0eb742363
Signed-off-by: Eric Rosas <quic_erosas@quicinc.com>
For test program < 3, use local default trim values
for harmonium 2.0 version.
Change-Id: I8cdcbe83ddae4626cef1f3dc4bfab3b2c285a0ca
Signed-off-by: Phani Kumar Uppalapati <quic_phaniu@quicinc.com>
Update wcd939x register settings for 2.15V VDD_RX supply
and for 2Vpk and 1.4Vpk modes depending on the headphone
load impedance values.
Change-Id: Iae5e6087fe96d22c9b9f8b755c468d2e6dface4e
Signed-off-by: Phani Kumar Uppalapati <quic_phaniu@quicinc.com>
Add static variable to store version to avoid improper
device pointer in wcd939x_readable_register().
Update WCD939X_NUM_REGISTERS macro to be correct size.
Change-Id: Ib594f2f799ac2202ff78c02ccf2f6cdb80ffd38e
Signed-off-by: Eric Rosas <quic_erosas@quicinc.com>
Few register default values are incorrectly set for harmonium
codec in the register map table. Fix it by setting correct
values as per the hardware interface documentation.
Change-Id: Ibcb517d6050a4932243ead396e6f89294aab4a23
Signed-off-by: Phani Kumar Uppalapati <quic_phaniu@quicinc.com>
Check and update register sequences for wcd9395 version
2.0.
Change-Id: I85fc739744ee2ba2c5dbdc853eb639b84cac6478
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
Add scale and alpha register value updates based
on computed digital xtalk cancellation gain.
Change-Id: I8c12e2ba7c1566476741fec5459a74549f19cf5f
Signed-off-by: Sam Rainey <quic_rainey@quicinc.com>
Update wcd939x-usbss mode on PA enable and disable.
Change-Id: I73a19ea73102ced5c8011a5a1567ebfa372b2e44
Signed-off-by: Eric Rosas <quic_erosas@quicinc.com>
Harmonium supports full and half rate modes for DAC.
Update DAC rate to swr clkdiv2 to achieve better
power performance.
Change-Id: I136a064dc258ee839ea78c9f1051ba34521ac871
Signed-off-by: Phani Kumar Uppalapati <quic_phaniu@quicinc.com>
Get the wcd939x power mode of from mixer ctls and configure
same power mode to wcd-usbss.
Change-Id: I9dc8fe586f7e7608da542b0986bb7c605fc552d4
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
For wcd939x LDORT_SCD_INT IQR register is removed, so remove
LDORT_SCD_INT register to avoid CMD ignore errors from RX SWR
while booting.
Change-Id: I6dfe6a1c32fddbcdbbf388b47efde60b6b4b5f35
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
Disable legacy HPH surge protection
for certain platforms. Enable HPH over-current
protection for all platforms.
Change-Id: I147321417ad2152530a71b3990a7cbf064c9299f
Signed-off-by: Sam Rainey <quic_rainey@quicinc.com>
Add support for HPH 2Vpk output mode in the
WCD939X driver.
Change-Id: I44a84cde84f0feee6d7d1255e097a5ffb616f78e
Signed-off-by: Sam Rainey <quic_rainey@quicinc.com>
update HPH power mode comparison with mixer ctls enum names,
so this will pick the correct compander coeff values depends on modes.
Change-Id: I42cdfeceda4c4bac960b71bbd62d0e8528680490
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
For PCM mode no need to enbale PDM interrupts, so add condition
to skip for register of PDM interrupts. Also avoid unwanted register
writes for PCM mode.
Change-Id: I4675a7ffe94d1f8628a4f539829f5aa83544cf8d
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
update register based on latest version and add conditional
check to enable PCM path.
Change-Id: Ib2fe0b477adfa07bef52954993fbd6aae011500a
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
update registers based on specific hph mode before compander
config.
Change-Id: Iea4f2bc5521dc701bd52ce8fe24323b1f9d96045
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
add support for compander to enable and disable for HPHL and HPHR
in wcd939x.
Change-Id: Ib7aa96bd9faac7389b38f01baff0a93c646f84f2
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
On wcd939x contains only one variant. Sometimes reading
for codec variant which is giving incorrect/unsupported,
due to this incorrect mixer ctl are picked. So Wcd939x
is updated with supported variant WCD9395.
Change-Id: Ie556350b3630b6f1f76a4b2af1db795f908f13d4
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
Use BIAS_LEVEL_OFF trigger from ASoC to mark the wcd/wsa power
supplies to LPM (if supported).
Change-Id: I89f232f9338168b99ae03f84318c21734b592f82
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
add mux in b/w IN1/2 and RX1/2 for configuring xtalk and
compander in hph pcm sequence.
Change-Id: I5ee97017585d03e0ef83841bbccef5982d79b9d9
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
Update wcd939x api and marcro in pineapple driver
Update wcd939x macro in wcd939x driver.
Change-Id: Id87fc550e0a3aff61efee61644fd6bc15ea7c66d
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>