summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2006-12-06 05:41:08 -0500
committerGabe Black <gblack@eecs.umich.edu>2006-12-06 05:41:08 -0500
commit4d8a0541dd16cf358c16dc8ad474717fcbed753f (patch)
treea4f9c9096f8218dfecff0a5344490dc8562aa3f5
parenta3f351ab595d61ddd7a3248fea5ddeea8c5ba65b (diff)
downloadgem5-4d8a0541dd16cf358c16dc8ad474717fcbed753f.tar.xz
Change MIPS's setSyscallReturn to use a thread context.
--HG-- extra : convert_revision : 618f8404ec5380615e28170d761b2fcdf9c07d96
-rw-r--r--src/arch/mips/syscallreturn.hh12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/arch/mips/syscallreturn.hh b/src/arch/mips/syscallreturn.hh
index 0d36b3330..47290b634 100644
--- a/src/arch/mips/syscallreturn.hh
+++ b/src/arch/mips/syscallreturn.hh
@@ -33,19 +33,21 @@
#define __ARCH_MIPS_SYSCALLRETURN_HH__
#include "sim/syscallreturn.hh"
+#include "cpu/thread_context.hh"
namespace MipsISA
{
- static inline void setSyscallReturn(SyscallReturn return_value, RegFile *regs)
+ static inline void setSyscallReturn(SyscallReturn return_value,
+ ThreadContext *tc)
{
if (return_value.successful()) {
// no error
- regs->setIntReg(SyscallSuccessReg, 0);
- regs->setIntReg(ReturnValueReg1, return_value.value());
+ tc->setIntReg(SyscallSuccessReg, 0);
+ tc->setIntReg(ReturnValueReg1, return_value.value());
} else {
// got an error, return details
- regs->setIntReg(SyscallSuccessReg, (IntReg) -1);
- regs->setIntReg(ReturnValueReg1, -return_value.value());
+ tc->setIntReg(SyscallSuccessReg, (IntReg) -1);
+ tc->setIntReg(ReturnValueReg1, -return_value.value());
}
}
}