i2c/bitbang: fix compile break when enable CONFIG_I2C_BITBANG_NO_DELAY
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
This commit is contained in:
parent
1e25602678
commit
e902b59006
|
@ -269,6 +269,7 @@ static int i2c_bitbang_wait_ack(FAR struct i2c_bitbang_dev_s *priv)
|
||||||
{
|
{
|
||||||
ret = -EIO;
|
ret = -EIO;
|
||||||
}
|
}
|
||||||
|
#ifndef CONFIG_I2C_BITBANG_NO_DELAY
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
int remaining = priv->delay - i;
|
int remaining = priv->delay - i;
|
||||||
|
@ -278,6 +279,7 @@ static int i2c_bitbang_wait_ack(FAR struct i2c_bitbang_dev_s *priv)
|
||||||
up_udelay(remaining);
|
up_udelay(remaining);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue