From 6fd3786837cbda28ee0c01e589ae48dc44d79f9c Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Wed, 4 Nov 2009 16:58:26 +0000 Subject: [PATCH] MFC 197772: When the timeout backoff hits the maximum value, leave it capped at the maximum value rather than setting it to the result of a boolean expression that is always true. --- sys/dev/ppbus/lpt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/ppbus/lpt.c b/sys/dev/ppbus/lpt.c index 10d67d91811b..77ebaea561f5 100644 --- a/sys/dev/ppbus/lpt.c +++ b/sys/dev/ppbus/lpt.c @@ -456,7 +456,7 @@ lptout(void *arg) if (sc->sc_state & OPEN) { sc->sc_backoff++; if (sc->sc_backoff > hz/LPTOUTMAX) - sc->sc_backoff = sc->sc_backoff > hz/LPTOUTMAX; + sc->sc_backoff = hz/LPTOUTMAX; callout_reset(&sc->sc_timer, sc->sc_backoff, lptout, sc); } else sc->sc_state &= ~TOUT;