From: Roel Kluin Date: Tue, 24 Feb 2009 18:19:48 +0000 (+0100) Subject: i2c: Timeouts reach -1 X-Git-Tag: v2.6.29-rc7~62^2~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a746b578d8406b2db0e9f0d040061bc1f78433cf;p=pandora-kernel.git 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 Signed-off-by: Jean Delvare --- Reading git-diff-tree failed