diff options
author | Roel Kluin <roel.kluin@gmail.com> | 2009-02-03 00:39:02 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-02-03 00:39:02 -0500 |
commit | 46578a6913e6f5e69229561736b94c18c2e88ae4 (patch) | |
tree | 23db22f32e094dd971650528ea1d499bd2ab3015 /drivers/net/sunqe.c | |
parent | 0047e5d240ede4e84c03bc9001375175900fd259 (diff) |
net: variables reach -1, but 0 tested
while (timeout--) { ... }
timeout becomes -1 if the loop isn't ended otherwise, not 0.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sunqe.c')
-rw-r--r-- | drivers/net/sunqe.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/sunqe.c b/drivers/net/sunqe.c index 6e8f377355fe..fe0c3f244562 100644 --- a/drivers/net/sunqe.c +++ b/drivers/net/sunqe.c | |||
@@ -227,7 +227,7 @@ static int qe_init(struct sunqe *qep, int from_irq) | |||
227 | if (!(sbus_readb(mregs + MREGS_PHYCONFIG) & MREGS_PHYCONFIG_LTESTDIS)) { | 227 | if (!(sbus_readb(mregs + MREGS_PHYCONFIG) & MREGS_PHYCONFIG_LTESTDIS)) { |
228 | int tries = 50; | 228 | int tries = 50; |
229 | 229 | ||
230 | while (tries--) { | 230 | while (--tries) { |
231 | u8 tmp; | 231 | u8 tmp; |
232 | 232 | ||
233 | mdelay(5); | 233 | mdelay(5); |