Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp631571rwe; Thu, 1 Sep 2022 05:31:19 -0700 (PDT) X-Google-Smtp-Source: AA6agR7oqG2mHBFTYfgrff1UoM4hTDPAXYHqXEp63bitpBdNnqNgDzgQJquA2kZb5AQGZkTLW+hl X-Received: by 2002:a65:6d13:0:b0:41d:7380:e9cc with SMTP id bf19-20020a656d13000000b0041d7380e9ccmr26242611pgb.153.1662035478688; Thu, 01 Sep 2022 05:31:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662035478; cv=none; d=google.com; s=arc-20160816; b=rWtHQw4tnvb958NEmBHcNMQyTPvn2IwfUflL5cpxxF24pB525YvLdk1Pg+m1zQRn3b AAcUdjcuapmquUgKOYP4rTK/l8nKUzgG3FPfdddj+FpCSi0yVtk9nJnmooBE9jv4weeK eRccgnUfKLkVjexZ8xvUmN24QCzOZHyxDBpSSFJrcdemGGsUNorOavMLQawQugALcAJC 5Dz45Aphh0RC9EnJjOTb9v9fQ2nrtsYKJeIu+Wy1Nelset7zc+CwHdobXtbqrSt4U+On 4FvpYc+sbrXnQdcytrv/h8mle/yAgS2jK8+uFVw67g3xhBen/GLnY1+ia3s086JDh0Ph ambw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:user-agent:mime-version:date :message-id:subject:dkim-signature; bh=85gR77OmGyIW5C5Jto08sz9YSHFvUHf+ehDzrjpitbM=; b=LnchfI4krxu6yMbKYJQ+O1zFmDb6W8ZTqL7uvJHTZYRiorVOMoIrJL0iFwEmUxFjwG thDZh+t4PAhmnzz2gXgyVeBCglj/yQteilDe5b1oq7ULHyAY5ekMvro2ZAAUdUKKslHQ 5PMtW1A5WHcM9mr4f9gHNkiqzZlWBfsihv8Bs0KieJ2wubTRUPuH44Jgl4/vRrpk13KG m4P96WghmDU9xmoWRqKfBQWWzF3bP6bKgnommwet65ZZBorMQALnKmqfUr7hanEvnzCF 2jiyejNXLGdOOqC8eK97lolY6bTZYgfiGZYipN0PBnQH1gy7UngczTwGx8qTkEM+n85X kQ2w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=V+k50UAx; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z2-20020a6553c2000000b0041df22d4507si7372463pgr.835.2022.09.01.05.31.06; Thu, 01 Sep 2022 05:31:18 -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; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=V+k50UAx; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232702AbiIAMW6 (ORCPT + 99 others); Thu, 1 Sep 2022 08:22:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36884 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232313AbiIAMW5 (ORCPT ); Thu, 1 Sep 2022 08:22:57 -0400 Received: from smtp-fw-6002.amazon.com (smtp-fw-6002.amazon.com [52.95.49.90]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 46D0898D14; Thu, 1 Sep 2022 05:22:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1662034977; x=1693570977; h=message-id:date:mime-version:to:cc:references:from: in-reply-to:content-transfer-encoding:subject; bh=85gR77OmGyIW5C5Jto08sz9YSHFvUHf+ehDzrjpitbM=; b=V+k50UAxxTwWR+UyRHOifp244mkK6m+qZPjfN1tLWUMv6/Ph3oOeIcL8 F8JheJQNxVv0jp4mt66ZnKE8EdhI+BiypqJolYGpW+mbrtGVIELbdy4Kj hOBOZQsCsKVDAiS7cqUaANQLcC4g4mJgo2NyBCsB+MCvcQzjPeKOTdl0s w=; X-IronPort-AV: E=Sophos;i="5.93,280,1654560000"; d="scan'208";a="239930101" Subject: Re: [PATCH v3 13/19] hwmon: (mr75203) modify the temperature equation according to series 5 datasheet Received: from iad12-co-svc-p1-lb1-vlan3.amazon.com (HELO email-inbound-relay-pdx-2a-1801e169.us-west-2.amazon.com) ([10.43.8.6]) by smtp-border-fw-6002.iad6.amazon.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Sep 2022 12:22:44 +0000 Received: from EX13MTAUWA001.ant.amazon.com (pdx1-ws-svc-p6-lb9-vlan3.pdx.amazon.com [10.236.137.198]) by email-inbound-relay-pdx-2a-1801e169.us-west-2.amazon.com (Postfix) with ESMTPS id A8A13C0920; Thu, 1 Sep 2022 12:22:42 +0000 (UTC) Received: from EX19D013UWA001.ant.amazon.com (10.13.138.253) by EX13MTAUWA001.ant.amazon.com (10.43.160.58) with Microsoft SMTP Server (TLS) id 15.0.1497.38; Thu, 1 Sep 2022 12:22:42 +0000 Received: from EX13MTAUWB001.ant.amazon.com (10.43.161.207) by EX19D013UWA001.ant.amazon.com (10.13.138.253) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA) id 15.2.1118.12; Thu, 1 Sep 2022 12:22:42 +0000 Received: from [192.168.93.228] (10.85.143.172) by mail-relay.amazon.com (10.43.161.249) with Microsoft SMTP Server id 15.0.1497.38 via Frontend Transport; Thu, 1 Sep 2022 12:22:36 +0000 Message-ID: <8ced7839-a66d-e281-6e07-fe3d591681fd@amazon.com> Date: Thu, 1 Sep 2022 15:22:35 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.2.1 Content-Language: en-US To: Andy Shevchenko CC: , , , , , , , , , , , , , , , , , , , "Farber, Eliav" References: <20220830192212.28570-1-farbere@amazon.com> <20220830192212.28570-14-farbere@amazon.com> From: "Farber, Eliav" In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-11.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,USER_IN_DEF_SPF_WL 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 On 8/31/2022 3:06 PM, Andy Shevchenko wrote: > On Tue, Aug 30, 2022 at 07:22:06PM +0000, Eliav Farber wrote: >> Modify the equation and coefficients used to convert the digital output >> to temperature according to series 5 of the Moortec Embedded Temperature >> Sensor (METS) datasheet: >> T = G + H * (n / cal5 - 0.5) + J * F >> >> Where: >> *) G = 60, H = 200, cal5 = 4094, J = -0.1. >> *) F = frequency clock in MHz. >> *) n is the digital output. >> >> In code, the G, H and J coefficients are multiplied by a factor of 1000 >> to get the temperature in milli-Celsius. >> Final result is clamped in case it exceeds min/max thresholds. >> >> Change is done since it is not clear where the current equation and > > not clear -> unclear > Fixed. >> coefficients came from. > > ... > >> +#define PVT_TEMP_MIN         -40000 >> +#define PVT_TEMP_MAX         125000 > > Unit suffix? _mC perhaps would be enough. Fixed. Added _mC suffix as you suggested. -- Thanks, Eliav