spi: mt65xx: Move clock parent setting to remove clock disable gotos
authorAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Thu, 7 Apr 2022 11:44:24 +0000 (13:44 +0200)
committerMark Brown <broonie@kernel.org>
Tue, 19 Apr 2022 15:32:09 +0000 (16:32 +0100)
commit5dee8bb8d14dc7536cec58cc1d94148dce89dfc5
treefb894bf69319fde4e2b2bc08d30f3c9eed78553a
parent6b4440584b92851af44b235ad825c8554dd143c0
spi: mt65xx: Move clock parent setting to remove clock disable gotos

Reparenting sel_clk to parent_clk can be done before enabling any of
spi_clk and spi_hclk. Move the call to clk_set_parent() for sel_clk
earlier, and call disable_unprepare() upon spi_clk prepare_enable()
failure to remove all clock disablement related gotos.
This commit is in preparation of a later cleanup.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20220407114428.167091-5-angelogioacchino.delregno@collabora.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-mt65xx.c