Re: [PATCH 4/5] clk: qcom: gcc-hawi: Add support for global clock controller on Maili

From: Taniya Das

Date: Mon Jul 06 2026 - 00:57:19 EST




On 6/22/2026 7:30 PM, Konrad Dybcio wrote:
>> + /*
>> + * Maili-only clocks: NULL here to size the array to the highest Maili
>> + * clock index.
>> + */
>> + [GCC_QUPV3_WRAP_5_S_AHB_CLK] = NULL,
> we have:
>
> --- common.c
> qcom_cc_really_probe():
>
> ...
> cc->rclks = rclks; // desc->clks
> cc->num_rclks = num_clks; // desc->num_clks
> ...
>
> -> devm_of_clk_add_hw_provider(dev, qcom_cc_clk_hw_get, cc);
>
> and qcom_cc_clk_hw_get() has:
>
> if (idx >= cc->num_rclks) {
> pr_err("%s: invalid index %u\n", __func__, idx);
> return ERR_PTR(-EINVAL);
> }
>
> so I think this should be unnecessary
>

Though common clock driver takes care of the check of idx, in order to
allocate the memory for the new clocks present on top of Hawi, we need
this piece of code.

> Besides, is that new set of clocks actually unique to Maili, or
> is it bound to a QSPI usecase on the specific QUP?

Yes, these are specifically new clocks added to Maili.

--
Thanks,
Taniya Das