summaryrefslogtreecommitdiff
path: root/drivers/clk/qcom/clk-branch.h
AgeCommit message (Collapse)AuthorFilesLines
2023-12-07clk: qcom: branch: Add mem ops support for branch2 clocksTaniya Das1-0/+21
Add the support for mem ops implementation to handle the sequence of enable/disable of the memories in ethernet PHY, prior to enable/disable of the respective clocks, which helps retain the respecive block's register contents. Signed-off-by: Taniya Das <quic_tdas@quicinc.com> Signed-off-by: Imran Shaik <quic_imrashai@quicinc.com> Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org> Link: https://lore.kernel.org/r/20231123064735.2979802-3-quic_imrashai@quicinc.com Signed-off-by: Bjorn Andersson <andersson@kernel.org>
2023-03-13clk: qcom: branch: Clean up branch enable registersKonrad Dybcio1-4/+3
Prefix the "branch enable" registers with CBCR_ to be closer to what they are actually called in Qualcomm terms, use GENMASK instead of shifting values around and adjust their usage accordingly. Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> Signed-off-by: Bjorn Andersson <andersson@kernel.org> Link: https://lore.kernel.org/r/20230208091340.124641-5-konrad.dybcio@linaro.org
2023-03-13clk: qcom: branch: Move CBCR bits definitions to the header fileKonrad Dybcio1-0/+4
Move the definitions of CBCR bits to the branch header file. Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> Signed-off-by: Bjorn Andersson <andersson@kernel.org> Link: https://lore.kernel.org/r/20230208091340.124641-4-konrad.dybcio@linaro.org
2023-03-13clk: qcom: branch: Add helper functions for setting SLEEP/WAKE bitsKonrad Dybcio1-0/+15
HLOS-controlled branch clocks on non-ancient Qualcomm platforms feature SLEEP and WAKE fields which can be written to to configure how long the clock hardware should wait internally before being (un)gated. Some very sensitive clocks need to have these values programmed to prevent putting the hardware in a not-exactly-good state. Add definitions of these fields and introduce helpers for setting them inside clock drivers. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> Signed-off-by: Bjorn Andersson <andersson@kernel.org> Link: https://lore.kernel.org/r/20230208091340.124641-3-konrad.dybcio@linaro.org
2023-03-13clk: qcom: branch: Add helper functions for setting retain bitsKonrad Dybcio1-0/+26
Most Qualcomm branch clocks come with a pretty usual set of bits that can enable memory retention by means of not turning off parts of the memory logic. Add them to the common header file and introduce helper functions for setting them instead of using magic writes. Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> Signed-off-by: Bjorn Andersson <andersson@kernel.org> Link: https://lore.kernel.org/r/20230208091340.124641-2-konrad.dybcio@linaro.org
2019-04-11clk: qcom: branch: Add AON clock opsBjorn Andersson1-0/+1
Some clocks can only be turned on by resetting the block containing them, provide a clock type that allow us to reference these clocks and have the client drivers enable and "disable" them. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Stephen Boyd <sboyd@kernel.org>
2018-07-25clk: qcom: Update SPDX headers for common filesTaniya Das1-12/+2
SPDX headers updated for common/branch/pll/regmap files. Signed-off-by: Taniya Das <tdas@codeaurora.org> Signed-off-by: Stephen Boyd <sboyd@kernel.org>
2018-05-08clk: qcom: Add support for BRANCH_HALT_SKIP flag for branch clocksAmit Nischal1-0/+1
There could be few clocks where the clock status bit is not required to be polled as the clock on/off would be controlled by enabling/disabling external source. Add support for the same by introducing new flag named as 'BRANCH_HALT_SKIP'. Signed-off-by: Amit Nischal <anischal@codeaurora.org> [sboyd@kernel.org: Rename flag to BRANCH_HALT_SKIP] Signed-off-by: Stephen Boyd <sboyd@kernel.org>
2014-01-17clk: qcom: Add support for branches/gate clocksStephen Boyd1-0/+56
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Mike Turquette <mturquette@linaro.org>