summaryrefslogtreecommitdiff
path: root/drivers/w1/masters
diff options
context:
space:
mode:
authorBen Gardner <gardner.ben@gmail.com>2006-06-29 22:33:22 +0400
committerGreg Kroah-Hartman <gregkh@suse.de>2006-07-12 15:38:27 -0700
commitb4786f1893305312d0a3e602de9080b1b932a681 (patch)
tree6b913ee2159e4bf973109bb2e54fd7201b30c696 /drivers/w1/masters
parent4e35dea2f26b16735b242ed1ae876157f46f3b23 (diff)
downloadlinux-3.10-b4786f1893305312d0a3e602de9080b1b932a681.tar.gz
linux-3.10-b4786f1893305312d0a3e602de9080b1b932a681.tar.bz2
linux-3.10-b4786f1893305312d0a3e602de9080b1b932a681.zip
[PATCH] w1: fix idle check loop in ds2482
The idle check loop has a greater-than where it should have a less-than. This causes the ds2482 driver to check for the idle condition exactly once, which causes it to fail on faster machines. Signed-off-by: Ben Gardner <gardner.ben@gmail.com> Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/w1/masters')
-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 af492cc48db..d93eb626b2f 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)
do {
temp = i2c_smbus_read_byte(&pdev->client);
} while ((temp >= 0) && (temp & DS2482_REG_STS_1WB) &&
- (++retries > DS2482_WAIT_IDLE_TIMEOUT));
+ (++retries < DS2482_WAIT_IDLE_TIMEOUT));
}
if (retries > DS2482_WAIT_IDLE_TIMEOUT)