linux/sound/soc/blackfin
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
..
bf5xx-ac97-pcm.c DMA-API: sound: fix dma mask handling in a lot of drivers 2013-10-31 14:48:47 +00:00
bf5xx-ac97.c ASoC: bf5xx-ac97: Fix compile error with SND_BF5XX_HAVE_COLD_RESET 2013-07-30 12:51:02 +01:00
bf5xx-ac97.h ASoC: bf5xx-ac97: Remove unused extern declaration 2013-07-30 13:01:09 +01:00
bf5xx-ad193x.c ASoC: blackfin: Switch bf5xx-ad193x from bf5xx-tdm to bf5xx-i2s 2013-05-30 12:33:40 +01:00
bf5xx-ad1836.c ASoC: blackfin: Switch bf5xx-ad1836 from bf5xx-tdm to bf5xx-i2s 2013-05-30 12:33:41 +01:00
bf5xx-ad1980.c ASoC: blackfin: Remove unused bf5xx-{i2s, tdm, ac97}-pcm.h 2013-05-30 12:33:40 +01:00
bf5xx-ad73311.c ASoC: blackfin: Remove unused bf5xx-{i2s, tdm, ac97}-pcm.h 2013-05-30 12:33:40 +01:00
bf5xx-i2s-pcm.c DMA-API: sound: fix dma mask handling in a lot of drivers 2013-10-31 14:48:47 +00:00
bf5xx-i2s-pcm.h ASoC: blackfin: bf5xx-i2s: Add support for TDM mode 2013-05-30 12:33:40 +01:00
bf5xx-i2s.c ASoC: blackfin: bf5xx-i2s: Add support for TDM mode 2013-05-30 12:33:40 +01:00
bf5xx-sport.c ASoC: blackfin: bf5xx-sport: Allow setting rx and tx mask independently 2013-05-30 12:33:40 +01:00
bf5xx-sport.h ASoC: blackfin: bf5xx-sport: Allow setting rx and tx mask independently 2013-05-30 12:33:40 +01:00
bf5xx-ssm2602.c ASoC: blackfin: Remove unused bf5xx-{i2s, tdm, ac97}-pcm.h 2013-05-30 12:33:40 +01:00
bf6xx-i2s.c ASoC: switch over to use snd_soc_register_component() on bf6xx i2s 2013-03-26 21:55:24 +00:00
bf6xx-sport.c ASoC: bfin: fix memory leak in sport3 controller driver 2012-08-09 14:08:59 +01:00
bf6xx-sport.h ASoC: add sport driver for bf6xx soc 2012-06-20 11:26:12 +01:00
bfin-eval-adau1373.c ASoC: blackfin: remove __dev* attributes 2012-12-10 00:29:39 +09:00
bfin-eval-adau1701.c ASoC: blackfin: remove __dev* attributes 2012-12-10 00:29:39 +09:00
bfin-eval-adav80x.c ASoC: blackfin: remove __dev* attributes 2012-12-10 00:29:39 +09:00
Kconfig ASoC: blackfin: Remove bf5xx-tdm driver 2013-05-30 12:33:41 +01:00
Makefile ASoC: blackfin: Remove bf5xx-tdm driver 2013-05-30 12:33:41 +01:00