Re: [PATCH 2/7] soc: qcom: geni-se: Populate clk_perf_tbl with SE source clock frequencies from perf OPP table
Mukesh Savaliya <[email protected]> Wed, 12 Aug 2026 13:06:36 +0530
| Newsgroups | org.kernel.vger.linux-i2c,org.infradead.lists.linux-arm-kernel,org.kernel.vger.arm-scmi,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-kernel,org.kernel.vger.linux-pm,org.kernel.vger.linux-serial,org.kernel.vger.linux-spi |
|---|---|
| Message-ID | <[email protected]> |
On 8/5/2026 1:27 AM, Praveen Talari wrote: > Currently, on the SA8255P platform, protocol drivers attached via > geni_se_domain_attach() treat each OPP on the perf domain as directly > corresponding to a protocol value such as a baudrate or requested > frequency, and simply request that OPP via > geni_se_set_perf_level()/geni_se_set_perf_opp(). This does not allow > computing a source clock and divider combination for a protocol > requested frequency, unlike the Linux clock managed path which derives > this from se->clk_perf_tbl via geni_se_clk_freq_match(), and then > applies the matched source clock frequency with dev_pm_opp_set_rate(). > > Change this by treating the OPP table exposed on the perf domain > device as representing the actual SE HW supported source clock > frequencies, the same role clk_perf_tbl plays for the Linux clock > managed path. Populate se->clk_perf_tbl and se->num_clk_levels by > iterating over this OPP table in geni_se_domain_attach(), so that > protocol drivers on the firmware managed (SA8255P) path can also use > geni_se_clk_freq_match() to pick the closest supported source clock > frequency and calculate the required divider, and apply it with > dev_pm_opp_set_rate() the same way as it is done for the Linux clock > managed path, instead of relying on a direct frequency/baudrate-to- > perf-level mapping. > > Signed-off-by: Praveen Talari <[email protected]> > --- Acked-by: Mukesh Savaliya <[email protected]>