diff options
| author | Raman Gopalan <[email protected]> | 2023-11-26 15:47:06 +0530 |
|---|---|---|
| committer | Meco Man <[email protected]> | 2023-11-26 18:40:02 +0800 |
| commit | 4e656078b6e5282370b294355da43a988c2a8dfc (patch) | |
| tree | 38a6df30e569a554a62e7a1e5c293122ccbad1ba /components/drivers/i2c | |
| parent | 3ea3f3447e2a6f6233d64ed84ef7e5abc9cc655a (diff) | |
soft_i2c: Loop iteration variable: Conform to C89
Diffstat (limited to 'components/drivers/i2c')
| -rw-r--r-- | components/drivers/i2c/soft_i2c.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/components/drivers/i2c/soft_i2c.c b/components/drivers/i2c/soft_i2c.c index 7c3bd1e93a..54c7395121 100644 --- a/components/drivers/i2c/soft_i2c.c +++ b/components/drivers/i2c/soft_i2c.c @@ -221,8 +221,9 @@ int rt_soft_i2c_init(void) { int err = RT_EOK; struct rt_soft_i2c *obj; + int i; - for(int i = 0; i < sizeof(i2c_bus_obj) / sizeof(i2c_bus_obj[0]); i++) + for(i = 0; i < sizeof(i2c_bus_obj) / sizeof(i2c_bus_obj[0]); i++) { struct soft_i2c_config *cfg = &i2c_cfg[i]; |
