Thread (8 messages) flat view 8 messages, 2 authors, 2022-02-03

Re: [RESEND PATCH 1/2] dt-bindings: firmware: arm,scmi: define support for name based regulators

From: David Collins <hidden>
Date: 2022-02-03 00:09:52
Also in: linux-arm-msm, linux-devicetree, lkml

On 2/2/22 9:38 AM, Mark Brown wrote:
quoted
The system layout that this patch is targeted for consists of an SCMI
platform implemented in software in the primary Linux OS on the
application processor and an SCMI agent in a guest VM (also running
Linux).  This provides paravirtualized regulator control to the guest VM
where full virtualization is not supported.
quoted
During the course of development of these software images, it may be
necessary to add or reorder the set of SCMI voltage domains (regulators)
implemented on the platform side.  If the voltage domains are only
identified and matched based on the ID number, then it is easy for the
platform and agent to get out of sync.
quoted
Using the voltage domain name instead of ID number for identification
and matching provides robust assurance of correct regulator usage in the
face of domains being added, removed, or reordered on the platform side.
This seems like a scenario where the DT should be being generated at
runtime along with the virtualisation of the platform?  TBH a setup
where this is an issue feels like it's asking for trouble.
I'm not familiar with runtime device tree generation.  Could you please
point to an example of it or documentation for it?  How would this
handle kernel devices on the VM side which need a phandle to an
scmi-regulator DT subnode in order to get a pointer to the corresponding
regulator device at runtime via devm_regulator_get()?
quoted
quoted
quoted
+              regulator-name: true
quoted
quoted
This is abusing the existing regulator-name property which is there to
allow a human readable descriptive string to be attached to a regulator.
It should have no effect other than being included in diagnostic output.
quoted
Would you be ok with a new DT property being added in place of
"regulator-name" in this patch which serves the same matching purpose
(perhaps "arm,scmi-domain-name")?
Yes, it needs to be a new property.
Ok, I'll modify the series in V2 to use a different property.

Thanks,
David

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help