Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/7] soc: qcom: geni: Derive SE clock configuration from OPP table on SA8255P
@ 2026-08-04 19:57 Praveen Talari
  2026-08-04 19:57 ` [PATCH 1/7] pmdomain: arm: Fix -EINVAL from scmi_pd_set_perf_state() on state 0 Praveen Talari
                   ` (6 more replies)
  0 siblings, 7 replies; 34+ messages in thread
From: Praveen Talari @ 2026-08-04 19:57 UTC (permalink / raw)
  To: konrad.dybcio, Sudeep Holla, Cristian Marussi, Ulf Hansson,
	Bjorn Andersson, Konrad Dybcio, Greg Kroah-Hartman, Jiri Slaby,
	Mark Brown, Viken Dadhaniya, Andi Shyti
  Cc: mukesh.savaliya, chandana.chiluveru, arm-scmi, linux-arm-kernel,
	linux-pm, linux-kernel, linux-arm-msm, linux-serial, linux-spi,
	linux-i2c, Praveen Talari

On firmware-managed platforms such as SA8255P, there is no Linux clock
handler available to determine the appropriate SE source clock, source
clock index, and divider values for a requested protocol frequency.
However, these parameters are required when programming GSI TREs, where
the hardware expects an explicit clock source selection and divider
configuration for the serial engine.

In contrast, platforms using Linux-managed clocks derive these
parameters through geni_se_clk_freq_match() using the source clock
information stored in clk_perf_tbl. Since the firmware-managed path
lacks equivalent clock information, protocol drivers cannot reuse the
existing frequency matching logic and instead rely on a direct mapping
between protocol-requested frequencies and performance levels. This
creates a separate clock configuration flow and prevents
firmware-managed platforms from deriving the actual SE clock parameters
required for GSI TRE programming.

To address this limitation, the performance-domain OPP table is treated
as the representation of SE-supported source clock frequencies. During
geni_se_domain_attach(), the OPP entries are used to populate
clk_perf_tbl and related clock performance data, allowing
firmware-managed platforms to leverage the same clock frequency matching
infrastructure used by Linux-managed platforms.

With this change, protocol drivers can use geni_se_clk_freq_match() to
select the closest supported source clock frequency for a requested
protocol rate, derive the corresponding source clock index and divider
values required for GSI TRE programming, and apply the matched clock
through the OPP framework. This removes the dependency on direct
protocol-frequency-to-performance-level mappings and provides a common
clock selection and configuration mechanism across both firmware-managed
and Linux-managed GENI deployments.

Signed-off-by: Praveen Talari <praveen.talari@oss.qualcomm.com>
---
Praveen Talari (7):
      pmdomain: arm: Fix -EINVAL from scmi_pd_set_perf_state() on state 0
      soc: qcom: geni-se: Populate clk_perf_tbl with SE source clock frequencies from perf OPP table
      soc: qcom: geni-se: Add helper to set SE clock rate via OPP
      serial: qcom-geni: Use geni_se_set_rate() for source clock configuration
      spi: qcom-geni: Use geni_se_set_rate() for setting source clock frequency
      i2c: qcom-geni: Use common GENI resource initialization helper
      i2c: qcom-geni: Use geni_se_set_rate() for setting source clock frequency

 drivers/i2c/busses/i2c-qcom-geni.c      | 45 +++++++++++-----------------
 drivers/pmdomain/arm/scmi_perf_domain.c |  2 +-
 drivers/soc/qcom/qcom-geni-se.c         | 53 ++++++++++++++++++++++++++++++++-
 drivers/spi/spi-geni-qcom.c             | 17 ++++-------
 drivers/tty/serial/qcom_geni_serial.c   | 19 ++++++------
 include/linux/soc/qcom/geni-se.h        |  2 ++
 6 files changed, 88 insertions(+), 50 deletions(-)
---
base-commit: 0f6da28aab51b16762ed82e8fdeaa5042da45b08
change-id: 20260805-derive_clk_perf_tbl_from_perf_domain_opp_table-2f29ad32226a

Best regards,
--  
Praveen Talari <praveen.talari@oss.qualcomm.com>



^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2026-08-25 18:03 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-04 19:57 [PATCH 0/7] soc: qcom: geni: Derive SE clock configuration from OPP table on SA8255P Praveen Talari
2026-08-04 19:57 ` [PATCH 1/7] pmdomain: arm: Fix -EINVAL from scmi_pd_set_perf_state() on state 0 Praveen Talari
2026-08-10 14:19   ` Ulf Hansson
2026-08-12  6:58   ` Mukesh Savaliya
2026-08-12  7:24   ` Mukesh Savaliya
2026-08-12  8:57     ` Ulf Hansson
2026-08-12  9:13       ` Mukesh Savaliya
2026-08-25  8:22   ` Abel Vesa
2026-08-04 19:57 ` [PATCH 2/7] soc: qcom: geni-se: Populate clk_perf_tbl with SE source clock frequencies from perf OPP table Praveen Talari
2026-08-12  7:36   ` Mukesh Savaliya
2026-08-24 14:56   ` Konrad Dybcio
2026-08-24 16:55     ` Praveen Talari
2026-08-04 19:57 ` [PATCH 3/7] soc: qcom: geni-se: Add helper to set SE clock rate via OPP Praveen Talari
2026-08-12  8:55   ` Mukesh Savaliya
2026-08-24 11:07   ` Mukesh Savaliya
2026-08-24 14:58   ` Konrad Dybcio
2026-08-24 17:00     ` Praveen Talari
2026-08-04 19:57 ` [PATCH 4/7] serial: qcom-geni: Use geni_se_set_rate() for source clock configuration Praveen Talari
2026-08-24 11:39   ` Mukesh Savaliya
2026-08-24 11:40   ` Mukesh Savaliya
2026-08-24 15:05   ` Konrad Dybcio
2026-08-25  4:00     ` Praveen Talari
2026-08-25  8:28       ` Konrad Dybcio
2026-08-04 19:57 ` [PATCH 5/7] spi: qcom-geni: Use geni_se_set_rate() for setting source clock frequency Praveen Talari
2026-08-04 20:03   ` Mark Brown
2026-08-24 11:52   ` Mukesh Savaliya
2026-08-04 19:57 ` [PATCH 6/7] i2c: qcom-geni: Use common GENI resource initialization helper Praveen Talari
2026-08-24 13:12   ` Mukesh Savaliya
2026-08-25 13:34     ` Praveen Talari
2026-08-04 19:57 ` [PATCH 7/7] i2c: qcom-geni: Use geni_se_set_rate() for setting source clock frequency Praveen Talari
2026-08-24 13:41   ` Mukesh Savaliya
2026-08-25 18:03     ` Praveen Talari
2026-08-24 15:06   ` Konrad Dybcio
2026-08-25  8:19     ` Praveen Talari

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox