mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
rockchip: rk-rng: simplify with dev_err_probe
This commit is contained in:
parent
eb08cc889a
commit
9fcac0612c
@ -499,10 +499,9 @@ static int rk_rng_probe(struct platform_device *pdev)
|
|||||||
rk_rng->mem += rk_rng->soc_data->default_offset;
|
rk_rng->mem += rk_rng->soc_data->default_offset;
|
||||||
|
|
||||||
rk_rng->clk_num = devm_clk_bulk_get_all(&pdev->dev, &rk_rng->clk_bulks);
|
rk_rng->clk_num = devm_clk_bulk_get_all(&pdev->dev, &rk_rng->clk_bulks);
|
||||||
if (rk_rng->clk_num < 0) {
|
if (rk_rng->clk_num < 0)
|
||||||
dev_err(&pdev->dev, "failed to get clks property\n");
|
return dev_err_probe(&pdev->dev, rk_rng->clk_num,
|
||||||
return -ENODEV;
|
"failed to get clks property\n");
|
||||||
}
|
|
||||||
|
|
||||||
platform_set_drvdata(pdev, rk_rng);
|
platform_set_drvdata(pdev, rk_rng);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user