[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190130051806.fdsos27jaekkwgbs@vireshk-i7>
Date: Wed, 30 Jan 2019 10:48:06 +0530
From: Viresh Kumar <viresh.kumar@...aro.org>
To: Quentin Perret <quentin.perret@....com>
Cc: Matthias Kaehlcke <mka@...omium.org>, rjw@...ysocki.net,
sudeep.holla@....com, liviu.dudau@....com,
lorenzo.pieralisi@....com, robh+dt@...nel.org,
mark.rutland@....com, nm@...com, sboyd@...nel.org,
linux-arm-kernel@...ts.infradead.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-pm@...r.kernel.org,
dietmar.eggemann@....com
Subject: Re: [PATCH 2/7] cpufreq: dt: Register an Energy Model
On 29-01-19, 09:15, Quentin Perret wrote:
> On Tuesday 29 Jan 2019 at 10:51:44 (+0530), Viresh Kumar wrote:
> > On 28-01-19, 11:36, Matthias Kaehlcke wrote:
> > > I think this patch will result in error messages at registration on
> > > platforms that use the cpufreq-dt driver and don't specify
> > > 'dynamic-power-coefficient' for the CPUs in the DT. Not sure if that's
> > > a problem as long as the cpufreq initialization succeeds regardless,
> > > it could be seen as a not-so-gentle nudge to add the values.
> >
> > That wouldn't be acceptable.
>
> Fair enough. What I can propose in this case is to have in PM_OPP a
> helper called 'dev_pm_opp_of_register_em()' or something like this. This
> function will check all prerequisites are present (we have the right
> values in DT, and so on) and then call (or not) em_register_perf_domain().
> Then we can make the CPUFreq drivers use that instead of calling
> em_register_perf_domain() directly.
That should be fine.
> That would also make it easy to implement Matthias' suggestion to not
> call em_register_perf_domain() if an EM is already present.
So you will track registration state within the OPP core for that ?
Sorry but that doesn't sound right. What's wrong with having an
unregister helper in energy-model to keep proper code flow everywhere
?
--
viresh
Powered by blists - more mailing lists