Re: [PATCH v2 1/3] soc: qcom: ice: Add OPP-based clock scaling support for ICE
From: Abhinaba Rakshit
Date: Thu Dec 11 2025 - 00:49:48 EST
On Fri, Nov 21, 2025 at 02:46:52PM +0100, Konrad Dybcio wrote:
> On 11/21/25 11:36 AM, Abhinaba Rakshit wrote:
> > Register optional operation-points-v2 table for ICE device
> > and aquire its minimum and maximum frequency during ICE
> > device probe.
> >
> > Introduce clock scaling API qcom_ice_scale_clk which scale ICE
> > core clock if valid (non-zero) frequencies are obtained from
> > OPP-table. Zero min and max (default values) frequencies depicts
> > clock scaling is disabled.
> >
> > When an ICE-device specific OPP table is available, use the PM OPP
> > framework to manage frequency scaling and maintain proper power-domain
> > constraints. For legacy targets without an ICE-device specific OPP table,
> > fall back to the standard clock framework APIs to set the frequency.
>
> You can still set a frequency through OPP APIs if the table is empty
> (and one is always created even if devm_pm_opp_of_add_table() fails)
>
> [...]
>
> > /*
> > * Legacy DT binding uses different clk names for each consumer,
> > - * so lets try those first. If none of those are a match, it means
> > - * the we only have one clock and it is part of the dedicated DT node.
> > - * Also, enable the clock before we check what HW version the driver
> > - * supports.
> > + * so lets try those first. Also get its corresponding clock index.
> > + */
>
> I would argue *not* setting the rate on targets utilizing a binding without
> an OPP table for the ICE is probably a smart thing to do, because we may
> brownout the SoC this way
Also, adding to the previous reply, if we completly remove clock scaling for any target
we see a major degradation in IO throughput. On targets like Talos (target with legacy binding),
we observed around ~50%-70% degradation of IO performance if we don't keep the ICE clock
on par with storage clock and leaving it operate at default frequency.
>
> Konrad