[PATCH v4 1/3] dt-bindings: hwmon: Add Microchip emc2305 support

Krzysztof Kozlowski krzk at kernel.org
Fri Mar 14 01:07:56 PDT 2025


On Thu, Mar 13, 2025 at 02:57:44PM +0200, florin.leotescu at oss.nxp.com wrote:
> +  '#size-cells':
> +    const: 0
> +
> +  '#pwm-cells':
> +    const: 2
> +
> +patternProperties:
> +  "^fan@[0-4]$":

Keep consistent quotes, either ' or "

> +    $ref: fan-common.yaml#
> +    unevaluatedProperties: false
> +    properties:
> +      reg:
> +        description:
> +          The fan number.
> +
> +    required:
> +      - reg
> +      - pwms
> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    i2c {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        fan_controller: fan-controller at 2f {
> +            compatible = "microchip,emc2305";
> +            reg = <0x2f>;
> +            #address-cells = <1>;
> +            #size-cells = <0>;
> +            #pwm-cells = <2>;
> +
> +            fan at 0 {
> +                #cooling-cells = <2>;
> +                reg = <0x0>;

Please follow DTS coding style, so reg is here the first property.

> +                pwms = <&fan_controller 1 1>;

It's the same PWM for all fans? So isn't it basically one fan? How do
you exactly control them independently, if the same PWM channel is used?

> +            };
> +
> +            fan at 1 {
> +                #cooling-cells = <2>;
> +                reg = <0x1>;
> +                pwms = <&fan_controller 1 1>;


Best regards,
Krzysztof




More information about the linux-arm-kernel mailing list