ASPEED G6 PWM and Fan Tach controller

Schema identifier ($id): "http://devicetree.org/schemas/hwmon/aspeed,g6-pwm-tach.yaml#"

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

Maintainers (maintainers): "Billy Tsai <billy_tsai@aspeedtech.com>"

The ASPEED PWM controller can support up to 16 PWM outputs. The ASPEED Fan Tacho controller can support up to 16 fan tach input. They are independent hardware blocks, which are different from the previous version of the ASPEED chip.

Properties and child nodes (properties) #

compatible — required here #

Exactly one of these rules must match (oneOf) #

Rule 1

Array item rules (items)

Item 1

Exact value (const): "aspeed,ast2700-pwm-tach"

Item 2

Exact value (const): "aspeed,ast2600-pwm-tach"

Rule 2

Exact value (const): "aspeed,ast2600-pwm-tach"

reg — required here #

Maximum number of items (maxItems): 1

clocks — required here #

Maximum number of items (maxItems): 1

resets — required here #

Maximum number of items (maxItems): 1

#pwm-cells — required here #

Exact value (const): 3

Properties matching a name pattern (patternProperties) #

^fan-[0-9]+$ — 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.

Required in this object (required): "tach-ch"

Required in this object (required): "reg", "clocks", "resets", "#pwm-cells", "compatible"

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

false

Not allowed by this rule.

Examples (examples) #

#include <dt-bindings/clock/aspeed-clock.h>
pwm_tach: pwm-tach-controller@1e610000 {
  compatible = "aspeed,ast2600-pwm-tach";
  reg = <0x1e610000 0x100>;
  clocks = <&syscon ASPEED_CLK_AHB>;
  resets = <&syscon ASPEED_RESET_PWM>;
  #pwm-cells = <3>;

  fan-0 {
    tach-ch = /bits/ 8 <0x0>;
    pwms = <&pwm_tach 0 40000 0>;
  };

  fan-1 {
    tach-ch = /bits/ 8 <0x1 0x2>;
    pwms = <&pwm_tach 1 40000 0>;
  };
};

Source notes #

Annotations retained from the schema source

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

Line 2: Copyright (C) 2023 Aspeed, Inc.

Edit this page