Skip to content

Commit

Permalink
dma: imx-sdma: Print a message when firmare fails to be requested
Browse files Browse the repository at this point in the history
Print a message when firmare fails to be requested in the case of platform data being used.

While at it, distinguish between the error messages of the device tree and platform data cases.

Signed-off-by: Fabio Estevam <[email protected]>
Acked-by: Sascha Hauer <[email protected]>
Signed-off-by: Vinod Koul <[email protected]>
  • Loading branch information
fabioestevam authored and Vinod Koul committed Mar 6, 2012
1 parent 6602b0d commit 6d0d7e2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/dma/imx-sdma.c
Original file line number Diff line number Diff line change
Expand Up @@ -1387,7 +1387,9 @@ static int __init sdma_probe(struct platform_device *pdev)
sdma_add_scripts(sdma, pdata->script_addrs);

if (pdata) {
sdma_get_firmware(sdma, pdata->fw_name);
ret = sdma_get_firmware(sdma, pdata->fw_name);
if (ret)
dev_err(&pdev->dev, "failed to get firmware from platform data\n");
} else {
/*
* Because that device tree does not encode ROM script address,
Expand All @@ -1401,7 +1403,7 @@ static int __init sdma_probe(struct platform_device *pdev)
else {
ret = sdma_get_firmware(sdma, fw_name);
if (ret)
dev_err(&pdev->dev, "failed to get firmware\n");
dev_err(&pdev->dev, "failed to get firmware from device tree\n");
}
}

Expand Down

0 comments on commit 6d0d7e2

Please sign in to comment.