]> git.baikalelectronics.ru Git - uboot.git/commit
i2c: uniphier-f: correct error recovery
authorDai Okamura <okamura.dai@socionext.com>
Fri, 9 Dec 2022 11:38:27 +0000 (20:38 +0900)
committerTom Rini <trini@konsulko.com>
Fri, 6 Jan 2023 13:14:19 +0000 (08:14 -0500)
commit206f67f7a5a40bac20df04f16706be34c3397596
treedee50a1a0d7cd815d0a522f7d0c64ad1050f7fb7
parent4bce9c553dd5516f5eb8aad3ce7698a7c8315966
i2c: uniphier-f: correct error recovery

The uniphier i2c block can recognize some handshake errors.
But driver handles all error detections as no error if no timeout.
So this makes unrecoverable state.

This replaces the return values with the right ones to tell the i2c
framework the errors:
- EDEADLK for arbitration lost error
- ENODATA for no answer error

Signed-off-by: Dai Okamura <okamura.dai@socionext.com>
Acked-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
drivers/i2c/i2c-uniphier-f.c