Linux Power Management development
 help / color / mirror / Atom feed
From: Sudeep Holla <sudeep.holla@arm.com>
To: Ulf Hansson <ulf.hansson@linaro.org>
Cc: Nicolas Pitre <nico@fluxnic.net>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	Peng Fan <peng.fan@nxp.com>,
	"ben.dooks@codethink.co.uk" <ben.dooks@codethink.co.uk>,
	"rafael.j.wysocki@intel.com" <rafael.j.wysocki@intel.com>,
	"dmitry.baryshkov@linaro.org" <dmitry.baryshkov@linaro.org>,
	"jonathanh@nvidia.com" <jonathanh@nvidia.com>,
	"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
	Aisheng Dong <aisheng.dong@nxp.com>,
	Linux-Renesas <linux-renesas-soc@vger.kernel.org>,
	Dien Pham <dien.pham.ry@renesas.com>
Subject: Re: Question: why call clk_prepare in pm_clk_acquire
Date: Wed, 21 Sep 2022 15:42:03 +0100	[thread overview]
Message-ID: <20220921144203.asmpurbklwdcprix@bogus> (raw)
In-Reply-To: <CAPDyKFoBvX7WmJu0E1p0RuVCEKFFk===ZVnYtbz9o=RZPzHSTA@mail.gmail.com>

On Mon, Sep 19, 2022 at 11:53:18AM +0200, Ulf Hansson wrote:
> On Wed, 14 Sept 2022 at 19:05, Nicolas Pitre <nico@fluxnic.net> wrote:
> >
> > On Wed, 14 Sep 2022, Sudeep Holla wrote:
> >
> > > On Mon, Sep 12, 2022 at 06:58:49PM +0100, Geert Uytterhoeven wrote:
> > > > Hi Sudeep,
> > > >
> > > > CC Dien Pham
> > > >
> > > > On Mon, Sep 12, 2022 at 6:49 PM Geert Uytterhoeven <geert@linux-m68k.org> wrote:
> > > > > On Fri, Sep 9, 2022 at 4:51 PM Sudeep Holla <sudeep.holla@arm.com> wrote:
> > > > > > On Fri, Sep 09, 2022 at 01:12:03PM +0200, Ulf Hansson wrote:
> > > > > > > On Thu, 8 Sept 2022 at 19:38, Sudeep Holla <sudeep.holla@arm.com> wrote:
> > > > > > > > On Thu, Sep 08, 2022 at 04:37:13PM +0200, Ulf Hansson wrote:
> > > > > > > > > On Thu, 8 Sept 2022 at 09:33, Peng Fan <peng.fan@nxp.com> wrote:
> > > > > > > > > > We are facing an issue clk_set_rate fail with commit a3b884cef873 ("firmware:
> > > > > > > > > > arm_scmi: Add clock management to the SCMI power domain") ,
> > > > > > > > >
> > > > > > > > > Hmm, I wonder about the main reason behind that commit. Can we revert
> > > > > > > > > it or is there some platform/driver that is really relying on it?
> > > > > > > > >
> > > > > > > >
> > > > > > > > IIUC, at the time of the commit, it was needed on some Renesas platform.
> > > > > > > > Not sure if it is still used or not.
> > > > > > >
> > > > > > > Okay! Maybe Nico remembers more, as he authored the patch...
> > > > > > >
> > > > > >
> > > > > > May be, or even check with Renesas team who tested his patch.
> > > > >
> > > > > I'm not aware of Renesas platforms using SCMI...
> > > >
> > > > Upon closer look, Diep Pham did report a build issue in the SCMI code, so
> > > > perhaps Diep knows more...
> > > >
> > >
> > > Yes indeed, Diep Pham tested the original patch IIRC and also has reported
> > > few bugs in SCMI clock code which are fixed. Hence I know it is used by
> > > Renesas.
> > >
> > > Hi Peng,
> > >
> > > Absence of DTS changes indicate nothing. I am aware of couple of vendors
> > > who use SCMI on several platforms and do report issues regularly and help
> > > in review of the code. So DTS is not a good indicator of SCMI usage
> > > unfortunately. On reason could be that since it is a firmware, bootloaders
> > > can detect and update DTS, just my thought and may differ from the reality.
> >
> > Sorry for the delay.
> >
> > This patch was indeed requested by Renesas for one of their platform
> > that uses SCMI clocks. I didn't have access to the platform myself at
> > the time but the patch was positively validated and tested by Renesas.
> >
> > This works in conjunction with commit 0bfa0820c274 that made generic
> > clock pm code usable with the SCMI layer.
> >
> > I didn't touch any clock stuff since then and I forgot about the finer
> > details unfortunately.
> 
> Thanks Nico for coming back with this information. To me, it looks
> like the patch may be applicable to some Renesas' downstream kernel
> then.
>

Though I agree in most of the case, I am not sure in this particular
case as they may not need any downstream kernel changes for SCMI. All
they need is DT nodes.

> In my opinion I think we should rather try to revert, to avoid any
> further problems. So I am going to send that patch and see what people
> think about it.
>

Since I see absolute silence from Renesas, I am happy to revert if no
one has any objections.

> Another option, which Sudeep doesn't seem very happy about too, is to
> make the GENPD_FLAG_PM_CLK conditional, based on a platform
> compatible.

Correct, I would rather make it generic based on clock flags like in this
case it is CLK_SET_PARENT_GATE or CLK_SET_RATE_GATE or something right ?

-- 
Regards,
Sudeep

  reply	other threads:[~2022-09-21 14:42 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-08  7:33 Question: why call clk_prepare in pm_clk_acquire Peng Fan
2022-09-08 14:37 ` Ulf Hansson
2022-09-08 17:38   ` Sudeep Holla
2022-09-09 11:12     ` Ulf Hansson
2022-09-09 15:42       ` Sudeep Holla
2022-09-11  1:52         ` Peng Fan
2022-09-12 17:49         ` Geert Uytterhoeven
2022-09-12 17:58           ` Geert Uytterhoeven
2022-09-14 15:30             ` Sudeep Holla
2022-09-14 17:05               ` Nicolas Pitre
2022-09-19  9:53                 ` Ulf Hansson
2022-09-21 14:42                   ` Sudeep Holla [this message]
2022-09-22  8:08                     ` Ulf Hansson
2022-09-15  0:59               ` Peng Fan
2022-09-16 13:15                 ` Sudeep Holla
2022-09-11  1:47       ` Peng Fan
2022-09-11  1:31     ` Peng Fan
2022-09-12 13:01       ` Sudeep Holla

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=20220921144203.asmpurbklwdcprix@bogus \
    --to=sudeep.holla@arm.com \
    --cc=aisheng.dong@nxp.com \
    --cc=ben.dooks@codethink.co.uk \
    --cc=dien.pham.ry@renesas.com \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=geert@linux-m68k.org \
    --cc=jonathanh@nvidia.com \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=nico@fluxnic.net \
    --cc=peng.fan@nxp.com \
    --cc=rafael.j.wysocki@intel.com \
    --cc=ulf.hansson@linaro.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