Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 1f35b865 authored by Claudio Foellmi's avatar Claudio Foellmi Committed by Wolfram Sang
Browse files

i2c: generic recovery: check SCL before SDA



Move the check for a stuck SCL before the check for a high SDA.
This prevent false positives in the specific case that SDA is fine
and SCL is stuck, which previously returned 0.

Also check SDA again after the loop, if we can.
Together, these changes should lead to a lot more failed
recoveries being caught and returning error codes.

Signed-off-by: default avatarClaudio Foellmi <claudio.foellmi@ergon.ch>
Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
parent 3ded0512
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment