From: sashiko-bot@kernel.org
To: "Taniya Das" <taniya.das@oss.qualcomm.com>
Cc: conor+dt@kernel.org, robh@kernel.org, devicetree@vger.kernel.org,
krzk+dt@kernel.org
Subject: Re: [PATCH v3 5/7] clk: qcom: gpucc: Add GPU Clock Controller driver for Eliza
Date: Thu, 14 May 2026 10:02:29 +0000 [thread overview]
Message-ID: <20260514100230.0AD7CC2BCB3@smtp.kernel.org> (raw)
In-Reply-To: <20260513-eliza_mm_cc_v2-v3-5-b59c370dc281@oss.qualcomm.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] Hardware State Conflict and CCF Reference Counting Race on SMMU Vote Clocks
--
commit 677d8bac725b37e31762837245d464597c8a7f08
Author: Taniya Das <taniya.das@oss.qualcomm.com>
clk: qcom: gpucc: Add GPU Clock Controller driver for Eliza
This commit adds Graphics Clock Controller (GPUCC) support for the Eliza
platform.
> diff --git a/drivers/clk/qcom/gpucc-eliza.c b/drivers/clk/qcom/gpucc-eliza.c
> new file mode 100644
> index 0000000000000..85ae0ab118405
> --- /dev/null
> +++ b/drivers/clk/qcom/gpucc-eliza.c
[ ... ]
> +static struct clk_branch gpu_cc_gpu_smmu_vote_clk = {
> + .halt_reg = 0x7000,
> + .halt_check = BRANCH_HALT_VOTED,
> + .clkr = {
> + .enable_reg = 0x7000,
> + .enable_mask = BIT(0),
> + .hw.init = &(const struct clk_init_data) {
> + .name = "gpu_cc_gpu_smmu_vote_clk",
> + .ops = &clk_branch2_ops,
> + },
> + },
> +};
> +
> +static struct clk_branch gpu_cc_hlos1_vote_gpu_smmu_clk = {
> + .halt_reg = 0x7000,
> + .halt_check = BRANCH_HALT_VOTED,
> + .clkr = {
> + .enable_reg = 0x7000,
> + .enable_mask = BIT(0),
Will this cause a hardware state conflict?
Both gpu_cc_gpu_smmu_vote_clk and gpu_cc_hlos1_vote_gpu_smmu_clk are defined
using the exact same hardware register (0x7000) and mask (BIT(0)).
Since the Common Clock Framework maintains software reference counts per
clk_core instance rather than per hardware bit, if two separate consumers
enable these clocks, both will set BIT(0).
If one consumer then disables its clock, the disable callback will clear
BIT(0) in hardware because its local software reference count reached 0.
This would turn off the physical clock even though the other consumer's
reference count is still positive.
Could this lead to a system hang, bus fault, or unrecoverable kernel panic
when the active consumer accesses the unclocked hardware?
> + .hw.init = &(const struct clk_init_data) {
> + .name = "gpu_cc_hlos1_vote_gpu_smmu_clk",
> + .ops = &clk_branch2_ops,
> + },
> + },
> +};
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260513-eliza_mm_cc_v2-v3-0-b59c370dc281@oss.qualcomm.com?part=5
next prev parent reply other threads:[~2026-05-14 10:02 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-13 14:23 [PATCH v3 0/7] Add support for Video, Camera, Graphics clock controllers on Eliza Taniya Das
2026-05-13 14:23 ` [PATCH v3 1/7] dt-bindings: clock: qcom: Add video clock controller on Qualcomm Eliza SoC Taniya Das
2026-05-14 5:33 ` sashiko-bot
2026-05-13 14:23 ` [PATCH v3 2/7] dt-bindings: clock: qcom: document the Eliza GPU Clock Controller Taniya Das
2026-05-13 14:23 ` [PATCH v3 3/7] dt-bindings: clock: qcom: Add support for CAMCC for Eliza Taniya Das
2026-05-14 6:04 ` sashiko-bot
2026-05-13 14:23 ` [PATCH v3 4/7] clk: qcom: videocc: Add video clock controller driver " Taniya Das
2026-05-13 14:23 ` [PATCH v3 5/7] clk: qcom: gpucc: Add GPU Clock Controller " Taniya Das
2026-05-14 10:02 ` sashiko-bot [this message]
2026-05-13 14:23 ` [PATCH v3 6/7] clk: qcom: camcc: Add support for camera clock controller " Taniya Das
2026-05-14 11:01 ` sashiko-bot
2026-05-13 14:23 ` [PATCH v3 7/7] arm64: dts: qcom: eliza: Add support for MM clock controllers Taniya Das
2026-05-14 11:18 ` sashiko-bot
2026-05-13 15:29 ` [PATCH v3 0/7] Add support for Video, Camera, Graphics clock controllers on Eliza Taniya Das
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260514100230.0AD7CC2BCB3@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=taniya.das@oss.qualcomm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox