Skip to content

Commit 75d3da5

Browse files
committed
v3d_drv: Handle missing clock more gracefully
Signed-off-by: popcornmix <popcornmix@gmail.com>
1 parent b64eeb5 commit 75d3da5

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎drivers/gpu/drm/v3d/v3d_drv.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -284,9 +284,9 @@ static int v3d_platform_drm_probe(struct platform_device *pdev)
284284
}
285285

286286
v3d->clk = devm_clk_get(dev, NULL);
287-
if (IS_ERR(v3d->clk)) {
288-
if (ret != -EPROBE_DEFER)
289-
dev_err(dev, "Failed to get clock\n");
287+
if (IS_ERR_OR_NULL(v3d->clk)) {
288+
if (PTR_ERR(v3d->clk) != -EPROBE_DEFER)
289+
dev_err(dev, "Failed to get clock (%ld)\n", PTR_ERR(v3d->clk));
290290
goto dev_free;
291291
}
292292
v3d->clk_up_rate = clk_get_rate(v3d->clk);

0 commit comments

Comments
 (0)