Re: [PATCH v3 11/13] thermal: qoriq: Do not report invalid temperature reading
From: Andrey Smirnov
Date: Fri Apr 05 2019 - 14:30:55 EST
On Thu, Apr 4, 2019 at 2:05 AM Daniel Lezcano <daniel.lezcano@xxxxxxxxxx> wrote:
>
> On 01/04/2019 06:14, Andrey Smirnov wrote:
> > Before returning measured temperature data to upper layer we need to
> > make sure that the reading was marked as "valid" to avoid reporting
> > bogus data.
>
> Is it possible to add a comment above the read_poll to describe the
> layout of the register ? That will help to understand the valid bit.
>
Sure, will do.
> Is the valid bit reset after reading the value?
>
It works a bit differently. Here's the description form the datasheet:
Valid measured temperature.
0 Not valid. Temperature out of sensor range or first
measurement still pending.
1 Valid.
Thanks,
Andrey Smirnov