Add machine driver for Kona with stub codec.
Change-Id: Ic214324e22e2eaeaa2651e4fbeb8fd187aeb458e
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
chmap in msm_lsm_check_and_set_lab_controls, data in
wcd9xxx_i2c_write_device and irq_level in wcd9xxx_irq_init
are Variable Length Array (VLA). VLAs are considered unfit
when it comes to security, performance, code quality and so
on. Hence, allocate the memory dynamically.
Change-Id: I52f33e61f857a00774eb26dc1d6372f2ed3d425c
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Switch audio drivers to SPDX identifier on msm-4.19.
Change-Id: Ic3f0230a516db251b8d81e8a7e73dbc04d66fe1b
Signed-off-by: Meng Wang <mengw@codeaurora.org>
On kernel-4.19, setup_timer is changed to timer_setup.
Update ep92 driver to fix compile error.
Change-Id: I844241413c72c415819774921f267d84692ba177
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Update app type config get function and userspace can
get the app type config with mixer control.
Change-Id: I78eda2963161936ae1dbf90dad1bfb64cb079e8d
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Move struct snd_dec_ddp from uapi folder to msm-compress-q6-v2.c to
avoid code check warning.
Change-Id: Id33eee6da8f42841c80e7e5795bb19e71ab6e784
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Zdet current source is enabled for 4 pole aux cable and kept
even after plug removal. This increases voltage for both hph left and
right which causes error in cross-connection detection for subsequent plug
detections. Remove current source enablement from unrequired places.
CRs-Fixed: 2234559
Change-Id: Icffbca88f7a6873c509c91e31b494dd6d5d21cb9
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
The clk users count goes out of sync with the actual
clk requests from clients during SSR/PDR. Increment the
clk users only after the clk request is successful.
Change-Id: I512f037a118f4763a64e7a64f7f559bcfa37a37f
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
On headphone path, cold start output latency
is not met. Optimize delays during HPH DAC
and PA paths.
CRs-Fixed: 2338278
Change-Id: If96975d664fc655a4ac38a9d6ed88b6af61adfdf
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
On headphone(HPH) path, CnP spec is not met.
Handle sequences for bolero and tanggu codecs
as per HW sequences. Disable vdd_buck during
system suspend when no usecase is active.
CRs-Fixed: 2343436
Change-Id: I62f89d829715f07885a97531fdcb2cc3ca0822ef
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Microphone Activity Detection (MAD) hardware in the codec is used to
perform detection of audio/beacon/ultrasound audio activity on the
microphone. Add routing controls and configuration to enable the
capture support for MAD in WCD9335 codec.
Change-Id: I48359c6069bbebfc7f58efc24654544309912b69
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
Signed-off-by: Raja Mallik <rmallik@codeaurora.org>
Use soc_find_component locked version to ensure proper
access of component list while trying to find wsa
components from the list.
Change-Id: I1960d5b023c3d59f5c97ca0f616b4d9e39c15c50
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
MICBIAS1 is mapped to MICB2_VOUT. Replace it with
MICBIAS2 as MICBIAS2 is used for mbhc detect.
Change-Id: I23bade728f0c5b9de75d78ccb70e57d74f01adbb
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Enable compilation for sdmsteppe target and also fix
compilation errors.
Change-Id: I18a13764415ae955843706943e338bb575c11853
Signed-off-by: Md Mansoor Ahmed <mansoor@codeaurora.org>
Reduce auto suspend delay to 100ms from 1500ms for voting LPASS
NPA resource to reduce delay in entering LPASS into island mode.
Change-Id: Ic38f7b9e8d794963e51c30dfd03da586bca84bd2
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Pop is heard after PDR is triggered. This is
because while device down PA is still on.
Disable PA before SSR device down to prevent pop.
Change-Id: I6bfe3e731bdf60fba8fee90ab39c03a0512006ce
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
lpaif_muxsel_virt_addr to select AUXPCM or I2S is not needed in
machine driver. ADSP would select AUXPCM or I2S according to
afe port.
Remove related change in machine driver.
Change-Id: I55520a56bab2134a08e86909b98eb15d588c53ba
Signed-off-by: Meng Wang <mwang@codeaurora.org>
Paths using WDMA3_OUT widget are currently not marked to be ignored
during suspend, which results in the path teardown during suspend.
Due to this the audio use-case is broken. Fix this by marking
WDMA3_OUT widget as ignore_suspend.
CRs-fixed: 2176596
Change-Id: I72a2dda21aabfe9b13ea8660d4e3a51b3185d9ea
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
During bind/unbind of ngd_msm_ctrl power_gate_digital_core
is called. Simultaneously tavil_remove is also called
making tavil pointer as NULL. Check for tavil as not NULL
at the start of function to avoid NULL pointer dereference.
CRs-Fixed: 2267796
Change-Id: I6fc476cc8b706b556836f30838983de0f34d4fc1
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Private data pointer may not be initialized before
access it in adsp_stream_cmd_put. NULL check for prtd
avoids the issue.
CRs-Fixed: 2250112
Change-Id: I0a033d7e867b183c329941b57b49232729191f1b
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
HD2 canceller on analog codec is performing
better and enabling HD2 block on rx macro side
as well impacting THD+N spec. As per HW
recommendation, disable HD2 on digital bolero
rx macro by default. Mixer control option is
provided if required to enable it in future for
any requirements.
CRs-Fixed: 2343436
Change-Id: Ic1696ff9a6dea22a3c2a6071708267e2a024a4c7
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Updates for voting for LPASS island NPA resource while
access any LPASS registers.
Change-Id: Ibcebd2d6ef368f309594689335bc07a36eafeaf0
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Add callback event in ssr_disable to disable
tanggu PA before regcache_cache_only
to avoid pop after PDR. Also update proper bit
while RX Mute.
Change-Id: I06402269d393ca74c11611482cafbde03f4c62b9
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Add new clock node for LPASS NPA resource for clients
to enable or disable the resource.
Change-Id: I8aa587771618d301ace72d6df1045078cdf39c9c
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
SM6150 V1.0 target uses ipc wake up mechanism. Based on
version info of sm6150 chipset, register for
wake up interrupt either by ipc_wakeup or hardware
interrupt line machanism.
Change-Id: I7f12d919418b284f310c8b7bb5cd24e47f2099ec
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
Add reg_wake_irq macro callback and issue an event
from Tx macro to Tx sound wire master instance
in order to register for wake irq and to handle
the ipc wake up interrupt.
Change-Id: Iefddc1f85173ce267c0b00c9d06be3a4a2fe29fe
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
If button press and release interrupts occur at same time
processing button release first would treat the button event
as fake, as it is not preceeded with press event. Hence
process button press before button release in irq driver.
Change-Id: I9413def87537502c470236a3948a21be47c479bc
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
Add new class-H driver with sequences to support
both class-H and class-AB modes on wcd937x variants.
Change-Id: Ie109f3d951af1e8a0079dd39ab2fe1e9883bd6c2
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
For export functions from wcd937x use separate
header as internal header is only supposed to be
used within wcd937x driver logic.
Change-Id: Ice373ff95f7166a2f968458b25223c582edc7fba
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Two power modes are supported on bolero digital.
Add support to set required power mode using
mixer control and enable runtime during powerup
sequence.
Change-Id: I4c5a7560984d60745ac98848f1eec1d1f8485323
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Memset the param header struct to null values before
using or passing it to other functions.
Change-Id: I09ae686e62c8812ea267d4f809529b324fb7106d
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
Maintain eq data size to be equal to the max fe dais
present to not step over bound in accessing.
Change-Id: Ice0b7675b39a9fe2516a56d4e0b739ce34277958
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
During PCM closing, the AIF power down will be delayed due to flag
ignore_pmdown_time is not set. Set this flag for ultrasound RX DAI
to avoid delay in PCM close which causes slimbus overflow.
Change-Id: I5eeaceaacc5be0c200b50d1a7d0f211fa0d41f2b
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
ADSP, userspace and LSM client driver, all these three layer are maintaining
independent buffers and rewrite them irrespective of the buffer being read
successfully by their client or not.
Before switching to real-time capture, history buffers cached can be returned
with minimal delay and may lead to overrun in a module if buffering in the
module is not sufficient to store all those data generated almost instantaneously.
LSM driver having buffer size smaller than history buffer duration is hitting
this issue and resulting in buffer overrun for even a small delay from userspace
in start of capture processing thread.
Prevent this issue by synchronising read and write in LSM driver to make
sure the driver waits for read from userspace before writing the same buffer again.
Change-Id: I2710b484a7ef03e8314c7ba05bf729893aecb890
Signed-off-by: Dhananjay Kumar <dhakumar@codeaurora.org>
TX channel2 is not disabled after power down. It leads to
noise at the beginning of next recording on CH2.
Disable it after power down.
Change-Id: If12a84df52b9c8cd55de2bdcb91f950b054898b8
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
Add ec reference support for SEC_TDM_TX_0 and
TERT_TDM_RX_2 ports.
Change-Id: I3116b942fbd3c6c7bea14a77fdcd840dcab059aa
Signed-off-by: Derek Chen <chenche@codeaurora.org>
Add machine driver code to support SLIMBUS_9_TX port.
SLIMBUS_9_TX BE port is used for split A2DP sink usecase.
Change-Id: I9628a46c4b2b2fe0f5fb8c9861975fd4630bdcdb
Add audio effects related controls in transcode loopback driver to
support audio effects in hardware loopback usecase.
Update transcode loopback driver to support configuration of DSP render
window. Render window is used by DSP to take rendering decision.
i.e whether input frame should be rendered, dropped or repeated.
Change-Id: I09bb725d980b8051eae3a245584e2b66cd2af7ff
Signed-off-by: Trinath Thammishetty <tthamish@codeaurora.org>
Avoid access of gfmux register during SSR/PDR.
Reset the gfmux state to MCLK_MUX0 after
SSR up event in rx macro.
Change-Id: I2ac611049efd3ce9d03bc9dcd912f64887a23679
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Micb lock which is used to synchronize micbias
control api is not initialized causing spin lock
errors. Initialize the mutex to avoid the issue.
Change-Id: I580e52e1bd225c2d99bfba4657d80670296709a0
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
Add TDM clock reference count as LPASS
CLK API should only be controlled once
per TDM interface.
Change-Id: I025dc7cce3f1ccfe3b9d0ed652b71773f90d5c6f
Signed-off-by: Derek Chen <chenche@codeaurora.org>
Check the validity of copp index before calling
adm_close. This avoids redundant error logs in
adm_close.
CRs-Fixed: 2330388
Change-Id: I0b1cef5a45298fe9cbc84d9b944f6f10cec562df
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
USBC gnd mic swap is taken care of by FSA4480.
Gpio does not need to be swapped for this purpose.
CRs-Fixed: 2323772
Change-Id: Ida490995761ec5361ff2302b990d3c6fe1f32f85
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Add hostless FE and TDM BE DAI links for
TERT TDM TX7 and SEC TDM RX7 ports.
Change-Id: I57fed1162c5dc175475e7990f57d4a010a9057f2
Signed-off-by: Derek Chen <chenche@codeaurora.org>
Sometimes observed that session is taken more time to teardown
after ssr. Increase timeout to allow more time for session
to be tear down.
Change-Id: I3f1b4d8f583ad5b9c8f5e1b90af9c576ae6bd2b2
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
Add configuration flag to make use of 32channel support from
QDSP6.
Change-Id: I1e491b1ec870234140e914add4f177e5351b9953
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Currently, the fs_cntr for MAD is enabled whenever the MAD
audio path is enabled. But, a new issue is reported where
MAD fs_cntr is required even for some of the non-MAD paths.
As per hardware requirements, enable the MAD fs_cntr always
from the codec default registers.
Change-Id: I6fe8f663b82e711b4194aa51a3e21150aa98cf02
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
Runtime HPF param change leads to TX distortion at the beginning.
Unmute HPF after param change.
Change-Id: I7683ca047123dd004fb2dd019365305edfc72ea5
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
SXR1120 has additional gpio for micbias supply to be
enabled. Add control for this gpio and enable it.
Change-Id: Ica4ea9765db9bd48a1f8eb010d82d2687c8abbb9
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
When micbias is enabled set curr to higher value for
vreg bob bypass and when it is disabled set it
to default value for sm6150.
CRs-Fixed: 2315478
Change-Id: I451506002f382e666d47bc83944bdc8dbbedcad8
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Pop is observed on HPH playback start. Enable SWR port
config setup before HPH PA enable.
Change-Id: I2253be1c7e4d8df2bffd7bd0396ceb72a5018637
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Add widget and routing support for vdd-buck supply
as dynamic for all rx usecases.
Change-Id: I1e67e7e950e33a0d98900ee0b20e0dc818a7936d
Signed-off-by: Tanya Dixit <tdixit@codeaurora.org>
If interrupt indicates a fault in multichannel case,
reset all cluster devices in a specific order.
Change-Id: I077ff65c5f2b5e656fcdf6533fde04eba426e322
Signed-off-by: Romed Schur <rschur@codeaurora.org>
If headset is connected during SSR, after recovery mbhc
driver expects a new detection event as the driver is reinitialized.
Reset detection type to insertion to retrigger a hw interrupt
for mbhc driver.
Change-Id: I55705eb6b6a289deb5dc16a4b9ef6252082a3d9a
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
The format change event signaling for SPDIF input interfaces
is adapted to provide format information through sysfs nodes.
Change-Id: Ifab1074a0e4b13e08813e27f8694023c2c47bfe1
Signed-off-by: Ralf Herz <rherz@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Compressed streams now do support up to 32 channels.
Use new ADSP API for 32 channels if ADSP supports this.
If not fall back to 8 channel API.
Change-Id: Ief6fe189a6a34f15cfb96bfb9cb7d97b03633b95
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
AFE MI2S interfaces now support up to 8 data lines
(16 channels). Add support for the same.
Make senary PCM and MI2S ports available.
Change-Id: I810dbe1c12ff091b3b4604d9e59f7015e3a55c98
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
AFE MI2S interfaces now support up to 8 data lines
(16 channels). Add DAI support for the same.
Change-Id: I7c507c0161733094c1260731c7a046561fb63200
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
PCM streams do now support up to 32 channels.
Extend Playback Channel Map mixer control to 32
channels. Use new DSP 32 channel API if DSP version
supports it. If not fall back to 8 channels API.
Change-Id: I74c4f91b0c9fab2a963690ba8143ebea36ad23dd
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
The format change event signaling for EP92 HDMI input is adapted
to provide format information through sysfs nodes.
Chip configuration is done through sysfs as well.
Change-Id: I8c930ca5647899b4434272009699763c32fe9d04
Signed-off-by: Ralf Herz <rherz@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Add metadata to configure latency mode for DSP transcode
loopback to set legacy or low latency path. Userspace API
introduced to configure the same.
Change-Id: I914c68a9e9d8647530b72c42548e571b7508c423
Signed-off-by: Siddartha Shaik <sshaik@codeaurora.org>
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Add app type configuration support for DSP transcode
loopback to enable the required PP topologies.
Change-Id: I60ee50d78ba3c0edc9df042a2a86e691d62f24b7
Signed-off-by: Siddartha Shaik <sshaik@codeaurora.org>
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Mixer control queue handling is required only for
playback. Move mixer control queue handling to be
part of the playback stream in DSP transcode loopback
driver.
Change-Id: Ia8067237f80d509f969cf454f5afa08aaa6b0e52
Signed-off-by: Siddartha Shaik <sshaik@codeaurora.org>
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Update passthrough mode to pick proper path type for
compressed input data port in transcode loopback driver
to support compressed input in DSP loopback.
Change-Id: Ib2f66b467456787e08265a0da2bd85bb881a5d61
Signed-off-by: Siddartha Shaik <sshaik@codeaurora.org>
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Add new dailnks in machine driver to support
compress loopback usecase for HDMI and BT sink.
Change-Id: Ie9658b3c06fd8d9a68b9b2317fe2689fa34a96f5
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
Add new FE dais and their routings to support
compress loopback usecase for HDMI and BT sink.
Change-Id: I95d683ff22cda0e7d52333e7dabbb7694cb254f3
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
wcd interrupts can be disabled in the same interrupt
context. So use non-sync disable irq api for disabling the
interrupts to avoid a deadlock.
Change-Id: I82dda8dbcd80ba18674eea00686f6a4f54a3b340
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
During SSR, when the playback on speaker gets started before codec
is out of digital core power collapse, results in soundwire
register read/write failures. Check for codec power state before
enabling the soundwire during speaker device path enablement for
playback usecase to avoid soundwire register read/write failures.
Change-Id: I3b45ef0c34ad4f97aad89afaf719989ffbda7485
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Add proper way to clear interrupts using regmap irq framework,
to avoid mismatch between interrupts handled and interrupts
cleared. wcd937x requires writing '1' and then '0' to clear
interrupt. Set a new regmap irq flag 'clear_ack' to indicate this.
Change-Id: I1346dc66735d3b5788e1cc0cfef772c9deacbfc1
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
Update ignore suspend for AIF in/out and dapm input/output
widgets for bolero and wcd937x codecs to avoid suspend
of codec during active usecase running even after APSS
goes to suspend.
CRs-Fixed: 2321226
Change-Id: I277129e8e657485c56414a385150c4da55382770
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
After switching from native to non-native clip,
observe slowness in clip playback content heard
on headphones. Update mclk_mux for enable sequence
based on native flag and for disable sequence
use the same setting done during enable.
CRs-Fixed: 2322232
Change-Id: I795e0620e0239b53cdfdadaf2d57acfb570c4c3b
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Excessive logging causes throttling during bootup.
Update log level from error to debug in get functions to
avoid excessive logging.
CRs-Fixed: 2321589
Change-Id: If2a23144adf76cdd9bb2d9048a967b63186d7f6e
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
ANDROID_BUILD_TOP variable is deprecated and thus all paths are
assumed to be relative to the top directory.
Change-Id: Ifc1bba67bf47092a37336581990d4bcce82a72f5
Fix routing error from incorrect usage of passthrough mode
while switching LSM session from direct AFE connection to
path using ADM before AFE connection.
Issue is due to loss of passthrough mode for an FE not opened
with ADM during initial session setup or while moving the FE
from one BE port to another BE port, i.e. device switch usecases.
Since passthrough mode for an FE is supposed to be same for all
the BEs connecting to the FE and is directly decided from FE
driver having single value, decouple passthrough mode from BE
and store the required mode in an FE config independent of BE usage.
This allows storing passthrough mode for future usage irrespective
of initial setup path which can be with or without ADM.
Change-Id: I53106b49effd9b267363aedd77477eed103b317c
Signed-off-by: Dhananjay Kumar <dhakumar@codeaurora.org>
Add snd_event support for talos required for SSR.
Change-Id: If689d9cda131324b99e0dda0b91f237b495eeadc
Signed-off-by: Vaishnavi Kommaraju <vkommara@codeaurora.org>
Add changes to recover audio after SSR on wcd937x driver.
Change-Id: I661605e9b1bd71f08f331d14ae52f89ba8423d4f
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
For new swr master controller to recover WSA on wcd934x variant,
trigger events from wcd934x driver for ssr down and up.
Change-Id: I8f0163178708760ef3ad2a765a80682611693e9b
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
In bolero and tanggu combination, make bolero parent of tanggu.
Bolero and tanggu can communicate mutually using notifier and
plat_data callback APIs.
Change-Id: Iecd119df7f0ad1ba225c0427f3f42f217146b092
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Fix condition to register display port dai link as
part of soundcard registration.
CRs-Fixed: 2321275
Change-Id: I196163599299fa4aea21c930c0bfe3f8e5425223
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
Add mixer widgets, routing and mixer controls in order
to support BCL feature on WSA and RX macros
of bolero codec.
CRs-Fixed: 2225097
Change-Id: I463f89a517bb3878e51a6aca0c1d73bc652ab8c5
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
Check the value of ch_num and return if
less than zero to avoid out of bound access
in cdc_dma_cfg arrays.
Change-Id: Ie59f5e7ed063d65a61033a142acd2bcf2287c39b
Signed-off-by: Tanya Dixit <tdixit@codeaurora.org>
On wcd937x, add controls for HPH compander.
Handle sequences for headphone path based on
compander enabled or disabled.
Change-Id: I2ebdd03a4f79dc6156327d0613fab2f26710393f
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
When codec probe is not correctly completed and ADSP SSR happens
before sound card is registered, calling SSR callback may result
into NULL pointer dereference and kernel panic happens.
Check sound card state when calling device_down and post_reset to
avoid NULL pointer dereference.
Change-Id: I35fd84af51edf45db6fd451dc68dbcaaed11fee7
Signed-off-by: Meng Wang <mengw@codeaurora.org>
Bulk read api does not work properly for swr regmap,
causing failure/delay in impedance detection.
Use regmap read api to avoid the issue.
CRs-Fixed: 2301798
Change-Id: I5727cfcb7846f40f5b0f75b7976b492e2a2bfde0
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Add proper null checks and initialize variables
in rx-macro, tx-macro, va-macro and wcd937x drivers.
Change-Id: I90899c84d3391305b9a24d4b043adc08b7c0332a
Signed-off-by: Tanya Dixit <tdixit@codeaurora.org>
On bolero rx macro, add support to switch
mclk frequency based on native usecase active.
Change-Id: I2f915475dcfdadf1027507b7ed83a4a852ece1c7
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
PP event queue is not used by capture path. Initialize PP
event queue for playback path only to remove unnecessary log.
Change log level from error to debug when no matching afe
cal block is found.
Change-Id: Ibc323449f2fdc74cccd350ae30ac76d937898ffa
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
Add alias for in2p clamp register to check in2p
clamp state in insertion irq and ignore the interrupt
if the clamp is already set.
Change-Id: Ibd4ff2cef8690894a01072e74ce130f824656f5d
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
Add capability to receive notifications from voice service
when there is a change in mic break status during a voice call.
On receiving notification, send an uevent with mic status to userspace.
CRs-Fixed: 2211324
Change-Id: Ie55bd1490fd8cead7261b70169ae36eba95e4011
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
For headphone playback, update default power level
to Ultra_Low_Power(ULP) on wcd9370.
Change-Id: Ic5e76d8f8fca1806780a4dbc679166a68c31edf3
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>