aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/i2c.h
diff options
context:
space:
mode:
authorRoel Kluin <roel.kluin@gmail.com>2009-02-24 19:19:48 +0100
committerJean Delvare <khali@linux-fr.org>2009-02-24 19:19:48 +0100
commita746b578d8406b2db0e9f0d040061bc1f78433cf (patch)
treece79fc247342fa9fde8ad184a4ec39d70ce0012a /include/linux/i2c.h
parenti2c: Fix misplaced parentheses (diff)
downloadlinux-dev-a746b578d8406b2db0e9f0d040061bc1f78433cf.tar.xz
linux-dev-a746b578d8406b2db0e9f0d040061bc1f78433cf.zip
i2c: Timeouts reach -1
With a postfix decrement these timeouts reach -1 rather than 0, but after the loop it is tested whether they have become 0. As pointed out by Jean Delvare, the condition we are waiting for should also be tested before the timeout. With the current order, you could exit with a timeout error while the job is actually done. Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'include/linux/i2c.h')
0 files changed, 0 insertions, 0 deletions