Home
last modified time | relevance | path

Searched hist:ec63dcd3 (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/soc/qcom/
H A Dicc-bwmon.cec63dcd3 Thu Jul 28 06:37:44 CDT 2022 Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> soc: qcom: icc-bwmon: use regmap and prepare for BWMON v5

Refactor the code to prepare it for supporting BWMON v5 which comes with
different register layout by:
1. Adding use of MMIO regmap and regmap fields which allows to keep one
code logic with different register maps.
2. The "clear" type registers do not allow reading, therefore regmap
requires using cache with default values.
3. regmap has an effect of introducing barriers after each readl/writel,
which should negligible effect as only few writes were relaxed.
4. Additionally usage of regmap fields removes need of shifting the
register values.
5. Add "V4" prefix to names of all defines with register addresses (so
BWMON_V4_xxx) to differentiate it from V5. The actual register values
are shared so keep their naming.
6. While changing the defines, pad register addresses to three digits
for readability.

Cc: Rajendra Nayak <quic_rjendra@quicinc.com>
Cc: Sibi Sankar <quic_sibis@quicinc.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Tested-by: Steev Klimaszewski <steev@kali.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Link: https://lore.kernel.org/r/20220728113748.170548-8-krzysztof.kozlowski@linaro.org