projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
130d3e9
)
ASoC: Jack: Fix NULL pointer dereference in snd_soc_jack_report
author
Pawel Harlozinski
<pawel.harlozinski@linux.intel.com>
Tue, 12 Nov 2019 13:02:36 +0000
(14:02 +0100)
committer
Mark Brown
<broonie@kernel.org>
Tue, 12 Nov 2019 17:12:56 +0000
(17:12 +0000)
Check for existance of jack before tracing.
NULL pointer dereference has been reported by KASAN while unloading
machine driver (snd_soc_cnl_rt274).
Signed-off-by: Pawel Harlozinski <pawel.harlozinski@linux.intel.com>
Link:
https://lore.kernel.org/r/20191112130237.10141-1-pawel.harlozinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
sound/soc/soc-jack.c
patch
|
blob
|
history
diff --git
a/sound/soc/soc-jack.c
b/sound/soc/soc-jack.c
index
a71d234
..
b5748dc
100644
(file)
--- a/
sound/soc/soc-jack.c
+++ b/
sound/soc/soc-jack.c
@@
-82,10
+82,9
@@
void snd_soc_jack_report(struct snd_soc_jack *jack, int status, int mask)
unsigned int sync = 0;
int enable;
- trace_snd_soc_jack_report(jack, mask, status);
-
if (!jack)
return;
+ trace_snd_soc_jack_report(jack, mask, status);
dapm = &jack->card->dapm;