Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp1326601rdb; Mon, 2 Oct 2023 06:28:02 -0700 (PDT) X-Google-Smtp-Source: AGHT+IG5b+I8nNvhxou9eGnLfkmzalqDI78ufn98uKP4cL3i3RqnYM0Qhmfevjho16A9I8OG9nde X-Received: by 2002:a05:6a20:4422:b0:138:68b9:138e with SMTP id ce34-20020a056a20442200b0013868b9138emr18712979pzb.8.1696253281720; Mon, 02 Oct 2023 06:28:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696253281; cv=none; d=google.com; s=arc-20160816; b=ciSwTmCy5/4DJP3cHK1l6GYEN8F1sWfr6sWVQcaUqmk1xXeKs+ish0grRSK3cxw44t f1jJpPfAoLJL9r7Pka4S4yijvcFwbggWcECgz5VX2NUr7/6xvaopY1R/lGGGxmQddNwo DH/eSU5E8GKNXo6Q42jjO/kBc0JLyJBd/EfH4fklwvCYlOQC3mGS6XsrYp2nhs3CUpnf S83nOSV/xEoL/haARu7FOXuQM27Flr+kEuBo7T+BDuiRVJqueJm/s+AZM05hYnSwuS1Z ISdd8635KHnAZ/h2quN3eDLmjixLffMJpPnduyXWMNU4uayEje4jQkpKSWi+qjgDlIYn 7HAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=BGl6MBh9JeP9Hu3/z+7Nkam3tYLnQUAELnTSfFAvgBI=; fh=NVbW1UFqqIxTwIlWyivg0SltsdEPRUqzJL3QDbKQnXY=; b=ZXLVeC/5mUpwsxbDH3NtczLeUaCqRa9DA+DPUYauczMSj/ldlCJ4fPovi3C7bNza8r Pc4ngC6BGwB+azMuDQZcnjVV5/qkv73Gy49RedJW/l3i1v2QVpuCe6U1UFyWmAIiScDu NtPhgW6DQD2f3Gx+6qN56n26XvmDexJs4T4kgpzjcfkxnJyt2sIkn5mbZdQ6PNPSgUfO oZdEdxIwyQN0v6PUHNY3OAjzuEIMegoL8kH1nEWRsZmlb1pNUb27A2Dsn4lIMzmeIxsk 9MQRn3h147V9jEUAxIEbSHeSo7WCqWJ1/YpIGnDnI/li7pzgZT4FANNkH+wTBfgxqO/j Dm7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=un6g0REd; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id c29-20020a63725d000000b00578e2b20624si15664895pgn.72.2023.10.02.06.28.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Oct 2023 06:28:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=un6g0REd; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id AAD47807EBB5; Mon, 2 Oct 2023 06:00:55 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237267AbjJBNAq (ORCPT + 99 others); Mon, 2 Oct 2023 09:00:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49420 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237226AbjJBNAp (ORCPT ); Mon, 2 Oct 2023 09:00:45 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9B32199; Mon, 2 Oct 2023 06:00:42 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0088AC433C8; Mon, 2 Oct 2023 13:00:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1696251642; bh=HeArIM02Qnv4lwvTAbzTJtNzOGPD/ms1sGZR8dVdPZ0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=un6g0REdKqioq485uu78vWvDhqMLUyvRMuQyUp/Zcxw44DYckmgzNIhvn1qXxtRew olsuG2AXkzRftazezlM7rYsZ51CYuWpPkZOhIADL72qkiPNPNESHCjCQZ4Q8PhwRBf oEyTb7ufy3Yf4vpTkQ6slSLznxiVpyXoVz9NkxoRqhqM8Rzv3H77CZCNzzzwFO62Vb 3y3vK15aiP9AdkD0j1i5vXUgtMQ2wqXkxCyiCNSOiKhVZooeQiHbpPFq48Zugs37bH 61uIWW/HWNCfTHydeSRaa2+6HeGOD2fI+vJrKRhbtXsXom2elWVQouy4mG1QES/iS3 FZxC7Ilj75UaQ== Date: Mon, 2 Oct 2023 14:00:37 +0100 From: Conor Dooley To: Antoniu Miclaus Cc: Jean Delvare , Guenter Roeck , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jonathan Corbet , linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org Subject: Re: [PATCH v2 1/2] dt-bindings: hwmon: ltc2991: add bindings Message-ID: <20231002-babbling-justice-73d3601a71aa@spud> References: <20231002101835.39624-1-antoniu.miclaus@analog.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="4qGEe174rhPUIzeC" Content-Disposition: inline In-Reply-To: <20231002101835.39624-1-antoniu.miclaus@analog.com> X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Mon, 02 Oct 2023 06:00:56 -0700 (PDT) --4qGEe174rhPUIzeC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hey, On Mon, Oct 02, 2023 at 01:18:14PM +0300, Antoniu Miclaus wrote: > Add dt-bindings for ltc2991 octal i2c voltage, current and temperature > monitor. >=20 > Signed-off-by: Antoniu Miclaus > --- > changes in v2: > - make compatible const type > - remove `|` where not necessary > - switch to micro-ohms for the shunt resistor property > - add vendor prefix for temperature-enable Thanks for the updates... > .../bindings/hwmon/adi,ltc2991.yaml | 114 ++++++++++++++++++ > 1 file changed, 114 insertions(+) > create mode 100644 Documentation/devicetree/bindings/hwmon/adi,ltc2991.y= aml >=20 > diff --git a/Documentation/devicetree/bindings/hwmon/adi,ltc2991.yaml b/D= ocumentation/devicetree/bindings/hwmon/adi,ltc2991.yaml > new file mode 100644 > index 000000000000..3811ea07a04f > --- /dev/null > +++ b/Documentation/devicetree/bindings/hwmon/adi,ltc2991.yaml > @@ -0,0 +1,114 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) > +%YAML 1.2 > +--- > + > +$id: http://devicetree.org/schemas/hwmon/adi,ltc2991.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Analog Devices LTC2991 Octal I2C Voltage, Current and Temperature= Monitor > + > +maintainers: > + - Antoniu Miclaus > + > +description: | > + The LTC2991 is used to monitor system temperatures, voltages and curre= nts. > + Through the I2C serial interface, the eight monitors can individually = measure > + supply voltages and can be paired for differential measurements of cur= rent > + sense resistors or temperature sensing transistors. > + > + Datasheet: > + https://www.analog.com/en/products/ltc2991.html > + > +properties: > + compatible: > + const: adi,ltc2991 > + > + reg: > + maxItems: 1 > + > + '#address-cells': > + const: 1 > + > + '#size-cells': > + const: 0 > + > + vcc-supply: true > + > +patternProperties: > + "^channel@[0-3]$": > + type: object > + description: > + Represents the differential/temperature channels. > + > + properties: > + reg: > + description: > + The channel number. LTC2991 can monitor 4 currents/temperature= s. > + items: > + minimum: 0 > + maximum: 3 > + > + shunt-resistor-micro-ohms: > + description: > + The value of curent sense resistor in miliohms. Enables differ= ential > + input pair. > + > + adi,temperature-enable: > + description: > + Enables temperature readings for a input pair. > + type: boolean =2E..but I did not see an answer to my question on v1: TBH, this seems like it is used just to control software behaviour. Why would you want to actually disable this in DT? In other words, is there something in that hardware that precludes measuring temperature for channels that do not contain this property? Thanks, Conor. > + > +required: > + - compatible > + - reg > + - vcc-supply > + > +additionalProperties: false > + > +examples: > + - | > + i2c { > + #address-cells =3D <1>; > + #size-cells =3D <0>; > + > + hwmon@48 { > + compatible =3D "adi,ltc2991"; > + reg =3D <0x48>; > + vcc-supply =3D <&vcc>; > + }; > + }; > + - | > + i2c { > + #address-cells =3D <1>; > + #size-cells =3D <0>; > + > + hwmon@48 { > + #address-cells =3D <1>; > + #size-cells =3D <0>; > + > + compatible =3D "adi,ltc2991"; > + reg =3D <0x48>; > + vcc-supply =3D <&vcc>; > + > + channel@0 { > + reg =3D <0x0>; > + shunt-resistor-micro-ohms =3D <100000>; > + }; > + > + channel@1 { > + reg =3D <0x1>; > + shunt-resistor-micro-ohms =3D <100000>; > + }; > + > + channel@2 { > + reg =3D <0x2>; > + temperature-enable; > + }; > + > + channel@3 { > + reg =3D <0x3>; > + temperature-enable; > + }; > + }; > + }; > +... > --=20 > 2.42.0 >=20 --4qGEe174rhPUIzeC Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZRq+9QAKCRB4tDGHoIJi 0ueTAQDx05+Ro78ZLvC9iBZWPPBFodIfIuTafvjJsOC7s0x3+gEA7X0AM0o7Hrjo L0CXzkMCQDQOz309zfkOE0uTkrcVIwc= =EQhT -----END PGP SIGNATURE----- --4qGEe174rhPUIzeC--