kernel-ark/sound/arm
Russell King c9bd5e690a DMA-API: sound: fix dma mask handling in a lot of drivers
This code sequence is unsafe in modules:

static u64 mask = DMA_BIT_MASK(something);
...
	if (!dev->dma_mask)
		dev->dma_mask = &mask;

as if a module is reloaded, the mask will be pointing at the original
module's mask address, and this can lead to oopses.  Moreover, they
all follow this with:

	if (!dev->coherent_dma_mask)
		dev->coherent_dma_mask = mask;

where 'mask' is the same value as the statically defined mask, and this
bypasses the architecture's check on whether the DMA mask is possible.

Fix these issues by using the new dma_coerce_coherent_and_mask()
function.

Acked-by: Mark Brown <broonie@linaro.org>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2013-10-31 14:48:47 +00:00
..
aaci.c ALSA: Remove the rest of *_set_drvdata(NULL) calls 2013-05-29 12:50:59 +02:00
aaci.h ALSA: AACI: make fifo variables more explanitory 2011-01-26 20:24:52 +00:00
Kconfig ALSA: drop outdated and broken sa11xx-uda1341 driver 2009-03-17 17:58:13 +01:00
Makefile ALSA: Remove old DMA-mmap code from arm/devdma.c 2009-11-27 10:15:24 +01:00
pxa2xx-ac97-lib.c ALSA: pxa27x: rename pxa27x_assert_ac97reset() 2013-01-08 11:30:08 +00:00
pxa2xx-ac97.c ASoC: pxa: use snd_dmaengine_dai_dma_data 2013-08-15 11:29:07 +01:00
pxa2xx-pcm-lib.c ASoC: pxa: use snd_dmaengine_dai_dma_data 2013-08-15 11:29:07 +01:00
pxa2xx-pcm.c DMA-API: sound: fix dma mask handling in a lot of drivers 2013-10-31 14:48:47 +00:00
pxa2xx-pcm.h ASoC: pxa: use snd_dmaengine_dai_dma_data 2013-08-15 11:29:07 +01:00