Microchip EMC2305 SMBus compliant PWM fan controller

Schema identifier ($id): "http://devicetree.org/schemas/hwmon/microchip,emc2305.yaml#"

Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"

Maintainers (maintainers): "Michael Shych <michaelsh@nvidia.com>"

Microchip EMC2301/2/3/5 pwm controller which supports up to five programmable fan control circuits.

Properties and child nodes (properties) #

compatible — required here #

Exactly one of these rules must match (oneOf) #

Rule 1

Allowed values (enum): "microchip,emc2305"

Rule 2

Array item rules (items)

Item 1

Allowed values (enum): "microchip,emc2303", "microchip,emc2302", "microchip,emc2301"

Item 2

Exact value (const): "microchip,emc2305"

reg — required here #

Maximum number of items (maxItems): 1

#address-cells — not listed as required here #

Exact value (const): 1

#size-cells — not listed as required here #

Exact value (const): 0

#pwm-cells — not listed as required here #

Exact value (const): 3

Number of cells in a PWM specifier.
- cell 0: The PWM frequency
- cell 1: The PWM polarity: 0 or PWM_POLARITY_INVERTED
- cell 2: The PWM output config:
     - 0 (Open-Drain)
     - 1 (Push-Pull)

Properties matching a name pattern (patternProperties) #

^fan@[0-4]$ — name matches this regular expression #

Shared schema rule ($ref): fan-common.yaml#

Properties not evaluated by applicable rules (unevaluatedProperties) #

false

Not allowed by this rule.

Properties and child nodes (properties) #

reg — required here

The fan number used to determine the associated PWM channel.

Maximum number of items (maxItems): 1

Required in this object (required): "reg"

Required in this object (required): "compatible", "reg"

Properties not matched by properties or patternProperties in this schema (additionalProperties) #

false

Not allowed by this rule.

Examples (examples) #

#include <dt-bindings/pwm/pwm.h>
i2c {
    #address-cells = <1>;
    #size-cells = <0>;

    fan_controller: fan-controller@2f {
        compatible = "microchip,emc2305";
        reg = <0x2f>;
        #address-cells = <1>;
        #size-cells = <0>;
        #pwm-cells = <3>;

        fan@0 {
            reg = <0x0>;
            pwms = <&fan_controller 26000 PWM_POLARITY_INVERTED 1>;
            #cooling-cells = <2>;
        };

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

        fan@2 {
            reg = <0x2>;
            pwms = <&fan_controller 26000 0 1>;
            #cooling-cells = <2>;
        };

        fan@3 {
            reg = <0x3>;
            pwms = <&fan_controller 26000 0 1>;
            #cooling-cells = <2>;
        };

        fan@4 {
            reg = <0x4>;
            pwms = <&fan_controller 26000 0 1>;
            #cooling-cells = <2>;
        };
    };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)

Edit this page