Skip to content
Snippets Groups Projects
Commit 6db539f9 authored by Nikita Yushchenko's avatar Nikita Yushchenko Committed by Heiko Schocher
Browse files

i2c: fix always-true condition in i2c_probe_chip()


Per dm_i2c_ops.probe_chip documentation, i2c_probe_chip() shall fallback
to default probe method when .probe_chip() returns -ENOSYS.

Signed-off-by: default avatarNikita Yushchenko <nikita.yoush@cogentembedded.com>
Reviewed-by: default avatarHeiko Schocher <hs@denx.de>
parent 532a5b29
No related branches found
No related tags found
No related merge requests found
......@@ -280,7 +280,7 @@ static int i2c_probe_chip(struct udevice *bus, uint chip_addr,
if (ops->probe_chip) {
ret = ops->probe_chip(bus, chip_addr, chip_flags);
if (!ret || ret != -ENOSYS)
if (ret != -ENOSYS)
return ret;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment