From owner-svn-src-head@freebsd.org Mon May 23 17:37:52 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A9C5BB4727D for ; Mon, 23 May 2016 17:37:52 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-io0-x229.google.com (mail-io0-x229.google.com [IPv6:2607:f8b0:4001:c06::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7A80B11CF for ; Mon, 23 May 2016 17:37:52 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-io0-x229.google.com with SMTP id 190so198114761iow.1 for ; Mon, 23 May 2016 10:37:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc; bh=TxwWGyvNyaGcfUtQNa0/4P7WDAFjJUWcTtmnYHjn9uA=; b=zqHX5OVupk5xSLWrCrVZXqBelLvvxZVT0H9/x3KpwUfbHu0qlHx6wy9R1fJEuHYqU7 91mfRRZTKoig6xiVjqvPnuMfENPvj7dwae3hHXhC0cEHfaIQbrqcq6wQWHlUHqwdEDHe fXL7nmH+/GiJFWWujd7Z8AaoyfZweTk7xWcyeNaQBMrP8X9Yzg4UUf6utz8KtZJA4yjF E0WRievyQVFmGNn2jxysoIT4wMmh2JiYtVy2sAfv179VQujLezcRAS84jM/CXA4hBW3u 22xiaGZCXgd1ei/ghYMBP4rTzr1gDqQM7CBDh+bGLH/XimPOccus6Dn6ygcp+HzB3p10 gqdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc; bh=TxwWGyvNyaGcfUtQNa0/4P7WDAFjJUWcTtmnYHjn9uA=; b=JtPeAq3AqS6nHsdA1DlbvJ27woDV1M9uPwaBeGx47lWQ7gw/yNWAvP+pykDfW9zfjX tZrYm0TJw2++UYM3P4NCIXKG0KTHLVcYiD3S5dxMtVRuE1D6exU+za+2WRR6SGPmnbAo 3XUGO9QlTLh0ev6gfkaogbLMsqhxfpk9bh4nUALzVQ80R7UEytkkHSqwPESbNWjZgj5G 2O/o9dON5cyJXmhM74zVZANpSCmvMxHiQikXEvAnpzmxx7o4LH0De/WvYmSjwAEbuP7/ P1JdKFHup4uhMEjfQDUGHzqcYBQjIVSJ4EQh28DNGTMGZ7ZD5bF4yxBSP7h4icuV63wq UgVA== X-Gm-Message-State: AOPr4FXCFDdGfXizFSF55iTnD3zBPdLgPwaYtuzn5aBU7Ij9Ac3HmwWiBSm0cO/JZmj7i3o7qAZWk04sozmOSA== MIME-Version: 1.0 X-Received: by 10.107.40.201 with SMTP id o192mr12647534ioo.183.1464025071558; Mon, 23 May 2016 10:37:51 -0700 (PDT) Sender: wlosh@bsdimp.com Received: by 10.79.75.68 with HTTP; Mon, 23 May 2016 10:37:51 -0700 (PDT) X-Originating-IP: [50.253.99.174] In-Reply-To: References: <201605221358.u4MDwW8u097510@repo.freebsd.org> Date: Mon, 23 May 2016 11:37:51 -0600 X-Google-Sender-Auth: q1vk_GwQclxYQ5e4Zb6bIExvMC4 Message-ID: Subject: Re: svn commit: r300421 - in head/sys: arm/allwinner arm/broadcom/bcm2835 arm/freescale/imx arm/mv dev/acpi_support dev/acpica dev/amdtemp dev/coretemp dev/iicbus powerpc/powermac From: Warner Losh To: Justin Hibbits Cc: Ravi Pokala , src-committers , "svn-src-head@freebsd.org" , Luiz Otavio O Souza , "svn-src-all@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 May 2016 17:37:52 -0000 On Sun, May 22, 2016 at 1:12 PM, Justin Hibbits wrote: > > On May 22, 2016 13:51, "Ravi Pokala" wrote: >> >> -----Original Message----- >> From: on behalf of Luiz Otavio O Souza >> >> Date: 2016-05-22, Sunday at 06:58 >> To: , , >> >> Subject: svn commit: r300421 - in head/sys: arm/allwinner >> arm/broadcom/bcm2835 arm/freescale/imx arm/mv dev/acpi_support dev/acpica >> dev/amdtemp dev/coretemp dev/iicbus powerpc/powermac >> >> >Author: loos >> >Date: Sun May 22 13:58:32 2016 >> >New Revision: 300421 >> >URL: https://svnweb.freebsd.org/changeset/base/300421 >> > >> >Log: >> > Fix the deciKelvin to Celsius conversion in kernel. >> > >> > After r285994, sysctl(8) was fixed to use 273.15 instead of 273.20 as >> > 0C >> > reference and as result, the temperature read in sysctl(8) now exibits >> > a >> > +0.1C difference. >> >> Out of morbid curiosity, why do these things report in deciKelvin anyway? >> Are there sensors we support out there which report native Kelvin, or that >> report sub-degree precision? >> >> Thanks, >> >> Ravi (rpokala@) >> > > There are many i2c sensors which report in sub-degree centigrade. Though > some of them are in 1/8 (or other power of 2) degree precision, not 1/10. ACPI reports in decikelvin, and it was the first thing we supported. Some 1 wire devices support 1/16th a degree, and we support it in millikelvin since 1/16th is 0.0625. So the precision needed is actually greater than what we're reporting. However, the accuracy of the measurement isn't +/- 0.001, it's closer to +/1 0.063 or so (well, that's a relative accuracy, absolute accuracy is closer to +/- 1 degree). We report the higher level of precision so that applications that use the relative temperature can use it to inform a control loop. We have no good way to report relative precision for a measurement, or the absolute accuracy. Warner