diff options
| -rw-r--r-- | drivers/i2c/i2c-core-base.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/i2c/i2c-core-base.c b/drivers/i2c/i2c-core-base.c index 31d16ada6e7d..301285c54603 100644 --- a/drivers/i2c/i2c-core-base.c +++ b/drivers/i2c/i2c-core-base.c | |||
| @@ -198,7 +198,16 @@ int i2c_generic_scl_recovery(struct i2c_adapter *adap) | |||
| 198 | 198 | ||
| 199 | val = !val; | 199 | val = !val; |
| 200 | bri->set_scl(adap, val); | 200 | bri->set_scl(adap, val); |
| 201 | ndelay(RECOVERY_NDELAY); | 201 | |
| 202 | /* | ||
| 203 | * If we can set SDA, we will always create STOP here to ensure | ||
| 204 | * the additional pulses will do no harm. This is achieved by | ||
| 205 | * letting SDA follow SCL half a cycle later. | ||
| 206 | */ | ||
| 207 | ndelay(RECOVERY_NDELAY / 2); | ||
| 208 | if (bri->set_sda) | ||
| 209 | bri->set_sda(adap, val); | ||
| 210 | ndelay(RECOVERY_NDELAY / 2); | ||
| 202 | } | 211 | } |
| 203 | 212 | ||
| 204 | /* check if recovery actually succeeded */ | 213 | /* check if recovery actually succeeded */ |
