Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 May 2003 23:40:50 -0700 (PDT)
From:      Marcel Moolenaar <marcel@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 30839 for review
Message-ID:  <200305090640.h496eoca024787@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=30839

Change 30839 by marcel@marcel_nfs on 2003/05/08 23:40:17

	Fix the calculation of the number of nat collections between BSP
	and BSP-regs. The regs term is in bytes...

Affected files ...

.. //depot/projects/ia64_epc/sys/ia64/ia64/db_interface.c#7 edit

Differences ...

==== //depot/projects/ia64_epc/sys/ia64/ia64/db_interface.c#7 (text+ko) ====

@@ -235,7 +235,7 @@
 	bsp = ddb_regs.tf_special.bspstore + ddb_regs.tf_special.ndirty;
 	regno = (db_expr_t)vp->valuep - 32;
 	sof = ddb_regs.tf_special.cfm & 0x7f;
-	nats = (sof - regno + 62 - ((bsp >> 3) & 0x3f)) / 63;
+	nats = (((sof - regno) << 3) + 62 - ((bsp >> 3) & 0x3f)) / 63;
 
 	reg = (void*)(bsp - ((sof - regno + nats) << 3));
 
@@ -469,7 +469,7 @@
 		bsp = regs->tf_special.bspstore + regs->tf_special.ndirty;
 		regno -= 32;
 		sof = regs->tf_special.cfm & 0x7f;
-		nats = (sof - regno + 62 - ((bsp >> 3) & 0x3f)) / 63;
+		nats = (((sof - regno) << 3) + 62 - ((bsp >> 3) & 0x3f)) / 63;
 		rsp = (void*)(bsp - ((sof - regno + nats) << 3));
 		if (regno < sof)
 			return (*rsp);



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