Commit Graph

1613 Commits (5e07c2c7301bd2c82e55cf5cbb36f7b5bddeb8e9)

Author SHA1 Message Date
Peter Ujfalusi 6aceabb459 ASoC: tlv320dac33: Burst mode BCLK divider configuration
Add possibility to configure the burst mode BCLK divider through platform
data structure.
The BCLK divider changes the actual speed of the serial bus in burst mode,
which is faster than the sampling frequency of the running stream.
In this way platforms can experiment with the optimal burst speed without
the need to modify the codec driver itself.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-20 11:47:49 +00:00
Peter Ujfalusi 6cd6cede8c ASoC: tlv320dac33: BCLK divider fix
The BCLK divider was not configured in case of mode7.
This leads to unpredictable behavior when switching between FIFO modes.
Configure the BCLK divider depending on the fifo_mode (FIFO is in use,
or FIFO bypass).

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-20 11:47:49 +00:00
Peter Ujfalusi a5b5a0649a ASoC: tlv320dac33: Correct the prefill number of samples
Set the prefill number of samples as the same as the lower
threshold in mode7.
In this way the codec will read the same amount of data on
startup and during the running playback.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-19 12:36:24 +00:00
Mark Brown 9135f6db09 Merge branch 'mxc-audio' into for-2.6.34
Conflicts:
	arch/arm/plat-mxc/Makefile (dual add)
	sound/soc/imx/mx27vis_wm8974.c (API updates & removal)
2010-01-17 16:47:32 +00:00
Mark Brown b05f5c13d5 ASoC: Mark new i.MX drivers as BROKEN until arch/arm merged
Currently they don't build due to cross tree dependencies, they will be
reenabled once the arch/arm side has merged.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-17 16:45:06 +00:00
Mark Brown e919c24b64 ASoC: Remove old i.MX driver code
This has been superceeded by Sascha's new driver but was not removed in
the patch series due to cutdowns for review.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-17 11:10:03 +00:00
Mark Brown d08a68bfca ASoC: i.MX SSI driver does not yet support master mode
The clocks for the SSI block need handling before this can work.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-17 11:10:02 +00:00
Mark Brown 48dbc41988 ASoC: Convert new i.MX SSI driver to use static DAI array
While dynamically allocated DAIs are the way forward the core doesn't
yet support anything except matching with a pointer to the actual DAI
so convert to doing that so that machine drivers don't have to jump
through hoops to register themselves.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Javier Martin <javier.martin@vista-silicon.com>
2010-01-17 11:10:01 +00:00
Mark Brown 157a777c8e ASoC: Fix i.MX audio build for i.MX3x
Don't unconditionally include the i.MX2x DMA driver, the arch/arm
functions it uses aren't available for i.MX3x.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Javier Martin <javier.martin@vista-silicon.com>
2010-01-17 11:10:01 +00:00
Sascha Hauer 8380222ec9 ASoC: Add a new imx-ssi sound driver
The old driver has the number of SSI units in the system hardcoded,
does not make use of the device model and works only on i.MX21/27.

This driver replaces it. It works in DMA mode on i.MX21/27 and using
an FIQ handler on other systems. It also supports AC97 mode of
the SSI units.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Javier Martin <javier.martin@vista-silicon.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-17 11:09:46 +00:00
Daniel Mack a421296840 ASoC: support more sample rates on raumfeld devices
Add support for sample rates other than 44100Khz on raumfeld audio
devices. At startup time, call snd_soc_dai_set_sysclk() with 0 as 'freq'
argument so it offers all the sample rates. Later, the function is
called again to give proper constraints.

Use the external audio clock generator to provide double data rate
clocks as the PXA's internal baud generator does anything but what's
described in the datasheets.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-15 17:28:41 +00:00
Daniel Mack 6aababdf20 ASoC: cs4270: allow passing freq=0 in set_dai_sysclk()
For setups with variable MCLKs, the current logic of limiting the
available sampling rates at startup time is not sufficient. We need to
be able to change the setting at a later point, and so the codec must
offer all possible rates until the hw_params are given.

This patches allows that by passing 0 as 'freq' argument to
cs4270_set_dai_sysclk().

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-15 17:28:41 +00:00
Thomas Weber 738ada47cf ASoC: TWL4030: Fix typo in comment in header file
Signed-off-by: Thomas Weber <weber@corscience.de>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-14 10:36:52 +00:00
Daniel Mack 617b14c50e ASoC: ak4104: allow more sample rates
The transmitter supports all sample rates up to 192KHz, so the driver
should not give a limit.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-13 13:23:00 +00:00
Peter Ujfalusi fd63df2264 ASoC: TWL4030: Replace comma with semicolon in probe function
The codec structure initialization statements should be
separated by semicolons.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-13 13:22:55 +00:00
Mark Brown 735fe4cfbc ASoC: Add missing __devexit and __devinit annotations
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-12 14:13:00 +00:00
Mark Brown 03e7a35c0e Revert "ASoC: ad1836: reset and restore clock control mode in suspend/resume entry"
This reverts commit afe1c2cd71 since it
doesn't build.
2010-01-12 14:01:19 +00:00
Mark Brown 163849ea9b Merge branch 'for-2.6.33' into for-2.6.34 2010-01-12 12:59:05 +00:00
Ilkka Koskinen 2138301e16 ASoC: tpa6130a2: Support for tpa6140's regulators
tpa6140a2 uses different names for the regulators.

Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-11 17:13:11 +00:00
Mark Brown 5ee518ecbc ASoC: Fix WM8350 DSP mode B configuration
We need to set the LRCLK inversion bit to select DSP mode.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Cc: stable@kernel.org
2010-01-08 16:21:56 +00:00
Mark Brown 53242c6833 ASoC: Implement suspend and resume for WM8993
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-01-04 21:51:13 +00:00
Mark Brown 10505634bf ASoC: Only restore non-default registers for WM8961
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-01-04 21:50:58 +00:00
Mark Brown e0fb28e079 ASoC: Only restore non-default registers for WM8776
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-01-04 21:50:43 +00:00
Mark Brown d11c5ab186 ASoC: Only restore non-default registers for WM8731
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-01-04 21:50:23 +00:00
Mark Brown 5baf831541 ASoC: Fix variable shadowing warning in TLV320AIC3x
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-01-04 21:49:53 +00:00
Manuel Lauss ecbec24296 ASoC: fixup oops in generic AC97 codec glue
Initialize the glue by calling snd_soc_new_ac97_codec() as is done
in other ASoC AC97 codecs.  Fixes an oops caused by dereferencing
uninitialized members in snd_soc_new_pcms().

Run-tested on Au1250.

Signed-off-by: Manuel Lauss <manuel.lauss@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-04 18:30:01 +00:00
Ilkka Koskinen a126fd5691 ASoc: tpa6130a2: Remove unnecessary variable
Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-01-04 18:28:23 +00:00
Mark Brown 40ca114265 ASoC: Use snprintf() when generating stream names
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-31 12:44:43 +00:00
Mark Brown 633154d3a7 ASoC: Remove unneeded suspend checks from CODEC drivers
Better integration of the core with the device model means that we now
no longer get the ASoC suspend and resume callbacks without the card
having been set up.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-31 12:44:28 +00:00
Peter Ujfalusi adcb8bc02d ASoC: tlv320dac33: Safety check for codec slave mode
The currently available FIFO modes (mode1 and mode7) require master
mode from the codec.
Do not allow the slave configuration when the FIFO is in use.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-31 11:54:28 +00:00
Peter Ujfalusi 28e05d9870 ASoC: tlv320dac33: Add new FIFO mode: mode 7
Mode 7 of tlv320dac33 operates in the following way:
The codec is in master mode.
Host configures upper and lower thresholds in tlv320dac33
During playback the codec will clock in the data until the
upper threshold is reached in FIFO. At this point the codec
stops the colocks on the serial bus.
When the FIFO fill is reaching the lower threshold limit the
codec will enable the clocks on the serial bus, and clocks
in data till the upper threshold is reached.

In this mode, we can also request interrupts for threshold
events (upper, lower and alarm), which could be used for
power management.

At this point the interrupts are not enabled for this mode,
but it can be taken into use in the future, when the surrounding
code makes it possible to use it.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.oc.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-31 11:54:28 +00:00
Peter Ujfalusi aec242dc37 ASoC: tlv320dac33: Clean up the hardware configuration code
Use switch instead of if statements to configure FIFO bypass
and mode1.
With this change adding new FIFO mode is going to be easier,
and cleaner.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-31 11:54:27 +00:00
Peter Ujfalusi d4f102d437 ASoC: tlv320dac33: Introduce prefill and playback state handlers
Ensure that the code is going to be readable, when new FIFO modes
are introduced later.
Move the prefill and playback state handling to inlined
functions.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-31 11:54:27 +00:00
Peter Ujfalusi 7427b4b9a6 ASoC: tlv320dac33: Change nsample switch to FIFO mode enum
In order to have support for more FIFO modes supported by
tlv320dac33, the switch for enabling/disabling the FIFO
use has to be replaced with an enum.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-31 11:54:26 +00:00
Barry Song 8998c89907 ASoC: soc-cache: cleanup training whitespace and coding style
Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-31 11:54:16 +00:00
Kuninori Morimoto 59c3b003dd ASoC: fsi: Add over/under run error settlement
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-30 18:31:09 +00:00
Kuninori Morimoto 142e8174b3 ASoC: fsi: Add fsi_get_dai to get snd_soc_dai
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-30 18:31:09 +00:00
Kuninori Morimoto 1c418d1f62 ASoC: fsi: Add over_period flag to prevent the misunderstanding
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-30 18:31:08 +00:00
Barry Song 5b61735534 ASoC: ad1938: let soc-core dapm handle PLL power
PM architecture of ad1938 is simple, we don't need a bundle of functions like
ad1938_pll_powerctrl, ad1938_set_bias_level for only PLL. A dapm supply will
handle on/off of PLL.
Since soc-core can poweron/off PLL on-demand, we don't need to poweron/off PLL
in suspend/resume entries too.

Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-30 18:30:34 +00:00
Barry Song 08ba864e27 ASoC: ad1938: fix typo, rename mask to rx_mask for ad1938_set_tdm_slot
Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-30 18:30:27 +00:00
Barry Song afe1c2cd71 ASoC: ad1836: reset and restore clock control mode in suspend/resume entry
Tests show frequent suspend/resume(frequent poweroff/on ad1836 internal
components) maybe make ad1836 clock mode wrong sometimes after wakeup.
This patch reset/restore ad1836 clock mode while executing PM, then
ad1836 can always resume to right clock status.

Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-30 18:30:11 +00:00
Mark Brown 7f50548abb Merge commit 'v2.6.33-rc2' into for-2.6.33 2009-12-26 14:52:54 +00:00
Guennadi Liakhovetski b3172f222a ASoC: fix params_rate() macro use in several codecs
Sevelar ASoC codec drivers wrongly assume, that the params_rate() macro
returns one of SNDRV_PCM_RATE_* defines instead of the actual numerical
sampling rate. Fix them.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-12-24 11:41:21 +00:00
Kuninori Morimoto 18f98ab547 ASoC: fsi-ak4642: Remove ak4642_add_i2c_device
I2C devices should be registered when platform board setting
in latest ASoC.

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-24 11:41:18 +00:00
Takashi Iwai 3095b165a1 Merge branch 'fix/asoc' into for-linus 2009-12-23 18:50:13 +01:00
Eric Millbrandt 48e3cbb3f6 ASoC: Do not write to invalid registers on the wm9712.
This patch fixes a bug where "virtual" registers were being written to the ac97
bus.  This was causing unrelated registers to become corrupted (headphone 0x04,
touchscreen 0x78, etc).

This patch duplicates protection that was included in the wm9713 driver.

Signed-off-by: Eric Millbrandt <emillbrandt@dekaresearch.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-12-23 15:20:56 +00:00
Guennadi Liakhovetski 1628af5adf ASoC: add missing parameter to mx27vis_hifi_hw_free()
Commit 2ccafed4 added an extra parameter to the DAI .set_pll() method, but
it missed this call in sound/soc/imx/mx27vis_wm8974.c.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-22 12:33:56 +00:00
Uwe Kleine-König b6aa179334 ASoC: sh: FSI:: don't check platform_get_irq's return value against zero
platform_get_irq returns -ENXIO on failure, so !irq was probably
always true.  Better use (int)irq <= 0.  Note that a return value of
zero is still handled as error even though this could mean irq0.

This is a followup to 305b3228f9 that
changed the return value of platform_get_irq from 0 to -ENXIO on error.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-22 12:33:56 +00:00
Takashi Iwai 2c3b9b50db Merge branch 'fix/asoc' into for-linus 2009-12-21 12:05:37 +01:00
Mark Brown 18240b67c8 ASoC: Host clock2 read up in WM8904 FLL configuration
Avoids skipping over the read for disable cases.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-18 14:20:35 +00:00
Mark Brown a17accb7ae Merge branch 'for-2.6.33' into for-2.6.34 2009-12-18 13:31:40 +00:00
Mark Brown 56927eb054 ASoC: Set AIF word length for WM8904
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-18 13:31:22 +00:00
Mark Brown b35a28af0a ASoC: Add initial WM8955 CODEC driver
The WM8955 is a low power, high quality stereo DAC with integrated
headphone and loudspeaker amplifiers, designed to reduce external
component requirements in portable digital audio applications. This is
an initial driver implementing support for the majority of the
functionality in the device, currently OUT3 is not supported.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-18 13:06:47 +00:00
Guennadi Liakhovetski 48c03ce72f ASoC: wm8974: fix a wrong bit definition
The wm8974 datasheet defines BUFIOEN as bit 2.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-12-18 12:58:53 +00:00
Mark Brown c215143384 ASoC: Fix build of DA7210
DAC_VOICE_EN was not defined - looks to have been overly enthusiastically
deleted from a previous revision of the patch, pull the value from v1.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 20:59:54 +00:00
Peter Meerwald 255173b40d ASoC: PLL computation in TLV320AIC3x SoC driver
fix precision of PLL computation for TLV320AIC3x SoC driver,
test results are at http://pmeerw.net/clk

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Acked-by: Vladimir Barinov <vova.barinov@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 20:59:53 +00:00
Mark Brown 3497b91946 ASoC: Fix sorting of codecs Makefile entries
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-16 20:59:42 +00:00
Balaji T K ebeb53e1e1 mfd: twl: fix twl4030 rename for remaining driver, board files
Recent drivers/mfd/twl4030* renames to twl broke compile for
various boards as the series was missing a patch to change
the board-*.c files.

This patch renames include twl4030.h to include twl.h
and also renames twl4030_i2c_ routines.

Signed-off-by: Balaji T K <balajitk@ti.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Reviewed-by: Felipe Balbi <felipe.balbi@nokia.com>
Cc: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2009-12-16 12:44:04 -08:00
Kuninori Morimoto 038494059f ASoC: Add FSI-DA7210 sound support for SuperH
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 17:31:05 +00:00
Kuninori Morimoto 98615454f6 ASoC: Add DA7210 codec device support for ALSA
This original driver was created by Dialog Semiconductor,
and cleanuped by Kuninori Morimoto.
Special thanks to David Chen.
This became very simple ASoC codec driver,
and it is tested by EcoVec24 board.

Signed-off-by: David Chen <Dajun.chen@diasemi.com>
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 17:31:04 +00:00
Ilkka Koskinen 7c4e649220 ASoC: tpa6130a2: Add support for regulator framework
Take the regulator framework in use for managing the power sources

Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 17:31:04 +00:00
Jassi Brar 0fe692292a ASoC: S3C64XX: Compress and generalize the CPU driver
The driver can be 'generalized' a bit by not hardcoding '2'(the number of
I2Sv3 controllers that the driver can handle) at many places, instead we
define a macro for it. That makes it easier to increase number of controllers
by changing the parameter at just one place, this will be useful when there is
support for newer SoCs, which have the same controller, only more in number.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 17:31:03 +00:00
Jassi Brar 168db50d96 ASoC: S3C64XX: Remove unnecessary header includes
Removed redundant header includes which make no difference to compilation.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 17:31:02 +00:00
Mark Brown cce2e9db71 ASoC: Register the CODEC in WM8727
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-16 17:30:51 +00:00
Mark Brown d207c68dd9 ASoC: Sort DAPM sequences by CODEC as well
In preparation for multiple device support.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-16 17:30:37 +00:00
Mark Brown 283375cefb ASoC: Push registers out of mixer power decision
No need for the mixers to know about this, and it allows for virtual
controls.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-16 17:30:19 +00:00
Jon Smirl 75b46c1321 ASoC: Fix disable of SPDIF on STAC9766 codec
Change code so that switching to playing music through the analog output
disables SPDIF out instead of disabling it when stream ends.

Signed-off-by: Jon Smirl <jonsmirl@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-16 15:56:57 +00:00
Linus Torvalds a8aa1ebdf8 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: ac97_codec - increase timeout for analog sections to 5 second
  ASoC: Correct code taking the size of a pointer
  ALSA: hda - Add PCI IDs for Nvidia G2xx-series
  ALSA: sound/isa/gus: Correct code taking the size of a pointer
  ALSA: hda: Fix max PCM level to 0 dB for AD1981_HP
  ALSA: hda: Use ALC260_WILL quirk for another Acer model (0x1025007f)
2009-12-15 09:11:05 -08:00
Alexey Dobriyan 471452104b const: constify remaining dev_pm_ops
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-12-15 08:53:25 -08:00
Kuninori Morimoto 1cf86f6f9b ASoC: ak4642: Add default return value in ak4642_modinit
If ak4642 driver was compiled without I2C configs,
ak4642_modinit return value will become un-stable.
This patch modify this bug

Reported-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-15 14:54:01 +00:00
Takashi Iwai 6e0446cb4b Merge branch 'fix/asoc' into for-linus 2009-12-15 10:30:34 +01:00
Julia Lawall bc2580061e ASoC: Correct code taking the size of a pointer
sizeof(codec->reg_cache) is just the size of the pointer.  Elsewhere in the
file, codec->reg_cache is used with sizeof(wm8900_reg_defaults), so the
code is changed to do the same here.

A simplified version of the semantic patch that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression *x;
expression f;
type T;
@@

*f(...,(T)x,...)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-14 11:37:57 +00:00
Balaji T K fc7b92fca4 mfd: Rename all twl4030_i2c*
This patch renames function names like twl4030_i2c_write_u8,
twl4030_i2c_read_u8 to twl_i2c_write_u8, twl_i2c_read_u8
and also common variable in twl-core.c

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 21:23:33 +01:00
Santosh Shilimkar b07682b605 mfd: Rename twl4030* driver files to enable re-use
The upcoming TWL6030 is companion chip for OMAP4 like the current TWL4030
for OMAP3. The common modules like RTC, Regulator creates opportunity
to re-use the most of the code from twl4030.

This patch renames few common drivers twl4030* files to twl* to enable
the code re-use.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 20:05:51 +01:00
Mark Brown 6a6127462e mfd: Mask and unmask wm8350 IRQs on request and free
Bring the WM8350 IRQ API more in line with the generic IRQ API by
masking and unmasking interrupts as they are requested and freed.
This is mostly just a case of deleting the mask and unmask calls
from the individual drivers.

The RTC driver is changed to mask the periodic IRQ after requesting
it rather than only unmasking the alarm IRQ. If the periodic IRQ
fires in the period where it is reqested then there will be a
spurious notification but there should be no serious consequences
from this.

The CODEC drive is changed to explicitly disable headphone jack
detection prior to requesting the IRQs. This will avoid the IRQ
firing with no jack set up.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:40 +01:00
Mark Brown 5a65edbc12 mfd: Convert wm8350 IRQ handlers to irq_handler_t
This is done as simple code transformation, the semantics of the
IRQ API provided by the core are are still very different to those
of genirq (mainly with regard to masking).

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:39 +01:00
Linus Torvalds 6eb7365db6 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: hda - Overwrite pin config on intel DG45ID board.
  intelhdmi - dont power off HDA link
  ALSA: hrtimer - Fix lock-up
  ALSA: intelhdmi - add channel mapping for typical configurations
  ALSA: intelhdmi - channel mapping applies to Pin
  ALSA: intelhdmi - accept DisplayPort pin
  ALSA: hda - show HBR(High Bit Rate) pin cap in procfs
  ALSA: hda - Fix LED GPIO setup for HP laptops with IDT codecs
  ASoC: Fix build of OMAP sound drivers
  ALSA: opti93x: fix irq releasing if the irq cannot be allocated
2009-12-12 11:40:50 -08:00
Takashi Iwai f52d7a4393 Merge branch 'topic/asoc' into for-linus 2009-12-12 18:18:04 +01:00
Olof Johansson 761c9d45d1 ASoC: Fix build of OMAP sound drivers
There are build errors when building for some of the omap2/3 boards without
enabling sound:

sound/built-in.o:(.data+0x43bc): undefined reference to `soc_codec_dev_tlv320aic23'
sound/built-in.o:(.data+0x43cc): undefined reference to `tlv320aic23_dai'

Confused me quite a bit since the drivers that had references to the
codec weren't enabled. Turns out the Makefile was using the wrong
config option to enable them. Patch below.

Reported-by: Anand Gadiyar <gadiyar@ti.com>
Signed-off-by: Olof Johansson <olof@lixom.net>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-10 19:36:38 +00:00
Linus Torvalds 78f1ae193d Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: ice1724 - aureon - modify WM8770 Master & DAC volume
  ALSA: hda/realtek: quirk for D945GCLF2 mainboard
  ALSA: hda - Terradici HDA controllers does not support 64-bit mode
  ALSA: document: Add direct git link to grub hda-analyzer
  ALSA: radio/sound/miro: fix build, cleanup depends/selects
  ALSA: hda - Generalize EAPD inversion check in patch_analog.c
  ASoC: Wrong variable returned on error
  ALSA: snd-usb-us122l: add product IDs of US-122MKII and US-144MKII
  ALSA: hda - Exclude unusable ADCs for ALC88x
  ALSA: hda - Add missing Line-Out and PCM switches as slave
  ALSA: hda - iMac 9,1 sound patch.
  ALSA: opti93x: set MC indirect registers base from PnP data
2009-12-09 19:52:13 -08:00
Linus Torvalds 4ef58d4e2a Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (42 commits)
  tree-wide: fix misspelling of "definition" in comments
  reiserfs: fix misspelling of "journaled"
  doc: Fix a typo in slub.txt.
  inotify: remove superfluous return code check
  hdlc: spelling fix in find_pvc() comment
  doc: fix regulator docs cut-and-pasteism
  mtd: Fix comment in Kconfig
  doc: Fix IRQ chip docs
  tree-wide: fix assorted typos all over the place
  drivers/ata/libata-sff.c: comment spelling fixes
  fix typos/grammos in Documentation/edac.txt
  sysctl: add missing comments
  fs/debugfs/inode.c: fix comment typos
  sgivwfb: Make use of ARRAY_SIZE.
  sky2: fix sky2_link_down copy/paste comment error
  tree-wide: fix typos "couter" -> "counter"
  tree-wide: fix typos "offest" -> "offset"
  fix kerneldoc for set_irq_msi()
  spidev: fix double "of of" in comment
  comment typo fix: sybsystem -> subsystem
  ...
2009-12-09 19:43:33 -08:00
Takashi Iwai 84194883bc Merge branch 'topic/asoc' into for-linus 2009-12-09 18:16:15 +01:00
Linus Torvalds 1c496784a0 Merge branch 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6: (149 commits)
  arm: omap: Add omap3_defconfig
  AM35xx: Defconfig for AM3517 EVM board
  AM35xx: Add support for AM3517 EVM board
  omap: 3630sdp: defconfig creation
  omap: 3630sdp: introduce 3630 sdp board support
  omap3: Add defconfig for IGEP v2 board
  omap3: Add minimal IGEP v2 support
  omap3: Add CompuLab CM-T35 defconfig
  omap3: Add CompuLab CM-T35 board support
  omap3: rx51: Add wl1251 wlan driver support
  omap3: rx51: Add SDRAM init
  omap1: Add default kernel configuration for Herald
  omap1: Add board support and LCD for HTC Herald
  omap: zoom2: update defconfig for LL_DEBUG_NONE
  omap: zoom3: defconfig creation
  omap3: zoom: Introduce zoom3 board support
  omap3: zoom: Drop i2c-1 speed to 2400
  omap3: zoom: rename zoom2 name to generic zoom
  omap3: zoom: split board file for software reuse
  omap3evm: MIgrate to smsc911x ethernet driver
  ...

Fix trivial conflict (two unrelated config options added next to each
other) in arch/arm/mach-omap2/Makefile
2009-12-08 08:15:29 -08:00
Roel Kluin 370066e2b1 ASoC: Wrong variable returned on error
The wrong variable was returned in the case of an error

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-08 12:46:11 +00:00
Jiri Kosina d014d04386 Merge branch 'for-next' into for-linus
Conflicts:

	kernel/irq/chip.c
2009-12-07 18:36:35 +01:00
Daniel Mack ffbfd336f9 ASoC: Add regulator support to CS4270 codec driver
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Timur Tabi <timur@freescale.com>
Cc: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-07 13:11:56 +00:00
Mark Brown a91eb199e4 ASoC: Initial WM8904 CODEC driver
The WM8904 is a high performance ultra-low power stereo CODEC
optimised for portable audio applications, with features including
a class W amplifier, FLL with free running mode, Mobile ReTune and
ground referenced headphone and line outputs.

Support for some features, most particularly the digital microphone
interface, is not yet present.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-04 16:50:53 +00:00
Mark Brown d033c36ae5 ASoC: Display the power register in DAPM widget debugfs
Make it a bit easier to tie DAPM widgets in with the register map
without referring to the source by including the register location
controlled by the widget.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-04 16:07:26 +00:00
Mark Brown dd1b3d53c2 ASoC: Export snd_soc_update_bits_unlocked()
Allows custom controls to use it.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-12-04 16:07:06 +00:00
Takashi Iwai baf9226667 Merge branch 'topic/asoc' into for-linus 2009-12-04 16:22:41 +01:00
Takashi Iwai 7959832483 Merge branch 'topic/core-change' into for-linus 2009-12-04 16:22:32 +01:00
André Goddard Rosa af901ca181 tree-wide: fix assorted typos all over the place
That is "success", "unknown", "through", "performance", "[re|un]mapping"
, "access", "default", "reasonable", "[con]currently", "temperature"
, "channel", "[un]used", "application", "example","hierarchy", "therefore"
, "[over|under]flow", "contiguous", "threshold", "enough" and others.

Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-12-04 15:39:55 +01:00
Ilkka Koskinen 3a7aaed714 ASoC: tlv320dac33: Add support for regulator framework
Take the regulator framework in use for managing the power sources.

Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-04 12:35:08 +00:00
Mark Brown f1608cca9d Merge branch 'for-2.6.33' into for-2.6.34 2009-12-04 10:50:02 +00:00
Chaithrika U S a47979b5aa ASoC: DaVinci: Update suspend/resume support for McASP driver
Add clock enable and disable calls to resume and suspend respectively.
Also add a member to the audio device data structure which tracks the clock
status.

Tested on DA850/OMAP-L138 EVM. For the purpose of testing, the patches[1] which
add suspend-to-RAM support to DA850/OMAP-L138 SoC were applied.

[1] http://linux.davincidsp.com/pipermail/davinci-linux-open-source/
2009-November/016958.html

Signed-off-by: Chaithrika U S <chaithrika@ti.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-04 10:49:45 +00:00
Joonyoung Shim 3482594802 ASoC: Rename controls with a / in wm_hubs
This renames from a character / to : of controls. A / occurs below error
messages.

ASoC: Failed to create IN2RP/VXRP debugfs file
ASoC: Failed to create IN2LP/VXRN debugfs file

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-04 10:39:03 +00:00
Kuninori Morimoto 71f6e0645b ASoC: sh_fsi: avoid using global variable
Current FSI driver use global variable to access device data.
But this style will be broken
if SuperH come with multiple FSI blocks in future.
To solve this problem, this patch use cpu_dai->private_data.

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-03 10:53:37 +00:00
Manuel Lauss efd9eb96d5 ASoC: au1x: dbdma2: plug memleak in pcm device creation error path
free the allocated pcm platform device in the error path.

Signed-off-by: Manuel Lauss <manuel.lauss@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-03 10:49:55 +00:00
Manuel Lauss 1bc8079879 ASoC: au1x: dbdma2: fix oops on soc device removal.
platform_device_unregister() frees resources for us, no need to
do it explicitly.  Fixes an oops when machine code removes the
soc-audio device.

Signed-off-by: Manuel Lauss <manuel.lauss@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-12-03 10:49:55 +00:00
Takashi Iwai b00615d163 Merge branch 'topic/pcm-dma-fix' into topic/core-change 2009-12-01 15:58:15 +01:00
Takashi Iwai 75639e7ee1 Merge branch 'topic/beep-rename' into topic/core-change 2009-12-01 15:58:10 +01:00
Daniel Mack a649d1fcc9 ASoC: pxa/raumfeld: adopt new snd_soc_dai_set_pll() API
ALSA's for-2.6.33 branch has a new source argument to
snd_soc_dai_set_pll().

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-30 13:27:29 +00:00
Kuninori Morimoto 785d1c45ce ASoC: sh: fsi: Add runtime PM support
This patch add support runtime PM.
Driver callbacks for Runtime PM are empty because
the device registers are always re-initialized after
pm_runtime_get_sync(). The Runtime PM functions replaces the
clock framework module stop bit handling in this driver.

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-30 12:56:44 +00:00
Mark Brown 5c5452f703 Merge branch 'for-2.6.32' into for-2.6.33 2009-11-27 16:56:22 +00:00
Daniel Mack 49af574b60 ALSA: ARM: add Raumfeld audio support
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-27 16:54:57 +00:00
Anuj Aggarwal e9ff5eb2ae ASoC: AIC23: Fixing infinite loop in resume path
This patch fixes two issues:
a) Infinite loop in resume function
b) Writes to non-existing registers in resume function

Cc: stable@kernel.org
Signed-off-by: Anuj Aggarwal <anuj.aggarwal@ti.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-27 16:45:42 +00:00
Takashi Iwai a22eaf4ce1 ASoC: Revert missing reset_err in wm97*.c
The commit fe3e78e073
      ASoC: Factor out snd_soc_init_card()
removed the error paths that are still valid for wm97* codecs, causing
the compile errors like
  sound/soc/codecs/wm9705.c:399: error: label 'reset_err' used but not defined
  sound/soc/codecs/wm9712.c:687: error: label 'reset_err' used but not defined
  sound/soc/codecs/wm9713.c:1237: error: label 'reset_err' used but not defined

Revert the removed error path codes.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-11-27 15:14:09 +01:00
Peter Ujfalusi 74ea23aa6c ASoC: tlv320dac33: Change RT wq to singlethread wq
RT workqueue is going away in the near future, replace it with
singlethread wq for now, which is still supported.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-26 15:47:12 +00:00
Mark Brown c0fa59df72 ASoC: Add BCLK calculation utility for TDM mode too
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-25 19:55:46 +00:00
Mark Brown 97cef58521 Merge branch 'for-2.6.32' into for-2.6.33 2009-11-23 13:37:04 +00:00
Mark Brown 50b6bce59d ASoC: Fix suspend with active audio streams
When we get a stream suspend event force the power down since otherwise
the stream would remain marked as active.  In future we'll probably want
to make this stream-specific and add an interface to make the power down
of other widgets optional in order to support leaving bypass paths
active while suspending the processor.

Cc: stable@kernel.org
Reported-by: Joonyoung Shim <jy0922.shim@samsung.com>
Tested-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-23 13:11:53 +00:00
Tony Lindgren a76df42a67 Merge 7xx-iosplit-plat-merge with omap-fixes
Merge branch '7xx-iosplit-plat-merge' into omap-for-linus
2009-11-22 10:08:43 -08:00
Mark Brown dcdec639ad Merge branch 'ads117x' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into for-2.6.33 2009-11-20 16:37:10 +00:00
Enric Balletbò i Serra b2a2236d1f ASoC: Add support for IGEP v2
Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-19 10:48:43 +00:00
Troy Kisky 2b7b250df7 ASoC: DaVinci: use edma_pause, edma_resume
Use edma_pause and edma_resume to make missing dma_events
less likely. This may not be needed, but it looks better.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-19 10:48:27 +00:00
Troy Kisky 1e224f322b ASoC: DaVinci: pcm, fix underrun by using sram
Fix underruns by using dma to copy 1st to sram
in a ping/pong buffer style and then copying from
the sram to the ASP. This also has the advantage
of tolerating very long interrupt latency on dma
completion.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-19 10:48:08 +00:00
Troy Kisky 1587ea3157 ASoC: DaVinci: pcm, rename variables in prep for ping/pong
Rename variable master_lch to asp_channel
Rename variable slave_lch to asp_link[0]
Rename local variables:
	lch to link
	count to asp_count
	src to asp_src
	dst to asp_dst

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-19 10:47:56 +00:00
Troy Kisky 0d6c977429 ASoC: DaVinci: i2s, reduce underruns by combining into 1 element
Allow the left and right 16 bit samples to be shifted out as 1
32 bit sample.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-19 10:47:38 +00:00
Mark Brown 41b51dd47e Merge branch 'for-2.6.32' into for-2.6.33 2009-11-18 13:54:51 +00:00
Troy Kisky bab0212467 ASoC: tlv320aic23 fix rate selection
Fix the ordering of sr_valid_mask array.
The lower bit of the index represents USB
not bosr.

Reported-by: Anuj Aggarwal <anuj.aggarwal@ti.com>
Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:46:40 +00:00
Grazvydas Ignotas f3dd70414c ASoC: OMAP3 Pandora: update for TWL4030 codec changes
A while ago TWL4030 had it's playback stream name changed, but
pandora needs it for it's playback path. Update to correct stream
name so that playback works again.

Also mark VIBRA output as not connected.

Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:46:40 +00:00
Anuj Aggarwal bd6ddcb41d ASoC: Modifying the license string GPLv2 for OMAP3 EVM
Correcting the license string from GPLv2 -> GPL v2.
Found the problem while building OMAP3 ASoC driver as
module.

Signed-off-by: Anuj Aggarwal <anuj.aggarwal@ti.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:46:39 +00:00
Mark Brown 1452556beb Merge branch 'topic/asoc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 into for-2.6.33 2009-11-18 13:42:05 +00:00
Troy Kisky 57512c6432 ASoC: DaVinci: remove requirement that dma_params is 1st in structure
Remove requirement that dma_params is 1st in the structures
davinci_audio_dev and davinci_mcbsp_dev.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:35:06 +00:00
Jassi Brar 357a1db94e ASoC: Added the CPU driver for PCM controllers
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:35:05 +00:00
Jassi Brar d3ff5a3e61 ASoC: Rename 's3c24xx-pcm' driver to 's3c-dma'
Making room for namespace for the PCM Controller driver
the platform driver(s3c24xx-pcm) has been renamed to SoC
agnostic name 's3c-dma'.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:35:03 +00:00
Jassi Brar faa31776e4 ASoC: Rename s3c24xx_pcm prefix to s3c_dma
The s3c24xx_pcm prefix for the soc_platform is inappropriate when
some Samsung SoCs have PCM controllers which will eventually have
drivers and hence namespace ambiguities.

To resolve naming ambiguities in future the following have been
renamed in order
1) s3c24xx_pcm_dma_params -> s3c_dma_params
2) s3c24xx_pcm_preallocate_dma_buffer -> s3c_preallocate_dma_buffer
3) s3c24xx_pcm_dmamask -> s3c_dma_mask
4) s3c24xx_pcm_XXX -> s3c_dma_XXX

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-18 13:35:03 +00:00
Marin Mitov f9ede4eca0 ASoC: Use DMA_BIT_MASK(32) instead of deprecated DMA_32BIT_MASK
Signed-off-by: Marin Mitov <mitov@issp.bas.bg>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-11-17 09:04:06 +01:00
Mike Rapoport 8df89bc35c ASoC: OMAP: enable Overo driver for CM-T35
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Acked-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-16 16:02:03 +00:00
Mark Brown 0a3f5e35aa ASoC: Remove redundant snd_soc_dapm_new_widgets() calls
The DAPM widgets are now insntantiated by the core when creating the card
so there is no need for the individual CODEC drivers to do so.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-12 23:15:08 +00:00
Joonyoung Shim c871a05315 ASoC: Add jack_status_check callback function for GPIO jacks
The jack_status_check callback function is the interface to check the
status of the jack. Some target provides the method to distinguish what
is the jack inserted - headphone jack, microphone jack, tvout jack, etc,
so we can implement it using the jack_status_check function.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-12 16:45:53 +00:00
Barry Song f773205300 ASoC: move setting ac97 platformdata earlier than ac97 read/write
While probing, AC97 codec drivers and soc-core generically execute the
following sequence:
snd_soc_new_ac97_codec -> snd_soc_new_pcms -> reset ac-link/read AC97 ID
to detect ->...  -> set platform_data to ac97 by soc-core

commit 474828a40f adds platform_data to
snd_ac97 instance. But ac97 platform data hasn't given to snd_ac97
before actual ac97 operations. Then while ac97_read access platform_data
of snd_ac97 for detecting, NULL pointer oops will fire. That means old
platform_data patch doesn't work in real-life cases.

This patch moves the operation of setting ac97 platform_data earlier
than ac97 reading/writing operations. Then it makes platform_data of
AC97 become practically useful.

Signed-off-by: Barry Song <21cnbao@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-12 16:45:52 +00:00
Jassi Brar ba2b87f5a9 ASoC: Fixed arguments passed to SMDK64xx set_pll
Corrected the order of 'source' and 'pll_id' arguments.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-12 16:45:51 +00:00
Mark Brown 7aae816dae ASoC: Add bit clock rate calculator utility functions
Many devices need to calculate the bit clock rate desired to
work out the clock configuration required for the device.
Provide utility functions to do this using both hw_params
structures and raw numbers.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-11-12 16:45:48 +00:00
Tony Lindgren 774facda20 Merge branch '7xx-iosplit-plat' with omap-fixes 2009-11-10 18:10:34 -08:00
Grant Likely a68cc8daeb ASoC: mpc5200: remove duplicate identical IRQ handler
The TX and RX irq handlers are identical.  Merge them

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-10 13:02:01 +00:00
Peter Ujfalusi 68d019553b ASoC: TWL4030: Do not modify the APLL_CTL register
APLL_CTL register is configured by the twl4030-codec MFD
driver.
Remove code, which makes changes in the APLL_CTL register,
and replace those with checks against the configured
audio_mclk configuration done in the MFD driver.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-10 12:08:15 +00:00
Graeme Gregory 5f63ef9909 ASoC: omap-mcbsp - add support for upto 16 channels.
This patch increases the number of supported audio channels from 4
to 16 and has been sponsored by Shotspotter Inc. It also fixes a
FSYNC rate calculation bug when McBSP is FSYNC master.

Signed-off-by: Graeme Gregory <gg@slimlogic.co.uk>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-10 11:58:21 +00:00
Jarkko Nikula 9e5d86fe6a ASoC: Pandora: Pass SRG input clock frequency to the OMAP McBSP DAI
Upcoming change to omap-mcbsp.c require that machine drivers using OMAP
as a DAI master to pass sample rate generator input clock frequency to
the omap-mcbsp.c DAI driver.

Pandora is using 256*Fs output from the TWL4030 codec as an input clock to
the McBSP sample rate generator.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Tested-by: Grazvydas Ignotas <notasas@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-09 13:18:34 +00:00
Grant Likely c939e5c821 ASoC/mpc5200: fix enable/disable of AC97 slots
The MPC5200 AC97 driver is disabling the slots when a stop
trigger is received, but not reenabling them if the stream
is started again without processing the hw_params again.

This patch fixes the problem by caching the slot enable bit
settings calculated at hw_params time so that they can be
reapplied every time the start trigger is received.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-07 12:40:09 +00:00
Grant Likely 1d8222e8df ASoC/mpc5200: add to_psc_dma_stream() helper
Move the resolving of the psc_dma_stream pointer to a helper function
to reduce duplicate code

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-07 12:40:09 +00:00
Grant Likely c487827475 ASoC/mpc5200: Improve printk debug output for trigger
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-07 12:40:08 +00:00
Grant Likely d56b6eb6df ASoC/mpc5200: get rid of the appl_ptr tracking nonsense
Sound drivers PCM DMA is supposed to free-run until told to stop
by the trigger callback.  The current code tries to track appl_ptr,
to avoid stale buffer data getting played out at the end of the
data stream.  Unfortunately it also results in race conditions
which can cause the audio to stall.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-07 12:40:08 +00:00
Grant Likely 8f159d720b ASoC/mpc5200: Track DMA position by period number instead of bytes
All DMA blocks are lined up to period boundaries, but the DMA
handling code tracks bytes instead.  This patch reworks the code
to track the period index into the DMA buffer instead of the
physical address pointer.  Doing so makes the code simpler and
easier to understand.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-07 12:40:08 +00:00
Takashi Iwai 4cae37fa98 ASoC: Remove dead code and labels
Remove the dead code and labels "card_err" in the error paths of
some codec drivers.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-11-07 10:18:22 +01:00
Mark Brown 330f28f691 Merge branch 'for-2.6.32' into for-2.6.33 2009-11-06 15:46:18 +00:00
Jassi Brar 6fc786d503 ASoC: S3C64XX I2S: Enable audio-bus clock
Added the missing clk_enable after acquiring the 'audio-bus' clock.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-06 13:54:26 +00:00
Janusz Krzysztofik 4d187fb830 ASoC: OMAP: Don't try to set unsupported OMAP_DMA_DATA_BURST_16 on OMAP1
After DMA burst mode has been introduced in sound/soc/omap/omap-pcm.c,
omap_pcm_prepare() unconditionally calls:

        omap_set_dma_src_burst_mode(prtd->dma_ch, OMAP_DMA_DATA_BURST_16);
        omap_set_dma_dest_burst_mode(prtd->dma_ch, OMAP_DMA_DATA_BURST_16);

Current implementation of those two functions found in
arch/arm/plat-ompa/dma.c doesn't support OMAP_DMA_DATA_BURST_16 on OMAP1 at
all, so they both end with BUG() on that machine. That results in
ASoC being completely unusable, at least on my OMAP5910 based Amstrad Delta.

The patch corrects the problem by not calling those two functions when run on
OMAP1 class based machines.

Created against linux-2.6.32-rc5.
Tested on Amstrad Delta.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Acked-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-06 13:54:26 +00:00
Jaroslav Kysela d355c82a01 ALSA: rename "PC Speaker" and "PC Beep" controls to "Beep"
To avoid confusion in control names for the standard analog PC Beep generator
using a small Internal PC Speaker, rename all related "PC Speaker" and "PC
Beep" controls to "Beep" only. This name is more universal and can be also
used on more platforms without confusion.

Introduce also "Internal Speaker" in ControlNames.txt for systems with
full-featured build-in internal speaker.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-11-05 09:00:18 +01:00
Mark Brown f3d0e82fe3 ASoC: Update ads117x to current APIs
Probe as a platform driver (ads117x) and remove the call to
snd_soc_init_card().

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-04 21:43:27 +00:00