projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d7f1849
)
ASoC: pcm3008: Check for platform data
author
Mark Brown
<broonie@linaro.org>
Wed, 10 Jul 2013 15:49:16 +0000
(16:49 +0100)
committer
Mark Brown
<broonie@linaro.org>
Mon, 15 Jul 2013 10:11:03 +0000
(11:11 +0100)
The driver will crash if none is provided.
Signed-off-by: Mark Brown <broonie@linaro.org>
sound/soc/codecs/pcm3008.c
patch
|
blob
|
blame
|
history
diff --git
a/sound/soc/codecs/pcm3008.c
b/sound/soc/codecs/pcm3008.c
index 8ab1c03d26bd5b616d31303f2076753b3464089b..4fa4ded30407fe8ce04fc350b8cb1ea3b7324b7a 100644
(file)
--- a/
sound/soc/codecs/pcm3008.c
+++ b/
sound/soc/codecs/pcm3008.c
@@
-92,6
+92,9
@@
static int pcm3008_codec_probe(struct platform_device *pdev)
struct pcm3008_setup_data *setup = pdev->dev.platform_data;
int ret;
+ if (!setup)
+ return -EINVAL;
+
/* DEM1 DEM0 DE-EMPHASIS_MODE
* Low Low De-emphasis 44.1 kHz ON
* Low High De-emphasis OFF