diff options
author | Takashi Iwai <[email protected]> | 2020-01-07 08:09:56 +0100 |
---|---|---|
committer | Mark Brown <[email protected]> | 2020-01-07 22:27:44 +0000 |
commit | 8e3366cad2bfe4e669bfd3758110be90b1dc75aa (patch) | |
tree | efc5b85d712fd313266e450691b1cf587ffa5606 /tools/perf/util/c++/clang-test.cpp | |
parent | 869bced7a055665e3ddb1ba671a441ce6f997bf1 (diff) |
ASoC: Fix NULL dereference at freeing
When an ASoC driver with pcm_destruct component ops is freed before
the PCM object instantiation (e.g. deferring the probe), it hits an
Oops at snd_soc_pcm_component_free() that calls the pcm_destruct ops
unconditionally.
Fix it by adding a NULL-check of rtd->pcm before calling callbacks.
Fixes: c64bfc906600 ("ASoC: soc-core: add new pcm_construct/pcm_destruct")
Reported-by: Matthias Brugger <[email protected]>
Tested-by: Ben Ho <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'tools/perf/util/c++/clang-test.cpp')
0 files changed, 0 insertions, 0 deletions