mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
To: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Cc: Bjorn Andersson <andersson@kernel.org>,
	Michael Turquette <mturquette@baylibre.com>,
	Stephen Boyd <sboyd@kernel.org>,
	linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 0/2] clk: qcom: Add support for multiple power-domains for a clock controller.
Date: Mon, 18 Nov 2024 13:46:06 +0000	[thread overview]
Message-ID: <52eacf06-baa5-42c7-a451-363679728135@linaro.org> (raw)
In-Reply-To: <3ce358b9-6a65-4141-ad3a-bbb826082470@linaro.org>

On 18/11/2024 13:22, Bryan O'Donoghue wrote:
> On 18/11/2024 13:15, Dmitry Baryshkov wrote:
>>> On x1e80100 and it's SKUs the Camera Clock Controller - CAMCC has
>>> multiple power-domains which power it. Usually with a single power- 
>>> domain
>>> the core platform code will automatically switch on the singleton
>>> power-domain for you. If you have multiple power-domains for a 
>>> device, in
>>> this case the clock controller, you need to switch those power-domains
>>> on/off yourself.
> 
>> I think the series misses the platform-specific part. 
> 
> I don't think I understand what you mean by that.
> 
> It is hard to
>> understand what kind of power relationship do you need to express. Is it
>> actually the whole CC being powered by several domains? Or are some of
>> those domains used to power up PLLs? Or as parents to some of GDSCs?
> 
> Well for example the TITAN_TOP_GDSC needs both PDs to be switched on.
> 
> We _could_ do this just for the CAMCC on x1e80100 - i.e. make it just 
> for the camcc device but then, the next clock controller that needs more 
> than one PD will have to implement the same fix.

Can some of the PLLs run with one PD or the other ?

Perhaps, but without _both_ PDs on the GDSC will stay stuck @ off for my 
test case on x1e80100 and looking at other places we manage PDs directly 
- drivers/media/platform/venus.c for example its generally just all or 
nothing.

There may be more granularity to extract but, I don't think there's more 
granularity for the first case here. Both PDs are needed or the GDSC 
will remain stuck @ off.

As I see it we can either address

1. At the drivers/clk/qcom/camcc-somesoc.c level
2. At drivers/clk/qcom/[gdsc.c|common.c] level

I think option 2 is more how you'd expect this to work though. Its not 
particularly obvious but ATM with singleton power-domains for the clock 
controllers the singletons just get turned on and left that way.

So managing the PD on/off inside of common.c/gdsc.c means the calling 
clock controller can stay as a simple probe() type driver and also means 
we can reuse the generic common.c/gdsc.c approach.

---
bod

  reply	other threads:[~2024-11-18 13:46 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-18  2:24 Bryan O'Donoghue
2024-11-18  2:24 ` [PATCH 1/2] clk: qcom: common: Add support for power-domain attachment Bryan O'Donoghue
2024-11-18 13:03   ` Dmitry Baryshkov
2024-11-18 13:17     ` Bryan O'Donoghue
2024-11-18 22:17   ` Vladimir Zapolskiy
2024-11-18 22:52     ` Bryan O'Donoghue
2024-11-19 15:41   ` Bjorn Andersson
2024-11-20 16:49     ` Bryan O'Donoghue
2024-11-21 21:59       ` Dmitry Baryshkov
2024-11-21 23:25         ` Bryan O'Donoghue
2024-11-18  2:24 ` [PATCH 2/2] clk: qcom: gdsc: Add pm_runtime hooks Bryan O'Donoghue
2024-11-18 13:10   ` Dmitry Baryshkov
2024-11-18 13:19     ` Bryan O'Donoghue
2024-11-18 13:39       ` Dmitry Baryshkov
2024-11-18 13:47         ` Bryan O'Donoghue
2024-11-19 15:34   ` Bjorn Andersson
2024-11-20 17:09     ` Bryan O'Donoghue
2024-11-26 17:23       ` Bjorn Andersson
2024-11-26 23:45         ` Bryan O'Donoghue
2024-11-18 13:15 ` [PATCH 0/2] clk: qcom: Add support for multiple power-domains for a clock controller Dmitry Baryshkov
2024-11-18 13:22   ` Bryan O'Donoghue
2024-11-18 13:46     ` Bryan O'Donoghue [this message]
2024-11-19  6:08 ` Taniya Das
2024-11-19  9:46   ` Bryan O'Donoghue
2024-11-19 15:28   ` Bjorn Andersson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52eacf06-baa5-42c7-a451-363679728135@linaro.org \
    --to=bryan.odonoghue@linaro.org \
    --cc=andersson@kernel.org \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=sboyd@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®