Commit ae1fbdff authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Mark Brown

ASoC: imx-ssi: add check on platform_get_irq return value

Check return value from call to platform_get_irq(),
so in case of failure print error message and propagate
the return value.
Signed-off-by: default avatarGustavo A. R. Silva <garsilva@embeddedor.com>
Acked-by: default avatarNicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent b821d298
......@@ -527,6 +527,10 @@ static int imx_ssi_probe(struct platform_device *pdev)
}
ssi->irq = platform_get_irq(pdev, 0);
if (ssi->irq < 0) {
dev_err(&pdev->dev, "Failed to get IRQ: %d\n", ssi->irq);
return ssi->irq;
}
ssi->clk = devm_clk_get(&pdev->dev, NULL);
if (IS_ERR(ssi->clk)) {
......
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