aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJean Delvare <khali@linux-fr.org>2009-04-13 11:02:13 -0400
committerJean Delvare <khali@linux-fr.org>2009-04-13 11:02:13 -0400
commitc454dee21d589476608957ca4f57feaabde62fab (patch)
tree5b34d0367993d17a0523a321f221850f6fcc3106 /drivers
parentb0cbc861a3c05e634520b049b5cc27ad6febb51f (diff)
i2c-algo-pca: Fix use of uninitialized variable in debug message
A recent change broke debugging of pca_xfer(), fix it. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Wolfram Sang <w.sang@pengutronix.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/i2c/algos/i2c-algo-pca.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/algos/i2c-algo-pca.c b/drivers/i2c/algos/i2c-algo-pca.c
index f68e5f8e23ee..6318f7ddc1d4 100644
--- a/drivers/i2c/algos/i2c-algo-pca.c
+++ b/drivers/i2c/algos/i2c-algo-pca.c
@@ -190,7 +190,7 @@ static int pca_xfer(struct i2c_adapter *i2c_adap,
190 int completed = 1; 190 int completed = 1;
191 unsigned long timeout = jiffies + i2c_adap->timeout; 191 unsigned long timeout = jiffies + i2c_adap->timeout;
192 192
193 while (pca_status(adap) != 0xf8) { 193 while ((state = pca_status(adap)) != 0xf8) {
194 if (time_before(jiffies, timeout)) { 194 if (time_before(jiffies, timeout)) {
195 msleep(10); 195 msleep(10);
196 } else { 196 } else {