Skip to content

Commit f420f47

Browse files
olerembebarino
authored andcommitted
clk: imx6ul: fix "failed to get parent" error
On some configuration we may get following error: [ 0.000000] imx:clk-gpr-mux: failed to get parent (-EINVAL) This happens if selector is configured to not supported value. To avoid this warnings add dummy parents for not supported values. Fixes: 4e197ee ("clk: imx6ul: add ethernet refclock mux support") Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de> Link: https://lore.kernel.org/r/20230310164523.534571-1-o.rempel@pengutronix.de Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Reported-by: Stefan Wahren <stefan.wahren@i2se.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Stephen Boyd <sboyd@kernel.org>
1 parent 47d4308 commit f420f47

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

drivers/clk/imx/clk-imx6ul.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,14 +95,16 @@ static const struct clk_div_table video_div_table[] = {
9595
{ }
9696
};
9797

98-
static const char * enet1_ref_sels[] = { "enet1_ref_125m", "enet1_ref_pad", };
98+
static const char * enet1_ref_sels[] = { "enet1_ref_125m", "enet1_ref_pad", "dummy", "dummy"};
9999
static const u32 enet1_ref_sels_table[] = { IMX6UL_GPR1_ENET1_TX_CLK_DIR,
100-
IMX6UL_GPR1_ENET1_CLK_SEL };
100+
IMX6UL_GPR1_ENET1_CLK_SEL, 0,
101+
IMX6UL_GPR1_ENET1_TX_CLK_DIR | IMX6UL_GPR1_ENET1_CLK_SEL };
101102
static const u32 enet1_ref_sels_table_mask = IMX6UL_GPR1_ENET1_TX_CLK_DIR |
102103
IMX6UL_GPR1_ENET1_CLK_SEL;
103-
static const char * enet2_ref_sels[] = { "enet2_ref_125m", "enet2_ref_pad", };
104+
static const char * enet2_ref_sels[] = { "enet2_ref_125m", "enet2_ref_pad", "dummy", "dummy"};
104105
static const u32 enet2_ref_sels_table[] = { IMX6UL_GPR1_ENET2_TX_CLK_DIR,
105-
IMX6UL_GPR1_ENET2_CLK_SEL };
106+
IMX6UL_GPR1_ENET2_CLK_SEL, 0,
107+
IMX6UL_GPR1_ENET2_TX_CLK_DIR | IMX6UL_GPR1_ENET2_CLK_SEL };
106108
static const u32 enet2_ref_sels_table_mask = IMX6UL_GPR1_ENET2_TX_CLK_DIR |
107109
IMX6UL_GPR1_ENET2_CLK_SEL;
108110

0 commit comments

Comments
 (0)