Skip to content

PM / OPP: Introduce APIs to transition OPPs

Viresh Kumar linux-devicetree linux-pm lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest16 patches 10 repliesIn review
  2. v216 patches 21 repliesSuperseded
  3. v117 patches 50 repliesSuperseded

Changes in v3 from the cover letter

- Very minor updates.
- find_supply_name() doesn't return an error value now, and so its callers don't check for it.
- And so we don't need to initialize name to NULL

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/16PM / OPP: get/put regulators from OPP coredrivers/base/power/opp/core.c drivers/base/power/opp/opp.h include/linux/pm_opp.h+124 -01 reply
2/16PM / OPP: Disable OPPs that aren't supported by the regulatordrivers/base/power/opp/core.c+22 -00 replies
3/16PM / OPP: Introduce dev_pm_opp_get_max_volt_latency()drivers/base/power/opp/core.c include/linux/pm_opp.h+65 -01 reply
4/16PM / OPP: Introduce dev_pm_opp_get_max_transition_latency()drivers/base/power/opp/core.c include/linux/pm_opp.h+23 -00 replies
5/16PM / OPP: Parse clock-latency and voltage-tolerance for v1 bindingsdrivers/base/power/opp/core.c drivers/base/power/opp/opp.h+26 -00 replies
6/16PM / OPP: Manage device clkdrivers/base/power/opp/core.c drivers/base/power/opp/opp.h+18 -00 replies
7/16PM / OPP: Add dev_pm_opp_set_rate()drivers/base/power/opp/core.c include/linux/pm_opp.h+182 -01 reply
8/16cpufreq: dt: Convert few pr_debug/err() calls to dev_dbg/err()drivers/cpufreq/cpufreq-dt.c+2 -20 replies
9/16cpufreq: dt: Rename 'need_update' to 'opp_v1'drivers/cpufreq/cpufreq-dt.c+3 -30 replies
10/16cpufreq: dt: OPP layers handles clock-latency for V1 bindings as welldrivers/cpufreq/cpufreq-dt.c+1 -40 replies
11/16cpufreq: dt: Pass regulator name to the OPP coredrivers/cpufreq/cpufreq-dt.c+46 -05 replies
12/16cpufreq: dt: Unsupported OPPs are already disableddrivers/cpufreq/cpufreq-dt.c+0 -20 replies
13/16cpufreq: dt: Reuse dev_pm_opp_get_max_transition_latency()drivers/cpufreq/cpufreq-dt.c+4 -440 replies
14/16cpufreq: dt: Use dev_pm_opp_set_rate() to switch frequencydrivers/cpufreq/cpufreq-dt.c+2 -710 replies
15/16cpufreq: dt: No need to fetch voltage-tolerancedrivers/cpufreq/cpufreq-dt.c+23 -230 replies
16/16cpufreq: dt: No need to allocate resources anymoredrivers/cpufreq/cpufreq-dt.c+45 -671 reply

Reviews trailers per patch

All 16 patches have a Reviewed-by or Acked-by.

PatchStephen Boyd
1/16R-b
2/16R-b
3/16R-b
4/16R-b
5/16R-b
6/16R-b
7/16R-b
8/16R-b
9/16R-b
10/16R-b
11/16R-b
12/16R-b
13/16R-b
14/16R-b
15/16R-b
16/16R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH V3 00/16] PM / OPP: Introduce APIs to transition OPPs

Hi Guys,

This patchset add APIs in OPP layer to allow OPPs transitioning from within OPP layer. Currently all OPP users need to replicate the same code to switch between OPPs. While the same can be handled easily by OPP-core.

The first 7 patches update the OPP core to introduce the new APIs and the next Nine patches update cpufreq-dt for the same.

11 out of 17 are already Reviewed by Stephen, only few are left :)

I hope this is the last version of the series :)

Testing:
- Tested on exynos 5250-arndale (dual-cortex-A15)
- Tested for both Old-V1 bindings and New V2 bindings
- Tested with regulator names as: 'cpu-supply' and 'cpu0-supply'
- Tested with Unsupported supply ranges as well, to check the opp-disable logic

V2->V3:
- Very minor updates.
- find_supply_name() doesn't return an error value now, and so its callers don't check for it.
- And so we don't need to initialize name to NULL

Viresh Kumar (16):
PM / OPP: get/put regulators from OPP core
PM / OPP: Disable OPPs that aren't supported by the regulator PM / OPP: Introduce dev_pm_opp_get_max_volt_latency()
PM / OPP: Introduce dev_pm_opp_get_max_transition_latency() PM / OPP: Parse clock-latency and voltage-tolerance for v1 bindings PM / OPP: Manage device clk
PM / OPP: Add dev_pm_opp_set_rate()
cpufreq: dt: Convert few pr_debug/err() calls to dev_dbg/err()
cpufreq: dt: Rename 'need_update' to 'opp_v1'
cpufreq: dt: OPP layers handles clock-latency for V1 bindings as well
cpufreq: dt: Pass regulator name to the OPP core
cpufreq: dt: Unsupported OPPs are already disabled
cpufreq: dt: Reuse dev_pm_opp_get_max_transition_latency()
cpufreq: dt: Use dev_pm_opp_set_rate() to switch frequency
cpufreq: dt: No need to fetch voltage-tolerance
cpufreq: dt: No need to allocate resources anymore

 drivers/base/power/opp/core.c | 420 ++++++++++++++++++++++++++++++++++++++++++
 drivers/base/power/opp/opp.h  |  13 ++
 drivers/cpufreq/cpufreq-dt.c  | 300 +++++++++++-------------------
 include/linux/pm_opp.h        |  27 +++
 4 files changed, 565 insertions(+), 195 deletions(-)
Signature · 1 line
2.7.1.370.gb2aa7f8