Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp327161rwb; Thu, 27 Jul 2023 13:25:46 -0700 (PDT) X-Google-Smtp-Source: APBJJlHGfTAoU2alP5j3nKPfAp6ibBEM4Eot9cdE9e2SCmwsvBY7h5J61FEUTeFM/pQVqmJNQxrC X-Received: by 2002:a17:90a:1347:b0:268:93d:b936 with SMTP id y7-20020a17090a134700b00268093db936mr273474pjf.18.1690489545983; Thu, 27 Jul 2023 13:25:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690489545; cv=none; d=google.com; s=arc-20160816; b=JrLU2vpfgO8Fk9xPDZ65hpfatTG1a/Pb/lHAPAh3jjZlerbLyCFop7bKrwviyM45mN wIOv+j7I3bFrnbwKCzIwvboR0QE+KnwtnCqM7dEVs7kZnWmBMzcw3wEIJP63lsPPKVuD 4AQKlS/5fBmnUo+3XZk59z3n3wsQ9EXSkoL2jIiUeUtzNc19tMrFkAPjWnBAduS7mxv/ OquwrwdSnCbRQ5AvGxLmB++/oMaG3l7mM1aeBDn/YA3ndwVkw+ekzYOrjnMVE6fukaMF bTSe9mRBwEV1FtSdvWne7OcQhqxCcnb5R8jLc7uO0Gb+Tg0bWQotxqY7WGP0EqchG920 deqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=MkZhZr3cccGJ0blBtpsth4DdHg0zlnrgzpEsKOrmiVE=; fh=iUTvSxfWkZ3Ylxh1pMWk6wpzKHpWoUhPh/4KRuzQmb0=; b=e18I2tOojJr8BXZuQFJhC2GM5BUyiQxh36qnCWLiTZXShm74yqttdjxIw30WQ/k8fX Z7Oq8WoNjV7aW1cpA9EcPj6JKQ1PBJTrPDrKQ9Qte1bYg6jlkWO67p1A5QRq8+yGCy1M k1PqFgBQTqCC6RngTR8mjbXgLIeDYqZIkRqDqDCiC3Esq7nLFgEeFvSkAiJpZPlqcwzS WPSdlGRQ5mZOb7WbUzM1gW2xVP0X/Z+J68cXVoezQ5Yb1EXWMEYWlRLEywmJC26lDbrN z8sleCdAyghCrmLZF9jfM8hbQygW/aS9Q5TW3Z7xMsa8aZdmtQ7ZsPm75sXASF4XSqn3 HjiQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w7-20020a17090a4f4700b0025eeb3cc4b2si1820024pjl.9.2023.07.27.13.25.11; Thu, 27 Jul 2023 13:25:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232453AbjG0UDe (ORCPT + 99 others); Thu, 27 Jul 2023 16:03:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41750 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231304AbjG0UDd (ORCPT ); Thu, 27 Jul 2023 16:03:33 -0400 X-Greylist: delayed 101955 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Thu, 27 Jul 2023 13:02:53 PDT Received: from wp534.webpack.hosteurope.de (wp534.webpack.hosteurope.de [IPv6:2a01:488:42:1000:50ed:8238::]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9A77C30E9; Thu, 27 Jul 2023 13:02:53 -0700 (PDT) Received: from [2001:a61:6209:7f01:c80a:ff:fe00:19d] (helo=cs-wrt.lan.local); authenticated by wp534.webpack.hosteurope.de running ExIM with esmtpa id 1qP7CA-0005S7-M0; Thu, 27 Jul 2023 22:02:46 +0200 From: =?UTF-8?q?Carsten=20Spie=C3=9F?= To: =?UTF-8?q?Carsten=20Spie=C3=9F?= , Jean Delvare , Guenter Roeck , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm Cc: linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org Subject: [PATCH v2 2/2] dt-bindings: hwmon: add renesas,isl28022 Date: Thu, 27 Jul 2023 22:02:34 +0200 Message-Id: <20230727200234.2245395-1-mail@carsten-spiess.de> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-bounce-key: webpack.hosteurope.de;mail@carsten-spiess.de;1690488173;57f17ea2; X-HE-SMSGID: 1qP7CA-0005S7-M0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add dt-bindings for Renesas ISL28022 power monitor. Signed-off-by: Carsten Spieß --- .../bindings/hwmon/renesas,isl28022.yaml | 65 +++++++++++++++++++ MAINTAINERS | 1 + 2 files changed, 66 insertions(+) create mode 100644 Documentation/devicetree/bindings/hwmon/renesas,isl28022.yaml diff --git a/Documentation/devicetree/bindings/hwmon/renesas,isl28022.yaml b/Documentation/devicetree/bindings/hwmon/renesas,isl28022.yaml new file mode 100644 index 000000000000..1e0971287941 --- /dev/null +++ b/Documentation/devicetree/bindings/hwmon/renesas,isl28022.yaml @@ -0,0 +1,65 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/hwmon/renesas,isl28022.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Renesas ISL28022 power monitor + +maintainers: + - Carsten Spieß + +description: | + The ISL28022 is a power monitor with I2C interface. The device monitors + voltage, current via shunt resistor and calculated power. + + Datasheets: + https://www.renesas.com/us/en/www/doc/datasheet/isl28022.pdf + +properties: + compatible: + enum: + - renesas,isl28022 + + reg: + maxItems: 1 + + shunt-resistor-micro-ohms: + description: | + Shunt resistor value in micro-Ohm + minimum: 800 + default: 10000 + + renesas,shunt-range-microvolt: + description: | + Maximal shunt voltage range of +/- 40 mV, 80 mV, 160 mV or 320 mV + default: 320000 + enum: [40000, 80000, 160000, 320000] + + renesas,average-samples: + description: | + Number of samples to be used to report voltage, current and power values. + default: 1 + $ref: /schemas/types.yaml#/definitions/uint32 + enum: [1, 2, 4, 8, 16, 32, 64, 128] + +required: + - compatible + - reg + +additionalProperties: false + +examples: + - | + i2c { + #address-cells = <1>; + #size-cells = <0>; + + power-monitor@40 { + compatible = "renesas,isl28022"; + reg = <0x40>; + shunt-resistor-micro-ohms = <8000>; + renesas,shunt-range-microvolt = <40000>; + renesas,average-samples = <128>; + }; + }; diff --git a/MAINTAINERS b/MAINTAINERS index b02e3b991676..23b8e8183ece 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -11069,6 +11069,7 @@ ISL28022 HARDWARE MONITORING DRIVER M: Carsten Spieß L: linux-hwmon@vger.kernel.org S: Maintained +F: Documentation/devicetree/bindings/hwmon/renesas,isl28022.yaml F: Documentation/hwmon/isl28022.rst F: drivers/hwmon/isl28022.c -- 2.34.1