From: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>
To: patrick@stwcx.xyz, joel@jms.id.au, openbmc@lists.ozlabs.org
Cc: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>
Subject: [PATCH linux dev-6.5 v4 2/3] dt-bindings: hwmon: add MAX31790
Date: Thu, 2 Nov 2023 11:39:01 +0800 [thread overview]
Message-ID: <20231102033902.3884466-3-Delphine_CC_Chiu@wiwynn.com> (raw)
In-Reply-To: <20231102033902.3884466-1-Delphine_CC_Chiu@wiwynn.com>
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=y, Size: 3325 bytes --]
Add dt-bindings for the MAXIM MAX31790.
Signed-off-by: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>
---
Changelog:
v4 - No change.
v3 - Use 'sensor-type' in 'channel' node to config pwm as tach.
- Changed the status in MAINTAINERS to 'Maintained'.
v2 - Add dt-bindings for the MAXIM MAX31790.
---
.../bindings/hwmon/maxim,max31790.yaml | 89 +++++++++++++++++++
MAINTAINERS | 6 ++
2 files changed, 95 insertions(+)
create mode 100644 Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
diff --git a/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml b/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
new file mode 100644
index 000000000000..7f717ab4caac
--- /dev/null
+++ b/Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
@@ -0,0 +1,89 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+
+$id: http://devicetree.org/schemas/hwmon/maxim,max31790.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Maxim max31790
+
+maintainers:
+ - Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>
+
+description: |
+ The MAX31790 controls the speeds of up to six fans using
+ six independent PWM outputs. The desired fan speeds (or PWM duty cycles)
+ are written through the I2C interface.
+ The outputs drive “4-wire” fans directly, or can be used to modulate
+ the fan’s power terminals using an external pass transistor.
+
+ Datasheets:
+ https://datasheets.maximintegrated.com/en/ds/MAX31790.pdf
+
+additionalProperties: false
+
+properties:
+ compatible:
+ enum:
+ - maxim,max31790
+
+ reg:
+ maxItems: 1
+
+ "#address-cells":
+ const: 1
+
+ "#size-cells":
+ const: 0
+
+patternProperties:
+ "^channel@[1-6]$":
+ type: object
+
+ additionalProperties: false
+
+ properties:
+ reg:
+ items:
+ - enum: [1, 2, 3, 4, 5, 6]
+
+ # There are 6 PWM output channel in MAX31790 that allows to be configured
+ # as a TACH input by setting the Fan Configuration register.
+ # The default setting will be PWM output.
+ sensor-type:
+ items:
+ - enum:
+ - PWM
+ - TACH
+
+ required:
+ - reg
+
+required:
+ - compatible
+ - reg
+
+examples:
+ - |
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ pwm@20 {
+ compatible = "maxim,max31790";
+ reg = <0x20>;
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ channel@3 {
+ reg = <3>;
+ sensor-type = "TACH";
+ };
+
+ channel@6 {
+ reg = <6>;
+ sensor-type = "TACH";
+ };
+ };
+ };
diff --git a/MAINTAINERS b/MAINTAINERS
index f9cc9f25799f..b0c86d70b034 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1360,6 +1360,12 @@ F: Documentation/devicetree/bindings/hwmon/adi,max31760.yaml
F: Documentation/hwmon/max31760.rst
F: drivers/hwmon/max31760.c
+ANALOG DEVICES INC MAX31790 DRIVER
+M: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>
+S: Maintained
+F: Documentation/devicetree/bindings/hwmon/maxim,max31790.yaml
+F: drivers/hwmon/max31790.c
+
ANALOGBITS PLL LIBRARIES
M: Paul Walmsley <paul.walmsley@sifive.com>
S: Supported
--
2.25.1
next prev parent reply other threads:[~2023-11-02 3:40 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-02 3:38 [PATCH linux dev-6.5 v4 0/3] hwmon: max31790: support to config PWM as TACH Delphine CC Chiu
2023-11-02 3:39 ` [PATCH linux dev-6.5 v4 1/3] " Delphine CC Chiu
2023-11-02 3:39 ` Delphine CC Chiu [this message]
2023-11-02 3:39 ` [PATCH linux dev-6.5 v4 3/3] hwmon: max31790: add fanN_enable for all fans Delphine CC Chiu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231102033902.3884466-3-Delphine_CC_Chiu@wiwynn.com \
--to=delphine_cc_chiu@wiwynn.com \
--cc=joel@jms.id.au \
--cc=openbmc@lists.ozlabs.org \
--cc=patrick@stwcx.xyz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).