Commit Graph

6545 Commits

Author SHA1 Message Date
Mark Brown f6f629f833 ASoC: wm5102: Correct lookup of arizona struct in SYSCLK event
Reported-by: Ryo Tsutsui <Ryo.Tsutsui@wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2013-04-09 17:50:55 +01:00
Alban Bedel f1ca493b0b ASoC: wm8903: Fix the bypass to HP/LINEOUT when no DAC or ADC is running
The Charge Pump needs the DSP clock to work properly, without it the
bypass to HP/LINEOUT is not working properly. This requirement is not
mentioned in the datasheet but has been confirmed by Mark Brown from
Wolfson.

Signed-off-by: Alban Bedel <alban.bedel@avionic-design.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2013-04-09 17:43:48 +01:00
Arnd Bergmann 71f6424023 Merge branch 'mxs/cleanup' into next/multiplatform
This is a dependency for mxs/multiplatform

Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Conflicts:
	drivers/clocksource/Makefile
2013-04-09 16:02:14 +02:00
Mark Brown da445afe35 ASoC: wm8994: Remove duplicate revision cache
There's already a device revision stored in the core data structure,
don't duplicate it in the CODEC driver.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-09 12:15:35 +01:00
Paul Bolle 4f88eff834 ASoC: Ux500: remove test for undefined Kconfig macro
A test for CONFIG_SND_SOC_UX500_AB5500 was added in v3.5. But there
never was a corresponding Kconfig symbol so this test has always
evaluated to true. And since AB5500 support was removed in v3.5 it
appears safe to remove this test and a few lines of code.

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-08 13:44:32 +01:00
Linus Walleij 174e779662 ARM: ux500: get rid of <mach/[hardware|db8500-regs].h>
This removes <mach/hardware.h> and <mach/db8500-regs.h>
from the Ux500, merging them into the local include
"db8500-regs.h" in mach-ux500. There is some impact
outside the ux500 machine, but most of it is dealt with
in earlier patches.

Contains portions of a clean-up patch from Arnd Bergmann.

Cc: Samuel Ortiz <sameo@linux.intel.com>
Cc: Ulf Hansson <ulf.hansson@linaro.org>
Acked-by: Mike Turquette <mturquette@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-04-08 13:59:28 +02:00
Arnd Bergmann ab0fc6ce48 ARM: ux500: move mach/msp.h to <linux/platform_data/*>
This header file only contains platform data structure definitions,
so it's straightforward to move.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
[Delete one include rather than move it]
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-04-08 13:59:22 +02:00
Lars-Peter Clausen 69b6f19622 ASoC: ux500_pcm: Use the same snd_pcm_hardware for playback and capture
The snd_pcm_hardware structs for playback and capture in the ux500 PCM are
identical, so remove one of them and use the same snd_pcm_hardware struct for
both playback and capture. Also move the defines used to initialize the
snd_pcm_hardware fields from ux500_pcm.h to ux500_pcm.c since that's the only
place where they are used.

Also drop the assignment of the snd_pcm_hardware struct to runtime->hw since
that is what the call to snd_soc_set_runtime_hwparams() right above it already
does, so the second assignment is redundant.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-07 19:51:05 +01:00
Yegor Yefremov f5023af65a ASoC: davinci-mcasp: don't overwrite DIT settings
Channel size settings will be made at the end of
davinci_mcasp_hw_params() routine and thus overwrite frame
format settings made for DIT mode. This patch fixes this issue
by taking op_mode into account. Tested with official PSP 3.2
kernel and sii9022a HDMI transmitter.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
Tested-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-05 11:27:13 +01:00
Yegor Yefremov 2dda75e07d ASoC: davinci-mcasp: don't configure AFSX direction in DIT mode
AFSX won't be used in DIT mode. The related pins are AHCLKX and
the data pins.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
Acked-by: Vaibhav Bedia <vaibhav.bedia@ti.com>
Tested-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-05 11:27:09 +01:00
Lars-Peter Clausen e6451c3ff8 ASoC: ep93xx_pcm: Fix compile error
Commit 453807f3 ("ASoC: ep93xx: Use ep93xx_dma_params instead of
ep93xx_pcm_dma_params") introduced a small compile error by not updating the
name of the 'dma_port' field to 'port'. This patch fixes it.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-05 11:26:16 +01:00
Lars-Peter Clausen a8909c9bc5 ASoC: fsl: Use common DAI DMA data struct
Use the common DAI DMA data struct for fsl/imx, this allows us to use the common
helper function to configure the DMA slave config based on the DAI DMA data.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-05 11:25:47 +01:00
Mark Brown 89cab4624a ASoC: core: Merge Samsung fixes to avoid trivial context conflict
Merge branch 'fix/samsung' of
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into
asoc-component to resolve trivial conflict

Conflicts:
	sound/soc/samsung/i2s.c
2013-04-03 18:22:51 +01:00
Mark Brown a7c1a644e1 Merge branch 'fix/samsung' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-samsung 2013-04-03 18:15:57 +01:00
Lars-Peter Clausen 3489d5067a ASoC: tegra: Use common DAI DMA data struct
Use the common DAI DMA data struct for tegra, this allows us to use the common
helper function to configure the DMA slave config based on the DAI DMA data.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 18:13:34 +01:00
Lars-Peter Clausen 09ae3aaf3c ASoC: omap: Use common DAI DMA data
Use the common DAI DMA data struct for omap, this allows us to use the common
helper function to configure the DMA slave config based on the DAI DMA data.

For omap-dmic and omap-mcpdm also move the DMA data from a global variable to
the driver state struct.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 18:12:58 +01:00
Mark Brown 2735e6cd2b Merge branch 'topic/omap' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into HEAD 2013-04-03 18:12:53 +01:00
Lars-Peter Clausen 85c9f9c5f9 ASoC: dmaengine-pcm: Add a common DAI DMA data struct
This patch adds a common DMA data struct which can be used by DAI drivers to
communicate their DMA configuration requirements to the DMA pcm driver.  Having
a common data structure for this allows us to implement common functions on top
of them, which can be used by multiple platforms.

This patch also introduces a new function to initialize certain fields of a
dma_slave_config struct from the common DAI DMA data struct.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 18:12:33 +01:00
Lars-Peter Clausen 5fa70f71db ASoC: dmaengine_pcm: Setup device_fc in snd_hwparams_to_dma_slave_config
Usually device_fc should be set to false for audio DMAs. Initialize it in a
common place so drivers don't have to do this manually.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 18:12:27 +01:00
Lars-Peter Clausen 5aa995e83a ASoC: tegra: Don't claim to support PCM pause and resume
The tegra dmaengine driver does not support pausing and resuming a DMA stream.
The tegra PCM driver still claims to support pause and resume though and
implements them by stopping and restarting the stream. This is not what an
application using pause/resume would expect. Usually applications have support
for working around PCMs which do not support suspend and resume, so don't set
the SNDRV_PCM_INFO_PAUSE and SNDRV_PCM_INFO_RESUME flags for the tegra PCM and
use the default snd_dmaengine_pcm_trigger callback.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 18:11:08 +01:00
Prathyush K c6f9b1eb0e ASoC: Samsung: set drvdata before adding secondary device
Currently, a new platform device is created for secondary device
by calling platform_device_register_resndata and then the drvdata
is set for this device.

The following patch has been added to driver core:
"driver core: fix possible missing of device probe".

This results in the added device getting probed immediately but
the drvdata for the secondary device is not yet set.
This patch removes the platform_device_register_resndata call and
instead calls platform_device_alloc, platform_set_drvdata and
platform_device_add which fixes the above issue.

Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Signed-off-by: Padmavathi Venna <padma.v@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 17:56:44 +01:00
Prathyush K a9b977ecd3 ASoC: Samsung: return error if drvdata is not set
This patch fixes a possible crash in case drvdata for the secondary
device is not set.

Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Signed-off-by: Padmavathi Venna <padma.v@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-03 17:56:43 +01:00
Paul Bolle 379cf39781 ASoC: codecs: remove hidden prompt
The Kconfig symbol SND_SOC_OF_SIMPLE got removed in commit
f0fba2ad1b ("ASoC: multi-component - ASoC
Multi-Component Support"). But that commit missed one instance. Remove
it now, together with the prompt it has effectively hidden ever since.

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-01 22:20:54 +01:00
Ryo Tsutsui 1059ecfa0f ASoC: dapm: Only clear paths we've walked
When clearing the walked flags there is no need to clear all paths, we
only need to clear the paths we actually walked. This means we can split
dapm_clear_walk() into input and output versions and rather than going
through all DAPM paths we can recurse down the path until we encounter
paths we have not yet walked.

This reduces the number of operations we need to perform and improves
cache locality.

[Pulled out of the vendor tree that the patch was originally generated
for by me, any bugs were introduced in that process -- broonie]

Signed-off-by: Ryo Tsutsui <Ryo.Tsutsui@wolfsonmicro.com>
Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-01 22:10:20 +01:00
Ryo Tsutsui 0e669246dc ASoC: dapm: Remove redundant clear_walk() for supply widgets
We already clear the walked state in dapm_widget_power_check(), no need
to do it again.

Signed-off-by: Ryo Tsutsui <Ryo.Tsutsui@wolfsonmicro.com>
Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-01 22:10:01 +01:00
Shawn Guo 114fe75def ASoC: mxs-saif: remove mach header inclusion
The header <mach/hardware.h> is not needed at all, and <mach/mxs.h> is
needed only for macros MXS_SET_ADDR and MXS_CLR_ADDR.  Define the macros
and remove the mach header inclusions.

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-01 20:41:59 +08:00
Stephen Warren 85762e71f1 ASoC: dapm: Implement mixer control sharing
This is the equivalent of commit af46800 "ASoC: Implement mux control
sharing", but applied to mixers instead of muxes.

This allows a single control to affect multiple mixer widgets at once,
which is useful when there is a single set of register bits that affects
multiple mixers in HW, for example both the L and R mixers of a stereo
path.

Without this, you either:

1) End up with multiple controls that affect the same register bits, but
whose DAPM state falls out of sync with HW, since the DAPM state is only
updated for the specific control that is modified, and not for other
paths that are affected by the register bit(s).

2) False paths through DAPM, since you end up merging unconnected stereo
paths together into a single widget which hosts the single control, and
then branching back out again, thus conjoining the enable states of the
two input paths.

Now that the kcontrol creation logic is split out into a separate
function, dapm_create_or_share_mixmux_kcontrol(), also use that to
replace most of the body of dapm_new_mux(). This should produce no
functional change, but simply eliminates some mostly duplicated code.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-31 13:28:40 +01:00
Vinod Koul 0cd5751ab3 ASoC: mid-x86 - add support for meaadata apis
while at it, update the copyright timeline too

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-29 21:08:32 +00:00
Mark Brown b6ed61cfa2 ASoC: wm_adsp: Split ADSP1 and ADSP2 firmware controls
Now that we have regular register mapped controls we should be splitting
the control sets for ADSP1 and ADSP2 as the register maps are not
identical. Do that.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-29 18:00:24 +00:00
Mark Brown dd84f9259b ASoC: wm_adsp: Provide defines for firmwares
For future work to have specific handling for some firmwares.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-29 17:58:02 +00:00
Mark Brown 939dc51bdd ASoC: wm2000: Expose some more registers for diagnostics
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-29 13:08:03 +00:00
Charles Keepax 3e112af51e ASoC: wm0010: Report filename when we fail to load firmware
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-29 10:52:09 +00:00
Charles Keepax 961b0fc840 ASoC: wm0010: Constify usage of firmware filenames
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-29 10:52:08 +00:00
Charles Keepax fa40ef208c ASoC: compress: Cancel delayed power down if needed
When a new stream is being opened it is necessary to cancel any delayed
power down of the audio.

[Fixed unused variable -- broonie]

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-28 00:23:56 +00:00
Charles Keepax a96f5e9394 ASoC: wm5102: Correctly use SOC_VALUE_ENUM for ISRC FSL controls
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-27 23:17:34 +00:00
Lars-Peter Clausen d79e57db84 ASoC: Constify the 'driver' field of snd_soc_platform
The ASoC core does no not modify the driver of a platform. Making it const
allows ASoC platform drivers to declare the snd_soc_platform_driver struct as
const.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-27 23:08:35 +00:00
Mark Brown 658e6101d0 ASoC: wm5102: Implement OSR support
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-27 15:40:04 +00:00
Paul Bolle dc7bd34571 sound: Remove stray pluses from Kconfig file
Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2013-03-27 13:47:15 +01:00
Stephen Warren 2e1cc199fc ASoC: export snd_soc_register_component
Without this, modules will fail to link against those symbols.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 22:52:26 +00:00
Kuninori Morimoto 0a09dfa041 ASoC: switch over to use snd_soc_register_component() on sh4 siu
siu_dai.c is using snd_soc_register_dais(),
even though array size of siu_i2s_dai is 1.
OTOH, new API snd_soc_register_component() uses properly
snd_soc_register_dai()  (henceforth dai()) or
snd_soc_register_dais() (henceforth dais()) via num_dai.
Then, cpu_dai_name will be "siu-i2s-dai" if dais() was used,
and it will be "siu-pcm-audio" if dai() was used.
Therefore this patch fixup migor_dai :: cpu_dai_name too.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:55 +00:00
Kuninori Morimoto f53179c026 ASoC: snd_soc_[un]register_dai[s]() become non global function
All drivers are using snd_soc_register_component()
instead of snd_soc_register_dai[s]()
snd_soc_[un]register_dai[s]() are no longer needed

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:54 +00:00
Kuninori Morimoto 42277bddc6 ASoC: switch over to use snd_soc_register_component() on ux500 msp
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:52 +00:00
Kuninori Morimoto b00e2fa1ab ASoC: switch over to use snd_soc_register_component() on txx9aclc ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:51 +00:00
Kuninori Morimoto a413a3c282 ASoC: switch over to use snd_soc_register_component() on tegra20 i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:51 +00:00
Kuninori Morimoto 359e2cb749 ASoC: switch over to use snd_soc_register_component() on tegra20 ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:50 +00:00
Kuninori Morimoto 094e1a3d7d ASoC: switch over to use snd_soc_register_component() on tegra20 spdif
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:49 +00:00
Kuninori Morimoto 65328454fb ASoC: switch over to use snd_soc_register_component() on tegra30 i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:48 +00:00
Kuninori Morimoto 669b497674 ASoC: switch over to use snd_soc_register_component() on spear spdif in
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:46 +00:00
Kuninori Morimoto a582d44b13 ASoC: switch over to use snd_soc_register_component() on spear spdif out
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:45 +00:00
Kuninori Morimoto 73d86d9808 ASoC: switch over to use snd_soc_register_component() on sh4 hac
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:44 +00:00
Kuninori Morimoto cd9003a200 ASoC: switch over to use snd_soc_register_component() on sh4 ssi
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:44 +00:00
Kuninori Morimoto 1dfec3954e ASoC: switch over to use snd_soc_register_component() on goni_wm8994
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:42 +00:00
Kuninori Morimoto fc466ba3ee ASoC: switch over to use snd_soc_register_component() on samsung pcm
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:41 +00:00
Kuninori Morimoto 4b828535f7 ASoC: switch over to use snd_soc_register_component() on samsung i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:40 +00:00
Kuninori Morimoto c3764d8bb4 ASoC: switch over to use snd_soc_register_component() on samsung spdif
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:39 +00:00
Kuninori Morimoto 6d717f3ef5 ASoC: switch over to use snd_soc_register_component() on s3c ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:37 +00:00
Kuninori Morimoto eca3b01d08 ASoC: switch over to use snd_soc_register_component() on s3c i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:31 +00:00
Kuninori Morimoto 5642ddff27 ASoC: switch over to use snd_soc_register_component() on s3c24xx i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:30 +00:00
Kuninori Morimoto cd5e4d0b2f ASoC: switch over to use snd_soc_register_component() on s6000 i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:30 +00:00
Kuninori Morimoto 425f370894 ASoC: switch over to use snd_soc_register_component() on mmp sspa
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:29 +00:00
Kuninori Morimoto bccf7d8bf9 ASoC: switch over to use snd_soc_register_component() on pxa2xx i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:28 +00:00
Kuninori Morimoto ad53232c1f ASoC: switch over to use snd_soc_register_component() on pxa2xx ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:28 +00:00
Kuninori Morimoto e580f1ced9 ASoC: switch over to use snd_soc_register_component() on pxa ssp
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:27 +00:00
Kuninori Morimoto 0ba7f849ec ASoC: switch over to use snd_soc_register_component() on omap hdmi
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:26 +00:00
Kuninori Morimoto ed22853a5b ASoC: switch over to use snd_soc_register_component() on omap dmic
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:24 +00:00
Kuninori Morimoto 58709a329e ASoC: switch over to use snd_soc_register_component() on omap mcpdm
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:23 +00:00
Kuninori Morimoto 43cd814a73 ASoC: switch over to use snd_soc_register_component() on omap mcbsp
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:22 +00:00
Kuninori Morimoto 7fc34cc3f3 ASoC: switch over to use snd_soc_register_component() on nuc900 ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:22 +00:00
Kuninori Morimoto 026240bb15 ASoC: switch over to use snd_soc_register_component() on mxs saif
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:21 +00:00
Kuninori Morimoto b1c3686131 ASoC: switch over to use snd_soc_register_component() on sst
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:20 +00:00
Kuninori Morimoto 83d85f53ad ASoC: switch over to use snd_soc_register_component() on kirkwood i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:19 +00:00
Kuninori Morimoto 29cc15cfd2 ASoC: switch over to use snd_soc_register_component() on jz4740 i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:57:12 +00:00
Kuninori Morimoto c22fd5ef0f ASoC: switch over to use snd_soc_register_component() on imx ssi
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:27 +00:00
Kuninori Morimoto 3580aa10fb ASoC: switch over to use snd_soc_register_component() on fsl ssi
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:26 +00:00
Kuninori Morimoto f200c02beb ASoC: switch over to use snd_soc_register_component() on mpc5200 i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:26 +00:00
Kuninori Morimoto ec05085170 ASoC: switch over to use snd_soc_register_component() on ep93xx i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:26 +00:00
Kuninori Morimoto 426c340853 ASoC: switch over to use snd_soc_register_component() on ep93xx ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:26 +00:00
Kuninori Morimoto 58309649b4 ASoC: switch over to use snd_soc_register_component() on bf5xx tdm
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:25 +00:00
Kuninori Morimoto b56733bd2b ASoC: switch over to use snd_soc_register_component() on bf5xx i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:25 +00:00
Kuninori Morimoto 514f6ac78b ASoC: switch over to use snd_soc_register_component() on bf5xx ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:24 +00:00
Kuninori Morimoto 3272c51bfa ASoC: switch over to use snd_soc_register_component() on bf6xx i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:24 +00:00
Kuninori Morimoto bbedf1b255 ASoC: switch over to use snd_soc_register_component() on au1x ac97c
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:24 +00:00
Kuninori Morimoto 4edf87f5f7 ASoC: switch over to use snd_soc_register_component() on au1x psc-i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:23 +00:00
Kuninori Morimoto a4ff200c00 ASoC: switch over to use snd_soc_register_component() on au1x psc-ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:23 +00:00
Kuninori Morimoto 8b1be63bdf ASoC: switch over to use snd_soc_register_component() on au1x i2sc
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:23 +00:00
Kuninori Morimoto a2c662c0e5 ASoC: switch over to use snd_soc_register_component() on atmel ssc
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:23 +00:00
Kuninori Morimoto f298a0ffa4 ASoC: switch over to use snd_soc_register_component() on mpc5200 ac97
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:22 +00:00
Kuninori Morimoto 92eaa328f2 ASoC: switch over to use snd_soc_register_component() on dw i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:22 +00:00
Kuninori Morimoto eeef0eda7a ASoC: switch over to use snd_soc_register_component() on davinci mcasp
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:22 +00:00
Kuninori Morimoto ee226ce195 ASoC: switch over to use snd_soc_register_component() on davinci vcif
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:22 +00:00
Kuninori Morimoto bfcb921caf ASoC: switch over to use snd_soc_register_component() on davinci i2s
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:21 +00:00
Kuninori Morimoto a1422b8cb4 ASoC: snd_soc_register_component() uses properly snd_soc_register_dai[s]()
snd_soc_register_dai()  uses fmt_single_name(), and
snd_soc_register_dais() uses fmt_multiple_name()
for dai->name which is used for name based matching.
This patch uses properly snd_soc_register_dai() it it was single driver,
and uses snd_register_dais() if it were multiple drivers.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 21:55:21 +00:00
Mark Brown 995f297298 Merge branch 'topic/pxa' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-component 2013-03-26 21:54:47 +00:00
Mark Brown 1a2c7d568f ASoC: arizona: Add delay after powering up line level outputs
Ensure that the outputs are fully enabled before we begin passing audio
through them.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 18:49:04 +00:00
Jeeja KP 36953d9814 ASoC: compress - add support for metadata apis
Compress core added metadata apis in 9727b4, so add same in ASoC

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 17:46:33 +00:00
Mark Brown 49bc389ec2 ASoC/extcon: arizona: Fix interaction between HPDET and headphone outputs
This patch series covers both ASoC and extcon subsystems and fixes an
 interaction between the HPDET function and the headphone outputs - we
 really shouldn't run HPDET while the headphone is active.  The first
 patch is a refactoring to make the extcon side easier.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.12 (GNU/Linux)
 
 iQIcBAABAgAGBQJRUcMYAAoJELSic+t+oim9PkAP/RQWC98LrD3kQgVk22MIDdyk
 P7dr37AePy+nMHP/sp3XIVyeD6pwuRWrlf31jAgMsXSb/+8ymJ3oO3t6aPUa9V9+
 KsxxoSUW+/ZO+88aK4r/w/Y45XMqMXsoEwllIxZoEpHXhDIxYFyF8wloPBXLzzbw
 AALowigrNbeYuijr5R1oV+kUOcT8DpzbamoK0jSbpdBdoPEP3ypD/yJTdi/RSyu/
 ELRNZFy4jUw2B3HVOB1YxUeCPpPA63u1oTypFgD7XrQX5v4MDuWyCv5bbBd7KhBk
 vbK/PHti5CMvi5RbA2EHbkI+n/Lb1qfnxIggN5BaSOQ1tlqrHnMlHYoSE/Sjterh
 TDGyYDNrWU1Wve2NTDJEd8oECPwm+8ABBnRYgwtnth/4D/EFkT+6Pv8FuIlYg1ku
 Tj/jwS2q/q26WfssDOph/GfUXtaagMALY99yy/HXM9RPYztOnUyvJIXLzKUUdapT
 KluChggzbj5ytsSy3L808BkgDxYTwHxva4q+n0ST4hDIeqe95HyE8gZA8jrYOf7T
 oA4tsBL3i0YGkPoPkVhMY9qeV0AOwDVlZioGP9Qcs8EI/Z9Bri8NZ4iW8VWkNoTt
 QG7EyuJy90VI/XvGgpITXKXxWQStMZG4+df6pXcn1h47K6ujtDyK/PBBt3t0OPCp
 WihSDHwuFQPSDWYULbZQ
 =gc7f
 -----END PGP SIGNATURE-----

Merge tag 'arizona-extcon-asoc' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/misc into asoc-arizona

ASoC/extcon: arizona: Fix interaction between HPDET and headphone outputs

This patch series covers both ASoC and extcon subsystems and fixes an
interaction between the HPDET function and the headphone outputs - we
really shouldn't run HPDET while the headphone is active.  The first
patch is a refactoring to make the extcon side easier.
2013-03-26 17:16:14 +00:00
Mark Brown f607e31ce3 ASoC: arizona: Fix interaction between headphone outputs and identification
Running HPDET while the headphone outputs are enabled can disrupt the
operation of HPDET. In order to avoid this HPDET needs to disable the
headphone outputs and ASoC needs to not enable them while HPDET is
running.

Do the ASoC side of this by storing the enable state in the core driver
structure and only writing to the device if a flag indicating that the
accessory detection side is in a state where it can have the headphone
output stage enabled.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 15:45:25 +00:00
Lars-Peter Clausen b1bd7f62cf ASoC: dmaengine-pcm: Remove snd_dmaengine_pcm_{set,get}_data
These functions were initially added to be able to support some oddball dma
drivers, but all users have been updated to deal with the situation without the
help of snd_dmaengine_pcm_{set,get}_data, so these two functions can be removed.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:18:01 +00:00
Lars-Peter Clausen b7e5e91210 ASoC: mxs: Embed the mxs_dma_data struct in the mxs_pcm_dma_params struct
Currently the mxs_dma_data struct, which gets passed to the dmaengine driver, is
allocated in the pcm driver's open callback. The mxs_dma_data struct has exactly
one field which is initialized from the the same field in the mxs_pcm_dma_params
struct. The mxs_pcm_dma_params struct gets passed to the pcm driver from the dai
driver. Instead of taking this indirection embed the mxs_dma_data struct
directly in the mxs_pcm_dma_params struct. This allows us to simplify the pcm
driver quite a bit, since we don't have to care about memory managing the
mxs_dma_data struct anymore.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:17:41 +00:00
Lars-Peter Clausen 312bb4f626 ASoC: imx-pcm: Embed the imx_dma_data struct in the dma_params struct
Currently the imx_dma_data struct, which gets passed to the dmaengine driver, is
allocated and constructed in the pcm driver from the data stored in the
dma_params struct. The dma_params struct gets passed to the pcm driver from the
dai driver. Instead of going this route of indirection embed the dma_data struct
directly into the dma_params struct and let the dai driver fill it in. This
allows us to simplify the imx-pcm-dma driver quite a bit, since it doesn't have
care about memory managing the imx_dma_data struct anymore.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:17:31 +00:00
Lars-Peter Clausen ac581e60df ASoC: mmp-pcm: Allocate dma filter parameters on the stack
The dma filter parameters are only used within filter callback, so there is no
need to allocate them on the heap and keep them around until the PCM has been
closed.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:17:03 +00:00
Lars-Peter Clausen 453807f300 ASoC: ep93xx: Use ep93xx_dma_params instead of ep93xx_pcm_dma_params
Currently the ep93xx_dma_params struct which is passed to the dmaengine driver
is constructed at runtime from the ep93xx_pcm_dma_params that gets passed to the
ep93xx PCM driver from one of the ep93xx DAI drivers. The ep93xx_pcm_dma_params
struct is almost identical to the ep93xx_dma_params struct. The only missing
field is the 'direction' field, which is computed at runtime in the PCM driver
based on the current substream. Since we know in advance which
ep93xx_pcm_dma_params struct is being used for which substream at compile time,
we also already know which direction to use at compile time. So we can easily
replace all instances of ep93xx_pcm_dma_params with their ep93xx_dma_params
counterpart. This allows us to simplify the code in the ep93xx pcm driver quite
a bit.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Reviewed-by: Ryan Mallon <rmallon@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:16:52 +00:00
Lars-Peter Clausen 5fe668a1d2 ASoC: atmel-pcm-dma: Do not use snd_dmaengine_pcm_{set,get}_data()
We want to get rid of snd_dmaengine_pcm_{set,get}_data(). All instances of
snd_dmaengine_pcm_get_data() in the atmel pcm driver can easily be replaced with
snd_soc_dai_get_dma_data().

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Bo Shen <voice.shen@atmel.com>
Acked-by: Bo Shen <voice.shen@atmel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:16:41 +00:00
Lars-Peter Clausen 593b66fbbc ASoC: speaer_pcm: No need to use snd_dmaengine_pcm_set_data()
The driver never uses snd_dmaengine_pcm_get_data(), so there is no need to use
snd_dmaengine_pcm_set_data().

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:16:22 +00:00
Lars-Peter Clausen ebd59b07ec ASoC: ux500_pcm: No need to use snd_dmaengine_pcm_set_data()
The driver never uses snd_dmaengine_pcm_get_data(), so there is no need to use
snd_dmaengine_pcm_set_data().

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Ola Lilja <ola.o.lilja@stericsson.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:15:38 +00:00
Lars-Peter Clausen a85fc1b073 ASoC: atmel-pcm-dma: No need to wrap snd_dmaengine_pcm_close()
If a PCM driver using the dmaengine PCM helper functions doesn't need to do
anything special in its pcm_close callback, snd_dmaengine_pcm_close can be used
directly for as the pcm_close callback and there is no need to wrap it in a
custom function.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Bo Shen <voice.shen@atmel.com>
Acked-by: Bo Shen <voice.shen@atmel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:15:24 +00:00
Lars-Peter Clausen 8c4e56fd55 ASoC: ux500_pcm: No need to wrap snd_dmaengine_pcm_close()
If a PCM driver using the dmaengine PCM helper functions doesn't need to do
anything special in its pcm_close callback, snd_dmaengine_pcm_close can be used
directly for as the pcm_close callback and there is no need to wrap it in a
custom function.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Ola Lilja <ola.o.lilja@stericsson.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:15:16 +00:00
Lars-Peter Clausen 3021bd38ed ASoC: tegra_pcm: No need to wrap snd_dmaengine_pcm_close()
If a PCM driver using the dmaengine PCM helper functions doesn't need to do
anything special in its pcm_close callback, snd_dmaengine_pcm_close can be used
directly for as the pcm_close callback and there is no need to wrap it in a
custom function.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Stephen Warren <swarren@wwwdotorg.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:14:55 +00:00
Lars-Peter Clausen 340af748bc ASoC: omap-pcm: No need to wrap snd_dmaengine_pcm_close()
If a PCM driver using the dmaengine PCM helper functions doesn't need to do
anything special in its pcm_close callback, snd_dmaengine_pcm_close can be used
directly for as the pcm_close callback and there is no need to wrap it in a
custom function.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:14:46 +00:00
Lars-Peter Clausen 023934b405 ASoC: spear_pcm: No need to wrap snd_dmaengine_pcm_close()
If a PCM driver using the dmaengine PCM helper functions doesn't need to do
anything special in its pcm_close callback, snd_dmaengine_pcm_close can be used
directly for as the pcm_close callback and there is no need to wrap it in a
custom function.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:14:29 +00:00
Lars-Peter Clausen cb20d5757b ASoC: ux500_pcm: Remove duplicated SNDRV_PCM_HW_PARAM_PERIODS constraint
The generic dmaengine based PCM driver code takes care of setting this
constraint, there is no need of doing it manually in the ux500 driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Ola Lilja <ola.o.lilja@stericsson.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:14:23 +00:00
Alexandru Gheorghiu 36300fd098 ASoC: core: Use PTR_RET function
Used PTR_RET function instead of IS_ERR and PTR_ERR.
Patch found using coccinelle.

Signed-off-by: Alexandru Gheorghiu <gheorghiuandru@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:12:01 +00:00
Lars-Peter Clausen abe99370b3 ASoC: omap: Call omap_mcbsp_set_threshold() from mcbsp hw_params
The omap PCM driver provides a set_threshold callback which gets called by the
PCM driver when either playback or capture is started. The only DAI driver which
sets this callback is the mcbsp driver. This patch removes the callback from the
PCM driver and moves the invocation of the omap_mcbsp_set_threshold() function
to the mcbsp hw_params callback since this is the only place where the threshold
size can change. Doing so allows us to use the default dmaengine PCM trigger
callback in the omap PCM driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:11:12 +00:00
Joonyoung Shim 0eaa6cca1f ASoC: core: Fix to check return value of snd_soc_update_bits_locked()
It can be 0 or 1 return value of snd_soc_update_bits_locked() when it is
success. So just check return value is negative.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2013-03-26 14:10:02 +00:00
Mark Brown 40bac28eb1 Merge remote-tracking branch 'asoc/fix/spear' into asoc-next 2013-03-26 14:08:07 +00:00
Mark Brown 5f948722cd Merge remote-tracking branch 'asoc/fix/si476x' into asoc-next 2013-03-26 14:08:05 +00:00
Mark Brown ff6550104c Merge remote-tracking branch 'asoc/fix/sh' into asoc-next 2013-03-26 14:08:04 +00:00
Mark Brown de7ba0574e Merge remote-tracking branch 'asoc/fix/max98090' into asoc-next 2013-03-26 14:08:03 +00:00
Mark Brown d7963b72e4 Merge remote-tracking branch 'asoc/fix/fsl' into asoc-next 2013-03-26 14:08:01 +00:00
Mark Brown a36b32402a Merge remote-tracking branch 'asoc/fix/dapm' into asoc-next 2013-03-26 14:07:58 +00:00
Mark Brown 23af7b0bba Merge remote-tracking branch 'asoc/fix/core' into asoc-next 2013-03-26 14:07:57 +00:00
Wei Yongjun aed9913e6f ASoC: arizona: remove duplicated include from arizona.c
Remove duplicated include.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26 14:04:58 +00:00
Stephen Warren a7fc5d256b ASoC: tegra: add Tegra114 support to tegra_asoc_utils.c
Tegra114 requires different PLL rates. Modify the code to know about
this.

On Tegra114 only for now, use regular clk_get() rather than clk_get_sys()
to retrieve clocks. This assumes that the clocks will be represented in
device tree. We can assure that from the start of any Tegra114 audio
support. For older chips, I'll add the required clocks properties to the
device trees this kernel cycle, and switch this code to only support the
"new_clocks" path next cycle.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-25 15:56:36 +00:00
Stephen Warren 95d3607569 ASoC: tegra: add Tegra114 support to the AHUB driver
Tegra114's AHUB shares a design with Tegra30, with the followin changes:
* Supports more (10 vs. 4) bi-directional FIFO channels into RAM.
* Requires a separate block of registers to support the above.
* Supports more attached clients, i.e. new audio multiplexing and
  de-multiplexing modules.
* Is affected by more clocks due to the above.

This change fully defines the device tree binding changes required to
represent these changes, and minimally extends the driver to support
the new hardware, without exposing any of the new FIFO channels.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-25 15:56:35 +00:00
Shawn Guo fa659d830d ASoC: imx-sgtl5000: use of_node to match cpu dai
Since imx-sgtl5000 is only used on DT platform, it makes more sense to
use cpu_of_node rather than cpu_dai_name to match cpu dai.

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-25 10:22:20 +00:00
Lars-Peter Clausen 417a1178f1 ASoC: dma-sh7760: Fix compile error
The dma-sh7760 currently fails with the following compile error:
	sound/soc/sh/dma-sh7760.c:346:2: error: unknown field 'pcm_ops' specified in initializer
	sound/soc/sh/dma-sh7760.c:346:2: warning: initialization from incompatible pointer type
	sound/soc/sh/dma-sh7760.c:347:2: error: unknown field 'pcm_new' specified in initializer
	sound/soc/sh/dma-sh7760.c:347:2: warning: initialization makes integer from pointer without a cast
	sound/soc/sh/dma-sh7760.c:348:2: error: unknown field 'pcm_free' specified in initializer
	sound/soc/sh/dma-sh7760.c:348:2: warning: initialization from incompatible pointer type
	sound/soc/sh/dma-sh7760.c: In function 'sh7760_soc_platform_probe':
	sound/soc/sh/dma-sh7760.c:353:2: warning: passing argument 2 of 'snd_soc_register_platform' from incompatible pointer type
	include/sound/soc.h:368:5: note: expected 'struct snd_soc_platform_driver *' but argument is of type 'struct snd_soc_platform *'

This is due the misnaming of the snd_soc_platform_driver type name and 'ops'
field. The issue was introduced in commit f0fba2a("ASoC: multi-component - ASoC
Multi-Component Support").

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2013-03-22 12:23:11 +01:00
Kuninori Morimoto 8abfc2608b ASoC: pxa2xx-ac97: move EXPORT_SYMBOL_GPL() next to definition
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-22 12:13:20 +01:00
Daniel Mack c24a34dbcd ASoC: cs4271: switch to mute_stream
Use the newly introduced mute_stream DAI operation, and don't mute the
codec if it's called for the _CAPTURE stream.

Signed-off-by: Daniel Mack <zonque@gmail.com>
Acked-by: Alexander Sverdlin <subaparts@yandex.ru>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-22 11:13:09 +01:00
Mark Brown d3725761ee ASoC: wm8994: Restore AIFnCLK after reducing it for low clock rates
This helps to ensure a smooth startup when we restore.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-21 21:37:09 +01:00
Mark Brown dc91428a61 ASoC: arizona: Basic support for ISRC rate selection
Since ASoC does not yet really have the framework features needed to
support propagating sample rates through the device well yet implement
basic support for the ISRCs equivalent to that we currently have for the
ASRCs. The user can opt for 8kHz or 16kHz as the rate for the DSP blocks
in addition to the main audio rate, these being the primary use cases.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-21 18:55:14 +01:00
Mark Brown f4a76e7cc6 ASoC: arizona: Suppress speaker enable if thermal shutdown is flagged
Ensure that the device state does not diverge from the state we have set
in the register map in order to make the behaviour clearer.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-21 18:55:13 +01:00
Mark Brown 899817e27a ASoC: arizona: Log thermal events
Help with debuggability.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-21 18:54:59 +01:00
Mark Brown 56447e1324 ASoC: arizona: Factor out speaker widgets from CODEC drivers
Some system designs have been identified which repurpose portions of the
speaker driver circuits for other functions which will require that they
not be managed using DAPM. Prepare for this by factoring out the creation
of the speaker widgets into the core driver, the widgets will be replaced
by dummy ones when the additional functions are enabled.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-21 18:54:18 +01:00
Mark Brown 3cf956eebe ASoC: wm8994: Support constraining the maximum number of channels clocked
Some systems use the audio CODEC to clock a DAI with multiple data lines
in parallel, meaning that bit clocks are only required for a smaller number
of channels than data is sent for. In some cases providing the extra bit
clocks can take the other devices on the audio bus out of spec.

Support such systems by allowing a maximum number of channels to be
specified.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-21 17:27:32 +01:00
Alban Bedel 00aa0fac76 ASoC: wm8903: Add the DAC boost control
Signed-off-by: Alban Bedel <alban.bedel@avionic-design.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 20:23:24 +01:00
Silviu-Mihai Popescu f7ba716f1e ASoC: core: fix invalid free of devm_ allocated data
The objects allocated by devm_* APIs are managed by devres and are freed when
the device is detached. Hence there is no need to use kfree() explicitly.

Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 11:05:56 +01:00
Lars-Peter Clausen 18b97dbe86 ASoC: spear_pcm: Staticize non-exported structs
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 11:03:09 +01:00
Lars-Peter Clausen 59d9cc2a50 ASoC: spear_pcm: Update to new pcm_new() API
Commit 552d1ef6 ("ASoC: core - Optimise and refactor pcm_new() to pass only
rtd") updated the pcm_new() callback to take the rtd as the only parameter. The
spear PCM driver (which was merged much later) still uses the old API. This
patch updates the driver to the new API.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
2013-03-20 11:02:33 +01:00
Peter Ujfalusi 167b5b93a4 ASoC: omap-mcpdm: Remove leftower define for IO address
The IO address is no longer hardwired into the driver.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 10:59:54 +01:00
Peter Ujfalusi 81054b226b ASoC: omap-mcpdm: Fix for full duplex audio use case
Due to HW limitation within OMAP McPDM IP uplink and downlink need to be
started at the same time. This causes issues when we have two streams
running, for example:
arecord | aplay

In this case the playback stream would have no channels enabled since at the
capture start we are not aware that a playback is going to start.

The workaround is to configure the other direction to stereo when the first
stream is started. When the second stream is coming we check the new stream's
number of channels against the pre-configured channels. If it does not match
we stop and restart McPDM to update the configuration. This might result a
small pop. If the coming stream is a match we do nothing in the McPDM driver.

This workaround can handle most use cases without the need to restart McPDM.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 10:59:52 +01:00
Peter Ujfalusi 623766318a ASoC: omap-mcpdm: Collect link direction configuration under a struct
mcpdm_link_config will collect the link direction related configurations like
channel masks, FIFO threshold.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 10:59:52 +01:00
Fabio Estevam 2fb148804f ASoC: fsl: imx-pcm-fiq: Use 'unsigned int' for period
Fix the following warning when building with W=1 option:

sound/soc/fsl/imx-pcm-fiq.c: In function 'snd_hrtimer_callback':
sound/soc/fsl/imx-pcm-fiq.c:76:12: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 10:58:39 +01:00
Joe Perches 4480764f57 ASoC:: max98090: Remove executable bit
Source files shouldn't have the executable bit set.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20 10:54:12 +01:00
Peter Ujfalusi 7f08a89862 ASoC: dapm: Fix pointer dereference in is_connected_output_ep()
*path is not yet initialized when we check if the widget is connected.

The compiler also warns about this:
sound/soc/soc-dapm.c: In function 'is_connected_output_ep':
sound/soc/soc-dapm.c:824:18: warning: 'path' may be used uninitialized in this function

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-15 01:27:39 +00:00
Kuninori Morimoto da4f2f9e6b ASoC: fsi: use snd_soc_register_component() instead of snd_soc_register_dais()
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-15 01:24:57 +00:00
Daniel Mack 1b1861ead4 ASoC: cs4271: convert to direct regmap API usage
By using the regmap API directly, we can make use of the
.write_flag_mask for SPI, which allows us to drop the strange register
hacks that were necessary so far.

Signed-off-by: Daniel Mack <zonque@gmail.com>
Acked-by: Alexander Sverdlin <alexander.sverdlin@gmx.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-15 01:23:26 +00:00
Mark Brown 76bf969e6f ASoC: arizona: Ensure we clock two channels for I2S mode
I2S requires stereo clocking even for mono data.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-13 19:03:17 +00:00
Mark Brown f395a21853 ASoC: wm_adsp: Handle old .bin files
Older .bin files report the global coefficients as absolute address writes
to zero; maintain compatibility with them.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-13 12:40:37 +00:00
Mark Brown 3f341f741d ASoC: arizona: Provide defines for the clock rates
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-13 11:18:57 +00:00
Dan Carpenter 28dbd1611f ASoC: tas5086: signedness bug in tas5086_hw_params()
"val" has to be signed for the error handling to work.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-13 11:08:56 +00:00