summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2009-07-22ASoC: MAX9877: separate callback functionsJoonyoung Shim1-33/+63
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-22ASoC: MPC5200: Increase the delay time between resetsJohn Bonesio1-1/+2
Reset was failing with the original udelay(50) between the code in psc_ac97_cold_reset() and the call to psc_ac97_warm_reset(). Through testing it was found that a delay of 1ms was necessary for the cold_reset code to consistently complete successfully. Signed-off-by: John Bonesio <bones@secretlab.ca> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-18ASoC: Fix checkpatch issues in AD1938Mark Brown1-78/+78
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-17ASoC: Fix FLL reference clock division setup in WM8993Mark Brown1-0/+2
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-17ASoC: Bodge around GCC 4.4.0 flow analysis bug in GCC 4.4.0Mark Brown1-2/+7
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-17ASoC: SDP3430: Add support for EXTMUTE using TWL GPIO6Candelaria Villareal, Jorge1-0/+9
Board sdp3430 has hardware support for EXTMUTE using TWL4030 GPIO6 line, controlled by register INTBR_PMBR1. Machine driver takes care of enabling gpio line through i2c and codec driver manipulates the line during headset ramp up/down sequence. Signed-off-by: Jorge Eduardo Candelaria <x0107209@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-17ASoC: Kill direct accesses to driver_dataTakashi Iwai1-2/+2
Replaced with dev_{get|set}_drvdata(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-16ASoC: new ad1938 codec driver based on asocBarry Song4-0/+758
Signed-off-by: Barry Song <21cnbao@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-16ASoC: davinci: don't use clock namesKevin Hilman2-2/+2
clock name strings are no longer passed on platform_data. Instead, we rely entirely on struct device and clkdev to find the right clock. Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-15ASoC: MAX9877: add MAX9877 amp driverJoonyoung Shim4-0/+318
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-15ASoC: add SOC_DOUBLE_R_EXT_TLV control typeJoonyoung Shim1-0/+11
This is a macro for double controls with special callback function and TLV. The SOC_DOUBLE_R_EXT_TLV needs two registers and one shift for double controls. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-15ASoC: add SOC_DOUBLE_EXT_TLV control typeJoonyoung Shim1-0/+11
This is a macro for double controls with special callback function and TLV. The SOC_DOUBLE_EXT_TLV needs one register and two shifts for double controls. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-15ASoC: Error out if we can't determine a suitable WM9081 sysclkMark Brown1-0/+8
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-15ASoC: Fix sample rate lookup in WM8993Mark Brown1-1/+2
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-14ASoC: Blackfin I2S: fix resume handlingCliff Cai1-6/+2
There is no need to manually start playback/capture ourselves as the PCM driver will handle things for us. 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-07-14ASoC: Blackfin AC97: fix resume handlingCliff Cai1-7/+3
There is no need to manually start playback/capture ourselves as the PCM driver will handle things for us. 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-07-13Merge branch 'for-2.6.31' into for-2.6.32Mark Brown1-1/+1
2009-07-13ASoC: fixes multiple typos in comments, no functional changePeter Meerwald1-13/+13
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-13ASoC: spdif: set module licence to GPLKevin Hilman1-0/+2
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-13ASoC: spdif codec: enable use by modulesKevin Hilman1-0/+1
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-13ASoC: fix checking for external widgets bugRongrong Cao1-2/+2
In SOC DAPM layer of SOUND subsystem, when add signal route (in the function snd_soc_dapm_add_route() ), the original code has wrong logic when dapm layer check each widget whether an external one. Signed-off-by: Rongrong Cao <rrcao@ambarella.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-13ASoC: Keep index within stac9766_reg[]Roel Kluin1-2/+2
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-10Merge branch 'tlv320aic3x' into reg-cacheMark Brown2-25/+2
2009-07-09ASoC: WM8510 has a single frame clock so needs symmetric ratesMark Brown1-0/+1
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-09ASoC: Fix NULL pointer dereference in __pxa2xx_pcm_hw_freeDaniel Mack1-1/+1
Check for rtd->params->drcmr != NULL before accessing it. Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Add pop delay debug at end of DAPM sequencingMark Brown1-0/+3
Provide an interval after the end of DAPM sequencing so that we can distinguish between a pop in the final step of the sequence and a pop generated from some other source outside DAPM. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Configure WM8731 SYSCLK at startup on AT91SAM9G20-EKMark Brown1-25/+10
The system clock is currently fixed by the driver and this avoids the need for us to handle errors with enabling and disabling MCLK (which was incorrect previously so this fixes bugs in error handling). Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Disable microphone input for AT91SAM9G20-EK by defaultMark Brown1-1/+13
As shipped the board does not have inputs but it is relatively straightforward to modify the board to hook them up so support is provided in the driver. When these modifications have not been made enabling the microphone stage can cause problems. Add an ifdef to disable this by default. Don't put it into Kconfig since users will have to get their soldering irons out to change things. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Use CODEC as clock master on AT91SAM9G20-EKMark Brown1-87/+2
This simplifies the driver by removing the need to manually configure dividers within the CPU and improve audio performance by ensuring that the optimal phase relationships between the clocks in the system are maintained. Note that currently this means that for playback to work the Output Mixer HiFi switch must be enabled since otherwise CODEC will not generate the DAC clock. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Limit WM8731 to symmetric ratesMark Brown1-0/+1
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-08ASoC: Add WM8993 CODEC driverMark Brown5-0/+4385
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-08ASoC: DaVinci I2S needs mach/asp.hMark Brown1-0/+2
Reported-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Correct WM8731 Mic Capture Switch control nameMark Brown1-1/+1
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: Add TLV information for WM8731Mark Brown1-4/+11
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-08ASoC: DaVinci: pcm, don't play 1st sound period twiceTroy Kisky1-0/+1
Update the dma link with correct data as soon as the master channel has copied it. Otherwise, the 1st period will play twice. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-07Merge branch 'davinci' into for-2.6.32Mark Brown7-113/+1073
Conflicts: sound/soc/davinci/davinci-i2s.c
2009-07-06Merge branch 'for-2.6.31' into for-2.6.32Mark Brown4-4/+21
2009-07-05ASoC: Factor out WM8580 register cache codeMark Brown1-107/+41
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-05ASoC: Remove use of hw_read from TLV320AIC3x driverMark Brown1-9/+2
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-05ASoC: Remove unused AK4535 hardware read functionalityMark Brown1-16/+0
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-05ASoC: Begin to factor out register cache I/O functionsMark Brown10-577/+400
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-05ASoC: Fix leaks in WM8988 registration error handlingMark Brown1-3/+5
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: Fix WM8960 leaks on probe failureMark Brown1-5/+11
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: Fix leaks in WM8731 probe error handlingMark Brown1-5/+12
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: Add CODEC volatile register operationMark Brown2-0/+19
Add a volatile_register() operation to the CODEC structure providing a standard operation to query if a register is volatile. This will be used to factor out the register cache I/O operations for the CODECs. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: DaVinci: i2s, add davinci_i2s_prepare and shutdownTroy Kisky1-1/+27
If the codec is master then prepare should call mcbsp_start, not trigger. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: DaVinci: i2s, fix mcbsp_word_length updateTroy Kisky1-21/+29
Code previously just "ors" in this field without clearing first. Fix, by never reading this register. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: DaVinci: i2s, minor cleanup of davinci_i2s_startupTroy Kisky1-6/+2
Save a few lines of code. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: DaVinci: i2s, only start sample generator if neededTroy Kisky1-18/+14
Only start sample generator if needed, and more cleanup on davinci_mcbsp_start. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: DaVinci: i2s cleanupTroy Kisky1-3/+2
Move variable declaration closer to use. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>