aboutsummaryrefslogtreecommitdiff
path: root/sound
AgeCommit message (Collapse)Author
2013-04-25Merge tag 'asoc-v3.10-3' of ↵Takashi Iwai
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next ASoC: More updates for v3.10 A few more fixes, nothing too major though the DMA changes fix modular builds.
2013-04-25ALSA: hda - Add the support for ALC286 codecKailang Yang
It's yet another ALC269-variant. Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-25ALSA: usb-audio: USB quirk for Yamaha THR10CTrulan Martin
This patch adds a USB quirk for the Yamaha THR10C amp. Signed-off-by: Trulan Martin <trulanm@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-25ALSA: usb-audio: USB quirk for Yamaha THR5ATrulan Martin
This patch adds a USB quirk for the Yamaha THR5A amp. Signed-off-by: Trulan Martin <trulanm@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-25ALSA: usb-audio: USB quirk for Yamaha THR10Trulan Martin
This patch adds a USB quirk for the Yamaha THR10 amp. Signed-off-by: Trulan Martin <trulanm@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-25ALSA: usb-audio: Fix autopm error during probingTakashi Iwai
We've got strange errors in get_ctl_value() in mixer.c during probing, e.g. on Hercules RMX2 DJ Controller: ALSA mixer.c:352 cannot get ctl value: req = 0x83, wValue = 0x201, wIndex = 0xa00, type = 4 ALSA mixer.c:352 cannot get ctl value: req = 0x83, wValue = 0x200, wIndex = 0xa00, type = 4 .... It turned out that the culprit is autopm: snd_usb_autoresume() returns -ENODEV when called during card->probing = 1. Since the call itself during card->probing = 1 is valid, let's fix the return value of snd_usb_autoresume() as success. Reported-and-tested-by: Daniel Schürmann <daschuer@mixxx.org> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-25ALSA: snd-usb: try harder to find USB_DT_CS_ENDPOINTDaniel Mack
The USB_DT_CS_ENDPOINT class-specific endpoint descriptor is usually stuffed directly after the standard USB endpoint descriptor, and this is where the driver currently expects it to be. There are, however, devices in the wild that have it the other way around in their descriptor sets, so the USB_DT_CS_ENDPOINT comes *before* the standard enpoint. Devices known to implement it that way are "Sennheiser BTD-500" and Plantronics USB headsets. When the driver can't find the USB_DT_CS_ENDPOINT, it won't be able to change sample rates, as the bitmask for the validity of this command is storen in bmAttributes of that descriptor. Fix this by searching the entire interface instead of just the extra bytes of the first endpoint, in case the latter fails. Signed-off-by: Daniel Mack <zonque@gmail.com> Reported-and-tested-by: Torstein Hegge <hegge@resisty.net> Reported-and-tested-by: Yves G <alsa-user@vivigatt.com> Cc: stable@kernel.org Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-24ALSA: sound kconfig typoPavel Machek
Fix english in sound/drivers/Kconfig. Signed-off-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-24ALSA: emu10k1: Fix dock firmware loadingTakashi Iwai
The commit [b209c4df: ALSA: emu10k1: cache emu1010 firmware] broke the firmware loading of the dock, just (mistakenly) ignoring a different firmware for docks on some models. This patch revives them again. Bugzilla: https://bugs.archlinux.org/task/34865 Reported-and-tested-by: Tobias Powalowski <tobias.powalowski@googlemail.com> Cc: <stable@vger.kernel.org> [v3.8+] Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-23Merge remote-tracking branch 'asoc/topic/ux500' into asoc-nextMark Brown
2013-04-23Merge remote-tracking branch 'asoc/topic/max98088' into asoc-nextMark Brown
2013-04-23Merge remote-tracking branch 'asoc/topic/fsl' into asoc-nextMark Brown
2013-04-23Merge remote-tracking branch 'asoc/topic/dma' into asoc-nextMark Brown
2013-04-23Merge remote-tracking branch 'asoc/topic/davinci' into asoc-nextMark Brown
2013-04-23Merge remote-tracking branch 'asoc/topic/cs4271' into asoc-nextMark Brown
2013-04-23Merge remote-tracking branch 'asoc/topic/core' into asoc-nextMark Brown
2013-04-23ASoC: ux500: forward declare msp_i2s_platform_dataArnd Bergmann
We get a lot of build warnings from the msp driver like: In file included from sound/soc/ux500/ux500_msp_dai.h:21:0, from sound/soc/ux500/mop500.c:25: sound/soc/ux500/ux500_msp_i2s.h:546:11: warning: 'struct msp_i2s_platform_data' declared inside parameter list [enabled by default] struct msp_i2s_platform_data *platform_data); ^ sound/soc/ux500/ux500_msp_i2s.h:546:11: warning: its scope is only this definition or declaration, which is probably not what you want [enabled by default] The easiest solution is to add a declaration of the struct name. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-23ASoC: davinci-mcasp: Add Support BCLK-to-LRCLK ratio for TDM modesMichal Bachraty
For TDM mode, BCLK-to-LCLK ratio is computed as (tdm_slots) x (word_length). I2S mode is only subset of TDM mode with specific tdm_slots = 2 channels. Also bclk_lrclk_ratio can be greater than 255, therefore u16 need to be used. Signed-off-by: Michal Bachraty <michal.bachraty@streamunlimited.com> Acked-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-23ASoC: davinci-pcm, davinci-mcasp: Clean up active_serializersMichal Bachraty
As pointed of by Vaibhav, commit message: "ASoC: davinci-mcasp: Add support for multichannel playback" number of active serializers can be hidden into fifo_level variable, which is set in davimci-mcasp. Signed-off-by: Michal Bachraty <michal.bachraty@streamunlimited.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-23ASoC: generic-dmaengine-pcm: call dma_request_slave_channel()Shawn Guo
dma_request_slave_channel() is a more appropriate API for dmaengine clients that adopt generic DMA bindings to call. Let's use it instead of of_dma_request_slave_channel() to save <linux/of_dma.h> include. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-23ASoC: generic-dmaengine-pcm: use a more common dma nameShawn Guo
The examples in Documentation/devicetree/bindings/dma/dma.txt recommends the name for dma channel doing both RX and TX to be "rx-tx". This becomes a common pattern that has been adopted by platforms that converts to generic DMA bindings. Let's follow this common pattern in generic-dmaengine-pcm. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-22ALSA: hda - Limit internal mic boost for a few Asus machinesDavid Henningsson
These are being reported as being so noisy at high mic boost levels, so they are unusable in practice. Therefore artificially limit the boosts. BugLink: https://bugs.launchpad.net/bugs/1089795 Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-22ASoC: mxs: Use generic dmaengine PCMLars-Peter Clausen
Use the generic dmaengine PCM driver instead of a custom implementation. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-22ASoC: mxs: Setup dma data in DAI probeLars-Peter Clausen
This allows us to access the DAI DMA data when we create the PCM. We'll use this when converting mxs to generic DMA engine PCM driver. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-22ASoC: mxs-pcm: Set SNDRV_PCM_INFO_HALF_DUPLEXLars-Peter Clausen
The MXS SAIF is only half-duplex so set the SNDRV_PCM_INFO_HALF_DUPLEX flag for the PCM in order to prevent playback and capture from running at the same time. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-22ASoC: generic-dmaengine-pcm: Add support for half-duplexLars-Peter Clausen
Some platforms which are half-duplex share the same DMA channel between the playback and capture stream. Add support for this to the generic dmaengine PCM driver. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-22ALSA: snd-usb-audio: set the timeout for usb control set messages to 5000 msDaniel Schürmann
Set the timeout for USB control set messages according to the USB 2 spec, using the macros from include/linux/usb.h. The get timout becomes 5000 ms even though it is 500 ms in the spec. This patch is required to run the Hercules RMX2 which needs a timeout of 1240 ms. More notes from author: I still distinguish between set and get but as long both are 5000 ms GCC will remove it anyway. IMHO this is more easy read and there is no need to explain why we use a get timeout for set messages. Signed-off-by: Daniel Schürmann <daschuer@mixxx.org> Acked-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-22ALSA: compress: Use kzalloc() for ioctls writing back dataTakashi Iwai
Like the previous patch by Dan, we should clear the data to be returned from certain compress ioctls, namely, snd_compr_get_codec_caps() and snd_compr_get_params(). This time, we can simply replace kmalloc() with kzalloc(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-22ALSA: compress: info leak in snd_compr_get_caps()Dan Carpenter
If the ->get_caps() function doesn't clear the buffer then there would stack information leaked to userspace. For example, soc_compr_get_caps() can return success without clearing the buffer. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ALSA: compress_core: Rework writes to use cumulative valuesCharles Keepax
This patch reworks the writes to use cumulative values thus making the app_pointer unecessary and removing it. Only tested as far as build. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ALSA: compress_core: Remove unused hw_pointerCharles Keepax
Only tested as far as build. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ASoC: soc-compress: Deduce stream directionCharles Keepax
Previously we just hard coded all streams as playback streams, this patch checks the DAI to see if it is a capture or playback stream. It is worth noting that at this time only unidirectional streams are supported. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ALSA: compress_core: Add support for capture streamsCharles Keepax
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ALSA: compress_core: Deconstify copy callback bufferCharles Keepax
The buffer passed to the copy callback should not be const because the copy callback can be used for capture and playback. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ALSA: compress_core: Calculate avail correctly for capture streamsCharles Keepax
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-21ALSA: compress_core: Update calc_avail to use cumulative valuesCharles Keepax
The app_pointer is managed locally by the compress core for memory mapped DSPs but for DSPs that are not memory mapped this would have to be manually updated from within the DSP driver itself, which is hardly very idiomatic. This patch switches to using the cumulative values to calculate the available buffer space because these are already gracefully passed out of the DSP driver to the compress core and otherwise should be functionally equivalent. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-19vm: convert snd_pcm_lib_mmap_iomem() to vm_iomap_memory() helperLinus Torvalds
This is my example conversion of a few existing mmap users. The pcm mmap case is one of the more straightforward ones. Acked-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-04-18Merge tag 'asoc-v3.10-2' of ↵Takashi Iwai
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next ASoC: More updates for v3.10 The main additional change here is Lars-Peter's DMA work plus the platform conversions which have been tested - getting this in mainline will make life easier for development after the merge window. These factor a large chunk of code out of the drivers for the platforms using dmaengine, greatly simplifying development.
2013-04-18Merge remote-tracking branch 'asoc/topic/max98088' into asoc-nextMark Brown
2013-04-18Merge remote-tracking branch 'asoc/topic/fsl' into asoc-nextMark Brown
2013-04-18Merge remote-tracking branch 'asoc/topic/dma' into asoc-nextMark Brown
2013-04-18Merge remote-tracking branch 'asoc/topic/cs4271' into asoc-nextMark Brown
2013-04-18Merge remote-tracking branch 'asoc/topic/core' into asoc-nextMark Brown
2013-04-18ASoC: ux500: Use generic dmaengine PCMLars-Peter Clausen
Use the generic dmaengine PCM driver instead of a custom implemention. There is a minor functional change, the ux500 PCM driver did not preallocate the audio buffer, while the generic dmaengine PCM driver will do this. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-18ALSA: snd-usb: add quirks handler for DSD streamsDaniel Mack
Unfortunately, none of the UAC standards provides a way to identify DSD (Direct Stream Digital) formats. Hence, this patch adds a quirks handler to identify USB interfaces that are capable of handling DSD. That quirks handler can augment the already parsed formats bit-field, by any of the new SNDRV_PCM_FMTBIT_DSD_{U8_U16} and setting the dsd_dop flag in the audio format, if the driver should take care for the DOP byte stuffing. The only devices that are known to work with this are the ones with a 'Playback Designs' vendor id. Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18ALSA: snd-usb: add support for bit-reversed byte formatsDaniel Mack
There is quite some confusion around the bit-ordering in DSD samples, and no general agreement that defines whether hardware is supposed to expect the oldest sample in the MSB or the LSB of a byte. ALSA will hence set the rule that on the software API layer, bytes always carry the oldest bit in the most significant bit of a byte, and the driver has to translate that at runtime in order to match the hardware layout. This patch adds support for this by adding a boolean flag to the audio format struct. Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18ALSA: snd-usb: add support for DSD DOP stream transportDaniel Mack
In order to provide a compatibility way for pushing DSD samples through ordinary PCM channels, the "DoP open Standard" was invented. See http://www.dsd-guide.com for the official document. The host is required to stuff DSD marker bytes (0x05, 0xfa, alternating) in the MSB of 24 bit wide samples on the bus, in addition to the 16 bits of actual DSD sample payload. To support this, the hardware and software stride logic in the driver has to be tweaked a bit, as we make the userspace believe we're operating on 16 bit samples, while we in fact push one more byte per channel down to the hardware. The DOP runtime information is stored in struct snd_usb_substream, so we can keep track of our state across multiple calls to prepare_playback_urb_dsd_dop(). Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18ALSA: snd-usb: use ep->stride from urb callbacksDaniel Mack
For normal PCM transfer, this change has no effect, as the endpoint's stride is always frame_bits/8. For DSD DOP streams, however, which is added later, the hardware stride differs from the software stride, and the endpoint has the correct information in these cases. Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18ALSA: add DSD formatsDaniel Mack
This patch adds two formats for Direct Stream Digital (DSD), a pulse-density encoding format which is described here: https://en.wikipedia.org/wiki/Direct_Stream_Digital DSD operates on 2.8, 5.6 or 11.2MHz sample rates and as a 1-bit stream. The two new types added by this patch describe streams that are capable of handling DSD samples in DOP format as 8-bit or in 16-bit (or at a x8 or x16 data rate, respectively). DSD itself specifies samples in *bit*, while DOP and ALSA handle them as *bytes*. Hence, a factor of 8 or 16 has to be applied for the sample rare configuration, according to the following table: configured hardware 176.4KHz 352.8kHz 705.6KHz <---- sample rate 8-bit 2.8MHz 5.6MHz 16-bit 2.8Mhz 5.6MHz 11.2MHz `-----------------------------' actual DSD sample rates Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18ALSA: hda - Disable the sanity check in snd_hda_add_pincfg()Takashi Iwai
When pin default configs are overridden via patch option, these are evaluated before fixups are applied. Since some fixups change the whole codec trees and/or add pins dynamically, this sanity check might not pass when pins aren't present at the time the function is called. We may reorder the execution, but an easier fix is simply to disable this sanity check. Signed-off-by: Takashi Iwai <tiwai@suse.de>