linux-stable/sound/soc
Takashi Iwai 846b0dc704 ASoC: intel: atom: Fix breakage for PCM buffer address setup
[ Upstream commit 65ca89c2b1 ]

The commit 2e6b836312 ("ASoC: intel: atom: Fix reference to PCM
buffer address") changed the reference of PCM buffer address to
substream->runtime->dma_addr as the buffer address may change
dynamically.  However, I forgot that the dma_addr field is still not
set up for the CONTINUOUS buffer type (that this driver uses) yet in
5.14 and earlier kernels, and it resulted in garbage I/O.  The problem
will be fixed in 5.15, but we need to address it quickly for now.

The fix is to deduce the address again from the DMA pointer with
virt_to_phys(), but from the right one, substream->runtime->dma_area.

Fixes: 2e6b836312 ("ASoC: intel: atom: Fix reference to PCM buffer address")
Reported-and-tested-by: Hans de Goede <hdegoede@redhat.com>
Cc: <stable@vger.kernel.org>
Acked-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/2048c6aa-2187-46bd-6772-36a4fb3c5aeb@redhat.com
Link: https://lore.kernel.org/r/20210819152945.8510-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-08-26 08:37:10 -04:00
..
adi
amd
atmel ASoC: atmel: fix build error with CONFIG_SND_ATMEL_SOC_DMA=m 2020-02-28 16:36:03 +01:00
au1x
bcm
blackfin
cirrus ASoC: cirrus: i2s: Fix {TX|RX}LinCtrlData setup 2018-07-03 11:24:48 +02:00
codecs ASoC: cs42l42: Remove duplicate control for WNF filter frequency 2021-08-26 08:37:01 -04:00
davinci ASoC: davinci-mcasp: Fix dma_chan refcnt leak when getting dma type 2020-06-25 15:41:47 +02:00
dwc
fsl ASoC: fsl_esai: Fix TDM slot setup for I2S mode 2021-04-28 12:08:40 +02:00
generic
hisilicon ASoC: hisilicon: fix missing clk_disable_unprepare() on error in hi6210_i2s_startup() 2021-07-20 16:17:39 +02:00
img
intel ASoC: intel: atom: Fix breakage for PCM buffer address setup 2021-08-26 08:37:10 -04:00
jz4740 ASoC: jz4740-i2s: add missed checks for clk_get() 2020-12-29 13:46:58 +01:00
kirkwood ASoC: kirkwood: fix IRQ error handling 2020-10-01 13:12:26 +02:00
mediatek ASoC: mediatek: preallocate pages use platform device 2018-07-17 11:39:22 +02:00
mxs
nuc900
omap ASoC: omap-dmic: Add pm_qos handling to avoid overruns with CPU_IDLE 2018-12-17 09:28:50 +01:00
pxa
qcom ASoC: qcom: lpass-platform: Fix memory leak 2020-11-24 13:05:49 +01:00
rockchip ASoC: rockchip: Fix a reference count leak. 2020-06-30 15:38:04 -04:00
samsung ASoC: samsung: odroid: Fix clock configuration for 44100 sample rate 2019-05-10 17:53:09 +02:00
sh ASoC: rsnd: Fix HDMI channel mapping for multi-SSI mode 2020-05-10 10:28:59 +02:00
sirf ASoC: sirf: Fix potential NULL pointer dereference 2018-09-05 09:26:39 +02:00
spear
sti ASoC: sti: fix possible sleep-in-atomic 2020-02-05 14:18:20 +00:00
stm ASoC: stm32: spdifrx: fix race condition in irq handler 2020-01-17 19:45:44 +01:00
sunxi ASoC: sunxi: sun4i-codec: fill ASoC card owner 2021-04-16 11:57:50 +02:00
tegra ASoC: tegra: Set driver_name=tegra for all machine drivers 2021-07-20 16:17:46 +02:00
txx9
ux500
xtensa
zte ASoC: zte: Fix incorrect PCM format bit usages 2018-09-05 09:26:39 +02:00
Kconfig
Makefile
soc-ac97.c
soc-cache.c
soc-compress.c
soc-core.c ASoC: soc-core: Fix the error return code in snd_soc_of_parse_audio_routing() 2021-07-20 16:17:50 +02:00
soc-dapm.c ASoC: dapm: remove widget from dirty list on free 2021-01-23 15:48:40 +01:00
soc-devres.c
soc-generic-dmaengine-pcm.c ASoC: dmaengine: Make the pcm->name equal to pcm->id if the name is not set 2019-10-05 12:48:01 +02:00
soc-io.c
soc-jack.c ASoC: Jack: Fix NULL pointer dereference in snd_soc_jack_report 2019-12-17 20:39:27 +01:00
soc-ops.c ASoC: fix regwmask 2020-04-24 08:00:32 +02:00
soc-pcm.c ASoC: pcm: DRAIN support reactivation 2020-12-29 13:46:52 +01:00
soc-topology.c ASoC: topology: Check return value of pcm_new_ver 2020-05-10 10:28:58 +02:00
soc-utils.c