clk: qcom: lcc-msm8960: use macros to implement mi2s clocks
authorDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Thu, 23 Jun 2022 12:04:08 +0000 (15:04 +0300)
committerBjorn Andersson <andersson@kernel.org>
Wed, 14 Sep 2022 02:58:34 +0000 (21:58 -0500)
commit7026af10aa9196fd08d51eeea81af3de6440c72b
treeba5263c56f77d30e5c1ad80f6bdf9433b108e6d5
parente38fc8f036a0b2908721aee9b75864acb8445be4
clk: qcom: lcc-msm8960: use macros to implement mi2s clocks

Split and extend existing CLK_AIF_OSR_DIV macro to implement mi2s
clocks. This simplifies the driver and removes extra code duplication.

The clock mi2s_div_clk used .enable_reg/.enable_bit, however these
fields are not used with by the clk_regmap_div_ops, thus they are
silently dropped. Clock enablement is handled in the mi2s_bit_div_clk
clock.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Tested-by: David Heidelberg <david@ixit.cz> # tested on Nexus 7 (2013)
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Link: https://lore.kernel.org/r/20220623120418.250589-6-dmitry.baryshkov@linaro.org
drivers/clk/qcom/lcc-msm8960.c