summaryrefslogtreecommitdiff
path: root/src/arch/sparc/interrupts.hh
diff options
context:
space:
mode:
authorLisa Hsu <hsul@eecs.umich.edu>2007-01-19 21:33:36 -0500
committerLisa Hsu <hsul@eecs.umich.edu>2007-01-19 21:33:36 -0500
commitf1aeaf7ceb44ea6ef7032048a68c74ecedc7685b (patch)
tree022b6bcfe7f925156afd756f91e8dfca1599dfcb /src/arch/sparc/interrupts.hh
parent5c9cbdbb4597a3ba6908a41c1dc459c25626e514 (diff)
downloadgem5-f1aeaf7ceb44ea6ef7032048a68c74ecedc7685b.tar.xz
some hstick and hintp changes.
src/arch/sparc/interrupts.hh: condition hstick matches on HINTP src/arch/sparc/miscregfile.cc: implement HINTP src/arch/sparc/ua2005.cc: don't post interrupt unless it is enabled. --HG-- extra : convert_revision : f71d1c1d9fd1a898ddafd5a885c3a8d5c75e8ff0
Diffstat (limited to 'src/arch/sparc/interrupts.hh')
-rw-r--r--src/arch/sparc/interrupts.hh22
1 files changed, 15 insertions, 7 deletions
diff --git a/src/arch/sparc/interrupts.hh b/src/arch/sparc/interrupts.hh
index 879cd1825..99ddb4919 100644
--- a/src/arch/sparc/interrupts.hh
+++ b/src/arch/sparc/interrupts.hh
@@ -108,9 +108,11 @@ enum interrupts_t {
if (hpstate & HPSTATE::hpriv) {
if (ie) {
if (interrupts[hstick_match]) {
- interrupts[hstick_match] = false;
- --numPosted;
- return new HstickMatch;
+ if (tc->readMiscReg(MISCREG_HINTP) & 1) {
+ interrupts[hstick_match] = false;
+ --numPosted;
+ return new HstickMatch;
+ }
}
if (interrupts[interrupt_vector]) {
interrupts[interrupt_vector] = false;
@@ -118,9 +120,13 @@ enum interrupts_t {
//HAVEN'T IMPLed THIS YET
return NoFault;
}
+ } else {
+ if (interrupts[hstick_match]) {
+ return NoFault;
+ }
+
}
} else {
-
if (interrupts[trap_level_zero]) {
if ((pstate & HPSTATE::tlz) && (tc->readMiscReg(MISCREG_TL) == 0)) {
interrupts[trap_level_zero] = false;
@@ -129,9 +135,11 @@ enum interrupts_t {
}
}
if (interrupts[hstick_match]) {
- interrupts[hstick_match] = false;
- --numPosted;
- return new HstickMatch;
+ if (tc->readMiscReg(MISCREG_HINTP) & 1) {
+ interrupts[hstick_match] = false;
+ --numPosted;
+ return new HstickMatch;
+ }
}
if (ie) {
if (interrupts[cpu_mondo]) {