linux/sound/soc
Krzysztof Kozlowski 9f3ae72c5d
ASoC: codecs: wcd939x: Fix typec mux and switch leak during device removal
Driver does not unregister typec structures (typec_mux_dev and
typec_switch_desc) during removal leading to leaks.  Fix this by moving
typec registering parts to separate function and using devm interface to
release them.  This also makes code a bit simpler:
 - Smaller probe() function with less error paths and no #ifdefs,
 - No need to store typec_mux_dev and typec_switch_desc in driver state
   container structure.

Cc: stable@vger.kernel.org
Fixes: 10f514bd17 ("ASoC: codecs: Add WCD939x Codec driver")
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patch.msgid.link/20240701122616.414158-1-krzysztof.kozlowski@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
2024-07-04 12:42:24 +01:00
..
adi ASoC: adi: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:12 +09:00
amd ASoC: amd: acp: add pcm constraints for buffer size and period size 2024-06-21 13:18:09 +01:00
apple ASoC: apple: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:14 +09:00
atmel ASoC: atmel: atmel-classd: Re-add dai_link->platform to fix card init 2024-06-06 14:04:00 +01:00
au1x ASoC: au1x: Use *-y instead of *-objs Makefile 2024-05-08 11:39:16 +09:00
bcm ASoC: bcm: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:16 +09:00
cirrus ASoC: cirrus: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:17 +09:00
codecs ASoC: codecs: wcd939x: Fix typec mux and switch leak during device removal 2024-07-04 12:42:24 +01:00
dwc
fsl ASoC: fsl_xcvr: Improve suspend/resume flow in fsl_xcvr_trigger() 2024-07-03 15:17:51 +01:00
generic ASoC: audio-graph-card2: add link-trigger-order support 2024-06-26 17:47:59 +01:00
google
hisilicon
img ASoC: img: Use snd_soc_substream_to_rtd() for accessing private_data 2024-05-06 23:59:52 +09:00
intel ASoC: Intel: sof_sdw: select PINCTRL_CS42L43 and SPI_CS42L43 2024-06-24 13:40:09 +01:00
jz4740 ASoC: jz4740: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:21 +09:00
kirkwood ASoC: kirkwood: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:21 +09:00
loongson ASoC: loongson: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:22 +09:00
mediatek ASoC: mediatek: mt8183-da7219-max98357: Fix kcontrol name collision 2024-06-05 13:03:12 +01:00
meson ASoC: meson: tdm: add sample rate support up to 768kHz 2024-06-28 13:39:33 +01:00
mxs ASoC: mxs: add missing MODULE_DESCRIPTION() macro 2024-06-03 15:59:19 +01:00
pxa ASoC: pxa: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:26 +09:00
qcom ASoC: qcom: Adjust issues in case of DT error in asoc_qcom_lpass_cpu_platform_probe() 2024-06-26 18:35:51 +01:00
rockchip ASoC: Merge up fixes 2024-06-21 13:17:21 +01:00
samsung ASoC: samsung: midas_wm1811: Fix error code in probe() 2024-06-11 17:14:00 +01:00
sh ASoC: Constify DAI ops auto_selectable_formats 2024-06-17 18:29:02 +01:00
sof ASoC: SOF: ipc4-topology: Use single token list for the copiers 2024-07-04 12:42:23 +01:00
spear ASoC: spear: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:31 +09:00
sprd ASoC: sprd: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:32 +09:00
starfive
sti ASoC: sti: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:33 +09:00
stm ASoC: stm: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:34 +09:00
sunxi ASoC: sunxi: Use snd_soc_substream_to_rtd() for accessing private_data 2024-05-06 23:59:56 +09:00
tegra ASoC: tegra: I2S client convert formats handling 2024-05-27 13:59:49 +01:00
ti Fixes for McASP and dmaengine_pcm 2024-06-12 18:26:15 +01:00
uniphier ASoC: uniphier: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:36 +09:00
ux500 ASoC: Add missing module descriptions 2024-05-09 08:37:35 +02:00
xilinx ASoC: Add missing module descriptions 2024-05-09 08:37:35 +02:00
xtensa ASoC: xtensa: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:39 +09:00
Kconfig ASoC: soc-card: Add KUnit test case for snd_soc_card_get_kcontrol 2024-04-02 15:54:49 +01:00
Makefile ASoC: core: Use *-y instead of *-objs in Makefile 2024-05-08 11:39:11 +09:00
soc-ac97.c
soc-acpi.c
soc-card-test.c ASoC: soc-card: soc-card-test: Fix some error handling in init() 2024-04-14 16:54:39 +09:00
soc-card.c ASoC: soc-card: Use snd_ctl_find_id_mixer() instead of open-coding 2024-04-02 15:54:48 +01:00
soc-component.c
soc-compress.c ASoC: soc-compress: Fix and add DPCM locking 2024-03-18 14:41:51 +00:00
soc-core.c ASoC: Constify passed data to core function 2024-06-18 14:19:54 +01:00
soc-dai.c ASoC: Constify return of snd_soc_dai_get_pcm_stream() 2024-06-18 14:19:56 +01:00
soc-dapm.c ASoC: dapm: debugfs: show the widget type 2024-04-21 09:58:16 +09:00
soc-devres.c
soc-generic-dmaengine-pcm.c ALSA: dmaengine: Synchronize dma channel after drop() 2024-06-11 17:13:31 +01:00
soc-jack.c ASoC: soc-jack: Get rid of legacy GPIO support 2024-03-26 17:13:45 +00:00
soc-link.c
soc-ops.c ASoC: ops: Fix wraparound for mask in snd_soc_get_volsw 2024-03-28 22:01:43 +00:00
soc-pcm.c ASoC: Constify return of snd_soc_dai_get_pcm_stream() 2024-06-18 14:19:56 +01:00
soc-topology-test.c ASoC: topology-test: Add missing module description 2024-05-08 20:51:10 +09:00
soc-topology.c ASoC: topology: Unify code for creating standalone and widget enum control 2024-07-02 14:27:08 +01:00
soc-utils-test.c
soc-utils.c ASoC: soc-utils: allow sample rate up to 768kHz for the dummy dai 2024-06-28 13:39:29 +01:00