* [PATCH] clk: qcom: mmcc-sdm660: Fix MDSS AHB clock HWCG register offset
@ 2026-09-16 11:55 Abel Vesa
2026-09-17 8:02 ` Konrad Dybcio
0 siblings, 1 reply; 2+ messages in thread
From: Abel Vesa @ 2026-09-16 11:55 UTC (permalink / raw)
To: Bjorn Andersson, Abel Vesa, Stephen Boyd, Brian Masney,
Jerome Brunet, Konrad Dybcio, AngeloGioacchino Del Regno,
Martin Botka
Cc: linux-arm-msm, linux-clk, linux-kernel, Abel Vesa
The MDSS AHB clock HWCG bit resides in the same register as the branch
enable and halt status bits, at offset 0x2308. The current HWCG register
offset of 0x8a004 exceeds the regmap maximum of 0x40000, so regmap rejects
the read in clk_branch_in_hwcg_mode(). Since the read error is ignored,
the helper uses an uninitialized value to decide whether to skip the
halt status check.
Correct the HWCG register offset so the helper reads the actual hardware
clock gating state.
Fixes: 5db3ae8b33de ("clk: qcom: Add SDM660 Multimedia Clock Controller (MMCC) driver")
Assisted-by: LLM
Signed-off-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
---
drivers/clk/qcom/mmcc-sdm660.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/qcom/mmcc-sdm660.c b/drivers/clk/qcom/mmcc-sdm660.c
index 200f986de965..9f8b8e29fa0f 100644
--- a/drivers/clk/qcom/mmcc-sdm660.c
+++ b/drivers/clk/qcom/mmcc-sdm660.c
@@ -2017,7 +2017,7 @@ static struct clk_branch csiphy_ahb2crif_clk = {
static struct clk_branch mdss_ahb_clk = {
.halt_reg = 0x2308,
.halt_check = BRANCH_HALT,
- .hwcg_reg = 0x8a004,
+ .hwcg_reg = 0x2308,
.hwcg_bit = 1,
.clkr = {
.enable_reg = 0x2308,
---
base-commit: e6e35979777d646fe3c7c94dca7dd32fb25d45f4
change-id: 20260916-clk-qcom-mmcc-sdm660-fix-mdss-ahb-hwcg-offset-6009f29cb595
Best regards,
--
Abel Vesa <abel.vesa@oss.qualcomm.com>
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: [PATCH] clk: qcom: mmcc-sdm660: Fix MDSS AHB clock HWCG register offset
2026-09-16 11:55 [PATCH] clk: qcom: mmcc-sdm660: Fix MDSS AHB clock HWCG register offset Abel Vesa
@ 2026-09-17 8:02 ` Konrad Dybcio
0 siblings, 0 replies; 2+ messages in thread
From: Konrad Dybcio @ 2026-09-17 8:02 UTC (permalink / raw)
To: Abel Vesa, Bjorn Andersson, Abel Vesa, Stephen Boyd,
Brian Masney, Jerome Brunet, Konrad Dybcio,
AngeloGioacchino Del Regno, Martin Botka
Cc: linux-arm-msm, linux-clk, linux-kernel
On 9/16/26 1:55 PM, Abel Vesa wrote:
> The MDSS AHB clock HWCG bit resides in the same register as the branch
> enable and halt status bits, at offset 0x2308. The current HWCG register
> offset of 0x8a004 exceeds the regmap maximum of 0x40000, so regmap rejects
> the read in clk_branch_in_hwcg_mode(). Since the read error is ignored,
> the helper uses an uninitialized value to decide whether to skip the
> halt status check.
>
> Correct the HWCG register offset so the helper reads the actual hardware
> clock gating state.
>
> Fixes: 5db3ae8b33de ("clk: qcom: Add SDM660 Multimedia Clock Controller (MMCC) driver")
> Assisted-by: LLM
> Signed-off-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-09-17 8:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-16 11:55 [PATCH] clk: qcom: mmcc-sdm660: Fix MDSS AHB clock HWCG register offset Abel Vesa
2026-09-17 8:02 ` Konrad Dybcio
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®