All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH V2 0/3] OPP: Simplify required-opp handling
@ 2023-10-30 10:24 Viresh Kumar
  2023-10-30 10:24 ` [PATCH V2 1/3] OPP: Level zero is valid Viresh Kumar
                   ` (3 more replies)
  0 siblings, 4 replies; 13+ messages in thread
From: Viresh Kumar @ 2023-10-30 10:24 UTC (permalink / raw)
  To: Nishanth Menon, Rafael J. Wysocki, Stephen Boyd, Viresh Kumar
  Cc: Viresh Kumar, linux-pm, Vincent Guittot, Ulf Hansson,
	Stephan Gerhold, Konrad Dybcio, Manivannan Sadhasivam,
	linux-kernel

Hello,

I wasn't able to test this locally (despite trying to hack it around) and need
help from someone who is `virt_devs` field of `struct dev_pm_opp_config`.

Pushed here:

git://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm.git opp/required-opps

-------------------------8<-------------------------

Configuring the required OPP was never properly implemented, we just
took an exception for genpds and configured them directly, while leaving
out all other required OPP types.

Now that a standard call to dev_pm_opp_set_opp() takes care of
configuring the opp->level too, the special handling for genpds can be
avoided by simply calling dev_pm_opp_set_opp() for the required OPPs,
which shall eventually configure the corresponding level for genpds.

This also makes it possible for us to configure other type of required
OPPs (no concrete users yet though), via the same path. This is how
other frameworks take care of parent nodes, like clock, regulators, etc,
where we recursively call the same helper.

V1->V2:
- Support opp-level 0, drop vote i.e..
- Fix OPP pointer while calling dev_pm_opp_set_opp() recursively.
- Minor checks and fixes.
- Add Reviewed-by from Ulf.

--
Viresh

Viresh Kumar (3):
  OPP: Level zero is valid
  OPP: Use _set_opp_level() for single genpd case
  OPP: Call dev_pm_opp_set_opp() for required OPPs

 drivers/opp/core.c     | 176 ++++++++++++++++++++++-------------------
 drivers/opp/of.c       |  48 ++++++++---
 drivers/opp/opp.h      |   8 +-
 include/linux/pm_opp.h |  12 ++-
 4 files changed, 145 insertions(+), 99 deletions(-)

-- 
2.31.1.272.g89b43f80a514


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

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

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-30 10:24 [PATCH V2 0/3] OPP: Simplify required-opp handling Viresh Kumar
2023-10-30 10:24 ` [PATCH V2 1/3] OPP: Level zero is valid Viresh Kumar
2023-10-30 18:47   ` Konrad Dybcio
2023-10-31  5:26     ` Viresh Kumar
2023-10-31 10:07       ` Konrad Dybcio
2023-11-06 15:41   ` Ulf Hansson
2023-10-30 10:24 ` [PATCH V2 2/3] OPP: Use _set_opp_level() for single genpd case Viresh Kumar
2023-10-30 10:24 ` [PATCH V2 3/3] OPP: Call dev_pm_opp_set_opp() for required OPPs Viresh Kumar
2023-11-03  5:28 ` [PATCH V2 0/3] OPP: Simplify required-opp handling Viresh Kumar
2023-11-03  9:20   ` Ulf Hansson
2023-11-03  9:24   ` Stephan Gerhold
2023-11-03  9:27     ` Viresh Kumar
2023-11-16 10:43     ` Viresh Kumar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.