RFC PM / shmobile: Pass power domain information via DT (was: Re: [RFD] PM: Device tree representation of power domains)
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest14 patches 14 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/14 | PM / Domains: Make it possible to use domain names when adding devicesdrivers/ include/ | +56 | 0 replies | |
| 2/14 | ARM: shmobile: Use names of power domains for adding devices to themarch/ arch/ arch/ +4 more | +60 | 0 replies | |
| 3/14 | ARM: shmobile: Drop r8a7779_add_device_to_domain()arch/ arch/ | +4 | 0 replies | |
| 4/14 | PM / Domains: Make it possible to use names when adding subdomainsdrivers/ include/ | +38 | 0 replies | |
| 5/14 | ARM: shmobile: Use domain names when adding subdomains to power domainsarch/ arch/ arch/ +1 more | +5 | 0 replies | |
| 6/14 | RM: shmobile: Add routine for automatic PM domains initializationarch/ arch/ | +10 | 0 replies | |
| 7/14 | ARM: shmobile: Remove dead sh7372 power management codearch/ | +0 | 0 replies | |
| 8/14 | PM / Domains: Add power-on function using names to identify domainsdrivers/ include/ | +36 | 0 replies | |
| 9/14 | ARM: shmobile: Move sh7372's PM domain objects to a tablearch/ arch/ arch/ | +63 | 0 replies | |
| 10/14 | ARM: shmobile: Move r8a7740's PM domain objects to a tablearch/ arch/ arch/ | +28 | 0 replies | |
| 11/14 | ARM: shmobile: Move r8a7779's PM domain objects to a tablearch/ arch/ arch/ | +39 | 0 replies | |
| 12/14 | ARM: shmobile: Make rmobile_init_pm_domain() staticarch/ arch/ | +1 | 0 replies | |
| 13/14 | PM / Domains: Introduce pm_genpd_present()drivers/ include/ | +27 | 0 replies | |
| 14/14 | ARM: shmobile: Add support for storing PM domain information in DTsarch/ | +83 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [RFC][PATCH 0/14] PM / shmobile: Pass power domain information via DT (was: Re: [RFD] PM: Device tree representation of power domains)
Quoted 18 lines · Rafael J. Wysocki
Quoted 9 lines · Mark Brown
Quoted 6 lines · Rafael J. Wysocki
I actually don't have any ideas how to do that at the moment, but I wonder if anyone has already thought about it?
For one, I don't think that representing a power domain as a platform device would be a good approach and I'm not sure how to represent the relationships between devices and the domains they belong to.
Quoted 7 lines
I guess the OMAP hwmod stuff is the closest thing we've got at the minute (I don't recall seeing any other implementations in mainline) but the hwmods themselves don't appear in the DTS right now. They have a ti,hwmods property on each device naming the hwmod it's in, something like that seems like a reasonable approach, possibly a reference to another DT node rather than or as well as a string? That seems fairly easy.
Quoted 7 lines
Well, it looks like (and please tell me if I'm wrong) the hwmons are just string attributes that are parsed by the platform-specific code through a platform bus type notifier.
We could do that for power domains too, but then each platform wanting to use them would need to implement such a notifier and add its own routine for parsing those strings. Would that be acceptable to everyone concerned?
I tried to follow the above suggestion and prepared the following patchset that allows power domain information for Renesas platforms to be passed as "renesas,pmdomain" string attribute of device nodes. It adds functions allowing the generic PM domains framework to use names for domain identification in various situations and reworks the ARM/shmobile power domains support code to used those functions instead of the "raw" ones that take domain pointers as their arguments. Finally, it defines a platform bus type notifier that will add devices whose DT nodes contain the "renesas,pmdomain" attribute to the power domains indicated by it (the value of that attribute should be the name of the PM domain to add the device to after it's been registered). All of this should allow platform devices to be added to appropriate power domains automatically based on the information read from a DT.
The patches are on top of the current linux-next tree.
I've tested the patches that could be tested on the Mackerel board, except for the last one (I'm still working on testing it).
Thanks,
Rafael