aboutsummaryrefslogtreecommitdiffstats
path: root/include/sound (follow)
AgeCommit message (Collapse)AuthorFilesLines
2013-03-26Merge remote-tracking branch 'asoc/fix/max98090' into asoc-nextMark Brown1-0/+0
2013-03-26Merge remote-tracking branch 'asoc/fix/dapm' into asoc-nextMark Brown1-0/+1
2013-03-20ASoC:: max98090: Remove executable bitJoe Perches1-0/+0
Source files shouldn't have the executable bit set. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-15ASoC: add .name for snd_soc_component_driverKuninori Morimoto1-0/+1
This patch adds .name member on snd_soc_component_driver. But this patch doesn't care about whether cmpnt_drv was NULL, and/or its name was NULL in snd_soc_register_component() at this point. Because, it is easy to switch over to snd_soc_register_component() from snd_soc_register_dais() if it doesn't care cmpnt_drv was NULL. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-13ASoC: add snd_soc_register_component()Kuninori Morimoto1-0/+19
Current ASoC has register function for platform/codec/dai/card, but doesn't have for cpu. It often produces confusion and fault on ASoC. As result of ASoC community discussion, we consider new struct snd_soc_component for CPU/CODEC, and will switch over to use it. This patch adds very basic struct snd_soc_component, and register function for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-12ALSA: add/change some comments describing function return valuesYacine Belkadi3-11/+19
script/kernel-doc reports the following type of warnings (when run in verbose mode): Warning(sound/core/init.c:152): No description found for return value of 'snd_card_create' To fix that: - add missing descriptions of function return values - use "Return:" sections to describe those return values Along the way: - complete some descriptions - fix some typos Signed-off-by: Yacine Belkadi <yacine.belkadi.1@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-11ALSA: Make snd_BUG_ON() always evaluate and return the conditional expressionChristine Spang1-16/+8
Having snd_BUG_ON() only evaluate its conditional when CONFIG_SND_DEBUG is set leads to frequent bugs, since other similar macros in the kernel have different behavior. Let's make snd_BUG_ON() act like those macros so it will stop being accidentally misused. Signed-off-by: Christine Spang <christine.spang@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-08ALSA: ASoC: add codec driver for TI TAS5086Daniel Mack1-0/+7
This patch adds a driver for TI's TA5086 6-channel PWM processor. This chip has a very unusual register layout, specifically because the registers are of unequal size, and multi-byte registers require bulk writes to take effect. Regmap does not support these kind of mappings. Currently, the driver does not touch any of the registers >= 0x20, so it doesn't matter, because the register map is mapped to an 8-bit array. In case more features will be added in the future that require access to higher registers, the entire regmap H/W I/O routines have to be open-coded. Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-08ASoC: core: Remove unused "n_widgets" field from snd_soc_dapm structLars-Peter Clausen1-1/+0
Commit 497098be ("ASoC: dapm: Remove bodges for no-widget CODECs") removed the last user of the n_widgets field. Currently it is incremented for each widget added, but the value is never used, so we can remove it. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-08ASoC: core: Drop unused "dapm" field form soc_enum structLars-Peter Clausen1-1/+0
This field was added in commit 2e72f8e ("ASoC: New enum type: value_enum"), but has never been used since. Considering that the soc_enum struct is usually shared between all instances of a CODEC, it also doesn't make much sense to have a pointer to DAPM specific data in it. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-04ASoC: tegra_wm8903: assume CONFIG_OF, remove platform dataStephen Warren1-26/+0
Tegra only supports, and always enables, device tree. Remove all runtime checks for DT support from the driver. This allows removal of the hard-coded Harmony ASoC mapping table, since Harmony only boots with DT now. All board-specific configuration now comes from device tree, so there is no need to have a platform_data structure. Rework the driver to parse the device tree directly into struct tegra_wm8903. Also some slight re-ordering of probe() so that the code more closely resembles other drivers for easier comparison. Inparticular, the GPIO DT parsing and initial programming are moved together for each GPIO. Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-02-28Merge tag 'late-omap' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-socLinus Torvalds1-0/+53
Pull ARM SoC late OMAP changes from Olof Johansson: "This branch contains changes for OMAP that came in late during the release staging, close to when the merge window opened. It contains, among other things: - OMAP PM fixes and some patches for audio device integration - OMAP clock fixes related to common clock conversion - A set of patches cleaning up WFI entry and blocking. - A set of fixes and IP block support for PM on TI AM33xx SoCs (Beaglebone, etc) - A set of smaller fixes and cleanups around AM33xx restart and revision detection, as well as removal of some dead code (CONFIG_32K_TIMER_HZ)" * tag 'late-omap' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (34 commits) ARM: omap2: include linux/errno.h in hwmod_reset ARM: OMAP2+: fix some omap_device_build() calls that aren't compiled by default ARM: OMAP4: hwmod data: Enable AESS hwmod device ARM: OMAP4: hwmod data: Update AESS data with memory bank area ARM: OMAP4+: AESS: enable internal auto-gating during initial setup ASoC: TI AESS: add autogating-enable function, callable from architecture code ARM: OMAP2+: hwmod: add enable_preprogram hook ARM: OMAP4: clock data: Add missing clkdm association for dpll_usb ARM: OMAP2+: PM: Fix the dt return condition in pm_late_init() ARM: OMAP2: am33xx-hwmod: Fix "register offset NULL check" bug ARM: OMAP2+: AM33xx: hwmod: add missing HWMOD_NO_IDLEST flags ARM: OMAP: AM33xx hwmod: Add parent-child relationship for PWM subsystem ARM: OMAP: AM33xx hwmod: Corrects PWM subsystem HWMOD entries ARM: DTS: AM33XX: Add nodes for OCMC RAM and WKUP-M3 ARM: OMAP2+: AM33XX: Update the hardreset API ARM: OMAP2+: AM33XX: hwmod: Update the WKUP-M3 hwmod with reset status bit ARM: OMAP2+: AM33XX: hwmod: Fixup cpgmac0 hwmod entry ARM: OMAP2+: AM33XX: hwmod: Update TPTC0 hwmod with the right flags ARM: OMAP2+: AM33XX: hwmod: Register OCMC RAM hwmod ARM: OMAP2+: AM33XX: CM/PRM: Use __ASSEMBLER__ macros in header files ...
2013-02-25ASoC: dapm: Fix handling of loopsMark Brown1-0/+1
Currently if a path loops back on itself we correctly skip over it to avoid going into an infinite loop but this causes us to ignore the need to power up the path as we don't count the loop for the purposes of counting inputs and outputs. This means that internal loopbacks within a device that have powered devices on them won't be powered up. Fix this by treating any path that is currently in the process of being recursed as having a single input or output so that it is counted for the purposes of power decisions. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2013-02-16Merge tag 'asoc-3.9-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-nextTakashi Iwai1-0/+52
ASoC: Final updates for v3.9 A few more updates from the past week - a new driver from Dialog and some small fixes and tweaks.
2013-02-14Merge remote-tracking branch 'asoc/topic/da7213' into asoc-nextMark Brown1-0/+52
2013-02-14ASoC: codecs: Add da7213 codecAdam Thomson1-0/+52
This patch adds support for the Dialog DA7213 audio codec. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-02-14ALSA: compress: add support for gapless playbackJeeja KP1-0/+8
this add new API for sound compress to support gapless playback. As noted in Documentation change, we add API to send metadata of encoder and padding delay to DSP. Also add API for indicating EOF and switching to subsequent track Also bump the compress API version Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-11Merge tag 'asoc-3.9' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-nextTakashi Iwai10-97/+94
ASoC: Updates for v3.9 A fairly quiet release for ASoC: - Support for a wider range of hardware in the compressed stream code. - The ability to mute capture streams as well as playback streams while inactive. - DT support for AK4642, FSI, Samsung I2S and WM8962. - AC'97 support for Tegra. - New driver for max98090, replacing the stub which was there. Due to dependencies we've also got support for asynchronous I/O in regmap and DTification of DMA support for Samsung platforms (used only by the I2S driver and SPI) merged here as well.
2013-02-11Merge remote-tracking branch 'asoc/topic/wm2200' into asoc-nextMark Brown1-1/+21
2013-02-11Merge remote-tracking branch 'asoc/topic/wm2000' into asoc-nextMark Brown1-3/+0
2013-02-11Merge remote-tracking branch 'asoc/topic/tlv320aic3x' into asoc-nextMark Brown1-0/+10
2013-02-11Merge remote-tracking branch 'asoc/topic/simple-card' into asoc-nextMark Brown1-6/+6
2013-02-11Merge remote-tracking branch 'asoc/topic/of' into asoc-nextMark Brown2-1/+3
2013-02-11Merge remote-tracking branch 'asoc/topic/mxs' into asoc-nextMark Brown1-16/+0
2013-02-11Merge remote-tracking branch 'asoc/topic/max98090' into asoc-nextMark Brown1-0/+29
2013-02-11Merge remote-tracking branch 'asoc/topic/fsi' into asoc-nextMark Brown1-66/+4
2013-02-11Merge remote-tracking branch 'asoc/topic/cs4271' into asoc-nextMark Brown1-0/+15
2013-02-11Merge remote-tracking branch 'asoc/topic/core' into asoc-nextMark Brown2-3/+3
2013-02-10ASoC: TI AESS: add autogating-enable function, callable from architecture codePaul Walmsley1-0/+53
Add a basic header file for the TI AESS IP block, located in the OMAP4 Audio Back-End subsystem. Currently, this header file only contains a function to enable the AESS internal clock auto-gating. This will be used by a subsequent patch to ensure that the AESS won't block the entire chip low-power-idle mode. We wish to be able to place the AESS into idle even when no AESS driver has been compiled in. Signed-off-by: Paul Walmsley <paul@pwsan.com> Cc: Liam Girdwood <lrg@ti.com> Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: Péter Ujfalusi <peter.ujfalusi@ti.com> Cc: Tony Lindgren <tony@atomide.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-02-08ASoC: core: Allow digital mute for captureMark Brown1-1/+3
Help avoid noise from the power up of the capture path propagating through into the start of the recording (especially noise caused by the ramp of microphone biases) by keeping the capture muted until after we've finished powering things up with DAPM in the same manner we do for playback. This allows us to take advantage of soft mute support in the hardware more effectively and is more consistent. The core code using the existing digital mute operation is updated to take advantage of this. Some additional cases in the soc-pcm code and suspend will need separate handling but these are less practically relevant than the main runtime stream start/stop case. Rather than refactor the digital mute function in every single driver a new operation is added for drivers taking advantage of this functionality, the old operation should be phased out over time. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by Vinod Koul <vinod.koul@intel.com> Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2013-02-07ASoC: Replace max98090 Device DriverJerry Wong1-0/+29
This patch completes the replacement of the existing max98090 driver, by installing a more complete driver. Signed-off-by: Jerry Wong <jerry.wong@maximintegrated.com> Tested-by: Matthew Mowdy <matthew.mowdy@maximintegrated.com> Reviewed-by: Ralph Birt <ralph.birt@maximintegrated.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-02-05ASoC: wm2200: Provide platform data for MICBIAS configurationChris Rattray1-1/+21
Signed-off-by: Chris Rattray <crattray@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-02-04ASoC: tlv320aic3x: Convert mic bias to a supply widgetHebbar Gururaja1-0/+10
Convert MicBias widgets to supply widget. On tlv320aic3x, Mic bias power on/off shares the same register bits with output mic bias voltage. So, when power on mic bias, we need reclaim it to voltage value. Provide a new platform data so that the micbias voltage can be sent according to board requirement. Now since tlv320aic3x codec driver is DT aware, update dt files and functions to handle this new "micbias-vg" platform data. Because of sharing of bits, when enabling the micbias, voltage also needs to be updated. So use SND_SOC_DAPM_POST_PMU & SND_SOC_DAPM_PRE_PMD macro to create an event to handle this. Since micbias is converted to supply widget, updated machine drivers as well. This change is runtime tested on da850-evm with audio loopback (arecord|aplay) for confirmation. Signed-off-by: Hebbar Gururaja <gururaja.hebbar@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-30ASoC: SND_SOC_DAIFMT_GATED become 0 as default settingsKuninori Morimoto1-1/+1
Current soc-dai.h defines SND_SOC_DAIFMT_GATED as (2 << 4), but gated clock should be default settings (= 0). This patch fixup SND_SOC_DAIFMT_GATED as (0 << 4). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-29ALSA: Force a cast to silence a warning from "sparse"Antonio Ospite1-1/+1
Some audio drivers are calling snd_dma_continuous_data(GFP_KERNEL) which makes "sparse" give a warning: $ make C=2 M=sound/usb modules ... sound/usb/6fire/pcm.c:625:25: warning: cast from restricted gfp_t sound/usb/caiaq/audio.c:845:41: warning: cast from restricted gfp_t sound/usb/usx2y/usbusx2yaudio.c:997:54: warning: cast from restricted gfp_t sound/usb/usx2y/usbusx2yaudio.c:1001:54: warning: cast from restricted gfp_t sound/usb/usx2y/usx2yhwdeppcm.c:774:54: warning: cast from restricted gfp_t sound/usb/usx2y/usx2yhwdeppcm.c:778:54: warning: cast from restricted gfp_t Add __force to the cast to silence the warning. Signed-off-by: Antonio Ospite <ao2@amarulasolutions.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-27ASoC: add snd_soc_of_parse_daifmt() for DeviceTreeKuninori Morimoto1-0/+2
This patch adds snd_soc_of_parse_daifmt() and supports below style on DT. [prefix]format = "i2c"; [prefix]clock-gating = "continuous"; [prefix]bitclock-inversion; [prefix]bitclock-master; [prefix]frame-master; Each driver can use specific [prefix] (ex simple-card,cpu,dai,format = xxx;) This sample will be SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_CONT | SND_SOC_DAIFMT_IB_NF | SND_SOC_DAIFMT_CBM_CFM Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-25ALSA: Make snd_printd() and snd_printdd() inlineTakashi Iwai1-3/+9
Because currently snd_printd() and snd_printdd() macros are expanded to empty when CONFIG_SND_DEBUG=n, a compile warning like below appears sometimes, and we had to covert it by ugly ifdefs: sound/pci/hda/patch_sigmatel.c: In function ‘stac92hd71bxx_fixup_hp’: sound/pci/hda/patch_sigmatel.c:2434:24: warning: unused variable ‘spec’ [-Wunused-variable] For "fixing" these issues better, this patch replaces snd_printd() and snd_printdd() definitions with empty inline functions instead of macros. This should have the same effect but shut up warnings like above. But since we had already put ifdefs, changing to inline functions would trigger compile errors. So, such ifdefs is removed in this patch. In addition, snd_pci_quirk name field is defined only when CONFIG_SND_DEBUG_VERBOSE is set, and the reference to it in snd_printdd() argument triggers the build errors, too. For avoiding these errors, introduce a new macro snd_pci_quirk_name() that is defined no matter how the debug option is set. Reported-by: Stratos Karafotis <stratosk@semaphore.gr> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-16ASoC: SND_SOC_DAIFMT_NB_NF become 0 as default settingsKuninori Morimoto1-1/+1
Current soc-dai.h defines SND_SOC_DAIFMT_NB_NF as (1 << 8), but normal bit clock / normal frame should be default settings (= 0). This patch fixup SND_SOC_DAIFMT_NB_NF as (0 << 8). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-14ASoC: Constify ops and compr_ops fields of snd_soc_dai_linkLars-Peter Clausen1-2/+2
The core does not modify these fields, so they can be made const. This allows drivers to declare their op tables as const. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-14ASoC: simple-card: add asoc_simple_dai for initializingKuninori Morimoto1-6/+6
Current simple-card driver calls asoc_simple_card_dai_init() if platform had a asoc_simple_card_dai_init pointer. And, this initialization function works only when platform has an applicable initial value for each dai settings. And basically, almost all sound card requires certain initialization. This means that almost all platform has initialization settings, and driver do nothing if it doesn't have settings. And additionally, current simple-card supports sysclk settings but it was only for codec. In order to abolish deviation between cpu and codec, and in order to simplify processing, this patch adds asoc_simple_dai, and removed pointless struct asoc_simple_dai_init_info which was trigger of calling asoc_simple_card_dai_init(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-10Merge remote-tracking branch 'asoc/fix/cs4271' into tmpMark Brown1-1/+1
2013-01-10Merge remote-tracking branch 'asoc/fix/core' into tmpMark Brown1-4/+6
2013-01-08ASoC: mxs-saif: Remove platform dataFabio Estevam1-16/+0
All MXS users have been converted to device tree and the board files have been removed. No need to keep platform data in the driver. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Dong Aisheng <dong.aisheng@linaro.org> Acked-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-01-02UAPI: Remove empty Kbuild filesDavid Howells1-0/+0
Empty files can get deleted by the patch program, so remove empty Kbuild files and their links from the parent Kbuilds. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-12-24ASoC: fsi: cleanup sh_fsi.hKuninori Morimoto1-26/+4
FSI driver's flag usage was changed/removed by 3449f5fab8c51e37a8a48bc2516588c615373191 (ASoC: fsi: add SND_SOC_DAIFMT_INV_xxx support) ab6f6d85210c4d0265cf48e9958c04e08595055a (ASoC: fsi: add master clock control functions) And unused flags had been removed on FSI driver, but the definition had been kept to avoid compile error. It is possible to cleanup sh_fsi.h now. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-12-24ASoC: fsi: remove SH_FSI_xxx_INV flagsKuninori Morimoto1-7/+0
3449f5fab8c51e37a8a48bc2516588c615373191 (ASoC: fsi: add SND_SOC_DAIFMT_INV_xxx support) added clock inversion support via snd_soc_dai_set_fmt(). Thus, this patch removed SH_FSI_xxx_INV and fsi_get_info() from fsi driver, and modified platform settings to use new style. Then, it cleaned up meaningless settings from platform. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-12-24ASoC: fsi: remove platform depended .set_rate() callback supportKuninori Morimoto1-33/+0
ab6f6d85210c4d0265cf48e9958c04e08595055a (ASoC: fsi: add master clock control functions) added driver level clock control functions. And now, platform depended .set_rate() is no longer needed. This patch removed unnecessary .set_rate() platform callback support. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-12-24ALSA: ASoC: cs4271: add optional soft reset workaroundDaniel Mack1-0/+15
The CS4271 requires its LRCLK and MCLK to be stable before its RESET line is de-asserted. That also means that clocks cannot be changed without putting the chip back into hardware reset, which also requires a complete re-initialization of all registers. One (undocumented) workaround is to assert and de-assert the PDN bit in the MODE2 register. This patch adds a new flag to both the DT bindings as well as to the platform data to enable that workaround. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Alexander Sverdlin <subaparts@yandex.ru> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-12-24Merge branch 'asoc-fix-cs4271' into asoc-cs4271Mark Brown1-1/+1
2012-12-24ASoC: wm2000: Use clock API integration to configure MCLK divisorMark Brown1-3/+0
Since we are now using the clock API integration to manage MCLK we can now use clk_get_rate() to determine if we need to divide MCLK without relying on platform data. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>