Commit graph

1074 commits

Author SHA1 Message Date
Patrick Lai
7d142e34bd ASoC: msm: flush if prior and current backends rate not matching
It is found that during device switch from one backend
with one sample rate to another backend with another sample rate,
the command to QDSP6 ADM which maps audio stream session to a
particular backend would not get carried out until pending
data of audio stream session from previous backend is either
read out or flushed. This scenario occurs when application
stops providing more buffers to retrieve captured data.
Remedy is to flush upon detection of rate mismatching

Change-Id: I2c01c036d9bb71f938a6795337f08948bd986553
CRs-fixed: 422205
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
2018-08-27 14:52:45 +00:00
Artem Borisov
d7992e6feb Merge remote-tracking branch 'stable/linux-3.4.y' into lineage-15.1
All bluetooth-related changes were omitted because of our ancient incompatible bt stack.

Change-Id: I96440b7be9342a9c1adc9476066272b827776e64
2017-12-27 17:13:15 +03:00
Lars-Peter Clausen
602366ce81 ALSA: Remove transfer_ack_{begin,end} callbacks from struct snd_pcm_runtime
While there is nothing wrong with the transfer_ack_begin and
transfer_ack_end callbacks per-se, the last documented user was part of the
alsa-driver 0.5.12a package, which was released 14 years ago and even
predates the upstream integration of the ALSA core and has subsequently
been superseded by newer alsa-driver releases.

This seems to indicate that there is no need for having these callbacks and
they are just cruft that can be removed.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
(cherry picked from commit 53e597b1d194910bef53ed0632da329fef497904)

Change-Id: Ifa69c873640b171aa1843335b2b3cb856d29bb1a
2017-03-07 05:44:05 +00:00
Charles Keepax
b5fb46e134 ASoC: wm8904: Correct number of EQ registers
commit 97aff2c03a1e4d343266adadb52313613efb027f upstream.

There are 24 EQ registers not 25, I suspect this bug came about because
the registers start at EQ1 not zero. The bug is relatively harmless as
the extra register written is an unused one.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Zefan Li <lizefan@huawei.com>
2016-04-27 18:55:28 +08:00
Clemens Ladisch
ba8a85ef4d ALSA: tlv: add DECLARE_TLV_DB_RANGE()
commit bf1d1c9b61 upstream.

Add a DECLARE_TLV_DB_RANGE() macro so that dB range information
can be specified without having to count the items manually for
TLV_DB_RANGE_HEAD().

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Zefan Li <lizefan@huawei.com>
2016-03-21 09:17:58 +08:00
Clemens Ladisch
320f830334 ALSA: tlv: compute TLV_*_ITEM lengths automatically
commit b5b9eb5467 upstream.

Add helper macros with a little bit of preprocessor magic to
automatically compute the length of a TLV item.  This lets us avoid
having to compute this by hand, and will allow to use items that do
not use a fixed length.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Zefan Li <lizefan@huawei.com>
2016-03-21 09:17:58 +08:00
Peter Zubaj
9ae0519728 ALSA: emu10k1: Emu10k2 32 bit DMA mode
commit 7241ea558c6715501e777396b5fc312c372e11d9 upstream.

Looks like audigy emu10k2 (probably emu10k1 - sb live too) support two
modes for DMA. Second mode is useful for 64 bit os with more then 2 GB
of ram (fixes problems with big soundfont loading)

1) 32MB from 2 GB address space using 8192 pages (used now as default)
2) 16MB from 4 GB address space using 4096 pages

Mode is set using HCFG_EXPANDED_MEM flag in HCFG register.
Also format of emu10k2 page table is then different.

Signed-off-by: Peter Zubaj <pzubaj@marticonet.sk>
Tested-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Zefan Li <lizefan@huawei.com>
2015-09-18 09:20:34 +08:00
Takashi Iwai
574b59db65 ALSA: ak411x: Fix stall in work callback
commit 4161b4505f1690358ac0a9ee59845a7887336b21 upstream.

When ak4114 work calls its callback and the callback invokes
ak4114_reinit(), it stalls due to flush_delayed_work().  For avoiding
this, control the reentrance by introducing a refcount.  Also
flush_delayed_work() is replaced with cancel_delayed_work_sync().

The exactly same bug is present in ak4113.c and fixed as well.

Reported-by: Pavel Hofman <pavel.hofman@ivitera.com>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Tested-by: Pavel Hofman <pavel.hofman@ivitera.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
[lizf: Backported to 3.4: snd_ak4113_reinit() and snd_ak4114_reinit()
used flush_delayed_work_sync() instead of flush_delayed_work()]
Signed-off-by: Zefan Li <lizefan@huawei.com>
2015-04-14 17:33:59 +08:00
Lars-Peter Clausen
e4036860a7 ALSA: control: Protect user controls against concurrent access
commit 07f4d9d74a upstream.

The user-control put and get handlers as well as the tlv do not protect against
concurrent access from multiple threads. Since the state of the control is not
updated atomically it is possible that either two write operations or a write
and a read operation race against each other. Both can lead to arbitrary memory
disclosure. This patch introduces a new lock that protects user-controls from
concurrent access. Since applications typically access controls sequentially
than in parallel a single lock per card should be fine.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-26 15:10:29 -04:00
Stefano Panella
50a715f272 ALSA: memalloc.h - fix wrong truncation of dma_addr_t
commit 932e9dec38 upstream.

When running a 32bit kernel the hda_intel driver is still reporting
a 64bit dma_mask if the HW supports it.

From sound/pci/hda/hda_intel.c:

        /* allow 64bit DMA address if supported by H/W */
        if ((gcap & ICH6_GCAP_64OK) && !pci_set_dma_mask(pci, DMA_BIT_MASK(64)))
                pci_set_consistent_dma_mask(pci, DMA_BIT_MASK(64));
        else {
                pci_set_dma_mask(pci, DMA_BIT_MASK(32));
                pci_set_consistent_dma_mask(pci, DMA_BIT_MASK(32));
        }

which means when there is a call to dma_alloc_coherent from
snd_malloc_dev_pages a machine address bigger than 32bit can be returned.
This can be true in particular if running  the 32bit kernel as a pv dom0
under the Xen Hypervisor or PAE on bare metal.

The problem is that when calling setup_bdle to program the BLE the
dma_addr_t returned from the dma_alloc_coherent is wrongly truncated
from snd_sgbuf_get_addr if running a 32bit kernel:

static inline dma_addr_t snd_sgbuf_get_addr(struct snd_dma_buffer *dmab,
                                           size_t offset)
{
        struct snd_sg_buf *sgbuf = dmab->private_data;
        dma_addr_t addr = sgbuf->table[offset >> PAGE_SHIFT].addr;
        addr &= PAGE_MASK;
        return addr + offset % PAGE_SIZE;
}

where PAGE_MASK in a 32bit kernel is zeroing the upper 32bit af addr.

Without this patch the HW will fetch the 32bit truncated address,
which is not the one obtained from dma_alloc_coherent and will result
to a non working audio but can corrupt host memory at a random location.

The current patch apply to v3.13-rc3-74-g6c843f5

Signed-off-by: Stefano Panella <stefano.panella@citrix.com>
Reviewed-by: Frediano Ziglio <frediano.ziglio@citrix.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-20 07:34:19 -08:00
Vinod Koul
e03f92da05 ASoC: add definations for compressed operations
Here we update the asoc structures to add compress stream definations
First the struct snd_soc_dai_driver adds a new member to indicate if the dai is
compressed or pcm. Next we add a new structre the struct snd_soc_compr_ops in
the struct snd_soc_dai_link. This is to be used for machine driver to perform
any opertaions required for setting up compressed audio streams

next is the compressed data operations, they are added using struct
snd_compr_ops in the struct snd_soc_platform_driver.

Signed-off-by: Namarta Kohli <namartax.kohli@intel.com>
Signed-off-by: Ramesh Babu K V <ramesh.babu@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-18 16:08:45 -07:00
Jeeja KP
0b74be8050 ALSA: compress: add support for gapless playback
this add new API for sound compress to support gapless playback.
As noted in Documentation change, we add API to send metadata of encoder and
padding delay to DSP. Also add API for indicating EOF and switching to
subsequent track

Also bump the compress API version

Conflicts:
	include/uapi/sound/compress_offload.h

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18 16:08:45 -07:00
Vinod Koul
42dac55493 ALSA: Compress - add codec parameter checks
Conflicts:
	include/sound/compress_params.h

Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18 16:08:44 -07:00
Amal Paul
ed056a5a55 ASoC: msm: qdsp6: Add support to configure ISO and ARIB coefficients
Add support for configuring ISO or ARIB stereo mixing
coefficients. This change introduces a function with whichi,
AAC multi-channel driver can configure ISO or ARIB coefficients
according to configuration done by the client.

Change-Id: I72b74033532a276fa3bc1d305a04720ff6767409
Signed-off-by: Amal Paul <amal@codeaurora.org>
2013-03-15 17:09:03 -07:00
Patrick Lai
c58e2f4bb2 ASoC: msm: avoid negative time stamp check
Time stamp is unsigned. There is no need to check for
negative value.

Change-Id: I15e380f81e46908f6a9fe8d29c174de1b7c33173
CRs-fixed: 423372
Signed-off-by: Patrick Lai <plai@codeaurora.org>
2013-03-15 17:08:28 -07:00
Duy Truong
04e554807c Update copyright to The Linux Foundation
Change-Id: Ibead64ce2e901dede2ddd1b86088b88f2350ce92
Signed-off-by: Duy Truong <dtruong@codeaurora.org>
2013-03-15 17:07:39 -07:00
Santosh Mardi
dec3f44a64 ASoC: core: Update ALSA core to issue restart in underrun.
When compressed and pcm session is started the buffer pull will
Be from the DSP, in mmap mode for the scenario Hardware pointer
Is same as application pointer implies application has not filled the
Buffer to be send to DSP, and platform driver has to break and restart
The de queue process when the application has sufficient buffers.

When hardware pointer is same as application pointer it is an under run
Scenario where the ALSA framework has to trigger the under run and in HAL
The session has to re-prepare and re-triggered. based on the stop
Threshold, but in our system the stop threshold is INT_MAX which
Indicates that under run is not triggered in practical cases.

We have a brodcast usecase in which the mentioned under run case
Is hit mulitple times, and every time re-prepare and re-trigger will be
Expensive

Update the ASoC core framework to restart de queue process stopped
By platform Driver when the under run is hit, based on the available
Buffer and render flag, so the System will recover from the hang state.

To restart de queue process the ASoC core will be calling the restart
Callback registered by platform driver and this callback will be running in
Atomic context.

Change-Id: Ic9ea05a0dc6246346e9913493232882e2f5447d1
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
2013-03-07 15:21:54 -08:00
Ajit Khare
9ebff212cd ASoc: msm: Add amr-wb/wb+ tunnel playback support
Update compress audio platform driver
to support amr-wb/wb+ tunnel mode playback.

Change-Id: I98d087db490441c57c8e2d4fe03a7e91b28e67fc
Signed-off-by: Ajit Khare <ajitk@codeaurora.org>
2013-03-07 15:21:29 -08:00
Phani Kumar Uppalapati
3fb13a4e2c ASoC: msm8974: fall back to have AFE port started at prepare
After upgrading to kernel 3.4, there is 5 second delay
at the closing of PCM playback. The delay is due to missing
EOS from QDSP6 audio session manager causing pcm close function
of PCM platform driver to wait for 5 seconds. The root cause
for missing EOS is that ALSA dynmic PCM shutdown sequence has
changed. Now, trigger stop is called on the back-end DAI-LINK.
Furthermore, back-end trigger stop is called before front-end
trigger stop. Since sink stops rendering data, data at source
will never get consumed. EOS event will not arrive. As trigger
operation has to be atomic, it is very difficult to guarantee
sequence on shutting down various modules in QDSP6. The decision
is to abandon starting and stopping QDSP6 AFE port in trigger
function. This decision is considered acceptable as playback
and capture over SLIMBUS is no longer subject to strict sequence
which Q6 AFE port must be started after CODEC configuration.

Change-Id: Ief351168b08d5cca0a76405834cf3d6aa14a3941
Signed-off-by: Phani Kumar Uppalapati <phanik@codeaurora.org>
2013-03-07 15:21:28 -08:00
Bhalchandra Gajare
224a365720 ALSA: Extend sound jack to support upto 8 key events.
ALSA sound jack currently only supports upto 6 key events on a single
jack. Extend sound jack to support upto 8 buttons

CRs-fixed: 390846
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
(cherry picked from commit 33cca1e3db8b961f898daa776b99621def9219d6)
(cherry picked from commit c012ad9fb0a819842ecd7ff672c19bbe17bf2f82)

Change-Id: I33a46404b67b83721afde56b45defb40b529391a
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
2013-03-07 15:18:06 -08:00
Subhash Chandra Bose Naripeddy
e38c24e617 ASoC: msm: update opcode of read compressed interface.
For compressed AC3 and DTS in HDMI Input use case, new read
compressed interface is added. The opcode changed in the release
builds. Hence, update the opcode for the same.

Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
(cherry picked from commit 9b2180d23ea2e9a22f66f4358f26a282165fea29)
(cherry picked from commit 4787039a3acadacf384a919c4c5f5b8f4d586b05)

Change-Id: I69cc1675405665b5432f75102678fafd0d90c344
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
2013-03-07 15:18:05 -08:00
Mitchel Humpherys
f3f2186813 ASoC: msm: include msm-specific ion header.
All msm_ion clients need to use <linux/msm_ion.h> instead of
<linux/ion.h>

 Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
(cherry picked from commit 71a6ac9d4fc5e88efd57c2077caaff34afa36603)
(cherry picked from commit 353fac8a22a0253e990c745232d45586adb0defb)

Change-Id: I26165047d3361802ff3957b54a645544a8e9c3b5
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
2013-03-07 15:17:54 -08:00
ehgrace.kim
45717e0a26 audio : enable tpa2028d
Change-Id: Id35a8bf66b1b730d32d1d8cbc68cd3d7f607e72e
2013-03-04 09:11:49 -08:00
Jayasena Sangaraboina
978b65ca45 ASoc: msm: Add low latency playback and recording support.
- Add lowlatency pcm driver for Playback and Recording.
- Add support in target board files
- Add Recording Path to Multimedia5 FE DAI
- Add support in routing, platform, machine drivers
- Add low latency interfaces support in ASM and ADM drivers.

Change-Id: I1beb11db9010534e5aa91179ac6040a41622185d
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
2013-02-27 18:21:33 -08:00
Joonwoo Park
1238a07489 msm: q6dspv2: Add slimbus data path support
Register slimbus CPU dai link to support slimbus data path.

Change-Id: I3584306ac1e0ad6561a19cecfe71f2a63aadafa9
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
2013-02-27 18:17:57 -08:00
Subhash Chandra Bose Naripeddy
d7f5276687 ASoC: msm: Add support for meta data in compressed TX
There is a usecase where compressed data is sent over HDMI IN to
ADSP. The format of compressed is detected in ADSP and sent through
the meta data to compressed driver. Add support for meta data in
compressed TX for this use case.

Change-Id: Idbb18fe4a0ad828e9c2e9d7beec048b3cedf002d
Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
2013-02-27 18:16:45 -08:00
Patrick Lai
c24665621d ASoC: msm: qdsp6: set correct SET_PARAM payload size
QDSP6 AFE module produces error message whenever afe
loopback gain control command is issued. The reason is that
loopback gain control function sets wrong payload size.
Make change to set appropriate payload size for a given
SET_PARAM command

Change-Id: Ida2bf76baf56c35e89fe29f887f5b43af8bceabe
Signed-off-by: Patrick Lai <plai@codeaurora.org>
2013-02-27 18:16:42 -08:00
Jay Wang
79a415c76b ASoC: msm: qdsp6: Fixed the issue unmap command is sent incorrectly
When session CLOSE command is sent right before session RUN command
is acknowledged, callback function can mistakenly think that
the next received acknowledgement is for CLOSE command instead of
RUN command. This triggers driver to send memory unmap command to
the Q6 while it is still processing the CLOSE command. Eventually,
this leads to an invalid memory access and causes Q6 crash.

Change-Id: Ib5d560fbcb7e8ced79cc1075a9f6bea3b55a86b6
CRs-Fixed: 377281
Signed-off-by: Jay Wang <jaywang@codeaurora.org>
2013-02-27 18:16:06 -08:00
Patrick Lai
99f526976d ASoC: msm: fall back to have AFE port started at prepare
After upgrading to kernel 3.4, there is 5 second delay
at the closing of PCM playback. The delay is due to missing
EOS from QDSP6 audio session manager causing pcm close function
of PCM platform driver to wait for 5 seconds. The root cause
for missing EOS is that ALSA dynmic PCM shutdown sequence has
changed. Now, trigger stop is called on the back-end DAI-LINK.
Furthermore, back-end trigger stop is called before front-end
trigger stop. Since sink stops rendering data, data at source
will never get consumed. EOS event will not arrive. As trigger
operation has to be atomic, it is very difficult to guarantee
sequence on shutting down various modules in QDSP6. The decision
is to abandon starting and stopping QDSP6 AFE port in trigger
function. This decision is considered acceptable as playback
and capture over SLIMBUS is no longer subject to strict sequence
which Q6 AFE port must be started after CODEC configuration.

Change-Id: I0cc1d8b7d058052d7fae55c84b6be46b5b0678e9
CRs-fixed: 373966
Signed-off-by: Patrick Lai <plai@codeaurora.org>
2013-02-27 18:15:19 -08:00
Srikanth Uyyala
63a739c278 ASoC: msm: Support for non-DTS Q6 image
If Q6 does not support DTS, LA driver has to exit gracefully.
Introducing a new member cmd_response in audio_client structure
to indicate format is supported or not, and use this cmd_response
to return error from open_write.

Change-Id: Icad30c787e8a5f26ead92584e163721b94ba509d
Signed-off-by: Srikanth Uyyala <suyyala@codeaurora.org>
2013-02-27 18:15:15 -08:00
Srikanth Uyyala
b157cf52c0 ASoC: msm: DTS playback support
Compressed driver changes for the DTS support

Change-Id: I595e638da78cced02142f4ee430afb7357eb336c
Signed-off-by: Srikanth Uyyala <suyyala@codeaurora.org>
2013-02-27 18:13:36 -08:00
Subhash Chandra Bose Naripeddy
1cd3eb87ac ASoC: msm: Add compressed TX support
There is use case that the HDMI input goes through MI2S
TX interface to ADSP. Add compressed TX support for
this use case.

Change-Id: I510e3e63b68ea1887e4c99ebf1c6f76112abbed5
Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
2013-02-27 18:13:35 -08:00
Jayasena Sangaraboina
6beeb66c9b ASoc: msm: Add support for audio recording with EC.
- Add Mixer controls for Reference Rx device to be
used as a endpoint2 in adm open for echo cancellation.
- Add logic to support echo cancellation for audio
recording with fluence topology.

Change-Id: I7b83c3fc1a19fef7826bc8c3671e2565e393566a
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
2013-02-27 18:13:18 -08:00
Aviral Gupta
77724b141f ASoC: msm: Update the encode option and sample rate.
Populate the sample rate, encode option in wma config params.

CRs-Fixed: 367243, 367242
Change-Id: Ieeb9d302454d3935faa51cac77021e7c1d77012c
Signed-off-by: Aviral Gupta <aviralg@codeaurora.org>
2013-02-27 18:12:59 -08:00
Harmandeep Singh
839ecb45c7 ASoc: msm: Add support for AAC and WMA decoders.
Add support for AAC and WMA decoders.

Change-Id: Iba66fdf71e852387015a0d03d0f1f9b5a0f09682
Signed-off-by: Harmandeep Singh <hsingh@codeaurora.org>
2013-02-27 18:12:51 -08:00
Santosh Mardi
387f28cf15 ASoC: msm: Add support for afe disconnect command
For compressed playback to bypass ADM, AFE connect command
Is used when the session is closed AFE disconnect command
Should be issued.

Add the support for AFE disconnect command.

Change-Id: I4cc4e867c1be36fbc2659520fd14a356c8405f7b
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
2013-02-27 18:12:37 -08:00
Helen Zeng
c7251a1675 ASoc: soc-pcm: Open/close share channel once if it is used by two streams
- During voice and normal recording concurrency case, both voice
and recording streams share the same tx channel. If one stream
already opens the tx channel, another stream will get error when
trying to open the same channel again. If one stream ends and closes
the channel, but another stream will lose the sound if it's still using
it.
- To prevent the above issues, only send SND_SOC_DAPM_STREAM_START event
when capture active count is one. And send SND_SOC_DAPM_STREAM_STOP event
when capture active count is zero.

Change-Id: Ic6dcd5d8d1949c2b96d46915a4399a454075fbb7
CRs-Fixed: 357022
Signed-off-by: Helen Zeng <xiaoyunz@codeaurora.org>
2013-02-27 18:12:17 -08:00
Patrick Lai
dcb77e20ae sound: Add MSM sound drivers
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
2013-02-25 11:41:24 -08:00
Gopikrishnaiah Anandan
e592653395 ASLA: sound: Add support for compressed formats
Change enables the compressed format ioctls for
ALSA driver clients.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:19 -08:00
Gopikrishnaiah Anandan
09ab9ae7ae ALSA: jack: Reduce delay in jack status notification
Change will bypass the dapm sync to report the jack status
with out delays.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:19 -08:00
Gopikrishnaiah Anandan
9a46cb4de9 ALSA: jack: update jack types
Change updates the jack types that will be supported
by the platform.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:18 -08:00
Gopikrishnaiah Anandan
2f22f117c5 ASoC: update the connected widgets functionality
ASoC core will scan for path, get the list of widgets
when playback and capture is started.When a mixer
command is issued it needs to scan only the path
to find if back end or front end dai needs to be shutdown.
Change ehances asoc core path finding functionality
to provide support for different usecases.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:16 -08:00
Gopikrishnaiah Anandan
fffcf82ba1 ASoC: Update alsa mixer/mux controls
Change updates the way mux and mixer controls
are registered with the Alsa core.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:15 -08:00
Gopikrishnaiah Anandan
30f8dcc8f1 ASoC: Update dapm widget power up and down sequence
Change the wigdet power up and power down sequnce
in the ASOC as per msm platform requirements.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:14 -08:00
Gopikrishnaiah Anandan
4fc0520f41 ALSA: core: Query Dai RX and TX channel information
When hardware params are set for the session alsa
core will query for the RX/TX channels for the
current back end dai.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:13 -08:00
Gopikrishnaiah Anandan
0de64fbea0 ASoC: pcm: Add support for Hostless pcm
Hostless PCM nodes will not exchange data with
the userspace clients.Control paths will
be setup by userspace clients.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:11 -08:00
Gopikrishnaiah Anandan
1f42244c54 ASoC: dpcm: Add Dynamic PCM core operations.
The Dynamic PCM core allows digital audio data to be dynamically
routed between different ALSA PCMs and DAI links on SoC CPUs with
on chip DSP devices. e.g. audio data could be played on pcm:0,0 and
routed to any (or all) SoC DAI links.

Dynamic PCM introduces the concept of Front End (FE) PCMs and Back
End (BE) PCMs. The FE PCMs are normal ALSA PCM devices except that
they can dynamically route digital audio data to any supported BE
PCM. A BE PCM has no ALSA device, but represents a DAI link and it's
substream and audio HW parameters.

Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
2013-02-25 11:41:10 -08:00
Gopikrishnaiah Anandan
9e3cd79005 ASoC: pcm: Create PCM streams for ASOC backend
Change creates a PCM stream for ASOC backend which will only be used
internally by kernel drivers.It provides existing ASoC components
drivers with a substream and access to any private data.
2013-02-25 11:41:09 -08:00
Takashi Iwai
41a496238d ALSA: Add a reference counter to card instance
commit a0830dbd4e upstream.

For more strict protection for wild disconnections, a refcount is
introduced to the card instance, and let it up/down when an object is
referred via snd_lookup_*() in the open ops.

The free-after-last-close check is also changed to check this refcount
instead of the empty list, too.

Reported-by: Matthieu CASTET <matthieu.castet@parrot.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-11-17 13:16:13 -08:00
Fengguang Wu
fae3d88a5c ALSA: hda - hide HDMI/ELD printks unless snd.debug=2
Also remove two warnings when CONFIG_SND_DEBUG is not set:

sound/pci/hda/patch_hdmi.c: In function ‘hdmi_intrinsic_event’:
sound/pci/hda/patch_hdmi.c:761:6: warning: unused variable ‘eldv’ [-Wunused-variable]
sound/pci/hda/patch_hdmi.c:760:6: warning: unused variable ‘pd’ [-Wunused-variable]

Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-04-10 14:53:55 +02:00