svn commit: r245976 - head/sys/dev/agp

Konstantin Belousov kib at FreeBSD.org
Sun Jan 27 09:31:12 UTC 2013


Author: kib
Date: Sun Jan 27 09:31:11 2013
New Revision: 245976
URL: http://svnweb.freebsd.org/changeset/base/245976

Log:
  Fix reversed condition in the logic to wait for the chipset buffers
  flush wait on the Gen2 chipsets.  Confirmed by the inspection of the
  Linux agp code.
  
  Submitted by:	Taku YAMAMOTO <taku at tackymt.homeip.net>
  MFC after:	2 weeks

Modified:
  head/sys/dev/agp/agp_i810.c

Modified: head/sys/dev/agp/agp_i810.c
==============================================================================
--- head/sys/dev/agp/agp_i810.c	Sun Jan 27 07:22:46 2013	(r245975)
+++ head/sys/dev/agp/agp_i810.c	Sun Jan 27 09:31:11 2013	(r245976)
@@ -2228,7 +2228,7 @@ agp_i830_chipset_flush(device_t dev)
 	bus_write_4(sc->sc_res[0], AGP_I830_HIC, hic | (1 << 31));
 	for (i = 0; i < 20000 /* 1 sec */; i++) {
 		hic = bus_read_4(sc->sc_res[0], AGP_I830_HIC);
-		if ((hic & (1 << 31)) != 0)
+		if ((hic & (1 << 31)) == 0)
 			break;
 		DELAY(50);
 	}


More information about the svn-src-all mailing list