summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-04-13 04:29:55 +0200
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2021-05-23 19:21:31 +0200
commiteed6a93044e38a63e397f7aef8dbc7ee667459fb (patch)
treee1625f9d10dd817d78510b1587f84b5b7010d116
parentca403b37cd9548115e2aeed61f6d147cc6f0d507 (diff)
downloadcachepc-linux-eed6a93044e38a63e397f7aef8dbc7ee667459fb.tar.gz
cachepc-linux-eed6a93044e38a63e397f7aef8dbc7ee667459fb.zip
media: imx: imx7_mipi_csis: Move static data to top of mipi_csis_dump_regs()
It's customary to declare static variables at the top of the function, with a blank line separating them from the non-static variables. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Rui Miguel Silva <rmfrfs@gmail.com> Reviewed-by: Frieder Schrempf <frieder.schrempf@kontron.de> Tested-by: Frieder Schrempf <frieder.schrempf@kontron.de> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
-rw-r--r--drivers/staging/media/imx/imx7-mipi-csis.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/staging/media/imx/imx7-mipi-csis.c b/drivers/staging/media/imx/imx7-mipi-csis.c
index fe6aa1d0afa1..1697d8740241 100644
--- a/drivers/staging/media/imx/imx7-mipi-csis.c
+++ b/drivers/staging/media/imx/imx7-mipi-csis.c
@@ -429,9 +429,6 @@ static inline u32 mipi_csis_read(struct csi_state *state, u32 reg)
static int mipi_csis_dump_regs(struct csi_state *state)
{
- struct device *dev = &state->pdev->dev;
- unsigned int i;
- u32 cfg;
static const struct {
u32 offset;
const char * const name;
@@ -450,6 +447,10 @@ static int mipi_csis_dump_regs(struct csi_state *state)
{ MIPI_CSIS_DBG_CTRL, "DBG_CTRL" },
};
+ struct device *dev = &state->pdev->dev;
+ unsigned int i;
+ u32 cfg;
+
dev_info(dev, "--- REGISTERS ---\n");
for (i = 0; i < ARRAY_SIZE(registers); i++) {