Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp2052114rwb; Thu, 27 Jul 2023 00:58:15 -0700 (PDT) X-Google-Smtp-Source: APBJJlFzR/+eX6X2Cy2iIlP/X7Th5ouZxGyVzCeWhylRJlRSGKIC60XcFiHeDDkHDeFmHT7PcgK2 X-Received: by 2002:aa7:c44a:0:b0:51e:26dc:b35e with SMTP id n10-20020aa7c44a000000b0051e26dcb35emr1112045edr.21.1690444694744; Thu, 27 Jul 2023 00:58:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690444694; cv=none; d=google.com; s=arc-20160816; b=uM2k8+em0NCKvwhItxPeuA/wEgCEwSh5SWa70zKYarNlcc3fpzcjT293SnYTA2DEXo rQ3GgYRuFu3oqDrtdkjICMhjY1Z45Y+Y9/29VtvDOxY4H6qTqNINSF0dXKiMOfgVPAz2 UDpRMkypsOuLEFBG3Ok7TrUkQhpBgdclkIqwE5Xil+4ji/fwNgYSuEI+NrcCWHAKyXlp d91LDgWH86/wTWHfed4QBZ3wm6zVnnXxH5xf7KoPBxNmeDe/d3ioDRNTtb0jjfiYRXGF 2FNSOFLJbQ7Uo1qZMBBrzV9rAbOjcRJfh75oiHJBnOkQWSgIgqoyM147H23UrK23bNGl 3NQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :subject:cc:to:from:date; bh=/e8xQg6PauH31SwUCDrjlBgaIFoYjIMCbIEmOokIcd4=; fh=0tSIi0APJzq2gVLdCqL+zJ1LzIVf4dYQOIwuZbEK+dE=; b=T1zZKoZbjC8TTjhly61DVjmAPUZJWpIXfPgdjbaoEmQmbTGxYyu1fpPX47DVdFdkOs RWbPVleDhCBTh/vRwNMyChUEn88r8fjy1035MWeDg6RHu0tpXyOH6NyVl0sdHf3vUvFN fczggEtjCj1dI7BiHRY8L4EPbBlgB/UPk2LSCs84miVcNrtDe4+V+ZR94hAndRbfO6Up oocdiE+3gUASIjmas2R/adi/IWGBhpPCEg/ySQ+aIhaZ3sI+cW61NS/iCdFwPB8+tHlH nB5wtt0bqz9P2Q8qXQy9OghL/poQ+VsoLEmHwonO2PRapDxwCHx/IBVCGHSkRKZCfAzE RjFQ== 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 n11-20020a05640206cb00b00522568dd22bsi582032edy.333.2023.07.27.00.57.50; Thu, 27 Jul 2023 00:58:14 -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 S233338AbjG0Hog (ORCPT + 99 others); Thu, 27 Jul 2023 03:44:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52398 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233657AbjG0HnV (ORCPT ); Thu, 27 Jul 2023 03:43:21 -0400 Received: from wp534.webpack.hosteurope.de (wp534.webpack.hosteurope.de [80.237.130.56]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7E7A36A5B; Thu, 27 Jul 2023 00:37:30 -0700 (PDT) Received: from [2001:a61:6209:7f40:c80a:ff:fe00:4098] (helo=cs-office3.lan.local); authenticated by wp534.webpack.hosteurope.de running ExIM with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) id 1qOvXS-0001KS-TP; Thu, 27 Jul 2023 09:35:58 +0200 Date: Thu, 27 Jul 2023 09:35:28 +0200 From: Carsten =?UTF-8?B?U3BpZcOf?= To: Guenter Roeck , Jean Delvare , 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: Re: [PATCH 2/2] dt-bindings: hwmon: add renesas,isl28022 Message-ID: <20230727093528.594ce3a7.mail@carsten-spiess.de> In-Reply-To: References: <20230726152235.249569-1-mail@carsten-spiess.de> <20230726152235.249569-3-mail@carsten-spiess.de> X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/e/q7Xi+4mzcxvn1ecSyofAo"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-bounce-key: webpack.hosteurope.de;mail@carsten-spiess.de;1690443451;3e94405d; X-HE-SMSGID: 1qOvXS-0001KS-TP 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 --Sig_/e/q7Xi+4mzcxvn1ecSyofAo Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable thanks all for your input. I conclude here in one answer: On 7/26/23 18:14, Krzysztof Kozlowski wrote: > It does not look like you tested the bindings, at least after quick > look. Please run `make dt_binding_check` (see sorry i missed that, fixed for [Patch v2]. On 7/26/23 18:14, Krzysztof Kozlowski wrote: >> + shunt-gain: =20 > 1. Missing vendor prefix (does not look like generic property) > 2. -microvolt > And then enum is for 40, 80, 160 and 320. replaced with renesas,shunt-range-milli-volts: description: | maximal shunt voltage range of 40mV, 80mV, 160mV or 320mV $ref: /schemas/types.yaml#/definitions/uint32-array default: 320 enum: [40, 80, 160, 320] On 26/07/2023 18:16, Guenter Roeck wrote: >> + shunt-resistor-micro-ohms: >> + description: >> + Shunt resistor value in micro-Ohm >> + defaults to <0> when not set >> + monitoring of current and power not supported when <0> > + =20 > Should not default to 0 (disabled). When shunt resistor value is not known, current and power calculation can n= ot be done, but the shunt voltage still can be measured. As the resistor is externaly connected to the ISL28022 chip there is no def= ault. When i set default to any value (e.g 1000 micro Ohm), current and power cal= culation will give wrong results (except when the shunt _is_ 1000 micro Ohm) On 26/07/2023 18:16, Guenter Roeck wrote: >> + average: >> + description: | >> + Number of samples to be used to report voltage, current and power= values. >> + defaults to <0> when not set >> + enum: [0, 1, 2, 4, 8, 16, 32, 64, 128] =20 > Should not default to 0 (disabled). =46rom datasheet table 6 on page 15 there are two similar ADC modes: 3 - without samples 8 - with one? sample I intended enum 0 to ADC mode 3, 1 to ADC mode 8, but i can live without ADC mode 3. On 26/07/2023 20:59, Guenter Roeck wrote: > On 7/26/23 11:27, Krzysztof Kozlowski wrote: =20 >> On 26/07/2023 20:19, Guenter Roeck wrote: =20 >>>>> + average: >>>>> + enum: [0, 1, 2, 4, 8, 16, 32, 64, 128] =20 >>>> >>>> I am sure hwmon has some property for this. Are you sure it is called >>>> "average"? >>>> =20 >>> >>> Something with samples. adi,power-sample-average is similar. Others >>> use average-samples, qcom,avg-samples, touchscreen-average-samples. =20 >> >> So probably it's a time to come with something generic, e.g.: >> average-samples in some hwmon.yaml As there's no generic yet, replaced with renesas,average-samples: description: | Number of samples to be used to report voltage, current and power val= ues. default: 1 $ref: /schemas/types.yaml#/definitions/uint32-array enum: [1, 2, 4, 8, 16, 32, 64, 128] On 26/07/2023 19:13, Rob Herring wrote: > My bot found errors running 'make DT_CHECKER_FLAGS=3D-m dt_binding_check' > on your patch (DT_CHECKER_FLAGS is new in v5.13): Fixed for [Patch v2], runs without errors or warnings Regards, Carsten --Sig_/e/q7Xi+4mzcxvn1ecSyofAo Content-Type: application/pgp-signature Content-Description: Digitale Signatur von OpenPGP -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEWM+MlUpz/bWsZllTM1JQzV9LKSwFAmTCHkAACgkQM1JQzV9L KSw/sQ//YfEBYzZ21ij/3yDpY81XyOVnjsICovJPxeClmxPbvA92RC+q9v+k8a+7 jcAvaTKVr8gFeMoUQe9jQ6br9M+tx8TH3CzWW8oGw7dSWCr+y6yofqeAGxpSuL9V Hce6sEe//lQgHgVWUaqVHmo4jJBY2RsBBJuNHYz45noRv/ESekq+vnIgKyERlpcQ /bwwdO/nEyR76sNsPyMXepaipRjKsRDZA+0RysCAby3D8MDf+e7nIvUhgyvt37ne dpI78cEJ05JF7ZYvXUfXC2q67Qr6VsaNwsDVaXEFxA//Cy88rVlSb/bN70qoSutf 3pwczGGln9vJNx7dG6fgXSo0o3QZKC/ifCfey7nkVbKonBIKvNhoJKeGBrO4ETIG c3yZ69O1Sb+hdinXrOXTjBFciieSP4OIqUnHBSywNjM+u1WmAaP3tt6GgyXMu84X A1K9hgmD/1cbbBabFTa750LEud/q17OU+B9h+IiS2nARWDEvjl2cWKB290s3AFP7 wjmdr3FCczVTRq1OpbwLieromZ6yaiXfgTJXenhclaHo3lh7n+LGOiSMT0MIDs4Z iV/X06ad6wzp1AfgSdtOYhtJL6Z+RZoJoRqoTD6E2Wzl5uYZrv5BbjIdFm2C1qEw uwZmK6aGVmGMiTt9XuhjIExWzt06krZRtbFtUh27R8xsASXk6qw= =KFij -----END PGP SIGNATURE----- --Sig_/e/q7Xi+4mzcxvn1ecSyofAo--