Currently snd_soc_jack_report() always acquires codec->mutex and
synchronize DAPM widgets. This automation is helpful if jack has defined
widget. However if codec driver doesn't have defined jack widget and
non-jack widget wants to synchronize with report_sock_jack's thread which
is usually irq handler, it can make dead-lock as all DAPM widget
call-backs are called after codec->mutex acquisition.
Add new API snd_soc_jack_report_no_dapm() so codec driver can have ability
of control DAPM synchronization part of snd_soc_jack_report()
Change-Id: Ifc6054cd8b6d8a6b52517cf84baca1e3949e09fe
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Add support for Slimbus channels between external modem and APQ.
These channels transfer voice packets to/from the modem to the
BT stack on APQ.
Change-Id: I48bd5248104719574fbc6cf52edfb92cff79bff9
Signed-off-by: Neema Shetty <nshetty@codeaurora.org>
Create ION client and allocate buffers based on
the client handle and free the buffers when no
more needed
Change-Id: I00be9dbd3e8f5eff286d8f1bc0d61656866bf360
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
Previously, DSP used to setup the data path towards the
codec via slimbus. Now, the data path setup is broken into
two parts - one half of the path setup between apps to slimbus
and the other half from DSP. This configuration mode is
required to reduce overflow or underflow errors. Also this is
required to handle a configuration where mdm can talk
directly to codec.
Change-Id: Ic9f20b8a2f8a8eb355c07565ec80ec947a7a7337
Signed-off-by: Bharath Ramachandramurthy <bramacha@codeaurora.org>
HDMI 1.3 supports Multi channel PCM up to 8 channels with sample
size of 16/20/24 bits and sample rate of 32, 44.1, 48, 96, 176.4,
192K. This patch add supports for 6 channel PCM at 48K sample rate
with sample size of 16 bits.
Change-Id: Id09f1f9d7ef2e2444c8c1b661bfc5b3b4c1e66a6
Signed-off-by: Kiran Kandi <kkandi@codeaurora.org>
The timestamp would be used by applications for AVSYNC purpose.
Change-Id: I416c38e82fbd51b58df119c0122bcd629ccd88fd
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
Define more sound jack types to be able to report additional buttons.
Change-Id: Ib37f854550cc147d90231352bc7d6b03316f60f5
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Add support for adie RX & TX calibration. This calibration
is used for RMC and speaker protection. A non-blocking
function was created for AFE memory map since it is now
being called from an atomic process and the acdb driver
was changed to use to use atomic variables.
Change-Id: Id6c6ca7a303ef5ee5d23a9932e910e6a7a08805d
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
Issue - backend dai prepare fails with concurrent LPA and non-LPA
sessions during stability tests. Since front end dai reference
count gets incremented for both sessions and backend dai hw_params
doesnt get invoked. This results NULL pointer in backend dai hw_params.
Fix - use the flag hwparam_set to ensure backend dai hw_parmas is
invoked properly.
Change-Id: Id08628e67d0f8ccf284c0e07a801aa8fc47bd8aa
CRs-fixed: 326458
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
Add MI2S CPU driver which configures QDSP6 AFE to start MI2S port.
Change-Id: Idc12325d83607d60e66636c3fba052204905a629
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
The sampling rate of Fluencepro topology is either 16K or 8K.
Therefore, we need to reduce the ADM sampling rate to 16K during
recording with Fluencepro topology.
Change-Id: I0a558c359dbfd62aa35c05dbadba57b3e3820d21
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
Add one backend DAI, and add one mixer control to route playback stream
to the new backend DAI. Start/stop playback commands will be sent to CVD
if starting/stopping playback, after voice call is established.
Change-Id: I334f1894ac0800e6a71fa7e20ac634b1b05cc414
Signed-off-by: Helen Zeng <xiaoyunz@codeaurora.org>
This patch adds the header files for ioctl definations and header file for
driver APIs for lower level device drivers to use
Change-Id: I9d35b1a34aab0aaee8f8b3cd3d9fad1c2d633158
Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
The USF driver manages ultrasound data path between QDSP6 and
user space based daemons, calculating input events upon the
ultrasound data.
Change-Id: I087227f0b9a224bc6633be3ccb76be463d90640c
Signed-off-by: Baruch Eruchimovitch <baruche@codeaurora.org>
LPA_IF dma channel is disabled without checking the per count value.
Because of this dma channel is not functional after few iterations
of continuous playback. Fix this issue by checking the dma per count
value to stop before disabling the LPA_IF dma channel.
Change-Id: Ie9e9a9337ca2c4b76cebd99cd3eb98137be85b89
Signed-off-by: Deepa Madiregama <dmadireg@codeaurora.org>
Add function to get the ASM audio client from a session
ID. Allow the ability to get audio client information
used by the ASM interface when only a session ID is
available.
Change-Id: Id9be30954c1a839648194c4a0120cccd341afae4
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
Some CODECs monitor current drawn by headphone power amplifer.
If current consumed goes over pre-defined threshold, CODEC would
communicate to host processor. Then, CODEC driver would propagate
the event so user-space application can react accordingly.
Add support to propagate over current events for both
left headphone and right headphone through ALSA jack framework.
Change-Id: Ieef36f070a4478a5a80ec4c8b0cc81464abd75ad
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Adds the macro SOC_SINGLE_MULTI_EXT which allows the user
to pass the number of integer inputs accepted by the control.
Change-Id: I75009672568d1e0979ecd577031e72bd87f310d2
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
Previously, dolby aac decoder was enabled by disabling
legacy aac decoder. This change should correct it.
Change-Id: I0b46a444701585921c546c6668a0bc0c8e63ec50
Signed-off-by: Bharath Ramachandramurthy <bramacha@codeaurora.org>
Enable dolby pulse codec, to be used for decoding multi stream
aac content.
Change-Id: Ia936f25820c062112e9838230511e20db2472726
Signed-off-by: Sidipotu Ashok <sashok@codeaurora.org>
Audio hardware path can be started not only for audio playback/capture
but also voice call. ADM COPP is created through Q6ADM driver
when AFE port is started. For voice call use case, creating
ADM COPP in DSP wastes unnecessary memory resource. To create
ADM COPP only for audio playback/capture case, management logic
is moved to pcm routing driver which has information about session
ID of MultiMedia streams and state of audio back-ends. With this
information, pcm routing driver decides to start/stop ADM COPP.
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Auxiliary PCM Interface is external PCM interface on msm that
can be used instead of internal codec as a way to connect an
external codec to the msm.
Enable support for AUX PCM. Current setting on PCM interface is,
2.048 MHz bit clock, mono stream, 8Khz sample rate, with MSM in
master mode. AUX PCM uses GPIO's to interface with external
codec device.
Adds platform data for cpu dai since cpu dai needs to know
which clock on MSM to use, clock rate to use and other
configuration parameters.
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
Add support for soft volume and soft pause commands and
enable the features to avoid glitch or pop during volume
change and pause-resume sequence
Signed-off-by: Sriranjan Srikantam <cssrika@codeaurora.org>
To support the RTPorts Playback and Capture,new platform
driver msm-pcm-afe is added. Two FE's each for playback
and capture are added. Four BE's are added - two for each
port acting as playback and capture. Corresponding mixer
controls are also updated.
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Change voice routing controls to contain back-end DAI and front-end
DAI information.
CRs-fixed: 304889
Signed-off-by: Neema Shetty <nshetty@codeaurora.org>
Add support for soft volume command and enable it to avoid
noise during volume change sequence
CRs-fixed: 304164
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
ALSA currently supports a 16-bit register which contains
two 8-bit two's complement gain values.
This patch modifies the same callback functions as the
above register type to support an 8-bit two's complement
gain register.
Signed-off-by: Brad Rubin <brubin@codeaurora.org>
Because q6asm_write use mutex to protect the shared data, this API
should not be called from event handler. Instead, calling
q6asm_write_nolock interface.
CRs-fixed: 298006
Signed-off-by: Jay Wang <jaywang@codeaurora.org>
ALSA trigger function must be atomic. Therefore, removing the AFE APR
registering function to prepare since apr_register uses mutex
CRs-Fixed: 298122
Signed-off-by: Jay Wang <jaywang@codeaurora.org>
Device mute control is added which can mute the
respective dev_id to volume zero.
msm_device_mute() in user space will use this
control.
CRs-Fixed: 295399
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
This patch adds the OMAP4 ABE platform driver. This driver defines and
exports control for the DSP Frontend and Backend routing.
TODO: cleanup
Signed-off-by: Liam Girdwood <lrg@ti.com>
This allows the DSP core to call a beskope trigger() call
on DAIs and platforms that require it.
TODO: move into DSP patch series.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Allow DAI's to be hostless so that no PCM data is sent between DAI
and CPU. This allows for power savings as there is no DMA or CPU
interaction required.
TODO: we shouldn't need to allocate a PAGE for a dummy DMA buffer.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Allow some PCM devices to be hostless, i.e. there is no PCM data transferred
to or from the host CPU. This can be used to minimise power on systems since
the CPU can idle/sleep during the PCM device operation (e.g. a phone call
where the DAI is between a MODEM and DSP)
TODO: cleanup, look at adding a read/write blocker.
Singed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>