Skip to content

power: domain: Add driver for a PM domain provider which controls

Max Krummenacher linux-arm-kernel linux-devicetree linux-pm lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 36 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5dt-bindings: power: Add bindings for a power domain controlled by a regulatorDocumentation/devicetree/bindings/power/regulator-power-domain.yaml+58 -05 replies
2/5pm: add regulator power domain controllerdrivers/power/Kconfig drivers/power/Makefile drivers/power/domain/Kconfig +2 more+125 -20 replies
3/5MAINTAINERS: add REGULATOR POWER DOMAINMAINTAINERS+9 -00 replies
4/5arm64: defconfig: Enable generic power domain controller controlling a regulatorarch/arm64/configs/defconfig+1 -00 replies
5/5ARM64: verdin-imx8mm: use regulator power domain to model sleep-mociarch/arm64/boot/dts/freescale/imx8mm-verdin-dahlia.dtsi arch/arm64/boot/dts/freescale/imx8mm-verdin-dev.dtsi arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi+28 -102 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH v1 0/5] power: domain: Add driver for a PM domain provider which controls

From: Max Krummenacher <[email protected]>

its power enable by using a regulator.

The currently implemented PM domain providers are all specific to a particular system on chip.

This series adds a PM domain provider driver which enables/disables a regulator to control its power state. Additionally, marked with RFC, it adds two commits which actually make use of the new driver to instantiate a power domain provider and have a number of power domain consumers use the power domain.

The perceived use case is to control a common power domain used by several devices for which not all device drivers nessesarily have a means to control a regulator.

It also handles the suspend / resume use case for such devices, the generic power domain framework will disable the domain once the last device has been suspend and will enable it again before resuming the first device.

The generic power domain code handles a power domain consumer generically outside of the driver's code. (assuming the 'power-domains' property references exactly one power domain).
This allows to use the "regulator-pm-pd" driver with an arbitrary device just by adding the 'power-domains' property to the devices device tree node. However the device's dt-bindings schema likely does not allow the property 'power-domains'.
One way to solve this would be to allow 'power-domains' globally similarly how 'status' and other common properties are allowed as implicit properties.

Max Krummenacher (5):
dt-bindings: power: Add bindings for a power domain controlled by a
regulator
pm: add regulator power domain controller
MAINTAINERS: add REGULATOR POWER DOMAIN
arm64: defconfig: Enable generic power domain controller controlling a
regulator
ARM64: verdin-imx8mm: use regulator power domain to model sleep-moci

 .../power/regulator-power-domain.yaml         |  58 +++++++++
 MAINTAINERS                                   |   9 ++
 .../dts/freescale/imx8mm-verdin-dahlia.dtsi   |   1 +
 .../boot/dts/freescale/imx8mm-verdin-dev.dtsi |   2 +
 .../boot/dts/freescale/imx8mm-verdin.dtsi     |  35 ++++--
 arch/arm64/configs/defconfig                  |   1 +
 drivers/power/Kconfig                         |   1 +
 drivers/power/Makefile                        |   5 +-
 drivers/power/domain/Kconfig                  |   7 ++
 drivers/power/domain/Makefile                 |   2 +
 drivers/power/domain/regulator-pdc.c          | 112 ++++++++++++++++++
 11 files changed, 221 insertions(+), 12 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/power/regulator-power-domain.yaml
 create mode 100644 drivers/power/domain/Kconfig
 create mode 100644 drivers/power/domain/Makefile
 create mode 100644 drivers/power/domain/regulator-pdc.c
Signature · 1 line
2.20.1