linux/sound
Amelie Delaunay 9bb4af400c
ASoC: stm32: spdifrx: fix dma channel release in stm32_spdifrx_remove
In case of error when requesting ctrl_chan DMA channel, ctrl_chan is not
null. So the release of the dma channel leads to the following issue:
[    4.879000] st,stm32-spdifrx 500d0000.audio-controller:
dma_request_slave_channel error -19
[    4.888975] Unable to handle kernel NULL pointer dereference
at virtual address 000000000000003d
[...]
[    5.096577] Call trace:
[    5.099099]  dma_release_channel+0x24/0x100
[    5.103235]  stm32_spdifrx_remove+0x24/0x60 [snd_soc_stm32_spdifrx]
[    5.109494]  stm32_spdifrx_probe+0x320/0x4c4 [snd_soc_stm32_spdifrx]

To avoid this issue, release channel only if the pointer is valid.

Fixes: 794df9448e ("ASoC: stm32: spdifrx: manage rebind issue")
Signed-off-by: Amelie Delaunay <amelie.delaunay@foss.st.com>
Signed-off-by: Olivier Moysan <olivier.moysan@foss.st.com>
Link: https://patch.msgid.link/20241105140242.527279-1-olivier.moysan@foss.st.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2024-11-05 16:26:03 +00:00
..
ac97 driver core: have match() callback in struct bus_type take a const * 2024-07-03 15:16:54 +02:00
aoa ALSA: Drop explicit initialization of struct i2c_device_id::driver_data to 0 2024-09-20 17:44:52 +02:00
arm ASoC: Updates for v6.10 2024-05-13 11:39:49 +02:00
atmel ALSA: misc: Use *-y instead of *-objs in Makefile 2024-05-08 18:18:13 +02:00
core ALSA: core: add isascii() check to card ID generator 2024-10-03 09:16:58 +02:00
drivers ALSA: aloop: Allow using global timers 2024-08-18 09:55:54 +02:00
firewire ALSA: firewire: use nonatomic PCM operation 2024-09-04 21:51:54 +09:00
hda ASoC: Intel: sst: Support LPE0F28 ACPI HID 2024-10-25 14:10:11 +01:00
i2c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
isa ALSA: gus: Fix some error handling paths related to get_bpos() usage 2024-10-04 09:02:30 +02:00
mips ALSA: misc: Use *-y instead of *-objs in Makefile 2024-05-08 18:18:13 +02:00
oss [tree-wide] finally take no_llseek out 2024-09-27 08:18:43 -07:00
parisc ALSA: misc: Use *-y instead of *-objs in Makefile 2024-05-08 18:18:13 +02:00
pci sound fixes for 6.12-rc2 2024-10-04 11:29:46 -07:00
pcmcia ALSA: vxpocket: Fix a typo at conversion to dev_*() 2024-08-08 20:23:41 +02:00
ppc ALSA: ppc: Use standard print API 2024-08-08 07:49:47 +02:00
sh ALSA: sh: Use standard print API 2024-08-08 07:49:47 +02:00
soc ASoC: stm32: spdifrx: fix dma channel release in stm32_spdifrx_remove 2024-11-05 16:26:03 +00:00
sparc ALSA: sparc: Fix a typo at dev_*() conversion 2024-08-09 09:39:48 +02:00
spi ALSA: spi: Drop NULL check for snd_ctl_remove() 2024-06-18 12:54:34 +02:00
synth ALSA: emux: Use standard print API 2024-08-08 07:49:46 +02:00
usb ALSA: line6: add hw monitor volume control to POD HD500X 2024-10-04 09:05:24 +02:00
virtio virtio: rename virtio_find_vqs_info() to virtio_find_vqs() 2024-07-17 05:20:58 -04:00
x86 Merge drm/drm-next into drm-intel-next 2024-06-19 11:38:31 +03:00
xen ALSA: xen-front: remove unused struct 'alsa_sndif_hw_param' 2024-06-13 14:14:46 +02:00
ac97_bus.c ALSA: ac97: legacy: Add missing module description 2024-05-09 10:13:07 +02:00
Kconfig
last.c
Makefile ALSA: core: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:32 +02:00
sound_core.c