Commit 33319a2f authored by Mark Brown's avatar Mark Brown

ASoC: pcm3008: Check for platform data

The driver will crash if none is provided.
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent d7f18495
......@@ -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
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment