ASoC: rt5645: NULL pointer access when removing jack
authorBrent Lu <brent.lu@intel.com>
Mon, 4 Sep 2023 10:40:46 +0000 (18:40 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 4 Sep 2023 12:32:58 +0000 (13:32 +0100)
commit5366a64033ef46d7fc36db097d4bde12af22c405
treed4a112f4dd84f9dab4474641085a1e65ed7f2d26
parentd1cf5d30b43f1a331032ebf3e11d9e366ab0f885
ASoC: rt5645: NULL pointer access when removing jack

Machine driver calls snd_soc_component_set_jack() function with NULL
jack and data parameters when removing jack in codec exit function.
Do not access data when jack is NULL.

Signed-off-by: Brent Lu <brent.lu@intel.com>
Link: https://lore.kernel.org/r/20230904104046.4150208-1-brent.lu@intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5645.c