Skip to content

Commit 880c239

Browse files
André ApitzschHans Verkuil
authored andcommitted
media: i2c: imx214: Separate legacy link frequency check from PLL calculation
Make it easier to drop the legacy support from the driver later. Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: André Apitzsch <git@apitzsch.eu> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
1 parent db967cc commit 880c239

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

drivers/media/i2c/imx214.c

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1362,18 +1362,16 @@ static int imx214_parse_fwnode(struct imx214 *imx214)
13621362
u64 freq = bus_cfg->link_frequencies[i];
13631363
struct ccs_pll pll;
13641364

1365-
if (!imx214_pll_calculate(imx214, &pll, freq))
1366-
break;
13671365
if (freq == IMX214_DEFAULT_LINK_FREQ_LEGACY) {
13681366
dev_warn(dev,
13691367
"link-frequencies %d not supported, please review your DT. Continuing anyway\n",
13701368
IMX214_DEFAULT_LINK_FREQ);
13711369
freq = IMX214_DEFAULT_LINK_FREQ;
1372-
if (imx214_pll_calculate(imx214, &pll, freq))
1373-
continue;
13741370
bus_cfg->link_frequencies[i] = freq;
1375-
break;
13761371
}
1372+
1373+
if (!imx214_pll_calculate(imx214, &pll, freq))
1374+
break;
13771375
}
13781376

13791377
if (i == bus_cfg->nr_of_link_frequencies)

0 commit comments

Comments
 (0)