diff options
author | Jean Delvare <khali@linux-fr.org> | 2009-04-13 17:02:13 +0200 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2009-04-13 17:02:13 +0200 |
commit | c454dee21d589476608957ca4f57feaabde62fab (patch) | |
tree | 5b34d0367993d17a0523a321f221850f6fcc3106 /drivers/i2c/algos | |
parent | b0cbc861a3c05e634520b049b5cc27ad6febb51f (diff) | |
download | lwn-c454dee21d589476608957ca4f57feaabde62fab.tar.gz lwn-c454dee21d589476608957ca4f57feaabde62fab.zip |
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/i2c/algos')
-rw-r--r-- | drivers/i2c/algos/i2c-algo-pca.c | 2 |
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, int completed = 1; unsigned long timeout = jiffies + i2c_adap->timeout; - while (pca_status(adap) != 0xf8) { + while ((state = pca_status(adap)) != 0xf8) { if (time_before(jiffies, timeout)) { msleep(10); } else { |