From: André Apitzsch <g...@apitzsch.eu>

This makes it easier to drop this legacy support from the driver later.

Signed-off-by: André Apitzsch <g...@apitzsch.eu>
---
 drivers/media/i2c/imx214.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/media/i2c/imx214.c b/drivers/media/i2c/imx214.c
index 
63cf30acdc241de2f9ab3db339590da4af3d5102..52433775e9baddd8ab988e866a83387d53c1fd5c
 100644
--- a/drivers/media/i2c/imx214.c
+++ b/drivers/media/i2c/imx214.c
@@ -1362,18 +1362,16 @@ static int imx214_parse_fwnode(struct imx214 *imx214)
                u64 freq = bus_cfg->link_frequencies[i];
                struct ccs_pll pll;
 
-               if (!imx214_pll_calculate(imx214, &pll, freq))
-                       break;
                if (freq == IMX214_DEFAULT_LINK_FREQ_LEGACY) {
                        dev_warn(dev,
                                 "link-frequencies %d not supported, please 
review your DT. Continuing anyway\n",
                                 IMX214_DEFAULT_LINK_FREQ);
                        freq = IMX214_DEFAULT_LINK_FREQ;
-                       if (imx214_pll_calculate(imx214, &pll, freq))
-                               continue;
                        bus_cfg->link_frequencies[i] = freq;
-                       break;
                }
+
+               if (!imx214_pll_calculate(imx214, &pll, freq))
+                       break;
        }
 
        if (i == bus_cfg->nr_of_link_frequencies)

-- 
2.50.0



Reply via email to