Commit Graph

757 Commits (752ec2f2d97da34abffa1abff81c96183a895b28)

Author SHA1 Message Date
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
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
Takashi Iwai b00615d163 Merge branch 'topic/pcm-dma-fix' into topic/core-change 2009-12-01 15:58:15 +01:00
Mark Brown 5c5452f703 Merge branch 'for-2.6.32' into for-2.6.33 2009-11-27 16:56:22 +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 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
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
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
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
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
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
Graeme Gregory 2dcf9fb99d ASoC: ADS117x ADC driver
This patch adds support for the TI ADS117x family of multichannel ADCs
and was sponsored by Shotspotter Inc.

Signed-off-by: Graeme Gregory <gg@slimlogic.co.uk>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-04 21:27:53 +00:00
Mark Brown fe3e78e073 ASoC: Factor out snd_soc_init_card()
snd_soc_init_card() is always called as the last part of the CODEC probe
function so we can factor it out into the core card setup rather than
have each CODEC replicate the code to do the initialiastation. This will
be required to support multiple CODECs per card.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-03 22:14:43 +00:00
Mark Brown 529697c546 ASoC: Staticise wm8727 driver structure
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-03 22:14:31 +00:00
Peter Ujfalusi b3f5a272a3 ASoC: TWL4030: Make sure, that the codec is powered on startup
Set the codec->bias_level to SND_SOC_BIAS_OFF before changing
the initial bias level to STANDBY.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-02 17:28:00 +00:00
Neil Jones 89933dee5b ASoC: Add support for the WM8727 DAC.
Add support for the Wolfson Microelectronics WM8727 DAC, this is a simple
non-configurable DAC.

Signed-off-by: Neil Jones <neil.jones@imgtec.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-11-02 15:24:19 +00:00
Takashi Iwai e87a3dd33e Merge branch 'fix/misc' into topic/misc 2009-11-01 11:11:07 +01:00
Roel Kluin 84ed1a1942 ALSA: Cleanup redundant tests on unsigned
The variables are unsigned so the test `>= 0' is always true,
the `< 0' test always fails. In these cases the other part of
the test catches wrapped values.

In dac_audio_write() there does not occur a test for wrapped
values, but the test appears redundant.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-10-30 12:25:07 +01:00
Peter Ujfalusi 1c3d200271 ASoC: TWL4030: Add APLL supply for the capture path
Capture path also need the APLL enabled, adding DAPM_SUPPLY
for the Virtual ADCs.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-29 12:58:22 +00:00
Peter Ujfalusi 7729cf7493 ASoC: TWL4030: Change APLL powering sequence
It seams that certain part of the twl4030 codec needs the APLL
enabled before they are enabled.
Paths which has any digital processing needs need the APLL
enabled before they can function.
For example the vibra output will have some random data after
it is enabled and before the APLL also enabled.

If only analog components are in use (analog bypass), than it
seams, that the APLL does not need to be enabled. This lowers
the power consumption with around ~0.005A.

Adding DAPM_SUPPLY to the Digital playback route and also
to the capture route to enable and disable the APLL.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-29 12:58:21 +00:00
Jari Vanhala 86139a13ce ASoC: TWL4030: Vibra motor stop fix when it is driven with audio
This patch fixes vibrator playing incoherently, when driven
with audio. There is something wrong in switch 3 at
H-bridge and VIBRA_SET still affects PWM generator.
Slowest value fixes things.

Signed-off-by: Jari Vanhala <ext-jari.vanhala@nokia.com>
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-29 12:58:21 +00:00
Daniel Mack 7e1aa1dcd0 ASoC: CS4270: export de-emphasis filter as ALSA control
The CS4270 codec features an de-emphasis filter for compensation of
audio material filtered by an 50/15 uS algorithm. Not sure whether we
should always enable it for 44100Hz sampling frequency, but it should at
least be configurable by the user.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-29 12:58:13 +00:00
Peter Ujfalusi 2845fa13e5 ASoC: TWL4030: Change codec_muted to apll_enabled
codec_muted is missleading, change it to apll_enabled,
which is what it is doing: enabing and disabling the APLL.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-28 10:04:21 +00:00
Peter Ujfalusi 78e08e2f20 ASoC: TWL4030: Remove bypass tracking
Since ASoC core now handling the codec bias differently
there is no need to do the tracking of bypass switch states
anymore.

Handling of the common bit for analog loopbacks is done with
DAPM_SUPPLY for the bypass paths.

Now this bit is only enabled when there is a complete analog
bypass path, compared to the previous implementation, when the
global switch was enabled if there were any of the analog
bypass switch was on (regardless if there were complete path or
not)

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-28 10:04:21 +00:00
Mark Brown 7dea7c01da ASoC: Add regulator support for WM8731
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-26 15:37:37 +00:00
Peter Ujfalusi 7a1fecf57f ASoC: TWL4030: Driver registration via twl4030_codec MFD
Change the way how the twl4030 soc codec driver is
loaded/probed.
Use the device probing via tlw4030_codec MFD device.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-25 17:15:10 +00:00
Peter Ujfalusi 1f0f9b67f9 ASoC: TWL4030: use the twl4030-codec.h for register descriptions
Remove the register descriptions from the twl4030.h file and use
the linux/mfd/twl4030-codec.h instead, which has the codec
related register descriptions also.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-25 17:15:10 +00:00
Peter Ujfalusi 017deee639 ASoC: tlv320dac33: typo fix in the header
Fix the definition of DAC33_LTM field, the LTM bits in
FIFO_IRQ_MODE_B register are starting at bit 6.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-21 19:08:21 +01:00
Peter Ujfalusi d8707cecdf ASoC: TWL4030: Only update the needed bits in *set_dai_sysclk
Do not rewrite the whole register, but only update the needed
bits in set_dai_sysclk functions.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-19 16:12:17 +01:00
Peter Ujfalusi c8bf93f0fe ASoC: Codec driver for Texas Instruments tlv320dac33 codec
Driver for Texas Instruments TLV320DAC33 (SLAS546) low power stereo
audio DAC.

TLV320DAC33 is a stereo audio codec with integrated 24KB FIFO for low
power audio playback.

The digital interface can use I2S, DSP (A or B), Right and Left
justified formats.
DAC33 has stereo analog input, which can be bypassed to the analog
outputs.

Regarding to the internal 24KB FIFO the driver implements 'FIFO bypass'
mode (default) and nSample mode (FIFO is in use).
a) In 'FIFO bypass' mode the internal FIFO is not in use, the codec is
working synchronously as a normal codec (it needs constant stream of
data on the digital interface).

b) The nSample mode implementation uses one interrupt line from DAC33 to
the host:
Alarm threshold is set to 10ms of audio data (limit by the driver
implementation).
DAC33 will signal an interrupt, when the FIFO level goes under the
Alarm threshold.
The host will write to nSample register a value (number of stereo
samples), to tell DAC33 how many samples it should read in a burst from
the host. When the DAC33 received the number of samples, it disables the
clocks on the I2S bus. When the FIFO use again goes under the Alarm
threshold, DAC33 signals the host with an interrupt, and the process is
repeated.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-15 15:02:04 +01:00
Mark Brown d2058b0cd0 ASoC: Remove snd_soc_suspend_device()
The PM core will grow pm_link infrastructure in 2.6.33 which can be
used to implement the intended functionality of the ASoC-specific
device suspend and resume callbacks so drop them.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-15 15:01:43 +01:00
Peter Ujfalusi 814b7963e5 ASoC: TPA6130A2: Make tpa6130a2_power as static
The power for the amplifier should be handled internally
by the tpa6130a2 driver.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-12 13:40:54 +01:00
Mark Brown ebab1b1d07 ASoC: Minor fixups to tpa6130a2 driver
- Staticise ttpa6130a2_client.
- Remove unneeded cast from void.
- Use explict NULL rather than 0.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-09 19:13:47 +01:00
Peter Ujfalusi 493b67efff ASoC: TPA6130A2 amplifier driver
Driver for Texas Instruments TPA6130A2 stereo headphone
amplifier.

The driver provides playback gain control and also pre-defined
DAPM_HP widgets and DAPM routings for power management.

The DAPM_HP widget names are:
"TPA6130A2 Headphone Left"
"TPA6130A2 Headphone Right"

From soc machine drivers to use with the tpa6130a2 amplifier,
the tpa6130a2_add_controls has to be called, which adds the alsa
controls and the DAPM routing needed for the tpa6130a2.
After that the machine driver can connect the codec's output
with 'TPA6130A2 Left' and 'TPA6130A2 Right':

        {"TPA6130A2 Left", NULL, "CODEC LEFT OUT"},
        {"TPA6130A2 Right", NULL, "CODEC RIGHT OUT"},

Internally the left and right channels are powered separately.
When none of the channels are needed the amplifier is powered
down:
hard power: valid GPIO number is passed within platform data
soft power: Using the software shutdown of the amplifier

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-09 18:50:37 +01:00
Mark Brown b727916a1f Merge branch 'for-2.6.32' into for-2.6.33 2009-10-08 10:45:09 +01:00
Mark Brown 6f775ba015 Merge branch 'upstream/wm8350' into for-2.6.32 2009-10-06 19:29:47 +01:00
Mark Brown 5b7dde3468 ASoC: WM8350 capture PGA mutes are inverted
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-10-06 19:27:56 +01:00
Mark Brown 907bc6c7fc Merge branch 'for-2.6.32' into for-2.6.33 2009-10-06 16:01:27 +01:00
Mark Brown 2a0f5cb327 Merge branch 'for-2.6.32' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into for-2.6.32 2009-10-06 12:11:09 +01:00
Mark Brown d4a8da910e Merge branch 'for-2.6.32' into for-2.6.33 2009-10-05 10:36:28 +01:00
Jonathan Cameron e655a43544 ASoC: wm8940: Fix check on error code form snd_soc_codec_set_cache_io
Fix for typo in commit 8d50e447d1
ASoC: Factor out I/O for Wolfson 8 bit data 16 bit register CODECs

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-10-02 16:10:55 +01:00
Mark Brown f36c4045db Merge remote branch 'takashi/topic/asoc' into for-2.6.33 2009-10-01 11:33:37 +01:00
Takashi Iwai bb26276744 ASoC: Fix build errors of wm8711.c with SPI
Fix a couple of typos and a missing header file inclusion to build wm8711.c
properly with CONFIG_SPI_MASTER.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-10-01 07:39:45 +02:00
Mark Brown aa983d9d63 ASoC: Factor out analogue platform data from WM8993
This is also shared with newer CODECs.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-30 15:51:37 +01:00
Mark Brown 4c0bccbe66 Merge branch 'upstream/wm8974' into for-2.6.33 2009-09-30 15:48:38 +01:00
Mark Brown c36b2fc73a ASoC: Clean up WM8974 PLL configuration
Don't use a static for WM8974 PLL factors - we don't support more than
one device so it won't happen but no sense in leaving the race condition
hanging around.  Also, pre_div is a single bit and it's a bit simpler if
we move the handling of the factor of 4 in the output into the
coefficient setup.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-30 15:45:25 +01:00
Mark Brown 2c9ee33d37 Merge branch 'for-2.6.32' into for-2.6.33 2009-09-23 10:54:06 -07:00
Linus Torvalds fe61c99a12 Merge branch 'fix/asoc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'fix/asoc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ASoC: wm8753: fix mapping when MONOMIX is set to Stereo
  ASoC: some minor changes for AD1836 and AD1938 codec drivers
  ASoC: DaVinci: Fixes to McASP configuration
  ASoC: Blackfin I2S: fix resuming when device hasn't been used
  ASoC: Blackfin I2S: add lost platform_device parameter to resume function
  ASoC: fix typos in Blackfin headers
  ASoC: bf5xx-sport: the irq save/restore funcs take an unsigned long
  ASoC: Blackfin AC97: add a few missing multichannel define handling
2009-09-23 10:02:43 -07:00
Phil Vandry 877ae70763 ASoC: wm8753: fix mapping when MONOMIX is set to Stereo
When MONOMIX is set to Stereo, Left PGA was not powered on but should be.
Add a mapping from Capture Left Mux to Capture Left Mixer to fix the issue.

Signed-off-by: Phil Vandry <vandry@TZoNE.ORG>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-21 16:58:43 -07:00
Barry Song 98235a4bb0 ASoC: some minor changes for AD1836 and AD1938 codec drivers
1. delete redundant assignment to bus field in spi_driver structure
2. fix lost assignment to set_bias_level entry in ad1938 codec dai
3. change spi driver name of ad1836 from "ad1836-spi" to "ad1836"

Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-21 16:58:33 -07:00
Joe Perches a419aef8b8 trivial: remove unnecessary semicolons
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-09-21 15:14:58 +02:00
Mark Brown e0274b0a30 Merge branch 'upstream/wm8711' into for-2.6.33 2009-09-21 04:54:21 -07:00
Mark Brown 9f072b7b22 Merge branch 'for-2.6.32' into for-2.6.33 2009-09-18 15:09:44 +01:00
Takashi Iwai 673bca1906 Merge branch 'fix/asoc' into for-linus
* fix/asoc:
  ASoC: remove unused #include <linux/version.h>
  ASoC: S3C lrsync function made to work with IRQs disabled.
  ASoC: Fix display of stream name in DAPM debugfs
  ASoC: Clean up error handling in MPC5200 DMA setup
2009-09-17 21:08:53 +02:00
Huang Weiyi d4e54e871f ASoC: remove unused #include <linux/version.h>
Remove unused #include <linux/version.h>('s) in
  sound/soc/codecs/ad1836.c
  sound/soc/codecs/ad1938.c
  sound/soc/codecs/wm8974.c

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-16 21:08:54 +01:00
Takashi Iwai e0b3032bcd Merge branch 'topic/asoc' into for-linus
* topic/asoc: (226 commits)
  ASoC: au1x: PSC-AC97 bugfixes
  ASoC: Fix WM835x Out4 capture enumeration
  ASoC: Remove unuused hw_read_t
  ASoC: fix pxa2xx-ac97.c breakage
  ASoC: Fully specify DC servo bits to update in wm_hubs
  ASoC: Debugged improper setting of PLL fields in WM8580 driver
  ASoC: new board driver to connect bfin-5xx with ad1836 codec
  ASoC: OMAP: Add functionality to set CLKR and FSR sources in McBSP DAI
  ASoC: davinci: i2c device creation moved into board files
  ASoC: Don't reconfigure WM8350 FLL if not needed
  ASoC: Fix s3c-i2s-v2 build
  ASoC: Make platform data optional for TLV320AIC3x
  ASoC: Add S3C24xx dependencies for Simtec machines
  ASoC: SDP3430: Fix TWL GPIO6 pin mux request
  ASoC: S3C platform: Fix s3c2410_dma_started() called at improper time
  ARM: OMAP: McBSP: Merge two functions into omap_mcbsp_start/_stop
  ASoC: OMAP: Fix setup of XCCR and RCCR registers in McBSP DAI
  OMAP: McBSP: Use textual values in DMA operating mode sysfs files
  ARM: OMAP: DMA: Add support for DMA channel self linking on OMAP1510
  ASoC: Select core DMA when building for S3C64xx
  ...
2009-09-10 15:32:40 +02:00
Joonyoung Shim 2312fd8f6b ASoC: AK4671: add ak4671 codec driver
The AK4671 is a stereo CODEC with a built-in Microphone-Amplifier,
Receiver-Amplifier and Headphone-Amplifier.

The datasheet for the ak4671 can find at the following url:
http://www.asahi-kasei.co.jp/akm/en/product/ak4671/ak4671_f01e.pdf

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-10 00:27:57 +01:00
Mark Brown 87831cb660 ASoC: Fix WM835x Out4 capture enumeration
It's the 8th enum of a zero indexed array. This is why I don't let
new drivers use these arrays of enums...

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-09-07 18:56:24 +01:00
Mark Brown 85488037bb ASoC: Add source argument to PLL configuration
More and more devices feature PLLs and FLLs with the ability to select
between multiple input clocks. In order to better support these devices
a new argument, source, has been added to the set_pll() configuration
API. Using set_clkdiv() is often difficult due to the need to stop the
PLL/FLL before any reconfiguration can be done.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-05 18:52:16 +01:00
Mark Brown 2eff31e809 ASoC: Fully specify DC servo bits to update in wm_hubs
Avoids potential issues if we read back unexpected values during
a read/modify/write cycle.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-02 19:36:22 +01:00
jassi brar 5c0d38c947 ASoC: Debugged improper setting of PLL fields in WM8580 driver
Bug was caught while trying to use WM8580 as I2S master on SMDK.
Symptoms were lesser LRCLK read by CRO(41.02 instead of 44.1 KHz) Solved
by referring to WM8580A manual and setting mask value correctly and
making the code to not touch 'reserved' bits of PLL4 register.

Signed-off-by: Jassi <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-09-01 11:37:41 +01:00
Mark Brown f1e887de2d ASoC: Don't reconfigure WM8350 FLL if not needed
If the requested FLL configuration is the one we're currently running
in it's at best pointless to reconfigure the FLL.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-26 15:27:57 +01:00
Mark Brown 977d49e00d ASoC: Make platform data optional for TLV320AIC3x
Now that we don't need the I2C address for the device the platform data
is redundant so allow it to be omitted.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Chaithrika U S <chaithrika@ti.com>
2009-08-26 15:27:56 +01:00
Mark Brown e4aa8dd5ca Merge branch 'topic/digital-mixing' into for-2.6.32 2009-08-24 20:44:41 +01:00
Takashi Iwai c6ea2af76a ASoC: Remove unneeded inclusion of linux/regulator/consumer.h
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-08-24 09:41:32 +02:00
Roel Kluin 821ebc86ef ASoC: free socdev if init_card() fails in wm9705_soc_probe()
Free socdev if snd_soc_init_card() fails.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-23 10:41:06 +01:00
Kuninori Morimoto a3a83d9a7c ASoC: Add ak4642/ak4643 codec support
This is very simple driver for ALSA
It supprt headphone output and stereo input only
This patch is tested by ms7724se

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-21 10:54:02 +01:00
Ben Dooks cb3826f524 ASoC: tlv320aic3x: Change to use device model
The tlv320aic3x driver managed its own i2c device, instead of an extant
one created by the board support code. Change the code to make it so that
the driver binds to an extant (in this case i2c) device.

Add explict tlv320aic33 as well as tlv320aic3x to the supported device
table and remove the old driver bindings from the users of this code.

Signed-off-by: Ben Dooks <ben@simtec.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-21 10:52:49 +01:00
Mark Brown b5ab887e6d ASoC: Add TLV information to WM8711
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 21:29:31 +01:00
Mark Brown 431f777177 ASoC: WM8711 minor cleanups
Coding style changes only.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 21:17:34 +01:00
Mark Brown 08aff8cd7a ASoC: Add SPI support to WM8711
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 21:15:14 +01:00
Mark Brown d97d2e35b9 ASoC: Factor out WM8711 cache I/O
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 21:12:30 +01:00
Mark Brown f72222c74b Merge branch 'topic/asoc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 into upstream/wm8711 2009-08-18 20:59:01 +01:00
Mark Brown 318b0b8d90 ASoC: Update WM8711 to driver model registration method
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 20:57:33 +01:00
Mike Arthur bd6d417743 ASoC: Add WM8711 CODEC driver
The WM8711 or WM8711L (WM8711/L) is a low power stereo DAC with an
integrated headphone driver. The WM8711/L is designed specifically for
portable MP3 audio and speech players. The WM8711/L is also ideal for
MD, CD machines and DAT players.

Signed-off-by: Mike Arthur <Mike.Arthur@wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 20:37:49 +01:00
Mark Brown 59ae07a580 ASoC: WM8993 digital mixing support
The WM8993 provides digital sidetone paths and also allows each
channel on the audio interface to be routed separtately to the
DACs and ADCs.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 16:06:13 +01:00
Mark Brown d1a5e44b89 ASoC: Remove duplicate ADC/DAC widgets from wm_hubs.c
These need to be in the CODEC since the DAIs supported by the CODECs
aren't static.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-18 16:04:24 +01:00
Mark Brown d3c9e9a139 ASoC: Implement TDM configuration for WM8993
Note that the number of slots used internally is specified in terms
of stereo slots while the external API works with mono slots.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-17 18:53:50 +01:00
Mark Brown 0182dcc52c ASoC: Fix WM8993 MCLK configuration for high frequency MCLKs
When used without the PLL we were accidentally clearing the MCLK/2
divider, resulting in a double rate SYSCLK when the divider should
have been used.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-17 18:53:44 +01:00
Shine Liu 0c093fb542 ASoC: UDA134X: Fix mistaken mute/unmute code
There is a mistake in current uda134x_mute function: mute_reg has been
changed in line 162 or line 164, so uda134x_write should write
"mute_reg" but not "mute_reg & ~(1<<2)" to
UDA134X_DATA010.

Signed-off-by: Shine Liu <shinel@foxmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-17 12:56:57 +01:00
Mark Brown 1e97f50b70 ASoC: Factor out cache I/O from WM8974
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-15 12:15:10 +01:00
Mark Brown 37cfa1950e Merge branch 'wm8974-upstream' into for-2.6.32 2009-08-15 11:52:43 +01:00
Barry Song 2a708137fd ASoC: delete -spi suffix in ad1938 and free private data while registers fail
Signed-off-by: Barry Song <21cnbao@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-14 17:53:02 +01:00
Peter Ujfalusi 9028935d75 ASoC: TWL4030: Fix for capture mixer strings
Change the strings related to capture in order to be
interpreted correctly by alsamixer and possible other
UI based mixer applications.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-14 17:52:59 +01:00
Mark Brown a2342ae325 ASoC: Factor out shared code from WM8993
The WM8993 analogue control is shared with other devices in the same
product line.  Since this is a very substantial proportion of the
driver move the definitions of these controls into a new wm_hubs module
which allows them to be shared between the two.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-13 22:19:31 +01:00
Mark Brown e9ade7f933 ASoC: Minor cleanups to AD1938 driver
- Build in SND_SOC_ALL_CODECS.
- Remove null suspend/resume stuff.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-13 15:19:42 +01:00
Barry Song 7eaae41ea5 new ad1836 codec driver based on asoc
There has been an ad1836 driver in sound/blackfin based on traditional alsa.
The new driver is based on asoc. The architecture of ad1836 codec driver is
very much like ad1938.

Signed-off-by: Barry Song <21cnbao@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-13 15:18:53 +01:00
Peter Ujfalusi 9008adf9a9 ASoC: TWL4030: Introduce PGAs for outputs
Dynamically control and control only the needed output amplifier
muting/un-muting.

The original code was muting and un-muting the following output
amplifiers: Earpiece PreDrivL/R, CarkitL/R at the same time
regardless which pin is actually in use at the given moment.

Move these as separate PGA so only the needed amplifier will be touched.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-13 14:56:13 +01:00
Barry Song c4ff357ada ASoC: add output/input widgets in ad1938 to make dac/adc dynamic PM work
According to the function dapm_dac_check_power() in
sound/soc/soc-dapm.c, dac power can't be on/off stand-alone without any
output widget as sink. And according to dapm_adc_check_power(), adc
power can't be on/off stand-alone without any input widget as source. So
we can't only define some stand-alone SND_SOC_DAPM_DAC/SND_SOC_DAPM_ADC
to hope their power can be managed dynamically.

Signed-off-by: Barry Song <21cnbao@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-13 10:47:22 +01:00
Mark Brown d2a382143b ASoC: Update AD1938 for new TDM slot API
It's only actually paying attention to the slot count anyway.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-12 14:30:33 +01:00
Mark Brown e0026beac0 ASoC: Update WM9081 for tdm_slot() API change
Store the TDM slot width then if it's set use that rather than the
sample size to calculate BCLK. Leave imposing constraints to the
core (which should do this but doesn't yet) or machine driver.

Also allow 0 TDM slots to be configure (for use when disabling TDM).

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-11 16:29:21 +01:00
Mark Brown 1921bab217 Merge commit 'a5479e389e989acfeca9c32eeb0083d086202280' into for-2.6.32 2009-08-11 13:09:27 +01:00
Mark Brown e0c48a18f7 ASoC: Drop unneeded declaration of removed wm8731 SPI write function
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-10 12:59:29 +01:00
Mark Brown 35b1207b34 ASoC: Convert WM8776 to use factored out register cache code
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-08 10:37:33 +01:00
Mark Brown 06cddefc1f Merge branch 'reg-cache' into for-2.6.32 2009-08-07 11:43:58 +01:00
Daniel Ribeiro a5479e389e ASoC: change set_tdm_slot api to allow slot_width override.
Extend set_tdm_slot to allow the user to arbitrarily set the frame width
and active TX/RX slots.

Updates magician.c and wm9081.c for the new set_tdm_slot(). wm9081.c
still doesn't handle the slot_width override.

While being there, correct an incorrect use of SlotsPerFrm(7) use in
bitmask on pxa-ssp.c (SSCR0_SlotsPerFrm(x) is (((x) - 1) << 24)) ).

(this series is meant for Mark's for-2.6.32 branch)

Signed-off-by: Daniel Ribeiro <drwyrm@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-06 15:52:24 +01:00
Janusz Krzysztofik 9029bb316b ASoC: CX20442: simplify codec controller usage
This patch is a workaround for the problem of several subsequent control
statements not being applied correctly to the codec controller (modem).

In order to follow the hook switch state change from handset to handsfree
while
in full duplex mode, two consecutive +VLS control commands were sent to the
modem. The first one was M1 (microphone only), the seconds one was M1S1 (both
microphone and speaker). As there was no real modem handshaking procedure
implemented, neither in the codec nor in the machine driver part of the line
discipline, the modem was having the second command missed.

Since a possibility to switch to microphone only mode (and speaker only mode
as well) seams of no value, I have modified the code to issue single M1S1
command only for any of those cases.

Tested on my Amstrad Delta.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-06 11:36:46 +01:00
Janusz Krzysztofik 4977b03e3d ASoC: CX20442: add some debugging
This patch adds debugging statement that can help in tracing
how the driver is trying to control the codec device.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-06 11:36:45 +01:00
Mark Brown 924914ee95 ASoC: Add WM8776 CODEC driver
The WM8776 is a high performance, stereo audio CODEC with five channel
input selector. The WM8776 is ideal for surround sound processing
applications for home hi-fi, DVD-RW and other audio visual equipment.

This driver implements support for most WM8776 features - currently the
ADC automatic level control/limiter functionality is omitted.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-06 11:36:45 +01:00
Daniel Mack 15b5bdaeeb ALSA: ASoC: cs4270: move power management hooks to snd_soc_codec_device
Power management for the cs4270 codec is currently implemented as part
of the i2c_driver struct. The disadvantage of doing it this way is that
the callbacks registered in the snd_soc_card struct are called _before_
the codec's callbacks.

That doesn't work, because the snd_soc_card callbacks will most likely
switch down the codec's power domains or pull the reset GPIOs, and
hence make the i2c communication bail out.

Fix this by binding the suspend and resume code to the
snd_soc_codec_device driver model and let the I2C functions only call
the SoC core function for resume and suspend, which do nothing currently
but will do later.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-05 22:13:49 +01:00
Mark Brown 27ded041f0 ASoC: Factor out 7 bit register 9 bit data SPI write
This converts all the Wolfson drivers using this format (the only devices
that do) except WM8753 to use it.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-03 16:59:16 +01:00
Mark Brown 8d50e447d1 ASoC: Factor out I/O for Wolfson 8 bit data 16 bit register CODECs
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-03 16:59:16 +01:00
Mark Brown 7084a42b96 ASoC: Add I/O control bus information to factored out cache setup
While writes tend to be able to use a fairly bus independant format to
do the writes reads are all bus specific. To allow us to factor out
this code include the bus type as a parameter when setting up the
cache.

Initially just use this to factor out hw_write_t for I2C.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-03 16:59:09 +01:00
Janusz Krzysztofik ad120dae12 ASoC: CX20442: push down machine independent line discipline bits
This corrected patch adds machine independent line discipline code, prevoiusly
exsiting inside my Amstrad Delta ASoC machine dirver, to the Conexant CX20442
codec driver. The code can be used as a standalone line discipline, or as a
set of codec specific functions called from machine's line discipline
callbacks. Anyway, the line discipline itself must be registered by a machine
driver.

Applies on top of the followup to my initial driver version:
http://mailman.alsa-project.org/pipermail/alsa-devel/2009-July/019757.html

Suggested by ASoC manintainer Mark Brown <broonie@opensource.wolfsonmicro.com>

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-31 22:38:44 +01:00
Barry Song 3a39f832a5 ASoC: Fix checkpatch issues and typos of ad1938 codec and bf5xx-tdm dai
1. fix "line over 80 characters" checkpatch warnings
2. ‘DMA_nnBIT_MASK’ is deprecated, use DMA_BIT_MASK instead
3. fix typos

Signed-off-by: Barry Song <21cnbao@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-29 21:31:53 +01:00
Janusz Krzysztofik b84eab08a6 ASoC: CX20442: fix issues pointed out by subsystem maintainer
The patch fixes some checkpatch identified issues and adds a comment about
line discipline interaction to my driver code, as requested by Mark on my
inital submission (thank you Mark for applying my imperfect patch anyway).
It also fixes MODULE_ALIAS mismatch as used in my machine driver.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-28 22:15:23 +01:00
Takashi Iwai 7679d5c65b Merge branch 'fix/asoc' into for-linus
* fix/asoc:
  ASoC: tlv320aic3x: Enable PLL when not bypassed
2009-07-26 11:07:03 +02:00
Joonyoung Shim a7569afa8b ASoC: MAX9877: fix write operation for register
The MAX9877 needs an address of start register when we write values to
registers through i2c_master_send(), but the code for this was missed in
max9877_write_regs().

If the value of control is 0 in the max9877_set_out_mode(), the value is
not increased to 1, but actually the value to write to the register
should be 1.
And the register bits for out_mode and osc_mode should be cleared before
writing.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-23 11:08:30 +01:00
Janusz Krzysztofik 459dc35233 ASoC: Add support for Conexant CX20442-11 voice modem codec
This patch adds support for Conexant CX20442-11 voice modem codec, suitable
for use by the ASoC board driver for Amstrad E3 (Delta) videophone. Related
sound card driver will follow.

This codec is an optional part of the Conexant SmartV three chip modem design.
As such, documentation for its proprietary digital audio interface is not
available. However, on Amstrad Delta board, thanks to Mark Underwood who
created an initial, omap-alsa based sound driver a few years ago[1], the codec
has been discovered to be accessible not only from the modem side, but also
over the OMAP McBSP based CPU DAI. Thus, the driver can be used by any sound
card that can access the codec DAI directly. The DAI configuration parameters
(sample rate and format, number of channels) has been selected out empirically
for best user experience.

The codec analogue interface consists of two pairs of analogue I/O pins:
speakerphone interface or telephone handset/headset interface. Furthermore, it
seams to provide two operation modes for speakerphone I/O: standard and
advanced, with automatic gain control and echo cancelation. Even if the codec
control interface is unknown and not available, all those interfaces and modes
can be selected over the modem chip using V.253 commands. The driver is able
to issue necessary commands over a suitable hw_write function if provided by a
sound card driver. Otherwise, the codec can be controlled over the modem from
userspace while inactive.

Even if nothig is known about the codec internal power management
capabilities, DAPM widgets has been used to model the codec audio map.
Automatically performed powering up/down of those virtual widgets results in
corresponding V.253 commands being issued.

Some driver features/oddities may be board specific, but I have no way to
verify that with any board other than Amstrad Delta.

[1] http://www.earth.li/pipermail/e3-hacking/2006-April/000481.html

Created and tested against linux-2.6.31-rc3.
Applies and works with linux-omap-2.6 commit
7c5cb7862d as well.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-23 11:08:29 +01:00
Mark Brown c30853df98 Merge branch 'for-2.6.31' into for-2.6.32 2009-07-23 08:22:58 +01:00
Chaithrika U S 06c71282a9 ASoC: tlv320aic3x: Enable PLL when not bypassed
PLL was not being enabled when it was not bypassed. This patch
enables the PLL when it is used. Additionally, it disables the PLL
when it is bypassed.

Without this patch, the audio on TI DM646x EVM and DM355 EVM
does not work properly. The bit clocks and the frame sync signals
from the codec are not correct and hence the playback/record are faster
than usual for most sample rates. The reason for this was that the PLL
was not enabled when it was not bypassed.

Tested on DM6467 EVM, playback tested on DM355 EVM.

Signed-off-by: Chaithrika U S <chaithrika@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-23 08:14:29 +01:00
Joonyoung Shim e458a48f87 ASoC: MAX9877: separate callback functions
The callback function to control register was used by whole controls in
MAX9877 driver, but this causes using many if statement for double
register control or invert.
So, the callback function for double register control is separate
differently, and the code for invert is added in the callback function.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-22 11:02:49 +01:00
javier Martin 25cbf46520 ASoC: Correct a bug with "ADC Inversion Switch" in wm8974 codec.
This corrects a bug with ADC Inversion Switch in wm8974 codec.

Signed-off-by: Javier Martin <javier.martin@vista-silicon.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-22 00:13:27 +01:00
Mark Brown bca146578c ASoC: Fix checkpatch issues in AD1938
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-18 11:09:42 +01:00
Mark Brown 0c11f65555 ASoC: Fix FLL reference clock division setup in WM8993
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-17 22:13:01 +01:00
Mark Brown 8aa2df5308 ASoC: Bodge around GCC 4.4.0 flow analysis bug in GCC 4.4.0
GCC 4.4.0 doesn't appear to be able to spot that we don't apply any FLL
configuration if the output frequency is zero.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-17 21:53:49 +01:00
Takashi Iwai 416c8fe3cd ASoC: Kill direct accesses to driver_data
Replaced with dev_{get|set}_drvdata().

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-17 07:48:03 +02:00
Barry Song 1274738d85 ASoC: new ad1938 codec driver based on asoc
Signed-off-by: Barry Song <21cnbao@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-16 11:14:39 +01:00
Joonyoung Shim 9db9ed977d ASoC: MAX9877: add MAX9877 amp driver
The MAX9877 combines a high-efficiency Class D audio power amplifier
with a stereo Class AB capacitor-less DirectDrive headphone amplifier.

The max9877_add_controls() is called to register the MAX9877 specific
controls on machine specific init() of the machine driver.

The datasheet for the MAX9877 can find at the following url:
http://datasheets.maxim-ic.com/en/ds/MAX9877.pdf

[Slight edit to sort the ALL_CODECS entries -- broonie.]

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-15 16:59:31 +01:00
Mark Brown 4b75e94767 ASoC: Error out if we can't determine a suitable WM9081 sysclk
Due to the flexibility of the WM9081 FLL this should never happen
in a real system.

Reported-by: Jaswinder Singh Rajput <jaswinder@kernel.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-15 11:03:51 +01:00
Mark Brown e465d544fa ASoC: Fix sample rate lookup in WM8993
We need to use the best value we picked, not the last value we
looked at.

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-15 10:01:30 +01:00
Kevin Hilman 0a0cf58d93 ASoC: spdif: set module licence to GPL
Without MODULE_LICENCE("GPL"), when built as a module it will fail
to load because it uses other GPL symbols from kernel.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-13 23:01:30 +01:00
Kevin Hilman a27e304b5c ASoC: spdif codec: enable use by modules
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-13 23:01:30 +01:00
Roel Kluin 33e319fba7 ASoC: Keep index within stac9766_reg[]
Keep index within stac9766_reg[]

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-13 10:32:18 +01:00
Greg Kroah-Hartman 864e1e8db4 Sound: remove direct access of driver_data
This is the last in-kernel direct usage of driver_data, replace it with
the proper dev_get/set_drvdata() calls.

Cc: Takashi Iwai <tiwai@suse.de>
Cc: Jaroslav Kysela <perex@perex.cz>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-07-12 13:02:10 -07:00
Mark Brown 030c819e79 Merge branch 'tlv320aic3x' into reg-cache 2009-07-10 21:06:33 +01:00
Mark Brown cc369cf504 ASoC: WM8510 has a single frame clock so needs symmetric rates
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-09 11:28:07 +01:00
Mark Brown 4934482d93 ASoC: Limit WM8731 to symmetric rates
While the hardware is capable of some limited asynmmetric modes the
driver does not currently support those modes so tell applications
that only symmetric rates are available.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08 17:48:12 +01:00
Mark Brown 942c435ba7 ASoC: Add WM8993 CODEC driver
The WM8993 is a highly integrated ultra-low power hi-fi CODEC designed
for portable devices such as multimedia phones.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08 17:20:20 +01:00
Mark Brown ef38ed888e ASoC: Correct WM8731 Mic Capture Switch control name
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08 17:18:28 +01:00
Mark Brown d00efa648d ASoC: Add TLV information for WM8731
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08 17:08:40 +01:00
Mark Brown 4ec5c9693b Merge branch 'for-2.6.31' into for-2.6.32 2009-07-06 21:49:35 +01:00
Mark Brown f6f1eb1033 ASoC: Factor out WM8580 register cache code
Note the slightly tricky cache usage in the volume update function due
to the requirement for a separate write for the VU bit.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 17:57:57 +01:00
Mark Brown 5f345346dd ASoC: Remove use of hw_read from TLV320AIC3x driver
The TLV320AIC3x driver is currently the only user of the CODEC hw_read
operation and is jumping through some hoops in order to do so.  In order
to support future refactoring to make the hw_read operation more usable
unwrap the usage in this driver to avoid its use.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 17:35:28 +01:00
Mark Brown 1e30a5828e ASoC: Remove unused AK4535 hardware read functionality
Nothing uses it and the existing hw_read operation needs to be
refectored so it's easier to remove it rather than work with it.
Support can be re-added if the code requires volatile registers.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 17:28:41 +01:00
Mark Brown 17a52fd60a ASoC: Begin to factor out register cache I/O functions
A lot of CODECs share the same register data formats and therefore
replicate the code to manage access to and caching of the register
map. In order to reduce code duplication centralised versions of
this code will be introduced with drivers able to configure the use
of the common code by calling the new snd_soc_codec_set_cache_io()
API call during startup.

As an initial user the 7 bit address/9 bit data format used by many
Wolfson devices is supported for write only CODECs and the drivers
with straightforward register cache implementations are converted to
use it.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 17:24:50 +01:00
Mark Brown 5420f30723 ASoC: Fix leaks in WM8988 registration error handling
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 16:29:39 +01:00
Mark Brown 1a01417e85 ASoC: Fix WM8960 leaks on probe failure
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 15:47:03 +01:00
Mark Brown fe5422fc4a ASoC: Fix leaks in WM8731 probe error handling
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05 15:18:01 +01:00
Lars-Peter Clausen 637a935aab ASoC: Fix wm8753 register cache size and initialization
Register cache space was not being allocated for the final register,
causing bugs when it was used.  Allocate space for it.

Also ensure that the final register is displayed in sysfs.

[Commit message rewritten to document actual issue. -- broonie]

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-03 14:35:49 +01:00
Lopez Cruz, Misael 6814044324 ASoC: TWL4030: Add tristate callbacks for HiFi and Voice
Add "set_tristate" callbacks for HiFi and Voice DAIs.
Machine drivers can enable and disable tristate for each
DAI with "snd_soc_dai_set_tristate" function.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-03 11:01:05 +01:00
Mark Brown 1df892cba4 ASoC: Fix register cache initialisation for WM8753
The wrong register cache variable was being used to provide the size for
the memcpy(), resulting in a copy of only a void * of data.

Reported-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-07-03 10:41:45 +01:00
Candelaria Villareal, Jorge 4e49ffd10f ASoC: TWL4030: Add EXTMUTE to reduce pop-noise effect
According to TRM, an external FET controlled by a 1.8V output signal
can be used to reduce the pop-noise heard when the audio amplifier is
switched on. It is suggested that GPIO6 of TWL4030 be used, but any
other gpio can be used instead. This is indicated in machine driver
with the following twl4030_setup_data members:

-hs_extmute. Set to 1 if board has support for EXTMUTE.

-set_hs_extmute. Set to a callback funcion to control an external gpio
line. Set to NULL if MUTE[GPIO6] pin is used.

Codec driver takes care of enabling and disabling this output during
the headset pop attenuation sequence.

Also add a delay to let VMID settle in ramp up sequence.

Signed-off-by: Jorge Eduardo Candelaria <x0107209@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-02 11:06:26 +01:00
Mark Brown 1dcf98ff8e ASoC: Add WM8523 CODEC driver
The WM8523 is a high performance stereo DAC with integral charge
pump providing 2Vrms line driver outputs using a single 3.3V power
supply rail.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-01 18:47:45 +01:00
Mark Brown 8a123ee2a4 ASoC: WM8974 DAPM cleanups
Also implement AUX mode control.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 21:30:42 +01:00
Mark Brown 8b83a19367 ASoC: WM8974 cosmetic cleanups
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 21:30:35 +01:00
Mark Brown cb11d39ead ASoC: Use symmetric rates for WM8974
The chip has a single LRCLK.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 21:30:25 +01:00
Mark Brown a5f8d2f1b8 ASoC: Add WM8974 TLV information
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 19:34:32 +01:00
Mark Brown 91d0c3ecba ASoC: Refresh WM8974 PLL configuration
Move away from a fixed table to runtime calculation.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 19:34:23 +01:00
Mark Brown 33d81af4d1 ASoC: Declare 2 channels for WM8974
The device is a mono device but it can read two channel data and
many I2S controllers only understand 2 channels.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 19:34:16 +01:00
Mark Brown df1ef7a38d ASoC: Refresh WM8974 bias configuration
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-30 19:34:09 +01:00
Mark Brown 9ea21ebca1 ASoC: Fix WM8961 suspend function type
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-29 16:34:57 +01:00
Mark Brown 372a14a4a4 ASoC: Remove unreferenced wm8974_add_controls()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-29 16:14:19 +01:00
Lopez Cruz, Misael e3c7dbb07c ASoC: Remove word "Switch" from Handsfree switch name
SoC dapm adds the suffix "Switch" to SND_SOC_DAPM_SWITCH controls,
removing word "Switch" from HandsfreeL/HandsfreeR widget name
for avoiding to duplicate it.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-26 10:39:52 +01:00
Mark Brown d5fc3b5fe3 Merge branch 'for-2.6.31' into for-2.6.32 2009-06-25 13:58:37 +01:00
Mark Brown e2f551dacb ASoC: Add core suspend and resume callbacks to WM8961
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-25 13:57:59 +01:00
Lopez Cruz, Misael 30808ca751 ASoC: TWL4030: Correct bypass event for voice sidetone
Event for voice sidetone was being interpreted as an
analog HiFi bypass event because VSTPGA register offset
is less than ARXR2_APGA_CTL offset. Reordering the
register checks allows to handle voice digital bypass
event properly.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-23 10:57:38 +01:00
Lopez Cruz, Misael 328d0a138e ASoC: TWL4030: Add AVADC Clock Priority
AVDAC clk priority allows to determine the path ADC must
be connected when the codec is in option2 and both HiFi
and Voice paths are enabled.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-23 10:57:37 +01:00
Lopez Cruz, Misael c264301c77 ASoC: TWL4030: Fix voice interface clock masters
Voice interface of twl4030 codec supports: CBM_CFM and
CBS_CFS. It doesn't support CBS_CFM.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-By: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-22 11:24:04 +01:00
Mark Brown e370f45aeb Merge branch 'wm8961' into for-2.6.32 2009-06-22 11:08:26 +01:00
Mark Brown 423c238d71 ASoC: Staticise put_twl4030_opmode_enum_double()
It's an operation for a control and doesn't need to be exported.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-20 13:58:09 +01:00
Mark Brown b53109db5e ASoC: Fix shadowed variables in twl4030
No need to define second copies of mode and format, they're declared
with exactly the same type at the head of the function and there's no
conflict in their use.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-20 13:58:08 +01:00
Mark Brown a583cd5347 ASoC: Regulator support for WM8580
Add basic support for integration with the regulator API to WM8580.
Since the core cannot yet disable biases when the CODEC is idle we
simply request and enable the regulators for the entire time the
driver is active.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-17 17:33:01 +01:00
Philipp Zabel 1abd918499 ASoC: UDA1380: refactor device registration
This patch mostly follows commit 5998102b90
"ASoC: Refactor WM8731 device registration" to make UDA1380 use standard
device instantiation. Similarly, the I2C device registration temporarily
moves into the magician machine driver before it will find its final
resting place in the board file.

At the same time, platform specific configuration is moved to platform data
and common power/reset GPIO handling moves into the codec driver.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-15 21:54:48 +01:00
Mark Brown b3b50b3f31 ASoC: Add suspend and resume callbacks to Wolfson CODEC drivers
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-13 22:30:18 +01:00
Mark Brown 619439998a ASoC: Automatically manage WM8350 sloping stopband filter
For best performance the DAC sloping stopband filter should be enabled
below 24kHz and not enabled above that so remove the user visible
control for this and do it autonomously in the driver.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-13 20:06:25 +01:00
Mark Brown 21002e2076 ASoC: Automatically manage WM8900 sloping stopband filter
For best performance the DAC sloping stopband filter should be
enabled below 24kHz and not enabled above that so remove the
user visible control for this and do it autonomously in the
driver.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-13 20:06:23 +01:00
Mark Brown 9e79261f30 ASoC: Automatically control WM8903 sloping stopband filter
For best performance the DAC sloping stopband filter should be
enabled below 24kHz and not enabled above that so remove the
user visible control for this and do it autonomously in the
driver.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-13 20:06:23 +01:00
Mark Brown 5ba73683ba ASoC: Revert duplicated code in SSM2602 driver
The Blackfin submission was done as a patch against a different tree
and contained a duplicate hunk which will cause us to loose track of the
substream pointers when shutting down.  Remove one of the duplicated
hunks.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-13 19:35:24 +01:00
Mark Brown ba2533a478 ASoC: Remove odd bit clock ratios for WM8903
These are not supported since performance can not be guaranteed
when they are in use.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-06-12 17:29:54 +01:00
Mark Brown 74dc55ed5b ASoC: Add WM8961 driver
The WM8961 is a low power, high quality stereo CODEC designed for
portable digital applications with headphone and stereo class D speaker
drivers.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-12 17:16:06 +01:00
Troy Kisky ccff4b15e0 ASoC: codec tlv320aic23 fix bogus divide by 0 message
Some code analyzer software mistakenly gives
divide by 0 error messages for these lines.
This patch will end its confusion.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-06 09:24:48 +01:00
Takashi Iwai d08664fdb5 ASoC: Fix build error in twl4030.c
Fix the (likely cut-n-paste) error by commit
16a30fbb0d, which causes the error below:
  sound/soc/codecs/twl4030.c: In function 'twl4030_read_reg_cache':
  sound/soc/codecs/twl4030.c:152: error: 'cache' undeclared (first use in this function)

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-04 10:01:11 +02:00
Cliff Cai f692fce0cf ASoC: SSM2602: assign last substream to the master when shutting down
Fixes crash when shutting down.

Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-03 11:38:23 +01:00
Cliff Cai 2552a710f4 ASoC: SSM2602: remove unsupported sample rates
Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-03 11:25:51 +01:00
Peter Ujfalusi eaf1ac8bb5 ASoC: TWL4030: Check the interface format for 4 channel mode
In addition to the operating mode check, also check the
codec's interface format in case of four channel mode.
If the codec is not in TDM (DSP_A) mode, return with error.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-06-01 23:46:08 +01:00
Peter Ujfalusi 16a30fbb0d ASoC: TWL4030: Use reg_cache in twl4030_init_chip
Use the codec->reg_cache instead of the array directly
in twl4030_init_chip for setting the default values.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-29 11:02:48 +01:00
Mark Brown 203350c1a8 ASoC: Initialise dev for the dummy S/PDIF DAI
Also include the header to make sure the DAI is prototyped.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-28 18:54:52 +01:00
Chaithrika U S be461ba836 ASoC: Add dummy S/PDIF codec support
McASP on DM646x can operate in DIT (S/PDIF) where no codec is needed.
This patch provides stub codec that can be used in these configurations.
On DM646x EVM the McASP1 is connected to the S/PDIF out.

Signed-off-by: Steve Chen <schen@mvista.com>
Signed-off-by: Pavel Kiryukhin <pkiryukhin@ru.mvista.com>
Signed-off-by: Naresh Medisetty <naresh@ti.com>
Signed-off-by: Chaithrika U S <chaithrika@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-28 14:48:38 +01:00
Roel Kluin 449bd54dcb ASoC: correct print specifiers for unsigneds
Unsigned variables should use `%u' rather than `%d'.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-28 10:20:26 +01:00
Peter Ujfalusi 0f89bdcac6 ASoC: TWL4030: HandsfreeL/R mute DAPM switch
Add DAPM switch for HeadsetL/R mute. Since all bits are are needed
for the HFL/R pop removal to work the switch is using the SW_SHADOW
no HW register for the HandsfreeL/R mute.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-25 11:54:14 +01:00
Peter Ujfalusi f3b5d3002d ASoC: TWL4030: Add shadow register
Shadow, non HW register for dealing with the HandsfreeL/R
muting.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-25 11:54:14 +01:00
Peter Ujfalusi 5a2e9a48b1 ASoC: TWL4030: Handsfree pop removal redesign
Move the HandsfreeL/R (IHFL/R) pop removal code from the DAPM_MUX_E
to a more appropriate DAPM_PGA_E widget.
Also fix the power-up sequence to match with the TRM.
The power-down sequence is not described in the TRM, so do it
in a way, which seams like the correct sequence.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-25 11:54:13 +01:00
Mark Brown 05e1efa2de ASoC: Fix minor issues in STAC9766 driver
Fairly minor issues:
 - Don't register the DAIs, it's not required for AC97 devices.
 - Make unexported functions static.
 - Wrap some excessively long lines.
 - Undo tab/space breakage.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-24 13:32:24 +01:00
Jon Smirl 3c166c7f18 ASoC: Codec for STAC9766 used on the Efika
Datasheet: http://www.idt.com/products/getDoc.cfm?docID=13134007

Signed-off-by: Jon Smirl <jonsmirl@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-24 13:15:21 +01:00
Mark Brown 4fcbbb67a3 ASoC: Update WM8974 to use standard I2C device probe methods
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-23 16:43:12 +01:00
Mark Brown 1a55b3f6ed ASoC: WM8974 checkpatch cleanups
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-23 11:31:40 +01:00
Mark Brown 0a1bf55335 ASoC: Add WM8974 CODEC driver
The WM8974 is a low power, high quality mono CODEC designed for portable
applications such as digital still cameras or digital voice recorders.

This driver was originally written by Graeme Gregory and Liam Girdwood
and has since been maintained by myself with some updates contributed by
Brett Saunders and Javier Martin.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-23 11:28:03 +01:00
Mark Brown 0154724d48 ASoC: Fix WM9081 PowerPC compiler issues
Ensure that we always set a new sysclk when using the FLL in master mode
and pick out the correct value for the sample rate in hw_params().

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-23 10:24:15 +01:00
Mark Brown 86ed3669f0 ASoC: WM9081 mono DAC with integrated 2.6W class AB/D amplifier driver
The WM9081 is designed to provide high power output at low distortion
levels in space-constrained portable applications.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-22 15:11:22 +01:00
Peter Ujfalusi b4852b793a ASoC: TWL4030: Differentiate the playback streams
Give unique stream names for the two playback streams so
DAPM can figure out which codec_dai is in use.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-22 15:08:43 +01:00
Peter Ujfalusi 9da28c7b38 ASoC: TWL4030: Add support for platform dependent configuration
twl4030_setup_data structure can be passed from platform drivers to
the codec via the snd_soc_device->codec_data pointer.

Currently the setup data has support for the Headset pop-removal
related configuration, which differs from board to board.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-22 10:23:22 +01:00
Peter Ujfalusi 6943c92e87 ASoC: TWL4030: Move the Headset pop-attenuation code to PGA event
This patch adds SND_SOC_DAPM_PGA_E to the headset path, which handles
the headset ramp up and down sequences needed for the pop noise
removal.

With this patch the order of the internal components in the twl4030
codec is turned on and off in a correct order.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Tested-by: Anuj Aggarwal <anuj.aggarwal@ti.com>
Tested-by: Jarkko Nikula <jhnikula@gmail.com>
Tested-by: Misael Lopez Cruz  <x0052729@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-20 09:53:25 +01:00
Peter Ujfalusi 4005d39a5f ASoC: TWL4030: Change DAPM routings and controls for DACs and PGAs
Restructuring the twl4030 codec's DAPM routing to be able to handle the power
sequences correctly.

The twl4030 codec internal implementation have this order:
DAC -> Analog PGA -> Mixer/Mux

While the ASoC framework expects the following order:
DAC -> Mixer -> Analog PGA

This patch moves the Analog PGA handling from SND_SOC_DAPM_PGA to _MIXER and
adds two levels of mixer to handle the digital and analog loopback
functionality.

Now the analog loopback does not powers on any of the DACs.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Tested-by: Anuj Aggarwal <anuj.aggarwal@ti.com>
Tested-by: Jarkko Nikula <jhnikula@gmail.com>
Tested-by: Misael Lopez Cruz  <x0052729@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-20 09:52:51 +01:00
Lopez Cruz, Misael b74bd40fa4 ASoC: TWL4030: Add control for selecting codec operation mode
Add a control for selecting the codec operation mode. TWL4030 codec
has two modes:
- Option 1. Audio only (4 audio DACs)
- Option 2. Voice/Audio (2 audio DACs and voice ADC/DAC)

Control is restricted when a stream is ongoing, since codec's
operation mode cannot be changed on-the-fly.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujflausi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-19 10:35:11 +01:00
Peter Ujfalusi 181da78cd0 ASoC: TWL4030: Fix Analog capture path for AUXR
AUXR is selected by bit 2 and not by bit 1 in the ANAMICR register.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-19 09:38:57 +01:00
Misael Lopez Cruz b7a755a8a1 ASoC: TWL4030: Enable/disable voice digital filters
Enable TWL4030 VTXL/VTXR and VRX digital filters for uplink
and downlink paths, respectively.

This patch also corrects voice 8/16kHz mode selection bit
(SEL_16K) of CODEC_MODE register.

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-18 11:13:12 +01:00
Takashi Iwai 2baaec2806 ASoC: Add missing __devexit in wm8940.c
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-15 12:18:47 +02:00
Marek Vasut 63c26baa2a ASoC: Support AC97 link off by default on WM9712
The WM9712 can be configured by resistor strapping GPIO4 to behave like
the WM9713 and default to leaving the AC97 link disabled after cold
reset until a warm reset occurs.  In this configuration we need to issue
a warm reset after cold to bring the link up so do so.  The warm reset
will be harmless on systems that don't need it.

[Changelog rewritten to document the reasoning. -- broonie]

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-14 20:52:46 +01:00
Joonyoung Shim 97b8096dc9 ASoC: TWL4030: change DAPM for analog microphone selection
The inputs of the twl4030 codec can be mixed, so we will use the mixer
DAPM for the analog microphone registers(0x05, 0x06), but if we enable
more than one input at the same time, the input impedance of the input
amplifier will be reduced.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-12 10:53:22 +01:00
Roel Kluin 31cb31f76e ASoC: remove driver_data direct access of struct device
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-11 22:09:22 +01:00
Peter Ujfalusi c198d81181 ASoC: TWL4030: Fix typo in twl4030_codec_mute function
Copy-paste error: TWL4030_PRECKL_GAIN >> TWL4030_PRECKR_GAIN
It has not caused problems, since
TWL4030_PRECKL_GAIN == TWL4030_PRECKR_GAIN == 0x30

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-08 12:00:12 +01:00
Daniel Mack 5e7c034425 ASoC: cs4270: add power management support
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-07 09:00:27 +01:00
Daniel Mack 80ab8817bf ASoC: cs4270: introduce CS4270_I2C_INCR
Replace the magic 0x80 value with a suitable macro definition.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-05 19:16:41 +01:00
Mark Brown b290750172 Merge branch 'for-2.6.30' into for-2.6.31 2009-05-05 10:13:01 +01:00
Peter Ujfalusi 376f7839b7 ASoC: TWL4030: Add VIBRA output
This patch adds support for the VIBRA output on TWL4030 codec.
The VIBRA output can be driven with audio data or with
local vibrator driver.
Add the needed DAPM elements and routes for the VIBRA output and
controls for the VIBRA driver configuration.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-05 10:12:45 +01:00
Lopez Cruz, Misael ee8f6894f3 ASoC: TWL4030: Add voice digital loopback: sidetone
This patch add voice digital loopback (sidetone) to the twl4030
driver. It mixes voice uplink attenuated (by sidetone gain) with
voice downlink when the codec is working in option2 (voice/audio
mode).

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-05 10:12:20 +01:00
Lopez Cruz, Misael fcd274a345 ASoC: TWL4030: Add VDL analog bypass
This patch adds voice downlink analog bypass switch. It follows
the same approach as in other analog bypass switches.
DAC switch is moved from 'DAC Voice' to 'Analog Voice Playback Mixer',
that will also allow voice DAC to be powered in digital voice
loopback (sidetone).

Signed-off-by: Misael Lopez Cruz <x0052729@ti.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-05 10:12:14 +01:00
Jinyoung Park 97a775c49c ASoC: Fix errors in WM8990
The mis-typing exist in dapm controller definitions and dapm route definitions,
so happen mis-matched error when snd_soc_dapm_add_routes().

Cc: stable@kernel.org
Signed-off-by: Jinyoung Park <parkjy@mtekvision.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com
2009-05-05 09:56:49 +01:00
Mark Brown 33f503c96c ASoC: Use a shared define for AC97 CODEC data formats
The AC97 wire format is completely fixed so CODECs don't have any choice
about the formats they accept but controllers accept a variety of data
formats and render them down onto the bus.  Have a shared define so all
the CODEC drivers will interoperate with any of our controller drivers.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-02 12:32:09 +01:00
Mark Brown 72e31981a4 Merge branch 'for-2.6.30' into for-2.6.31 2009-04-28 19:33:45 +01:00
Joonyoung Shim 18cc8d8d9b ASoC: TWL4030: Fix gain control for earpiece amplifier
The gain control for earpiece amplifier uses 0dB ~ 12dB according to the
TRM, but the present code is implemented to -6dB ~ 6dB.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-28 16:11:22 +01:00
Mark Brown 6be01cfb85 ASoC: Staticise TLV values in WM8940
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:57:42 +01:00
Mark Brown 2625240d07 Merge branch 'for-2.6.30' into for-2.6.31 2009-04-27 20:47:35 +01:00
Mark Brown 5e42336a46 ASoC: Fix logic in WM8350 master clocking check
We need to check only if the WM8350 is master and only when starting
the stream so if either is not true then we can skip the check.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:40:21 +01:00
Daniel Mack 1a4ba05ec8 ASoC: cs4270: add Master Playback Switch
This adds a new control named 'Master Playback Switch' for cs4270
codecs. It is implemented using the new SOC_DOUBLE_EXT macro to catch
the put function and store the information about manually set mute
controls from userspace. When a manual mute is set, we don't want the
soc core to un-mute the outputs.

Renamed cs4270_mute() to cs4270_dai_mute() to avoid confusion.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:38:56 +01:00
Daniel Mack 9c93538651 ASoC: cs4270: fix Master Capture Switch polarity
The control modifies the MUTE register, hence the polarity must be
inverted.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Acked-By: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:37:49 +01:00
Jonathan Cameron 0b5e92c5e0 ASoC WM8940 Driver
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:37:13 +01:00
Mark Brown 008db442ef ASoC: Include WM8350 register definitions in CODEC header
It's expected behaviour for the CODEC header to provide them but the
WM8350 doesn't due to having all the registers together under drivers/mfd.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:27:01 +01:00
Peter Ujfalusi 8a1f936acd ASoC: TWL4030: Add 4 channel TDM support
Support for 4 channel TDM (SND_SOC_DAIFMT_DSP_A) for twl4030
codec.
The channel allocations are:
Playback:
TDM         i2s   TWL RX
Channel 1   Left  SDRL2
Channel 3   Right SDRR2
Channel 2   --    SDRL1
Channel 4   --    SDRR1

Capture:
TDM         i2s   TWL TX
Channel 1   Left  TXL1
Channel 3   Right TXR1
Channel 2   --    TXL2
Channel 4   --    TXR2

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-23 16:11:17 +01:00
Mark Brown 049da6393f Merge branch 'for-2.6.30' into for-2.6.31 2009-04-23 10:37:17 +01:00
Mark Brown 19ab054df8 Merge commit 'takashi/fix/asoc' into for-2.6.30 2009-04-23 10:33:47 +01:00
Joonyoung Shim 1a787e7ad2 ASoC: TWL4030: Add VDL path support
Add DAPMs for VDL(Voice Down Link) path. To support VDL path, we have
to change DAPMs of outputs(Earpiece, PreDrive Left/Right, Headset
Left/Right, Carkit Left/Right) from mux to mixer.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-23 10:15:08 +01:00
Takashi Iwai a1992db55d ASoC: remove non-existing referece to CONFIG_SND_SOC_CODEC_WM8991
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-04-23 08:23:10 +02:00
Mark Brown 291ce18ceb ASoC: Implement WM8903 digital sidetone support
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 21:37:48 +01:00
Mark Brown 727fb909e5 ASoC: Remove redundant rate constraint for WM8903
This is now handled by symmetric_rates.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 21:37:42 +01:00
Mark Brown d7d5c5476a ASoC: Actively manage the DC servo for WM8903
Save a little extra power by enabling the DC servo offset correction
for the output channels only when the relevant channels are enabled.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 21:37:36 +01:00
Mark Brown 4dbfe80971 ASoC: Optimise configuration of WM8903 DC servo
Modify the default startup sequence in the chip to set the DC servo
dither level for optimal performance.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 21:37:30 +01:00
Mark Brown c2aef4ffd2 ASoC: Support CLK_DSP in WM8903
CLK_DSP provides a master clock for the DAC and ADC related functionality
on the device.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 21:37:24 +01:00
Mark Brown 42768a1282 ASoC: Use DAPM supply widget for WM8903 charge pump
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 21:37:02 +01:00
Mark Brown ccb077fd46 ASoC: Fix WM8580 volume update handling for large register changes
The driver is out of sync with the core functions it is using.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-22 10:52:18 +01:00
Mark Brown ce88168f5b ASoC: Fix offset of freqmode in WM8580 PLL configuration
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
2009-04-21 16:18:01 +01:00
Joonyoung Shim 7154b3e802 ASoC: TWL4030: Add support Voice DAI
Add Voice DAI to support the PCM voice interface of the twl4030 codec.

The PCM voice interface can be used with 8-kHz(voice narrowband) or
16-kHz(voice wideband) sampling rates, and 16bits, and mono RX and mono
TX or stereo TX.

The PCM voice interface has two modes
 - PCM mode1 : This uses the normal FS polarity and the rising edge of
               the clock signal.
 - PCM mode2 : This uses the FS polarity inverted and the falling edge
               of the clock signal.

If the system master clock is not 26MHz or the twl4030 codec mode is not
option2, the voice PCM interface is not available.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-20 12:44:24 +01:00
Russell King - ARM Linux 516ef69f16 ASoC: Fix warning in wm9705
I notice that the fixes were merged, minus one:

sound/soc/codecs/wm9705.c: At top level:
sound/soc/codecs/wm9705.c:445: warning: initialization from incompatible pointer type

so you might find this trivial patch useful.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-18 10:45:10 +01:00
Peter Ujfalusi 6b87a91f54 ASoC: TWL4030: Fix for the constraint handling
The original implementation of the constraints were good against sane
applications.
If the opening sequence is:
stream1_open, stream1_hw_params, stream2_open, stream2_hw_params -> the
constraints are set correctly for stream2.

But if the sequence is:
stream1_open, stream2_open, stream2_hw_params, stream1_hw_params -> than stream2
would receive constraint rate = 0, sample_bits = 0, since the stream1 has not
yet called hw_params...

The command to trigger this event:
gst-launch-0.10 alsasrc device=hw:0 ! alsasink device=hw:0 sync=false

This patch does some 'black magic' in order to always set the correct
constraints and sets it only when it is needed for the other stream.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-17 16:02:23 +01:00
Mark Brown 0d960e8891 ASoC: Request shared rates for WM8903
It has a shared LRCLK.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-16 11:03:11 +01:00
Mark Brown 9b1a88c710 Merge branch 'for-2.6.30' into for-2.6.31 2009-04-13 15:12:48 +01:00
Mark Brown f2644a2c00 ASoC: Add WM8960 CODEC driver
The WM8960 is a low power, high quality stereo codec designed for
portable digital audio applications.

Stereo class D speaker drivers provide 1W per channel into 8W loads.
Guaranteed low leakage, excellent PSRR and pop/click suppression
mechanisms enable direct battery connection for the speaker supply.

The device also integrates a complete microphone interface and a stereo
headphone driver. External component requirements are drastically
reduced as no separate microphone, speaker or headphone amplifiers are
required. Advanced on-chip digital signal processing performs automatic
level control for the microphone or line input.

Stereo 24-bit sigma-delta ADCs and DACs are used with low power
over-sampling digital interpolation and decimation filters and a
flexible digital audio interface.

The master clock can be input directly or generated internally by an
onboard PLL, supporting most commonly-used clocking schemes.

This driver was originally written by Liam Girdwood, with substantial
subsequent additions and updates for feature completeness and changes in
the ASoC framework from me.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-13 15:11:46 +01:00
Mark Brown 6bbcb459cd ASoC: Move the WM9713 voice DAC powerdown to a DAPM event
This ensures that we sync with the DAPM powerdown sequencing properly
and don't need to bounce the power on the voice DAC so often.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-13 11:59:01 +01:00
Mark Brown f4976116a9 ASoC: WM9713 requires symmetric rates on the voice DAI
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-13 11:59:01 +01:00
Peter Ujfalusi 894bf92fde ASoC: tlv320aic23: add DSP_A format support
Add DSP_A interface format support by setting the LRP bit in
DSP mode.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-09 13:36:54 +01:00
Mark Brown 5409fb4e32 ASoC: Add WM8988 CODEC driver
The WM8988 is a low power, high quality stereo CODEC designed for
portable digital audio applications.

The device integrates complete interfaces to 2 stereo headphone or line
out ports. External component requirements are drastically reduced as no
separate headphone amplifiers are required. Advanced on-chip digital
signal processing performs graphic equaliser, 3-D sound enhancement and
automatic level control for the microphone or line input.

The WM8988 can operate as a master or a slave, with various master clock
frequencies including 12 or 24MHz for USB devices, or standard 256fs
rates like 12.288MHz and 24.576MHz. Different audio sample rates such as
96kHz, 48kHz, 44.1kHz are generated directly from the master clock
without the need for an external PLL.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-07 18:51:23 +01:00
Peter Ujfalusi d6648da122 ASoC: TWL4030: Compillation error fix
Fix for compillation error introduced by the constrain patch.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-07 10:52:00 +01:00
Dan Carpenter 09318c47b6 ASoC: Fix null dereference in ak4535_remove()
ak4535_remove() from sound/soc/codecs/ak4535.c calls
i2c_unregister_device() with a possibly null pointer.

This bug was found by smatch (http://repo.or.cz/w/smatch.git/).

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-06 10:53:37 +01:00