7ac238a697d315967dcec7a4c138c887be9eba0e
[openwrt/staging/pepe2k.git] /
1 From 09ea7bdac6000a6ef53cffae3015f1390dac8240 Mon Sep 17 00:00:00 2001
2 From: Michael Shych <michaelsh@nvidia.com>
3 Date: Sat, 30 Apr 2022 14:49:04 +0300
4 Subject: [PATCH 0370/1085] dt-bindings: hwmon: add microchip,emc2305.yaml dt
5 binding description.
6
7 Submitted to linux-hwmon mailing list at
8 https://patchwork.kernel.org/project/linux-hwmon/patch/20220430114905.53448-3-michaelsh@nvidia.com/
9
10 Add basic description of emc2305 driver device tree binding.
11
12 Signed-off-by: Michael Shych <michaelsh@nvidia.com>
13 Reviewed-by: Vadim Pasternak <vadimp@nvidia.com>
14
15 dtbindings: Fixup microchip,emc2305.yaml bindings
16
17 The bindings submitted to mainline had some issues, so fix them up.
18
19 Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
20 ---
21 .../bindings/hwmon/microchip,emc2305.yaml | 54 +++++++++++++++++++
22 1 file changed, 54 insertions(+)
23 create mode 100644 Documentation/devicetree/bindings/hwmon/microchip,emc2305.yaml
24
25 --- /dev/null
26 +++ b/Documentation/devicetree/bindings/hwmon/microchip,emc2305.yaml
27 @@ -0,0 +1,54 @@
28 +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
29 +%YAML 1.2
30 +---
31 +
32 +$id: http://devicetree.org/schemas/hwmon/emc2305.yaml#
33 +$schema: http://devicetree.org/meta-schemas/core.yaml#
34 +
35 +title: Microchip EMC230[1|2|3|5] RPM-based PWM Fan Speed Controller
36 +
37 +properties:
38 + compatible:
39 + enum:
40 + - microchip,emc2305
41 + - microchip,emc2301
42 + emc2305,pwm-min:
43 + description:
44 + Min pwm of emc2305
45 + maxItems: 1
46 + emc2305,pwm-max:
47 + description:
48 + Max pwm of emc2305
49 + maxItems: 1
50 + emc2305,pwm-channel:
51 + description:
52 + Max number of pwm channels
53 + maxItems: 1
54 + emcs205,max-state:
55 + description:
56 + maxItems: 1
57 + emc2305,cooling-levels:
58 + description:
59 + Quantity of cooling level state.
60 + maxItems: 1
61 +
62 +required:
63 + - compatible
64 +
65 +optional:
66 + - emc2305,min-pwm
67 + - emc2305,max-pwm
68 + - emc2305,pwm-channels
69 + - emc2305,cooling-levels
70 +
71 +additionalProperties: false
72 +
73 +examples:
74 + - |
75 + fan {
76 + compatible = "microchip,emc2305";
77 + emc2305,pwm-min = <0>;
78 + emc2305,pwm-max = <255>;
79 + emc2305,pwm-channel = <5>
80 + emc2305,cooling-levels = <10>;
81 + };