On 09/05/2025 08:51, Pawel Dembicki wrote: > Add device tree bindings for Monolithic Power Systems MPQ8785, MPM82504 > and MPM3695 PMBus-compliant voltage regulators. > > These bindings also documents the optional > "mps,vout-fb-divider-ratio-permille" property. > > --- > v2: > - remove mps,mpq8785 from trivial-devices.yaml > - fix alphabetical order > - rename voltage-scale-loop to mps,vout-fb-divider-ratio-permille > - add mps,vout-fb-divider-ratio-permille min and max values > - rewrite mps,vout-fb-divider-ratio-permille description If you are going to send a new version, then reorder the patches so the bindings are before the user (see submitting patches in DT doc dir). > > Signed-off-by: Pawel Dembicki <paweldembicki@xxxxxxxxx> > --- > .../bindings/hwmon/pmbus/mps,mpq8785.yaml | 88 +++++++++++++++++++ > .../devicetree/bindings/trivial-devices.yaml | 2 - > 2 files changed, 88 insertions(+), 2 deletions(-) > create mode 100644 Documentation/devicetree/bindings/hwmon/pmbus/mps,mpq8785.yaml > > diff --git a/Documentation/devicetree/bindings/hwmon/pmbus/mps,mpq8785.yaml b/Documentation/devicetree/bindings/hwmon/pmbus/mps,mpq8785.yaml > new file mode 100644 > index 000000000000..3c61f5484326 > --- /dev/null > +++ b/Documentation/devicetree/bindings/hwmon/pmbus/mps,mpq8785.yaml > @@ -0,0 +1,88 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/hwmon/pmbus/mps,mpq8785.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Monolithic Power Systems Multiphase Voltage Regulators with PMBus > + > +maintainers: > + - Charles Hsu <ythsu0511@xxxxxxxxx> > + > +description: > + Monolithic Power Systems digital multiphase voltage regulators with PMBus. > + > +properties: > + compatible: > + enum: > + - mps,mpm3695 > + - mps,mpm3695-25 > + - mps,mpm82504 > + - mps,mpq8785 > + > + reg: > + maxItems: 1 > + > + mps,vout-fb-divider-ratio-permille: > + description: > + The feedback resistor divider ratio, expressed in permille > + (Vfb / Vout * 1000). This value is written to the PMBUS_VOUT_SCALE_LOOP > + register and is required for correct output voltage presentation. > + $ref: /schemas/types.yaml#/definitions/uint32 > + minimum: 1 maximum: 4095 default: X required: block goes here, before allOf: block. > + > +allOf: > + - if: > + properties: > + compatible: > + const: mps,mpq8785 > + then: > + properties: > + mps,vout-fb-divider-ratio-permille: > + maximum: 2047 > + > + - if: > + properties: > + compatible: > + const: mps,mpm82504 That's enum with mpm3695 > + then: > + properties: > + mps,vout-fb-divider-ratio-permille: > + maximum: 1023 > + Best regards, Krzysztof