[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <BN6PR04MB066006C199A43996C0502B62A3AE0@BN6PR04MB0660.namprd04.prod.outlook.com>
Date: Sat, 25 Apr 2020 19:26:41 -0700
From: Jonathan Bakker <xc-racer2@...e.ca>
To: kyungmin.park@...sung.com, s.nawrocki@...sung.com,
mchehab@...nel.org, kgene@...nel.org, krzk@...nel.org,
linux-media@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-samsung-soc@...r.kernel.org, linux-kernel@...r.kernel.org
Cc: Tomasz Figa <tomasz.figa@...il.com>,
Jonathan Bakker <xc-racer2@...e.ca>
Subject: [PATCH 02/11] media: exynos4-is: Request syscon only if ISP writeback is present
From: Tomasz Figa <tomasz.figa@...il.com>
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@...il.com>
Signed-off-by: Jonathan Bakker <xc-racer2@...e.ca>
---
drivers/media/platform/exynos4-is/fimc-core.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/media/platform/exynos4-is/fimc-core.c b/drivers/media/platform/exynos4-is/fimc-core.c
index 2258f3bfc929..08d1f39a914c 100644
--- a/drivers/media/platform/exynos4-is/fimc-core.c
+++ b/drivers/media/platform/exynos4-is/fimc-core.c
@@ -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);
--
2.20.1
Powered by blists - more mailing lists