changeset 143:73cf7b972c19

Moved define for number of registers to PSW file
author Jonathan Pevarnek <pevarnj@gmail.com>
date Thu, 22 Sep 2011 16:11:50 -0400
parents ce04ebdd00e2
children cf569b2ab76c
files include/os/progint.h include/os/psw.h src/os/except.c
diffstat 3 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/include/os/progint.h	Thu Sep 22 14:23:40 2011 -0400
+++ b/include/os/progint.h	Thu Sep 22 16:11:50 2011 -0400
@@ -1,8 +1,6 @@
 #ifndef __PROGINT_H
 #define __PROGINT_H
 
-#define NUM_REGS 16
-
 #define PROGINT_REG_LOC 0x300
 
 #define PROGINT_PSW_OLD 0x150
--- a/include/os/psw.h	Thu Sep 22 14:23:40 2011 -0400
+++ b/include/os/psw.h	Thu Sep 22 16:11:50 2011 -0400
@@ -30,4 +30,6 @@
 
 typedef struct psw Psw;
 
+#define NUM_GPRS 16
+
 #endif
--- a/src/os/except.c	Thu Sep 22 14:23:40 2011 -0400
+++ b/src/os/except.c	Thu Sep 22 16:11:50 2011 -0400
@@ -23,7 +23,7 @@
 	Psw *oldPsw = (void*)PROGINT_PSW_OLD;
 	u64 *regStore = (u64*)PROGINT_REG_LOC;
 
-	for(i = 0; i < NUM_REGS; i++) {
+	for(i = 0; i < NUM_GPRS; i++) {
 		sprintf(buffer, "REG %x: %x\n", i, regStore[i]);
 		sPrint(buffer);
 	}