]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
media: hantro: test the correct variable in probe()
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 20 May 2021 16:02:49 +0000 (18:02 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Wed, 2 Jun 2021 12:05:50 +0000 (14:05 +0200)
This should be testing "vpu->clocks[0].clk" instead of "vpu->clocks".

Fixes: eb4cacdfb998 ("media: hantro: add fallback handling for single irq/clk")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/staging/media/hantro/hantro_drv.c

index 2f6b01c7a6a0f1f8c6ce144ef8731e2a31b4a505..4914987cfd9ddaa28e71946eaf254182aeeff989 100644 (file)
@@ -783,8 +783,8 @@ static int hantro_probe(struct platform_device *pdev)
                 * actual name in the DT bindings.
                 */
                vpu->clocks[0].clk = devm_clk_get(&pdev->dev, NULL);
-               if (IS_ERR(vpu->clocks))
-                       return PTR_ERR(vpu->clocks);
+               if (IS_ERR(vpu->clocks[0].clk))
+                       return PTR_ERR(vpu->clocks[0].clk);
        }
 
        num_bases = vpu->variant->num_regs ?: 1;