]> git.baikalelectronics.ru Git - kernel.git/commit
clk: qcom: clk-rcg2: Update logic to calculate D value for RCG
authorTaniya Das <tdas@codeaurora.org>
Sun, 27 Feb 2022 17:55:35 +0000 (23:25 +0530)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Wed, 9 Mar 2022 14:53:29 +0000 (08:53 -0600)
commit586212c36b32be4889dcc12936058cf024f6e12b
treee274969792a42570ec86aed4a979394da75e9a46
parent9a22b6f3f0b853f69d79ac05ede8cd3a89d8a4f0
clk: qcom: clk-rcg2: Update logic to calculate D value for RCG

The display pixel clock has a requirement on certain newer platforms to
support M/N as (2/3) and the final D value calculated results in
underflow errors.
As the current implementation does not check for D value is within
the accepted range for a given M & N value. Update the logic to
calculate the final D value based on the range.

Fixes: a84793d0045df ("clk: qcom: Support display RCG clocks")
Signed-off-by: Taniya Das <tdas@codeaurora.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Link: https://lore.kernel.org/r/20220227175536.3131-1-tdas@codeaurora.org
drivers/clk/qcom/clk-rcg2.c