In the rk628_csi_probe_of function, the clk_put label is currently used to disable and unprepare the soc_24M clock regardless of whether an error occurs earlier in the function. However, it seems that this might not be necessary and could be optimized. Specifically, the clk_put section may only need to be executed when an error occurs, rather than on every exit of the function.
In the rk628_csi_probe_of function, the clk_put label is currently used to disable and unprepare the soc_24M clock regardless of whether an error occurs earlier in the function. However, it seems that this might not be necessary and could be optimized. Specifically, the clk_put section may only need to be executed when an error occurs, rather than on every exit of the function.
https://github.com/armbian/linux-rockchip/blob/75ac2784c40818adbdabb06e98ac18317af5fdac/drivers/media/i2c/rk628/rk628_csi_v4l2.c#L2150-L2166
maybe just return on line 2175 ?