linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/5] media: qcom: camss: Introduce support for named power-domains
@ 2023-10-26 15:50 Bryan O'Donoghue
  2023-10-26 15:50 ` [PATCH v2 1/5] media: qcom: camss: Flag which VFEs require a power-domain Bryan O'Donoghue
                   ` (4 more replies)
  0 siblings, 5 replies; 16+ messages in thread
From: Bryan O'Donoghue @ 2023-10-26 15:50 UTC (permalink / raw)
  To: hverkuil-cisco, laurent.pinchart, rfoss, todor.too, andersson,
	konrad.dybcio, mchehab
  Cc: linux-media, linux-arm-msm, linux-kernel, bryan.odonoghue

V2:
- Incorporates Konrad's suggestion re: removing 'id'
- Adds RB - Konrad
- Adds in a flag to indicate if a VFE has a power domain.
  As I rebased this series I realised we had some magic indexing for VFE v
  VFE Lite, which isn't the root cause of my bug bear in this series but is
  the same sin - inferring functionality from indexing.
  Once we transition fully to named pds we won't need a 'has_pd' to flag
  which VFEs need power-domain attachment and which don't.
  That transition will require populating all upstream dtsi with pd-names
  and then deprecating the old way.
  has_pd is a far better choice than inferring from indexes so, I've added.

Link: https://git.codelinaro.org/bryan.odonoghue/kernel/-/commits/aa45a2b58aa1e187a2698a65164d694251f08fa1

V1:
At the moment the Qcom CAMSS driver relies on the declaration order of
power-domains within the dtsi to determine which power-domain relates to a
VFE and which power-domain relates to the top-level (top) CAMSS
power-domain.

VFE power-domains must be declared prior to the top power-domain. The top
power-domain must be declared last. Early SoCs have just one top
power-domain with later SoCs introducing VFE specific power-domains.

Differentiating between the number of power-domains results in lots of code
which is brittle and which we can mostly get rid of with named
power-domains.

The reliance on declaration ordering is in-effect magic number indexing.

This series introduces named power-domains for CAMSS and refactors some of
the code in CAMSS to support the new named power-domains. We continue to
support the legacy indexing model with an intention to remove after a
reasonable transition period.

New SoC additions should use named power-domains from now on.

Tested on x13s, rb5, db410c

Link: https://git.codelinaro.org/bryan.odonoghue/kernel/-/tree/linux-next-23-10-23-camss-named-power-domains

Bryan O'Donoghue (5):
  media: qcom: camss: Flag which VFEs require a power-domain
  media: qcom: camss: Convert to per-VFE pointer for power-domain
    linkages
  media: qcom: camss: Use common VFE pm_domain_on/pm_domain_off where
    applicable
  media: qcom: camss: Move VFE power-domain specifics into vfe.c
  media: qcom: camss: Add support for named power-domains

 .../media/platform/qcom/camss/camss-vfe-170.c | 36 --------
 .../media/platform/qcom/camss/camss-vfe-4-1.c |  8 +-
 .../media/platform/qcom/camss/camss-vfe-4-7.c | 36 --------
 .../media/platform/qcom/camss/camss-vfe-4-8.c | 31 -------
 .../media/platform/qcom/camss/camss-vfe-480.c | 36 --------
 drivers/media/platform/qcom/camss/camss-vfe.c | 77 ++++++++++++++++
 drivers/media/platform/qcom/camss/camss-vfe.h | 16 ++++
 drivers/media/platform/qcom/camss/camss.c     | 87 ++++++++++++-------
 drivers/media/platform/qcom/camss/camss.h     |  7 +-
 9 files changed, 156 insertions(+), 178 deletions(-)

-- 
2.42.0


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

end of thread, other threads:[~2023-10-31 17:11 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-26 15:50 [PATCH v2 0/5] media: qcom: camss: Introduce support for named power-domains Bryan O'Donoghue
2023-10-26 15:50 ` [PATCH v2 1/5] media: qcom: camss: Flag which VFEs require a power-domain Bryan O'Donoghue
2023-10-26 20:05   ` Konrad Dybcio
2023-10-26 15:50 ` [PATCH v2 2/5] media: qcom: camss: Convert to per-VFE pointer for power-domain linkages Bryan O'Donoghue
2023-10-26 20:08   ` Konrad Dybcio
2023-10-27  9:10     ` Bryan O'Donoghue
2023-10-27  9:38       ` Bryan O'Donoghue
2023-10-26 15:50 ` [PATCH v2 3/5] media: qcom: camss: Use common VFE pm_domain_on/pm_domain_off where applicable Bryan O'Donoghue
2023-10-26 15:50 ` [PATCH v2 4/5] media: qcom: camss: Move VFE power-domain specifics into vfe.c Bryan O'Donoghue
2023-10-31 10:54   ` Konrad Dybcio
2023-10-31 11:51     ` Bryan O'Donoghue
2023-10-31 15:04       ` Konrad Dybcio
2023-10-26 15:50 ` [PATCH v2 5/5] media: qcom: camss: Add support for named power-domains Bryan O'Donoghue
2023-10-31 10:53   ` Konrad Dybcio
2023-10-31 11:38     ` Bryan O'Donoghue
2023-10-31 17:10     ` Bryan O'Donoghue

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).