mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-01-18 12:52:44 +01:00
cpu/stm_common/i2c: Fix error code
This commit is contained in:
parent
8173aff6ec
commit
6016266c77
@ -500,7 +500,7 @@ static inline int _wait_ready(I2C_TypeDef *i2c)
|
|||||||
while ((i2c->SR2 & I2C_SR2_BUSY) && tick--) {
|
while ((i2c->SR2 & I2C_SR2_BUSY) && tick--) {
|
||||||
if (!tick) {
|
if (!tick) {
|
||||||
DEBUG("[i2c] wait_ready: timeout\n");
|
DEBUG("[i2c] wait_ready: timeout\n");
|
||||||
return -ETIMEDOUT;
|
return -EIO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user