From: Wei Yongjun Date: Tue, 12 Jul 2016 11:01:26 +0000 (-0300) Subject: [media] VPU: mediatek: remove redundant dev_err call in mtk_vpu_probe() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=14ee452f3a6db34706f2560951cd0010aff2c848;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [media] VPU: mediatek: remove redundant dev_err call in mtk_vpu_probe() There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message. Signed-off-by: Wei Yongjun Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/platform/mtk-vpu/mtk_vpu.c b/drivers/media/platform/mtk-vpu/mtk_vpu.c index c8b2c72e7c48..c9bf58c97878 100644 --- a/drivers/media/platform/mtk-vpu/mtk_vpu.c +++ b/drivers/media/platform/mtk-vpu/mtk_vpu.c @@ -774,17 +774,13 @@ static int mtk_vpu_probe(struct platform_device *pdev) vpu->dev = &pdev->dev; res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "tcm"); vpu->reg.tcm = devm_ioremap_resource(dev, res); - if (IS_ERR((__force void *)vpu->reg.tcm)) { - dev_err(dev, "devm_ioremap_resource vpu tcm failed.\n"); + if (IS_ERR((__force void *)vpu->reg.tcm)) return PTR_ERR((__force void *)vpu->reg.tcm); - } res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "cfg_reg"); vpu->reg.cfg = devm_ioremap_resource(dev, res); - if (IS_ERR((__force void *)vpu->reg.cfg)) { - dev_err(dev, "devm_ioremap_resource vpu cfg failed.\n"); + if (IS_ERR((__force void *)vpu->reg.cfg)) return PTR_ERR((__force void *)vpu->reg.cfg); - } /* Get VPU clock */ vpu->clk = devm_clk_get(dev, "main");