linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: krzk@kernel.org (Krzysztof Kozlowski)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: dts: exynos: Use thermal fuse value for thermal zone 0 on Exynos5420
Date: Mon, 13 Feb 2017 13:59:45 +0200	[thread overview]
Message-ID: <CAJKOXPeVLNRCWcWMT_subo2VRXdS1147MjFNCeGot8DpqguVNg@mail.gmail.com> (raw)
In-Reply-To: <CANAwSgSJRv6XGKvysbw+cXYyVUEcNyGv=6tYSWsvOn42dX5f1w@mail.gmail.com>

On Mon, Feb 13, 2017 at 1:38 PM, Anand Moon <linux.amoon@gmail.com> wrote:
> Hi Krzysztof,
>
>
>
> On 12 February 2017 at 01:44, Krzysztof Kozlowski <krzk@kernel.org> wrote:
>> In Odroid XU3 Lite board, the temperature levels reported for thermal
>> zone 0 were weird. In warm room:
>>         /sys/class/thermal/thermal_zone0/temp:32000
>>         /sys/class/thermal/thermal_zone1/temp:51000
>>         /sys/class/thermal/thermal_zone2/temp:55000
>>         /sys/class/thermal/thermal_zone3/temp:54000
>>         /sys/class/thermal/thermal_zone4/temp:51000
>>
>> Sometimes after booting the value was even equal to ambient temperature
>> which is highly unlikely to be a real temperature of sensor in SoC.
>>
>> The thermal sensor's calibration (trimming) is based on fused values.
>> In case of the board above, the fused values are: 35, 52, 43, 58 and 43
>> (corresponding to each TMU device).  However driver defined a minimum value
>> for fused data as 40 and for smaller values it was using a hard-coded 55
>> instead.  This lead to mapping data from sensor to wrong temperatures
>> for thermal zone 0.
>>
>> Various vendor 3.10 trees (Hardkernel's based on Samsung LSI, Artik 10)
>> do not impose any limits on fused values.  Since we do not have any
>> knowledge about these limits, use 0 as a minimum accepted fused value.
>> This should essentially allow accepting any reasonable fused value thus
>> behaving like vendor driver.
>>
>
> On HK following values are define in drivers/thermal/exynos_thermal.c
>
> #define EFUSE_MIN_VALUE                         40
> #define EFUSE_MAX_VALUE                         100

Are they being used?

Best regards,
Krzysztof

  reply	other threads:[~2017-02-13 11:59 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170211201512epcas2p2a49d26ddfbe2eaa6195927cbf01d48bb@epcas2p2.samsung.com>
2017-02-11 20:14 ` [PATCH] ARM: dts: exynos: Use thermal fuse value for thermal zone 0 on Exynos5420 Krzysztof Kozlowski
2017-02-13 11:38   ` Anand Moon
2017-02-13 11:59     ` Krzysztof Kozlowski [this message]
2017-02-13 12:21       ` Anand Moon
2017-02-13 16:22   ` Bartlomiej Zolnierkiewicz
2017-02-19  0:34   ` Eduardo Valentin
2017-03-03 21:50   ` Javier Martinez Canillas
2017-03-04  8:01     ` Krzysztof Kozlowski
2017-03-06  7:29       ` Anand Moon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAJKOXPeVLNRCWcWMT_subo2VRXdS1147MjFNCeGot8DpqguVNg@mail.gmail.com \
    --to=krzk@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).