summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* ASoC: core - Separate out PCM operations into new file.Liam Girdwood2011-06-093-612/+641
| | | | | | | | | | | | In preparation for Dynamic PCM support (AKA DSP support). There will be future patches that add support to allow PCMs to be dynamically routed to multiple DAIs at startup and also during stream runtime. This patch moves the ASoC core PCM operaitions into a new file called soc-pcm.c. This will in simplify the ASoC core features into distinct files. Signed-off-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-092-6/+12
|\
| * ASoC: fsl: fix initialization of DMA buffersTimur Tabi2011-06-091-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The DMA (PCM) driver used by some Freescale PowerPC supports separate DAIs for playback and capture, so DMA buffers should be allocated only for the initialized streams. Instead of checking for the number of active channels, which apparently is not reliable, check to see if the actual stream object exists. Also provide a better name for the DMA interrupt. Signed-off-by: Timur Tabi <timur@freescale.com> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * ASoC: WM8804 does not support sample rates below 32kHzMark Brown2011-06-091-2/+7
| | | | | | | | | | | | | | Reported-by: Kieran O'Leary <Kieran.O'Leary@wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com> Cc: stable@kernel.org
* | ASoC: p1022ds: fix incorrect referencing of device tree propertiesTimur Tabi2011-06-094-13/+18
| | | | | | | | | | | | | | | | | | | | | | | | Device tree integer properties are encoded in big-endian format, but some of the Freescale ASoC drivers were assuming that the host is in big-endian format as well. Although this is true, it's better to use endian-safe accessors. Also add a check for a failed ioremap() call in the SSI driver. Signed-off-by: Timur Tabi <timur@freescale.com> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: Fix mismerge of Speyside set_bias_level_post()Mark Brown2011-06-081-0/+1
| | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-081-2/+2
|\|
| * ASoC: Fix WM8962 headphone volume update for use of advanced cachesMark Brown2011-06-081-2/+2
| | | | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com> Cc: stable@kernel.org
* | ASoC: Support Speyside build variants with WM8962 fittedMark Brown2011-06-083-0/+268
| | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Defer all WM8962 clocking configuration until power upMark Brown2011-06-081-27/+33
| | | | | | | | | | | | | | Don't require an audio rate SYSCLK in hw_params() in order to better support microphone detection use cases. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: Implement base 5 band EQ control for WM8962Mark Brown2011-06-081-0/+16
| | | | | | | | | | | | | | ReTune Mobile modes are not currently supported. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Report errors when we have a WM8962 IRQ and don't get FLL lockMark Brown2011-06-081-5/+32
| | | | | | | | | | | | | | | | | | We really should be getting the interrupt - if we don't get one it's very likely that the configuration is incorrect and audio will fail. Also increase the timeout substantially in this case for safety. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Factor out I2C usage in WM8962 driverMark Brown2011-06-081-9/+10
| | | | | | | | | | | | | | | | The chip can actually support SPI so we shouldn't assume we've got an I2C device even though that's the most common configuration. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Suppress restore of default register values for rbtree cache syncMark Brown2011-06-081-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently the rbtree code will write out the entire register map when doing a cache sync which is wasteful and will slow things down. Check to see if the value we're about to write is the default and don't bother restoring it if it is, either the value will have been retained or the device will have been reset and holds the value already. We should really store the defaults in the nodes but this resolves the immediate issue. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: core - Allow components to probe/remove in sequence.Liam Girdwood2011-06-073-21/+61
| | | | | | | | | | | | | | | | | | | | | | Some ASoC components depend on other ASoC components to provide clocks and power resources in order to probe() and vice versa for remove(). Allow components to be ordered so that components can be probed() and removed() in sequences that conform to their dependencies. Signed-off-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: core - Optimise and refactor pcm_new() to pass only rtdLiam Girdwood2011-06-0727-61/+96
| | | | | | | | | | | | | | | | | | | | Currently pcm_new() passes in 3 arguments :- card, pcm and DAI. Refactor this to only pass in 1 argument (i.e. the rtd) since struct rtd contains card, pcm and DAI along with other members too that are useful too. Signed-off-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-071-2/+2
|\|
| * ASoC: Blackfin: bf5xx-ad1836: Fix codec device nameLars-Peter Clausen2011-06-071-2/+2
| | | | | | | | | | | | | | | | | | | | Fix the codec_name field of the dai_link to match the actual device name of the codec. Otherwise the card won't be instantiated. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@kernel.org
* | ASoC: AD1836: Fix build errorLars-Peter Clausen2011-06-071-1/+1
| | | | | | | | | | | | | | | | | | Commit f97d0c6d5f94 ("ASoC: AD1836: Add input gain control for ADC2") contained a typo in the register name, causing a build error. This patch fixes it. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: wm8940: remove unnecessary if statementsGreg Dietsche2011-06-071-7/+0
| | | | | | | | | | | | | | | | | | | | | | | | removing unnecessary if(ret) checks This updated patch corrects a minor spelling problem in the commit message and resolves two other (similar) issues found in wm8940.c by Jonathan Cameron. Signed-off-by: Greg Dietsche <Gregory.Dietsche@cuw.edu> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-062-7/+13
|\|
| * ASoC: AD1836: Fix setting the PCM formatLars-Peter Clausen2011-06-062-7/+13
| | | | | | | | | | | | | | Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@kernel.org
* | ASoC: AD1836: Add input gain control for ADC2Lars-Peter Clausen2011-06-061-0/+11
| | | | | | | | | | | | | | | | | | The AD1836 has a PGA for its second ADC. This patch adds a control for adjusting the the gain of the PGA. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: AD1836: Remove unused fields from private structLars-Peter Clausen2011-06-061-5/+0
| | | | | | | | | | | | | | | | | | | | | | The control_type field is never used, so it can be removed. The control_data field is used to initialize the codec's control_data field, but since this is also done by the snd-soc-cache core, the redundant assignment can be removed and the field can be dropped. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: AD1836: Add AD1835/AD1837/AD1838/AD1839 supportLars-Peter Clausen2011-06-061-54/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The AD183X codec devices are mostly register compatible and can easily be supported by the same driver. The main difference between those devices is the number of DACs and ADCs. This patch adjusts the driver to allocate the controls, DAPM widgets and routes for the DACs and ADCs dynamically based on the chip type. The AD1836 is a bit special in that it supports different modes for its second ADC, so it needs some special handling. Right now the driver hardcodes the mode to the differential PGA mode. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: AD1836: Use snd_soc_update_bits for read-modify-writeLars-Peter Clausen2011-06-061-12/+6
| | | | | | | | | | | | | | | | | | Use snd_soc_update_bits for read-modify-write register access instead of open-coding it using snd_soc_read and snd_soc_write. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: AD1836: Add ADC/DAC controls helper macrosLars-Peter Clausen2011-06-062-39/+34
| | | | | | | | | | | | | | | | | | | | | | The different ADC and DAC controls follow the same scheme, so add some helper macros for declaring them. This should make the code a bit more readable and also decreases the code size a bit. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | ASoC: Manage Speyside system clocking only in bias managementMark Brown2011-06-061-10/+40
| | | | | | | | | | | | | | | | | | | | Now that the CODEC driver supports it defer configuration of the system clock until bias management which is a much more idiomatic place to do system power control and makes things a lot more happy when we're using both interfaces. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Only provide a default bias level update for CODEC contextsMark Brown2011-06-061-4/+7
| | | | | | | | | | | | | | | | This allows the card driver to use the bias level variable more easily in multi component systems. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Add context parameter to card DAPM callbacksMark Brown2011-06-065-3/+11
| | | | | | | | | | | | | | | | | | The card callback will get called for each DAPM context in the card so it can be useful for it to know which device is currently undergoing a transition. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Simplify logic in snd_soc_dapm_set_bias_level()Mark Brown2011-06-061-10/+12
| | | | | | | | | | | | | | No functional changes but much less indentation. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Remove trace for DAPM bias level loggingMark Brown2011-06-061-18/+0
| | | | | | | | | | | | | | It's redundant now thanks to the use of the generic trace infrastructure. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Indentation fix for null loop operationMark Brown2011-06-061-1/+1
| | | | | | | | | | | | | | More with the legibility. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Don't bring the CODEC up to full power for supplies and biasesMark Brown2011-06-061-2/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | If the only widgets active within a CODEC are supplies and micbiases we are not passing audio, we are probably just doing microphone detection. This will not generally require either fully accurate reference voltages or much power so If this turns out to be unsuitable for some systems we can provide a facility to override this decision. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Specify target bias state directly as a bias stateMark Brown2011-06-063-32/+38
| | | | | | | | | | | | | | | | | | | | Rather than a simple flag to say if we want the DAPM context to be at full power specify the target bias state. This should have no current effect but is a bit more direct and so makes it easier to change our decisions about the which bias state to go into in future. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Allow WM8915 BCLK calculation outside hw_params()Mark Brown2011-06-061-29/+53
| | | | | | | | | | | | | | | | | | | | | | Allow more dynamic management of the device clocking by allowing BCLK to be calculated when we set SYSCLK. This means that if the system is idle when hw_params() runs then we don't try to use the SYSCLK used in that case to set up the BCLK dividers, we can instead wait until a later point such as bias level configuration. This makes it easier to manage low power modes. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-061-0/+3
|\|
| * ASoC: Check for NULL register bank in snd_soc_get_cache_val()Mark Brown2011-06-061-0/+3
| | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Enforce the mask in snd_soc_update_bits()Mark Brown2011-06-061-1/+1
| | | | | | | | | | | | | | | | Avoids issues if someone does a read followed by restore and doesn't mask out only the bits being updated. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Error out when FLL lock interrupt is not delivered on WM8915Mark Brown2011-06-061-2/+14
| | | | | | | | | | | | | | | | | | | | | | When the FLL locks on the WM8915 an interrupt is generated. For safety error out if we don't get that interrupt when the IRQ output of the WM8915 is hooked up. Since we *really* expect an interrupt but the threaded IRQ handler may take a bit longer than expected to get scheduled also dramatically increase the delay in this case. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | ASoC: Suppress noop SYSCLK updates in WM8915Mark Brown2011-06-061-0/+6
| | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-061-1/+2
|\|
| * ASoC: Add missing break in WM8915 FLL source selectionMark Brown2011-06-061-0/+1
| | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
| * ASoC: Only update SYSCLK_ENA when pausing WM8915 SYSCLKMark Brown2011-06-061-1/+1
| | | | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* | Merge branch 'for-3.0' into for-3.1Mark Brown2011-06-067663-426252/+498784
|\|
| * Merge branch 'for-3.0' of ↵Mark Brown2011-06-063-7/+11
| |\ | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into for-3.0
| | * ASoC: atmel_ssc: Don't try to free ssc if request failedJoachim Eastwood2011-06-031-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | We should only call ssc_free() when ssc_request() succeeds or bad things will happen. Signed-off-by: Joachim Eastwood <joachim.eastwood@jotron.com> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | Linux 3.0-rc1v3.0-rc1Linus Torvalds2011-05-291-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | .. except there are various scripts that really know that there are three numbers, so it calls itself "3.0.0-rc1". Hopefully by the time the final 3.0 is out, we'll have that extra zero all figured out. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
| * | Merge branch 'for-linus' of ↵Linus Torvalds2011-05-296-263/+220
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6: eCryptfs: Remove ecryptfs_header_cache_2 eCryptfs: Cleanup and optimize ecryptfs_lookup_interpose() eCryptfs: Return useful code from contains_ecryptfs_marker eCryptfs: Fix new inode race condition eCryptfs: Cleanup inode initialization code eCryptfs: Consolidate inode functions into inode.c
| | * | eCryptfs: Remove ecryptfs_header_cache_2Tyler Hicks2011-05-293-13/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that ecryptfs_lookup_interpose() is no longer using ecryptfs_header_cache_2 to read in metadata, the kmem_cache can be removed and the ecryptfs_header_cache_1 kmem_cache can be renamed to ecryptfs_header_cache. Signed-off-by: Tyler Hicks <tyhicks@linux.vnet.ibm.com>