[PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator

Woodrow Douglass posted 2 patches 4 weeks, 1 day ago
There is a newer version of this series
[PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator
Posted by Woodrow Douglass 4 weeks, 1 day ago
Bindings for the pf530x series of voltage regulators

Signed-off-by: Woodrow Douglass <wdouglass@carnegierobotics.com>
---
 .../devicetree/bindings/regulator/nxp,pf5300.yaml  | 52 ++++++++++++++++++++++
 1 file changed, 52 insertions(+)

diff --git a/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml b/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
new file mode 100644
index 000000000000..26cba1f1af62
--- /dev/null
+++ b/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
@@ -0,0 +1,52 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/regulator/nxp,pf530x-regulator.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: NXP PF5300/PF5301/PF5302 PMIC regulators
+
+maintainers:
+  - Woodrow Douglass <wdouglass@carnegierobotics.com>
+
+description: |
+  The PF5300, PF5301, and PF5302 integrate high-performance buck converters,
+  12 A, 8 A, and 15 A, respectively, to power high-end automotive and industrial
+  processors. With adaptive voltage positioning and a high-bandwidth loop, they
+  offer transient regulation to minimize capacitor requirements.
+
+properties:
+  compatible:
+    enum:
+      - nxp,pf5300
+      - nxp,pf5301
+      - nxp,pf5302
+
+  reg:
+    maxItems: 1
+
+  additionalProperties: false
+
+required:
+  - compatible
+  - reg
+  - regulators
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        regulator@28 {
+            compatible = "nxp,pf5302";
+            reg = <0x28>;
+
+            regulator-always-on;
+            regulator-boot-on;
+            regulator-max-microvolt = <1200000>;
+            regulator-min-microvolt = <500000>;
+        };
+    };

-- 
2.39.5
Re: [PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator
Posted by Krzysztof Kozlowski 4 weeks, 1 day ago
On 03/09/2025 22:03, Woodrow Douglass wrote:
> Bindings for the pf530x series of voltage regulators
> 
> Signed-off-by: Woodrow Douglass <wdouglass@carnegierobotics.com>
> ---
>  .../devicetree/bindings/regulator/nxp,pf5300.yaml  | 52 ++++++++++++++++++++++
>  1 file changed, 52 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml b/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
> new file mode 100644
> index 000000000000..26cba1f1af62
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
> @@ -0,0 +1,52 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/regulator/nxp,pf530x-regulator.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: NXP PF5300/PF5301/PF5302 PMIC regulators
> +
> +maintainers:
> +  - Woodrow Douglass <wdouglass@carnegierobotics.com>
> +
> +description: |
> +  The PF5300, PF5301, and PF5302 integrate high-performance buck converters,
> +  12 A, 8 A, and 15 A, respectively, to power high-end automotive and industrial
> +  processors. With adaptive voltage positioning and a high-bandwidth loop, they
> +  offer transient regulation to minimize capacitor requirements.
> +
> +properties:
> +  compatible:
> +    enum:
> +      - nxp,pf5300
> +      - nxp,pf5301
> +      - nxp,pf5302

Still compatibility not expressed.

Please respond to comments.

Best regards,
Krzysztof
Re: [PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator
Posted by Mark Brown 4 weeks ago
On Thu, Sep 04, 2025 at 07:44:57AM +0200, Krzysztof Kozlowski wrote:
> On 03/09/2025 22:03, Woodrow Douglass wrote:

> > +properties:
> > +  compatible:
> > +    enum:
> > +      - nxp,pf5300
> > +      - nxp,pf5301
> > +      - nxp,pf5302

> Still compatibility not expressed.

> Please respond to comments.

He did reply to this in the cover letter (possibly for v3?) explaining
that he couldn't understand what you are talking about, the devices have
the same register interface but differ in the rated current.  TBH I
can't really understand what the issue is either, perhaps if you could
suggest a concrete change you're looking for?
Re: [PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator
Posted by Woody Douglass 4 weeks ago
On 9/4/25 01:44, Krzysztof Kozlowski wrote:
> On 03/09/2025 22:03, Woodrow Douglass wrote:
>> Bindings for the pf530x series of voltage regulators
>>
>> Signed-off-by: Woodrow Douglass <wdouglass@carnegierobotics.com>
>> ---
>>  .../devicetree/bindings/regulator/nxp,pf5300.yaml  | 52 ++++++++++++++++++++++
>>  1 file changed, 52 insertions(+)
>>
>> diff --git a/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml b/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
>> new file mode 100644
>> index 000000000000..26cba1f1af62
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
>> @@ -0,0 +1,52 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/regulator/nxp,pf530x-regulator.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: NXP PF5300/PF5301/PF5302 PMIC regulators
>> +
>> +maintainers:
>> +  - Woodrow Douglass <wdouglass@carnegierobotics.com>
>> +
>> +description: |
>> +  The PF5300, PF5301, and PF5302 integrate high-performance buck converters,
>> +  12 A, 8 A, and 15 A, respectively, to power high-end automotive and industrial
>> +  processors. With adaptive voltage positioning and a high-bandwidth loop, they
>> +  offer transient regulation to minimize capacitor requirements.
>> +
>> +properties:
>> +  compatible:
>> +    enum:
>> +      - nxp,pf5300
>> +      - nxp,pf5301
>> +      - nxp,pf5302
> 
> Still compatibility not expressed.
> 

I'm sorry for the misunderstanding here -- I did reply (as Mark Brown mentioned in his
reply to this email) in the cover letter for v3 of this patch (this message 
https://lore.kernel.org/lkml/20250902-pf530x-v3-0-4242e7687761@carnegierobotics.com/).
Mark is right, I don't really understand what you're asking for, and other bindings for 
regulators seem to list off each compatible model in the way that I have. I have prepared
a v5 of this patchset that incorporates the various comments, but I'll wait for some
clarification here before submitting it.

> Please respond to comments.
> 
> Best regards,
> Krzysztof
> 

Thanks,
Woodrow Douglass
Re: [PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator
Posted by Krzysztof Kozlowski 4 weeks ago
On 04/09/2025 14:58, Woody Douglass wrote:
>>> +description: |
>>> +  The PF5300, PF5301, and PF5302 integrate high-performance buck converters,
>>> +  12 A, 8 A, and 15 A, respectively, to power high-end automotive and industrial
>>> +  processors. With adaptive voltage positioning and a high-bandwidth loop, they
>>> +  offer transient regulation to minimize capacitor requirements.
>>> +
>>> +properties:
>>> +  compatible:
>>> +    enum:
>>> +      - nxp,pf5300
>>> +      - nxp,pf5301
>>> +      - nxp,pf5302
>>
>> Still compatibility not expressed.
>>
> 
> I'm sorry for the misunderstanding here -- I did reply (as Mark Brown mentioned in his
> reply to this email) in the cover letter for v3 of this patch (this message 
> https://lore.kernel.org/lkml/20250902-pf530x-v3-0-4242e7687761@carnegierobotics.com/).
> Mark is right, I don't really understand what you're asking for, and other bindings for 
> regulators seem to list off each compatible model in the way that I have. I have prepared
> a v5 of this patchset that incorporates the various comments, but I'll wait for some
> clarification here before submitting it.


Quick look at the driver suggests devices are fully compatible, so you
should express it with dedicated and fallback compatibles. See
example-schema or my OSSE25 beginners talk.

It might be that devices are not compatible, then it is enough to
explain that briefly (why they are not compatible) in the commit msg.

Best regards,
Krzysztof
Re: [PATCH v4 2/2] regulator: pf530x: dt-bindings: nxp,pf530x-regulator
Posted by Rob Herring (Arm) 4 weeks, 1 day ago
On Wed, 03 Sep 2025 16:03:42 -0400, Woodrow Douglass wrote:
> Bindings for the pf530x series of voltage regulators
> 
> Signed-off-by: Woodrow Douglass <wdouglass@carnegierobotics.com>
> ---
>  .../devicetree/bindings/regulator/nxp,pf5300.yaml  | 52 ++++++++++++++++++++++
>  1 file changed, 52 insertions(+)
> 

My bot found errors running 'make dt_binding_check' on your patch:

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml: properties: 'additionalProperties' should not be valid under {'$ref': '#/definitions/json-schema-prop-names'}
	hint: A json-schema keyword was found instead of a DT property name.
	from schema $id: http://devicetree.org/meta-schemas/keywords.yaml#
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml: $id: Cannot determine base path from $id, relative path/filename doesn't match actual path or filename
 	 $id: http://devicetree.org/schemas/regulator/nxp,pf530x-regulator.yaml
 	file: /builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/regulator/nxp,pf5300.yaml
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/regulator/nxp,pf5300.example.dtb: regulator@28 (nxp,pf5302): 'regulator-always-on', 'regulator-boot-on', 'regulator-max-microvolt', 'regulator-min-microvolt' do not match any of the regexes: '^pinctrl-[0-9]+$'
	from schema $id: http://devicetree.org/schemas/regulator/nxp,pf530x-regulator.yaml#
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/regulator/nxp,pf5300.example.dtb: regulator@28 (nxp,pf5302): 'regulators' is a required property
	from schema $id: http://devicetree.org/schemas/regulator/nxp,pf530x-regulator.yaml#

doc reference errors (make refcheckdocs):
Warning: MAINTAINERS references a file that doesn't exist: Documentation/devicetree/bindings/regulator/nxp,pf530x-regulator.yaml
MAINTAINERS: Documentation/devicetree/bindings/regulator/nxp,pf530x-regulator.yaml

See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20250902-pf530x-v4-2-4727f112424e@carnegierobotics.com

The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.