Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Nov 2009 16:58:26 +0000 (UTC)
From:      John Baldwin <jhb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r198907 - stable/8/sys/dev/ppbus
Message-ID:  <200911041658.nA4GwQSB039184@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhb
Date: Wed Nov  4 16:58:26 2009
New Revision: 198907
URL: http://svn.freebsd.org/changeset/base/198907

Log:
  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.

Modified:
  stable/8/sys/dev/ppbus/lpt.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/dev/ppbus/lpt.c
==============================================================================
--- stable/8/sys/dev/ppbus/lpt.c	Wed Nov  4 16:57:12 2009	(r198906)
+++ stable/8/sys/dev/ppbus/lpt.c	Wed Nov  4 16:58:26 2009	(r198907)
@@ -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;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200911041658.nA4GwQSB039184>