Received: by 2002:a05:6358:bb9e:b0:b9:5105:a5b4 with SMTP id df30csp239306rwb; Fri, 2 Sep 2022 13:18:03 -0700 (PDT) X-Google-Smtp-Source: AA6agR4ndcASBShC+6MgHneWWhWxIh43f2HUGgpLWKbXcVAQ/DhgpHSJAirY6vk0JIXMATS2lVKb X-Received: by 2002:a05:6402:138f:b0:43d:8ed5:c841 with SMTP id b15-20020a056402138f00b0043d8ed5c841mr34700081edv.27.1662149883466; Fri, 02 Sep 2022 13:18:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662149883; cv=none; d=google.com; s=arc-20160816; b=f4ndtsXIbi4LEMqzfcL1GfPsYL9dHeW7pKjn0lYfPeVcgweYSh2bfvSL4edLvYguZI KEZeJp1wf2C3K/W2RRtEQdA1CBM2LVJeLbs3mfZg6w/ZUXQs5YQPSvF1mLfkF9D/arB1 H2pu/bODbfb8tcD2co8SkNMRiwB2i+IukopaAF+GWUVILMjUzctBNzGU6pgJ17aliGeb j7wF89tSJ0HycoFT0W64a59GoxklVM+FT5xC95xvOUVWpgDYVPRXlfbCxHEC0bKVkFfg U5HJwG3lLfKEO7dy83GtBKYS/2lDVcoAmYoOQ7jwk8cn0xAbnKlp9zxc6fLQOdySxr+t wRrA== 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; bh=C9aW5y522OX/8JtSB5bbTEMWELASaLGWe8KFzDOic70=; b=Y40yo+KMIxbkJ6kxOX9Iz1Bu9dBmCWROvRBJ8lqqP06yOu+EeLnnlE/TRbZ7zeD9zn 2b1qousren1sYjAR9ohnTpDrwbvm51JQksmOrAPvdBrTxyk/5R93Mb/HVU7H4i4FtnUT MIQ8b6q+UKApl7mBR5FRwGkN84m51hpWNXUhNVU4mXU1KwXcZnZt0JBnUxmk8POquIQB sCibXLcmMII4Kmx62yjuPwTtpV2bZaDHhVcJD4LO94rLbahrDjsJQ3f3pXPAaj8hIALN 1a1p1FRJqB9qtchZMX0Gup6ZLfvyQHm3Qx+OqlnKYdRl6ET23f13i1yJi42uaLj1Vzai KSIA== 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y8-20020a056402358800b0043d476f96c1si2931298edc.86.2022.09.02.13.17.37; Fri, 02 Sep 2022 13:18:03 -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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230365AbiIBUD6 (ORCPT + 99 others); Fri, 2 Sep 2022 16:03:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45436 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229637AbiIBUD4 (ORCPT ); Fri, 2 Sep 2022 16:03:56 -0400 Received: from mail-oa1-f49.google.com (mail-oa1-f49.google.com [209.85.160.49]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5EB7FB9434; Fri, 2 Sep 2022 13:03:55 -0700 (PDT) Received: by mail-oa1-f49.google.com with SMTP id 586e51a60fabf-11edd61a9edso7392918fac.5; Fri, 02 Sep 2022 13:03:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date; bh=C9aW5y522OX/8JtSB5bbTEMWELASaLGWe8KFzDOic70=; b=ePNjTgPcRC77mtehZ51e/DIyp7snYPjvKToDI3GkT4YFy3n7AQPi3idZEJJcraEFWR SvzRlHiFkXzH+vyIouIkK0JGpwRzWl/J/taeHiouCgc5YE8hDsDVXWm0eIFufhgs4O9a PbpwBO4Nc8Xg+WL7tUFEY0dOqzGUN7B7AQntaryAIL/ak6Z7erk1inUwplrBl2JIiBzr pyJ4TDqgdEl1D9chxTLXeGEE+pBCupmz0hLa8wSVxhLJB4Yiowh3UDRwYp9CCAGMXgJs EFZyNa/kUXCAgfds4b+2/n50HMtVL0qXBoeae3WALE0V75hly4K1lhBCTESq7iPWMmnf Zgzg== X-Gm-Message-State: ACgBeo02lKmRWWgOH61Lb3nDKS3RZj1cug5LcI4yEJHTTDlkywUPoR3P umTCir9bTJjOXpGzDYjG6Q== X-Received: by 2002:a05:6870:a90f:b0:11e:949a:e3ef with SMTP id eq15-20020a056870a90f00b0011e949ae3efmr3248791oab.106.1662149034595; Fri, 02 Sep 2022 13:03:54 -0700 (PDT) Received: from robh.at.kernel.org (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id s12-20020a056870ea8c00b001226d2100f2sm1537319oap.33.2022.09.02.13.03.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Sep 2022 13:03:54 -0700 (PDT) Received: (nullmailer pid 324903 invoked by uid 1000); Fri, 02 Sep 2022 20:03:53 -0000 Date: Fri, 2 Sep 2022 15:03:53 -0500 From: Rob Herring To: Eliav Farber Cc: jdelvare@suse.com, linux@roeck-us.net, p.zabel@pengutronix.de, rtanwar@maxlinear.com, linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, talel@amazon.com, hhhawa@amazon.com, jonnyc@amazon.com, hanochu@amazon.com, ronenk@amazon.com, itamark@amazon.com, shellykz@amazon.com, shorer@amazon.com, amitlavi@amazon.com, almogbs@amazon.com, dkl@amazon.com, rahul.tanwar@linux.intel.com, andriy.shevchenko@intel.com Subject: Re: [PATCH v3 16/19] dt-bindings: hwmon: (mr75203) add coefficient properties for the thermal equation Message-ID: <20220902200353.GA318894-robh@kernel.org> References: <20220830192212.28570-1-farbere@amazon.com> <20220830192212.28570-17-farbere@amazon.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220830192212.28570-17-farbere@amazon.com> X-Spam-Status: No, score=-1.2 required=5.0 tests=BAYES_00, FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no 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 On Tue, Aug 30, 2022 at 07:22:09PM +0000, Eliav Farber wrote: > Add optional temperature coefficient properties: > *) moortec,ts-coeff-g > *) moortec,ts-coeff-h > *) moortec,ts-coeff-cal5 > *) moortec,ts-coeff-j > If defined they shall be used instead of defaults. > > The coefficients were added to device tree on top of the series property > (which can be used to select between series 5 and series 6), because > coefficients can vary between product and product, and code defaults might > not be accurate enough. > > Signed-off-by: Eliav Farber > --- > V3 -> V2: > - Add "moortec" prefix to property name. > > .../bindings/hwmon/moortec,mr75203.yaml | 33 +++++++++++++++++++ > 1 file changed, 33 insertions(+) > > diff --git a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml > index ec2dbe7da9c2..a92da6064285 100644 > --- a/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml > +++ b/Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml > @@ -74,6 +74,37 @@ properties: > default: 5 > $ref: /schemas/types.yaml#definitions/uint32 > > + moortec,ts-coeff-g: > + description: > + G coefficient for temperature equation. > + Value should be multiplied by factor 1000. If you just multiply the values here, you can specify 'multipleOf: 1000' Either way, some constraints would be nice. Or is 0 - 2^32 valid? > + Default for series 5 = 60000 > + Default for series 6 = 57400 > + $ref: /schemas/types.yaml#/definitions/uint32 > + > + moortec,ts-coeff-h: > + description: > + H coefficient for temperature equation. > + Value should be multiplied by factor 1000. > + Default for series 5 = 200000 > + Default for series 6 = 249400 > + $ref: /schemas/types.yaml#/definitions/uint32 > + > + moortec,ts-coeff-cal5: > + description: > + cal5 coefficient for temperature equation (can't be 0). minimum: 1 > + Default for series 5 = 4094 > + Default for series 6 = 4096 > + $ref: /schemas/types.yaml#/definitions/uint32 > + > + moortec,ts-coeff-j: > + description: > + J coefficient for temperature equation. > + Value should be multiplied by factor 1000. > + Default for series 5 = -100 > + Default for series 6 = 0 > + $ref: /schemas/types.yaml#/definitions/int32 > + > required: > - compatible > - reg > @@ -97,5 +128,7 @@ examples: > resets = <&rcu0 0x40 7>; > moortec,vm-active-channels = <0x10 0x05>; > moortec,vm-pre-scaler = <5 6>; > + moortec,ts-coeff-g = <61400>; > + moortec,ts-coeff-h = <253700>; > #thermal-sensor-cells = <1>; > }; > -- > 2.37.1 > >