aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/w1/masters/ds2482.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/w1/masters/ds2482.c b/drivers/w1/masters/ds2482.c
index af492cc48db2..d93eb626b2f0 100644
--- a/drivers/w1/masters/ds2482.c
+++ b/drivers/w1/masters/ds2482.c
@@ -218,7 +218,7 @@ static int ds2482_wait_1wire_idle(struct ds2482_data *pdev)
218 do { 218 do {
219 temp = i2c_smbus_read_byte(&pdev->client); 219 temp = i2c_smbus_read_byte(&pdev->client);
220 } while ((temp >= 0) && (temp & DS2482_REG_STS_1WB) && 220 } while ((temp >= 0) && (temp & DS2482_REG_STS_1WB) &&
221 (++retries > DS2482_WAIT_IDLE_TIMEOUT)); 221 (++retries < DS2482_WAIT_IDLE_TIMEOUT));
222 } 222 }
223 223
224 if (retries > DS2482_WAIT_IDLE_TIMEOUT) 224 if (retries > DS2482_WAIT_IDLE_TIMEOUT)