summaryrefslogtreecommitdiff
path: root/sound/soc
AgeCommit message (Collapse)AuthorFilesLines
2010-10-10ASoC: omap: Remove needless prints from machine driversJarkko Nikula8-24/+8
It is currently completely normal to execute these machine drivers code on different boards if the kernel includes support for multiple boards so no error message should be printed if the machine_is_xxx does not match with the machine driver. Therefore remove these pr_err and pr_debug prints in those cases. Signed-off-by: Jarkko Nikula <jhnikula@gmail.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-08OMAP: McBSP: implement functional clock switching via clock frameworkPaul Walmsley1-56/+13
Previously the OMAP McBSP ASoC driver implemented CLKS switching by using omap_ctrl_{read,write}l() directly. This is against policy; the OMAP System Control Module functions are not intended to be exported to drivers. These symbols are no longer exported, so as a result, the OMAP McBSP ASoC driver does not build as a module. Resolve the CLKS clock changing portion of this problem by creating a clock parent changing function that lives in arch/arm/mach-omap2/mcbsp.c, and modify the ASoC driver to use it. Due to the unfortunate way that McBSP support is implemented in ASoC and the OMAP tree, this symbol must be exported for use by sound/soc/omap/omap-mcbsp.c. Going forward, the McBSP device driver should be moved from arch/arm/*omap* into drivers/ or sound/soc/* and the CPU DAI driver should be implemented as a platform_driver as many other ASoC CPU DAI drivers are. These two steps should resolve many of the layering problems, which will rapidly reappear during a McBSP hwmod/PM runtime conversions. Signed-off-by: Paul Walmsley <paul@pwsan.com> Acked-by: Jarkko Nikula <jhnikula@gmail.com> Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-08OMAP: McBSP: implement McBSP CLKR and FSR signal muxing via mach-omap2/mcbsp.cPaul Walmsley1-35/+17
The OMAP ASoC McBSP code implemented CLKR and FSR signal muxing via direct System Control Module writes on OMAP2+. This required the omap_ctrl_{read,write}l() functions to be exported, which is against policy: the only code that should call those functions directly is OMAP core code, not device drivers. omap_ctrl_{read,write}*() are no longer exported, so the driver no longer builds as a module. Fix the pinmuxing part of the problem by removing calls to omap_ctrl_{read,write}l() from the OMAP ASoC McBSP code and implementing signal muxing functions in arch/arm/mach-omap2/mcbsp.c. Due to the unfortunate way that McBSP support is implemented in ASoC and the OMAP tree, these symbols must be exported for use by sound/soc/omap/omap-mcbsp.c. Going forward, the McBSP device driver should be moved from arch/arm/*omap* into drivers/ or sound/soc/*, and the CPU DAI driver should be implemented as a platform_driver as many other ASoC CPU DAI drivers are. These two steps should resolve many of the layering problems, which will rapidly reappear during a McBSP hwmod/PM runtime conversion. Signed-off-by: Paul Walmsley <paul@pwsan.com> Acked-by: Jarkko Nikula <jhnikula@gmail.com> Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-08ASoC: Staticise CS4270 DAIMark Brown1-1/+1
It's not needed with multi-component. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Acked-by: Timur Tabi <timur@freescale.com>
2010-10-07ASoC: Use delayed work for debounce of GPIO based jacksMark Brown1-6/+5
Rather than block the workqueue by sleeping to do the debounce use delayed work to implement the debounce time. This should also means that we extend the debounce time on each new bounce, potentially allowing shorter debounce times for clean insertions. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jhnikula@gmail.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-07ASoC: Staticise AD1980 DAIMark Brown1-1/+1
It doesn't need to be exported with multi-component. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-06ASoC: remove duplicated include for nuc900Nicolas Kaiser1-1/+0
Remove duplicated include. Signed-off-by: Nicolas Kaiser <nikai@nikai.net> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-06ASoC: sh: fix build error: terminate the platform device ID listGuennadi Liakhovetski1-0/+1
Platform driver ID table must be zero-element terminated. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-05ASoC: WM8804: Retrieve the device revision and print itDimitris Papastamos1-0/+8
Be verbose and print out the device revision. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-05ASoC: soc-cache: Add spi_write support for all I/O typesDimitris Papastamos1-0/+96
Ensure that all drivers that use SPI and I2C will work properly by providing SPI write functions for all different I/O types. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-05ALSA: ASoc: DaVinci Delay start of ASP to triggerTroy Kisky1-6/+0
Since only 4 mainline ASoC codecs support the trigger callback, we cannot rely upon them stopping the frame clock if they are master and must assume it is running even if the sound is paused. Thus we cannot start the ASP until the trigger method. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Martin Ambrose <martin@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-04ASoC: WM8804: Power down the PLL correctlyDimitris Papastamos1-3/+3
The PLL is disabled when the corresponding bit is set not the other way around. This commit depends on my other commit with Subject "ASoC: WM8804: Refactor set_pll code to avoid GCC warnings". Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-04ASoC: WM8804: Refactor set_pll code to avoid GCC warningsDimitris Papastamos1-21/+26
Ensure that no uninitialised variable warnings are generated by GCC. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-03ASoC: WM8804: Use a proper DAI nameDimitris Papastamos1-1/+1
Make sure the DAI name does not include a '/' since we might have per DAI debugfs or sysfs entries in the future. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-03ASoC: Put WM8962 GPIO2/3 into GPIO mode when configuring platform data tooMark Brown1-13/+29
GPIO2 and GPIO3 on the WM8962 are MFPs and need to be put into GPIO mode before the GPIO block can be used to control them. We're already doing this when used via gpiolib, factor out the code for use when setting static configurations via platform data as well. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-03ASoC: Implement interrupt based jack detectionMark Brown2-0/+88
Allow microphone detection on WM8962 to be performed using the interrupt signal, allowing the detection of both microphone presence and button presses with a signal singal from the CODEC to CPU. Currently a 250ms debounce time is applied to both short circuit and presence detection, this has not been optimised. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-03ASoC: Add support for WM8962 GPIO outputsMark Brown2-0/+120
The WM8962 features five GPIOs, add support for controlling their output state via gpiolib. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-01ASoC: Remove -dai suffix from i.MX SSI driverMark Brown4-4/+4
While it is a generic serial port in practice the i.MX SSI is only supported in Linux as an audio port (the i.MX has dedicated SPI controllers and so on). This means we don't need to disambiguate against other uses of the hardware and so can drop the -dai suffix from the driver name which fixes merge issues with the i.MX tree in -next. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-01ASoC: Relax restrictions on WM8962 BCLK configurationMark Brown1-6/+0
The restrictions on configuring BCLK are overly cautious, other constraints in the system should ensure that reconfiguration is not possible when the device is sufficiently active to be unable to support reclocking. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-10-01ASoC: WM8804: Initial driverDimitris Papastamos4-0/+887
The WM8804 is a high performance consumer mode S/PDIF transceiver with support for 1 received channel and 1 transmitted channel. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-01ASoC: Remove unneeded use of spi_bus_typeDimitris Papastamos10-10/+0
No need to explicitly set the bus type, spi_register_driver does that for us. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-30ASoC: Provide microphone bias configuration for WM8962Mark Brown1-0/+12
Add the widget for MICBIAS power control and allow configuration of the microphone bias setup via the platform data for the WM8962. When microphone status signals are brought out to GPIO this should be sufficient to enable microphone detection. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-30ASoC: Mark WM8962 Additional Control 4 register as volatileMark Brown1-1/+1
There are some status bits for microphone detection in here. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-29ASoC: Initial WM8962 IRQ supportMark Brown1-1/+59
Provide an initial hookup for interrupts on the WM8962. Currently we simply report error status via log messages if an IRQ is provided for the device. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-29ASoC: Lowercase WM8962 CODEC nameMark Brown1-1/+1
For consistency. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-29ASoC: Fix masking of WM8962 FLL1 registerMark Brown1-1/+1
When configuring the FLL we preserve the FLL enable configuration in order to allow us to reenable the FLL after configuration but we do not clear the other bits in the register, causing old configuration to be preserved. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-29ASoC: WM8985: Use the correct macro for the kcontrol definedDimitris Papastamos1-2/+2
Since we are using custom get/put handlers use SOC_ENUM_SINGLE_EXT_DECL instead of the original SOC_ENUM_SINGLE_DECL macro. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-27ASoC: Fix a compile warning for printk formatTakashi Iwai1-1/+1
sound/soc/codecs/wm8985.c: In function 'wm8985_hw_params': sound/soc/codecs/wm8985.c:731:2: warning: format '%d' expects type 'int', but argument 4 has type 'size_t' Actually the variable is fine as int. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-09-25Merge branch 'fix/asoc' into for-linusTakashi Iwai2-4/+16
2010-09-24ASoC: WM8985: Remove unneeded declaration.Dimitris Papastamos1-2/+0
We are not using the private data in this function, so get rid of it. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-24ASoC: Clean up AC'97 glue driverMark Brown1-9/+5
Remove version number and clean up some indentation. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-24ASoC: Add debug logging for s3c-ac97 resetsMark Brown1-0/+3
Helps tracing errors further up the stack. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jassi Brar <jassi.brar@samsung.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-24ASoC: Convert s3c-ac97 to pr_() macrosMark Brown1-5/+6
Could use dev_() but we'd have to remember the struct device somewhere and it wouldn't make the logging clearer. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jassi Brar <jassi.brar@samsung.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-24ASoC: Clean up the CODEC device as well as the board for SMDK WM9713Mark Brown1-0/+1
Otherwise we try to re-register the CODEC device if the module is reloaded and sysfs becomes miserable. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jassi Brar <jassi.brar@samsung.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-24ASoC: Clarify naming for SMDK WM9713 driverMark Brown1-1/+1
At least some of the systems using this device have multiple audio subsystems so provide some guidance to userspace about which one this is. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jassi Brar <jassi.brar@samsung.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-24ASoC: Remove unneeded WM9713 header include from SMDK WM9713 driverMark Brown1-1/+0
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jassi Brar <jassi.brar@samsung.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-23ASoC: Fix incorrect parameter to snd_soc_codec_volatile_registerDimitris Papastamos1-1/+1
We need to pass the register index and not the register value. This patch depends on my previous patch "ASoC: Delegate to hw specific read for volatile registers". Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-23ASoC: Delegate to hw specific read for volatile registersDimitris Papastamos1-26/+50
Ensure that reads on volatile registers will correctly delegate to the bus specific read function. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-23Fix typo configue => configure in commentsThomas Weber2-2/+2
Signed-off-by: Thomas Weber <weber@corscience.de> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2010-09-23ASoC: adapt multi-componentism againTakashi Iwai1-3/+3
Go back to the new world order. (Also fixed indentation.) Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-09-23Merge branch 'for-2.6.36' of ↵Takashi Iwai1-1/+1
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into topic/asoc
2010-09-22ASoC: Fix multi-componentismMark Brown1-1/+1
Spot the build testing. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-22ASoC: Return -1 instead of -EINVAL to ensure consistencyDimitris Papastamos1-2/+2
The code can't really cope with I/O errors, so it would be better to be consistent throughout all cache functions and return -1 instead of -EINVAL. The return value of snd_soc_read(...) is mostly checked in the probe function and nowhere else. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-22ASoC: Report error codes for card DAI instantiation failuresMark Brown1-1/+2
Also clean up the error print a bit. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-22Merge branch 'for-2.6.37' of ↵Mark Brown3-217/+287
git://git.kernel.org/pub/scm/linux/kernel/git/lrg/asoc-2.6 into for-2.6.37
2010-09-22ASoC: Fix soc-cache buffer overflow bugDimitris Papastamos1-2/+3
Make sure we stay within the cache boundaries when updating the register cache. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-21ASoC: Fix soc-cache buffer overflow bugDimitris Papastamos1-2/+3
Make sure we stay within the cache boundaries when updating the register cache. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-21ASoC: Remove extra rtd->dev.init_name assignment in soc_probe_dai_linkJarkko Nikula1-1/+0
rtd->dev.init_name is set twice in soc_probe_dai_link. I removed the first assignement from dai_link->stream_name since then there won't be sysfs name changes and usually dai_link->name seems to fit anyway better for a sysfs directory name. Signed-off-by: Jarkko Nikula <jhnikula@gmail.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-09-21ASoC: Fix merge issue with WM8962 control additionMark Brown1-2/+0
Let's not add the core controls twice. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-09-21ASoC: Report error code when failing to add controlsMark Brown1-2/+2
Helps with diagnostics. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>