Commit eed6a930 authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Mauro Carvalho Chehab
Browse files

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: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: default avatarRui Miguel Silva <rmfrfs@gmail.com>
Reviewed-by: default avatarFrieder Schrempf <frieder.schrempf@kontron.de>
Tested-by: default avatarFrieder Schrempf <frieder.schrempf@kontron.de>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent ca403b37
Loading
Loading
Loading
Loading
+4 −3
Original line number Original line Diff line number Diff line
@@ -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)
static int mipi_csis_dump_regs(struct csi_state *state)
{
{
	struct device *dev = &state->pdev->dev;
	unsigned int i;
	u32 cfg;
	static const struct {
	static const struct {
		u32 offset;
		u32 offset;
		const char * const name;
		const char * const name;
@@ -450,6 +447,10 @@ static int mipi_csis_dump_regs(struct csi_state *state)
		{ MIPI_CSIS_DBG_CTRL, "DBG_CTRL" },
		{ MIPI_CSIS_DBG_CTRL, "DBG_CTRL" },
	};
	};


	struct device *dev = &state->pdev->dev;
	unsigned int i;
	u32 cfg;

	dev_info(dev, "--- REGISTERS ---\n");
	dev_info(dev, "--- REGISTERS ---\n");


	for (i = 0; i < ARRAY_SIZE(registers); i++) {
	for (i = 0; i < ARRAY_SIZE(registers); i++) {