lkml.org 
[lkml]   [2021]   [Mar]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Errant readings on LM81 with T2080 SoC
From
Date
On 3/9/21 6:19 PM, Chris Packham wrote:
> On 9/03/21 9:27 am, Chris Packham wrote:
>> On 8/03/21 5:59 pm, Guenter Roeck wrote:
>>> Other than that, the only other real idea I have would be to monitor
>>> the i2c bus.
>> I am in the fortunate position of being able to go into the office and
>> even happen to have the expensive scope at the moment. Now I just need
>> to find a tame HW engineer so I don't burn myself trying to attach the
>> probes.
> One thing I see on the scope is that when there is a CPU load there
> appears to be some clock stretching going on (SCL is held low some
> times). I don't see it without the CPU load. It's hard to correlate a
> clock stretching event with a bad read or error but it is one area where
> the SMBUS spec has a maximum that might cause the device to give up waiting.
>
Do you have CONFIG_PREEMPT enabled in your kernel ? But even without
that it is possible that the hot loops at the beginning and end of
each operation mess up the driver and cause it to sleep longer
than intended. Did you try usleep_range() ?

On a side note, can you send me a register dump for the lm81 ?
It would be useful for my module test code.

Thanks,
Guenter

\
 
 \ /
  Last update: 2021-03-10 06:09    [W:0.083 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site