Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

clk: imx: imx8: Add a message in case of devm_clk_hw_register_mux_parent_data_table() error

If devm_clk_hw_register_mux_parent_data_table() fails, we branch to the
error handling path and imx_check_clk_hws() is never called.

Actually, imx_check_clk_hws() is a no-op because values in 'hws' are either
valid, either NULL.

Move the call to imx_check_clk_hws() in the error handling path, so that
an error is logged.

Fixes: d3a0946d7ac9 ("clk: imx: imx8: add audio clock mux driver")
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Abel Vesa <abel.vesa@linaro.org>

authored by

Christophe JAILLET and committed by
Abel Vesa
ef23d44b e9a164e3

+1 -2
+1 -2
drivers/clk/imx/clk-imx8-acm.c
··· 374 374 0, NULL, NULL); 375 375 if (IS_ERR(hws[sels[i].clkid])) { 376 376 ret = PTR_ERR(hws[sels[i].clkid]); 377 + imx_check_clk_hws(hws, IMX_ADMA_ACM_CLK_END); 377 378 goto err_clk_register; 378 379 } 379 380 } 380 - 381 - imx_check_clk_hws(hws, IMX_ADMA_ACM_CLK_END); 382 381 383 382 ret = devm_of_clk_add_hw_provider(dev, of_clk_hw_onecell_get, clk_hw_data); 384 383 if (ret < 0) {