From: sashiko-bot@kernel.org
To: "Kathiravan Thirumoorthy" <kathiravan.thirumoorthy@oss.qualcomm.com>
Cc: robh@kernel.org, conor+dt@kernel.org, devicetree@vger.kernel.org,
krzk+dt@kernel.org
Subject: Re: [PATCH v4 2/4] clk: qcom: add Global Clock controller (GCC) driver for IPQ9650 SoC
Date: Wed, 13 May 2026 05:01:54 +0000 [thread overview]
Message-ID: <20260513050155.790F6C2BCB7@smtp.kernel.org> (raw)
In-Reply-To: <20260512-ipq9650_boot_to_shell-v4-2-1e87c8326e59@oss.qualcomm.com>
Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [High] The `gcc_qpic_sleep_clk` branch clock is missing its parent clock initialization in `clk_init_data`.
- [Medium] The `gpll4` and `gcc_pcnoc_bfdcd_clk_src` clocks use the `CLK_IS_CRITICAL` flag, which contradicts the explicit comments stating to use `CLK_IGNORE_UNUSED`.
--
commit 066e3207c3655c5fa209013fda4d22eaa8774c6c
Author: Kathiravan Thirumoorthy <kathiravan.thirumoorthy@oss.qualcomm.com>
clk: qcom: add Global Clock controller (GCC) driver for IPQ9650 SoC
This commit adds support for the global clock controller found on the
IPQ9650 SoC devices.
> --- /dev/null
> +++ b/drivers/clk/qcom/gcc-ipq9650.c
[ ... ]
> +static struct clk_alpha_pll gpll4 = {
> + .offset = 0x22000,
> + .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_LUCID],
> + .clkr = {
> + .enable_reg = 0xb000,
> + .enable_mask = BIT(2),
> + .hw.init = &(const struct clk_init_data) {
> + .name = "gpll4",
> + .parent_data = &gcc_parent_data_xo,
> + .num_parents = 1,
> + /*
> + * There are no consumers for this GPLL in kernel yet,
> + * (will be added soon), so the clock framework
> + * disables this source. But some of the clocks
> + * initialized by boot loaders uses this source. So we
> + * need to keep this clock ON. Add the
> + * CLK_IGNORE_UNUSED flag so the clock will not be
> + * disabled. Once the consumer in kernel is added, we
> + * can get rid of this flag.
> + */
> + .flags = CLK_IS_CRITICAL,
The comment explicitly mentions adding the CLK_IGNORE_UNUSED flag, but the
code sets CLK_IS_CRITICAL instead. Should this be CLK_IGNORE_UNUSED to match
the description and avoid unconditionally forcing the clock on?
[ ... ]
> +static struct clk_rcg2 gcc_pcnoc_bfdcd_clk_src = {
> + .cmd_rcgr = 0x31004,
> + .mnd_width = 0,
> + .hid_width = 5,
> + .parent_map = gcc_parent_map_0,
> + .freq_tbl = ftbl_gcc_pcnoc_bfdcd_clk_src,
> + .clkr.hw.init = &(const struct clk_init_data) {
> + .name = "gcc_pcnoc_bfdcd_clk_src",
> + .parent_data = gcc_parent_data_0,
> + .num_parents = ARRAY_SIZE(gcc_parent_data_0),
> + /*
> + * There are no consumers for this source in kernel yet,
> + * (will be added soon), so the clock framework
> + * disables this source. But some of the clocks
> + * initialized by boot loaders uses this source. So we
> + * need to keep this clock ON. Add the
> + * CLK_IGNORE_UNUSED flag so the clock will not be
> + * disabled. Once the consumer in kernel is added, we
> + * can get rid of this flag.
> + */
> + .flags = CLK_IS_CRITICAL,
There is a similar mismatch here where the comment indicates CLK_IGNORE_UNUSED
but the implementation sets CLK_IS_CRITICAL.
[ ... ]
> +static struct clk_branch gcc_qpic_sleep_clk = {
> + .halt_reg = 0x32018,
> + .halt_check = BRANCH_HALT,
> + .clkr = {
> + .enable_reg = 0x32018,
> + .enable_mask = BIT(0),
> + .hw.init = &(const struct clk_init_data) {
> + .name = "gcc_qpic_sleep_clk",
> + .ops = &clk_branch2_ops,
> + },
> + },
> +};
Does this clock need parent initialization? Other sleep branch clocks in this
driver specify their parent, but this one appears to omit parent_hws and
num_parents. Could this leave the clock unparented in the clock framework?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260512-ipq9650_boot_to_shell-v4-0-1e87c8326e59@oss.qualcomm.com?part=2
next prev parent reply other threads:[~2026-05-13 5:01 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-12 5:12 [PATCH v4 0/4] Add minimal boot support for Qualcomm IPQ9650 SoC Kathiravan Thirumoorthy
2026-05-12 5:12 ` [PATCH v4 1/4] dt-bindings: clock: add Qualcomm IPQ9650 GCC Kathiravan Thirumoorthy
2026-05-13 4:36 ` sashiko-bot
2026-05-12 5:12 ` [PATCH v4 2/4] clk: qcom: add Global Clock controller (GCC) driver for IPQ9650 SoC Kathiravan Thirumoorthy
2026-05-13 5:01 ` sashiko-bot [this message]
2026-05-12 5:12 ` [PATCH v4 3/4] dt-bindings: qcom: add IPQ9650 boards Kathiravan Thirumoorthy
2026-05-12 5:12 ` [PATCH v4 4/4] arm64: dts: qcom: add IPQ9650 SoC and rdp488 board support Kathiravan Thirumoorthy
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=20260513050155.790F6C2BCB7@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=kathiravan.thirumoorthy@oss.qualcomm.com \
--cc=krzk+dt@kernel.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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