diff options
author | jhb <jhb@FreeBSD.org> | 2009-10-05 14:13:16 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2009-10-05 14:13:16 +0000 |
commit | 9d270810482b03835088730678541f0c11cfb068 (patch) | |
tree | ab0cccfabf94fa47ad1e2b72b23e8dc9d411da3a /sys/dev/ppbus/lpt.c | |
parent | b956b860336ebc601e720d86b5e697249f3c3631 (diff) | |
download | FreeBSD-src-9d270810482b03835088730678541f0c11cfb068.zip FreeBSD-src-9d270810482b03835088730678541f0c11cfb068.tar.gz |
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.
Submitted by: Joseph Kong
MFC after: 1 month
Diffstat (limited to 'sys/dev/ppbus/lpt.c')
-rw-r--r-- | sys/dev/ppbus/lpt.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/ppbus/lpt.c b/sys/dev/ppbus/lpt.c index 10d67d9..77ebaea 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; |