mirror of https://gitee.com/openkylin/linux.git
media: exynos4-is: Request syscon only if ISP writeback is present
On FIMC variants which don't have writeback channel, there is no need to access system registers. This patch makes the driver request sysreg regmap conditionally depending on whether writeback is supported. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> Signed-off-by: Jonathan Bakker <xc-racer2@live.ca> Reviewed-by: Tomasz Figa <tfiga@chromium.org> Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
This commit is contained in:
parent
40df2adca6
commit
55400d7745
|
@ -954,9 +954,11 @@ static int fimc_probe(struct platform_device *pdev)
|
|||
spin_lock_init(&fimc->slock);
|
||||
mutex_init(&fimc->lock);
|
||||
|
||||
fimc->sysreg = fimc_get_sysreg_regmap(dev->of_node);
|
||||
if (IS_ERR(fimc->sysreg))
|
||||
return PTR_ERR(fimc->sysreg);
|
||||
if (fimc->variant->has_isp_wb) {
|
||||
fimc->sysreg = fimc_get_sysreg_regmap(dev->of_node);
|
||||
if (IS_ERR(fimc->sysreg))
|
||||
return PTR_ERR(fimc->sysreg);
|
||||
}
|
||||
|
||||
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
||||
fimc->regs = devm_ioremap_resource(dev, res);
|
||||
|
|
Loading…
Reference in New Issue