misc: Remove the "fault" parameter from syscall functions.

This parameter was never set or used, just plumbed everywhere,
occasionally with a dummy value. This change removes all of that
plumbing.

Change-Id: I9bc31ffd1fbc4952c5d3096f7f21eab30102300b
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33277
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
diff --git a/src/arch/arm/fastmodel/iris/thread_context.hh b/src/arch/arm/fastmodel/iris/thread_context.hh
index 363e1d7..dc53969 100644
--- a/src/arch/arm/fastmodel/iris/thread_context.hh
+++ b/src/arch/arm/fastmodel/iris/thread_context.hh
@@ -445,7 +445,7 @@
     }
 
     void
-    syscall(Fault *fault) override
+    syscall() override
     {
         panic("%s not implemented.", __FUNCTION__);
     }
diff --git a/src/arch/arm/faults.cc b/src/arch/arm/faults.cc
index 5b865ec..56e1814 100644
--- a/src/arch/arm/faults.cc
+++ b/src/arch/arm/faults.cc
@@ -865,8 +865,7 @@
 
     // As of now, there isn't a 32 bit thumb version of this instruction.
     assert(!machInst.bigThumb);
-    Fault fault;
-    tc->syscall(&fault);
+    tc->syscall();
 
     // Advance the PC since that won't happen automatically.
     PCState pc = tc->pcState();
diff --git a/src/arch/arm/freebsd/process.cc b/src/arch/arm/freebsd/process.cc
index d8a7d68..4bf6bcc 100644
--- a/src/arch/arm/freebsd/process.cc
+++ b/src/arch/arm/freebsd/process.cc
@@ -175,15 +175,15 @@
 }
 
 void
-ArmFreebsdProcess32::syscall(ThreadContext *tc, Fault *fault)
+ArmFreebsdProcess32::syscall(ThreadContext *tc)
 {
-    ArmProcess32::syscall(tc, fault);
-    syscallDescs32.get(tc->readIntReg(INTREG_R7))->doSyscall(tc, fault);
+    ArmProcess32::syscall(tc);
+    syscallDescs32.get(tc->readIntReg(INTREG_R7))->doSyscall(tc);
 }
 
 void
-ArmFreebsdProcess64::syscall(ThreadContext *tc, Fault *fault)
+ArmFreebsdProcess64::syscall(ThreadContext *tc)
 {
-    ArmProcess64::syscall(tc, fault);
-    syscallDescs64.get(tc->readIntReg(INTREG_X8))->doSyscall(tc, fault);
+    ArmProcess64::syscall(tc);
+    syscallDescs64.get(tc->readIntReg(INTREG_X8))->doSyscall(tc);
 }
diff --git a/src/arch/arm/freebsd/process.hh b/src/arch/arm/freebsd/process.hh
index d52512a..b64a3a0 100644
--- a/src/arch/arm/freebsd/process.hh
+++ b/src/arch/arm/freebsd/process.hh
@@ -82,7 +82,7 @@
 
     void initState() override;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     /// A page to hold "kernel" provided functions. The name might be wrong.
     static const Addr commPage;
@@ -100,7 +100,7 @@
                         ::Loader::Arch _arch);
 
     void initState() override;
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     struct SyscallABI : public ArmProcess64::SyscallABI,
                         public ArmFreebsdProcessBits::SyscallABI
diff --git a/src/arch/arm/linux/process.cc b/src/arch/arm/linux/process.cc
index 65f1cd1..c190167 100644
--- a/src/arch/arm/linux/process.cc
+++ b/src/arch/arm/linux/process.cc
@@ -912,9 +912,9 @@
 }
 
 void
-ArmLinuxProcess32::syscall(ThreadContext *tc, Fault *fault)
+ArmLinuxProcess32::syscall(ThreadContext *tc)
 {
-    ArmProcess32::syscall(tc, fault);
+    ArmProcess32::syscall(tc);
 
     int num = tc->readIntReg(INTREG_R7);
     SyscallDesc *desc = syscallDescs32Low.get(num, false);
@@ -922,13 +922,13 @@
         desc = syscallDescs32Low.get(num, false);
     if (!desc)
         desc = privSyscallDescs32.get(num);
-    desc->doSyscall(tc, fault);
+    desc->doSyscall(tc);
 }
 
 void
-ArmLinuxProcess64::syscall(ThreadContext *tc, Fault *fault)
+ArmLinuxProcess64::syscall(ThreadContext *tc)
 {
-    ArmProcess64::syscall(tc, fault);
+    ArmProcess64::syscall(tc);
 
     int num = tc->readIntReg(INTREG_X8);
     SyscallDesc *desc = syscallDescs64Low.get(num, false);
@@ -936,5 +936,5 @@
         desc = syscallDescs64Low.get(num, false);
     if (!desc)
         desc = privSyscallDescs64.get(num);
-    desc->doSyscall(tc, fault);
+    desc->doSyscall(tc);
 }
diff --git a/src/arch/arm/linux/process.hh b/src/arch/arm/linux/process.hh
index 0c15c28..21c2a29 100644
--- a/src/arch/arm/linux/process.hh
+++ b/src/arch/arm/linux/process.hh
@@ -82,7 +82,7 @@
 
     void initState() override;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     /// A page to hold "kernel" provided functions. The name might be wrong.
     static const Addr commPage;
@@ -100,7 +100,7 @@
                       ::Loader::Arch _arch);
 
     void initState() override;
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     struct SyscallABI : public ArmProcess64::SyscallABI,
                         public ArmLinuxProcessBits::SyscallABI
diff --git a/src/arch/mips/isa/decoder.isa b/src/arch/mips/isa/decoder.isa
index 19a1499..6e19f85 100644
--- a/src/arch/mips/isa/decoder.isa
+++ b/src/arch/mips/isa/decoder.isa
@@ -159,7 +159,7 @@
                     0x2: movz({{ Rd = (Rt == 0) ? Rs : Rd; }});
                     0x3: movn({{ Rd = (Rt != 0) ? Rs : Rd; }});
                     0x4: decode FullSystemInt {
-                        0: syscall_se({{ xc->syscall(&fault); }},
+                        0: syscall_se({{ xc->syscall(); }},
                                 IsSerializeAfter, IsNonSpeculative);
                       default: syscall({{ fault = std::make_shared<SystemCallFault>(); }});
                     }
diff --git a/src/arch/mips/linux/process.cc b/src/arch/mips/linux/process.cc
index 600d053..3bc88df 100644
--- a/src/arch/mips/linux/process.cc
+++ b/src/arch/mips/linux/process.cc
@@ -476,8 +476,8 @@
 {}
 
 void
-MipsLinuxProcess::syscall(ThreadContext *tc, Fault *fault)
+MipsLinuxProcess::syscall(ThreadContext *tc)
 {
-    MipsProcess::syscall(tc, fault);
-    syscallDescs.get(tc->readIntReg(2))->doSyscall(tc, fault);
+    MipsProcess::syscall(tc);
+    syscallDescs.get(tc->readIntReg(2))->doSyscall(tc);
 }
diff --git a/src/arch/mips/linux/process.hh b/src/arch/mips/linux/process.hh
index ddf2a11..981526c 100644
--- a/src/arch/mips/linux/process.hh
+++ b/src/arch/mips/linux/process.hh
@@ -47,7 +47,7 @@
     /// ID of the thread group leader for the process
     uint64_t __tgid;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     /// Syscall descriptors, indexed by call number.
     static SyscallDescTable<SyscallABI> syscallDescs;
diff --git a/src/arch/power/isa/decoder.isa b/src/arch/power/isa/decoder.isa
index ce9cbba..2e88aea 100644
--- a/src/arch/power/isa/decoder.isa
+++ b/src/arch/power/isa/decoder.isa
@@ -515,7 +515,7 @@
         55: stfdu({{ Mem_df = Fs; }});
     }
 
-    17: IntOp::sc({{ xc->syscall(&fault); }},
+    17: IntOp::sc({{ xc->syscall(); }},
                   [ IsSyscall, IsNonSpeculative, IsSerializeAfter ]);
 
     format FloatArithOp {
diff --git a/src/arch/power/linux/process.cc b/src/arch/power/linux/process.cc
index fd07947..633c3a7 100644
--- a/src/arch/power/linux/process.cc
+++ b/src/arch/power/linux/process.cc
@@ -451,8 +451,8 @@
 }
 
 void
-PowerLinuxProcess::syscall(ThreadContext *tc, Fault *fault)
+PowerLinuxProcess::syscall(ThreadContext *tc)
 {
-    PowerProcess::syscall(tc, fault);
-    syscallDescs.get(tc->readIntReg(0))->doSyscall(tc, fault);
+    PowerProcess::syscall(tc);
+    syscallDescs.get(tc->readIntReg(0))->doSyscall(tc);
 }
diff --git a/src/arch/power/linux/process.hh b/src/arch/power/linux/process.hh
index a81edfb..2c7883d 100644
--- a/src/arch/power/linux/process.hh
+++ b/src/arch/power/linux/process.hh
@@ -42,7 +42,7 @@
 
     void initState() override;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     /// Syscall descriptors, indexed by call number.
     static SyscallDescTable<SyscallABI> syscallDescs;
diff --git a/src/arch/riscv/faults.cc b/src/arch/riscv/faults.cc
index 2ef8df4..7a1c7bd 100644
--- a/src/arch/riscv/faults.cc
+++ b/src/arch/riscv/faults.cc
@@ -194,8 +194,7 @@
 void
 SyscallFault::invokeSE(ThreadContext *tc, const StaticInstPtr &inst)
 {
-    Fault *fault = NoFault;
-    tc->syscall(fault);
+    tc->syscall();
 }
 
 } // namespace RiscvISA
diff --git a/src/arch/riscv/linux/process.cc b/src/arch/riscv/linux/process.cc
index fa6bf01..094097f 100644
--- a/src/arch/riscv/linux/process.cc
+++ b/src/arch/riscv/linux/process.cc
@@ -781,10 +781,10 @@
 {}
 
 void
-RiscvLinuxProcess64::syscall(ThreadContext *tc, Fault *fault)
+RiscvLinuxProcess64::syscall(ThreadContext *tc)
 {
-    RiscvProcess64::syscall(tc, fault);
-    syscallDescs.get(tc->readIntReg(SyscallNumReg))->doSyscall(tc, fault);
+    RiscvProcess64::syscall(tc);
+    syscallDescs.get(tc->readIntReg(SyscallNumReg))->doSyscall(tc);
 }
 
 RiscvLinuxProcess32::RiscvLinuxProcess32(ProcessParams * params,
@@ -792,8 +792,8 @@
 {}
 
 void
-RiscvLinuxProcess32::syscall(ThreadContext *tc, Fault *fault)
+RiscvLinuxProcess32::syscall(ThreadContext *tc)
 {
-    RiscvProcess32::syscall(tc, fault);
-    syscallDescs.get(tc->readIntReg(SyscallNumReg))->doSyscall(tc, fault);
+    RiscvProcess32::syscall(tc);
+    syscallDescs.get(tc->readIntReg(SyscallNumReg))->doSyscall(tc);
 }
diff --git a/src/arch/riscv/linux/process.hh b/src/arch/riscv/linux/process.hh
index b553bef..8844273 100644
--- a/src/arch/riscv/linux/process.hh
+++ b/src/arch/riscv/linux/process.hh
@@ -50,7 +50,7 @@
     /// ID of the thread group leader for the process
     uint64_t __tgid;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     /// Syscall descriptors, indexed by call number.
     static SyscallDescTable<SyscallABI> syscallDescs;
@@ -68,7 +68,7 @@
     /// ID of the thread group leader for the process
     uint64_t __tgid;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     /// Array of syscall descriptors, indexed by call number.
     static SyscallDescTable<SyscallABI> syscallDescs;
diff --git a/src/arch/sparc/faults.cc b/src/arch/sparc/faults.cc
index 4197613..34a0d52 100644
--- a/src/arch/sparc/faults.cc
+++ b/src/arch/sparc/faults.cc
@@ -815,8 +815,7 @@
     SparcProcess *sp = dynamic_cast<SparcProcess *>(p);
     assert(sp);
 
-    Fault fault;
-    sp->handleTrap(_n, tc, &fault);
+    sp->handleTrap(_n, tc);
 
     // We need to explicitly advance the pc, since that's not done for us
     // on a faulting instruction
diff --git a/src/arch/sparc/linux/process.cc b/src/arch/sparc/linux/process.cc
index 2988223..79bbaee 100644
--- a/src/arch/sparc/linux/process.cc
+++ b/src/arch/sparc/linux/process.cc
@@ -81,21 +81,21 @@
 {}
 
 void
-Sparc32LinuxProcess::syscall(ThreadContext *tc, Fault *fault)
+Sparc32LinuxProcess::syscall(ThreadContext *tc)
 {
-    Sparc32Process::syscall(tc, fault);
-    syscall32Descs.get(tc->readIntReg(1))->doSyscall(tc, fault);
+    Sparc32Process::syscall(tc);
+    syscall32Descs.get(tc->readIntReg(1))->doSyscall(tc);
 }
 
 void
-Sparc32LinuxProcess::handleTrap(int trapNum, ThreadContext *tc, Fault *fault)
+Sparc32LinuxProcess::handleTrap(int trapNum, ThreadContext *tc)
 {
     switch (trapNum) {
       case 0x10: //Linux 32 bit syscall trap
-        tc->syscall(fault);
+        tc->syscall();
         break;
       default:
-        SparcProcess::handleTrap(trapNum, tc, fault);
+        SparcProcess::handleTrap(trapNum, tc);
     }
 }
 
@@ -105,10 +105,10 @@
 {}
 
 void
-Sparc64LinuxProcess::syscall(ThreadContext *tc, Fault *fault)
+Sparc64LinuxProcess::syscall(ThreadContext *tc)
 {
-    Sparc64Process::syscall(tc, fault);
-    syscallDescs.get(tc->readIntReg(1))->doSyscall(tc, fault);
+    Sparc64Process::syscall(tc);
+    syscallDescs.get(tc->readIntReg(1))->doSyscall(tc);
 }
 
 void
@@ -124,12 +124,12 @@
 }
 
 void
-Sparc64LinuxProcess::handleTrap(int trapNum, ThreadContext *tc, Fault *fault)
+Sparc64LinuxProcess::handleTrap(int trapNum, ThreadContext *tc)
 {
     switch (trapNum) {
       // case 0x10: // Linux 32 bit syscall trap
       case 0x6d: // Linux 64 bit syscall trap
-        tc->syscall(fault);
+        tc->syscall();
         break;
       case 0x6e: // Linux 64 bit getcontext trap
         getContext(tc);
@@ -138,6 +138,6 @@
         setContext(tc);
         break;
       default:
-        SparcProcess::handleTrap(trapNum, tc, fault);
+        SparcProcess::handleTrap(trapNum, tc);
     }
 }
diff --git a/src/arch/sparc/linux/process.hh b/src/arch/sparc/linux/process.hh
index 99c9547..0cea430 100644
--- a/src/arch/sparc/linux/process.hh
+++ b/src/arch/sparc/linux/process.hh
@@ -56,9 +56,9 @@
     /// Constructor.
     Sparc32LinuxProcess(ProcessParams * params, ::Loader::ObjectFile *objFile);
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
-    void handleTrap(int trapNum, ThreadContext *tc, Fault *fault) override;
+    void handleTrap(int trapNum, ThreadContext *tc) override;
 };
 
 /// A process with emulated 32 bit SPARC/Linux syscalls.
@@ -68,12 +68,12 @@
     /// Constructor.
     Sparc64LinuxProcess(ProcessParams * params, ::Loader::ObjectFile *objFile);
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
     void getContext(ThreadContext *tc);
     void setContext(ThreadContext *tc);
 
-    void handleTrap(int trapNum, ThreadContext *tc, Fault *fault) override;
+    void handleTrap(int trapNum, ThreadContext *tc) override;
 };
 
 SyscallReturn getresuidFunc(SyscallDesc *desc, ThreadContext *tc,
diff --git a/src/arch/sparc/process.cc b/src/arch/sparc/process.cc
index ca0df08..d28189c 100644
--- a/src/arch/sparc/process.cc
+++ b/src/arch/sparc/process.cc
@@ -66,7 +66,7 @@
 }
 
 void
-SparcProcess::handleTrap(int trapNum, ThreadContext *tc, Fault *fault)
+SparcProcess::handleTrap(int trapNum, ThreadContext *tc)
 {
     PCState pc = tc->pcState();
     switch (trapNum) {
diff --git a/src/arch/sparc/process.hh b/src/arch/sparc/process.hh
index bf99224..68b607f 100644
--- a/src/arch/sparc/process.hh
+++ b/src/arch/sparc/process.hh
@@ -61,7 +61,7 @@
   public:
 
     // Handles traps which request services from the operating system
-    virtual void handleTrap(int trapNum, ThreadContext *tc, Fault *fault);
+    virtual void handleTrap(int trapNum, ThreadContext *tc);
 
     Addr readFillStart() { return fillStart; }
     Addr readSpillStart() { return spillStart; }
diff --git a/src/arch/sparc/solaris/process.cc b/src/arch/sparc/solaris/process.cc
index 63f1a0f..88fb192 100644
--- a/src/arch/sparc/solaris/process.cc
+++ b/src/arch/sparc/solaris/process.cc
@@ -350,8 +350,8 @@
 {}
 
 void
-SparcSolarisProcess::syscall(ThreadContext *tc, Fault *fault)
+SparcSolarisProcess::syscall(ThreadContext *tc)
 {
-    Sparc64Process::syscall(tc, fault);
-    syscallDescs.get(tc->readIntReg(1))->doSyscall(tc, fault);
+    Sparc64Process::syscall(tc);
+    syscallDescs.get(tc->readIntReg(1))->doSyscall(tc);
 }
diff --git a/src/arch/sparc/solaris/process.hh b/src/arch/sparc/solaris/process.hh
index 2f218bb..0c71d4a 100644
--- a/src/arch/sparc/solaris/process.hh
+++ b/src/arch/sparc/solaris/process.hh
@@ -46,7 +46,7 @@
     /// The target system's hostname.
     static const char *hostname;
 
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
 
      /// Array of syscall descriptors, indexed by call number.
     static SyscallDescTable<Sparc64Process::SyscallABI> syscallDescs;
diff --git a/src/arch/x86/isa/decoder/one_byte_opcodes.isa b/src/arch/x86/isa/decoder/one_byte_opcodes.isa
index e09b34a..b1b6218 100644
--- a/src/arch/x86/isa/decoder/one_byte_opcodes.isa
+++ b/src/arch/x86/isa/decoder/one_byte_opcodes.isa
@@ -398,7 +398,7 @@
                         // will sign extend it, and there's no easy way to
                         // specify only checking the first byte.
                         0xffffffffffffff80:
-                            SyscallInst::int80('xc->syscall(&fault)',
+                            SyscallInst::int80('xc->syscall()',
                                                IsSyscall, IsNonSpeculative,
                                                IsSerializeAfter);
                     }
diff --git a/src/arch/x86/isa/decoder/two_byte_opcodes.isa b/src/arch/x86/isa/decoder/two_byte_opcodes.isa
index c147d08..0dec25b 100644
--- a/src/arch/x86/isa/decoder/two_byte_opcodes.isa
+++ b/src/arch/x86/isa/decoder/two_byte_opcodes.isa
@@ -237,7 +237,7 @@
                 }
             }
             0x05: decode FullSystemInt {
-                0: SyscallInst::syscall('xc->syscall(&fault)',
+                0: SyscallInst::syscall('xc->syscall()',
                                         IsSyscall, IsNonSpeculative,
                                         IsSerializeAfter);
                 default: decode MODE_MODE {
@@ -431,7 +431,7 @@
             0x2: Inst::RDMSR();
             0x3: rdpmc();
             0x4: decode FullSystemInt {
-                0: SyscallInst::sysenter('xc->syscall(&fault)',
+                0: SyscallInst::sysenter('xc->syscall()',
                                          IsSyscall, IsNonSpeculative,
                                          IsSerializeAfter);
                 default: sysenter();
diff --git a/src/arch/x86/linux/process.cc b/src/arch/x86/linux/process.cc
index 9460a4b..68a9841 100644
--- a/src/arch/x86/linux/process.cc
+++ b/src/arch/x86/linux/process.cc
@@ -566,10 +566,10 @@
 };
 
 void
-X86_64LinuxProcess::syscall(ThreadContext *tc, Fault *fault)
+X86_64LinuxProcess::syscall(ThreadContext *tc)
 {
-    X86_64Process::syscall(tc, fault);
-    syscallDescs64.get(tc->readIntReg(INTREG_RAX))->doSyscall(tc, fault);
+    X86_64Process::syscall(tc);
+    syscallDescs64.get(tc->readIntReg(INTREG_RAX))->doSyscall(tc);
 }
 
 void
@@ -915,9 +915,9 @@
 };
 
 void
-I386LinuxProcess::syscall(ThreadContext *tc, Fault *fault)
+I386LinuxProcess::syscall(ThreadContext *tc)
 {
-    I386Process::syscall(tc, fault);
+    I386Process::syscall(tc);
     PCState pc = tc->pcState();
     Addr eip = pc.pc();
     if (eip >= vsyscallPage.base &&
@@ -925,7 +925,7 @@
         pc.npc(vsyscallPage.base + vsyscallPage.vsysexitOffset);
         tc->pcState(pc);
     }
-    syscallDescs32.get(tc->readIntReg(INTREG_RAX))->doSyscall(tc, fault);
+    syscallDescs32.get(tc->readIntReg(INTREG_RAX))->doSyscall(tc);
 }
 
 void
diff --git a/src/arch/x86/linux/process.hh b/src/arch/x86/linux/process.hh
index c2fff8b..06b6692 100644
--- a/src/arch/x86/linux/process.hh
+++ b/src/arch/x86/linux/process.hh
@@ -53,7 +53,7 @@
 {
   public:
     using X86_64Process::X86_64Process;
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
     void clone(ThreadContext *old_tc, ThreadContext *new_tc, Process *process,
                RegVal flags) override;
 
@@ -67,7 +67,7 @@
 {
   public:
     using I386Process::I386Process;
-    void syscall(ThreadContext *tc, Fault *fault) override;
+    void syscall(ThreadContext *tc) override;
     void clone(ThreadContext *old_tc, ThreadContext *new_tc, Process *process,
                RegVal flags) override;
 
diff --git a/src/cpu/checker/cpu.hh b/src/cpu/checker/cpu.hh
index 3c04064..7d1807e 100644
--- a/src/cpu/checker/cpu.hh
+++ b/src/cpu/checker/cpu.hh
@@ -577,7 +577,7 @@
     void wakeup(ThreadID tid) override { }
     // Assume that the normal CPU's call to syscall was successful.
     // The checker's state would have already been updated by the syscall.
-    void syscall(Fault *fault) override { }
+    void syscall() override { }
 
     void
     handleError()
diff --git a/src/cpu/checker/thread_context.hh b/src/cpu/checker/thread_context.hh
index 06cb3b9..e98b3a2 100644
--- a/src/cpu/checker/thread_context.hh
+++ b/src/cpu/checker/thread_context.hh
@@ -172,11 +172,7 @@
     }
 
     /** Executes a syscall in SE mode. */
-    void
-    syscall(Fault *fault) override
-    {
-        return actualTC->syscall(fault);
-    }
+    void syscall() override { return actualTC->syscall(); }
 
     Status status() const override { return actualTC->status(); }
 
diff --git a/src/cpu/exec_context.hh b/src/cpu/exec_context.hh
index 29daced..4180191 100644
--- a/src/cpu/exec_context.hh
+++ b/src/cpu/exec_context.hh
@@ -303,7 +303,7 @@
     /**
      * Executes a syscall.
      */
-    virtual void syscall(Fault *fault) = 0;
+    virtual void syscall() = 0;
 
     /** @} */
 
diff --git a/src/cpu/minor/exec_context.hh b/src/cpu/minor/exec_context.hh
index a0b1d18..e65fdfb 100644
--- a/src/cpu/minor/exec_context.hh
+++ b/src/cpu/minor/exec_context.hh
@@ -379,11 +379,7 @@
         return thread.setMiscReg(reg.index(), val);
     }
 
-    void
-    syscall(Fault *fault) override
-    {
-        thread.syscall(fault);
-    }
+    void syscall() override { thread.syscall(); }
 
     ThreadContext *tcBase() const override { return thread.getTC(); }
 
diff --git a/src/cpu/o3/cpu.cc b/src/cpu/o3/cpu.cc
index d911490..d0a387c 100644
--- a/src/cpu/o3/cpu.cc
+++ b/src/cpu/o3/cpu.cc
@@ -915,7 +915,7 @@
 
 template <class Impl>
 void
-FullO3CPU<Impl>::syscall(ThreadID tid, Fault *fault)
+FullO3CPU<Impl>::syscall(ThreadID tid)
 {
     DPRINTF(O3CPU, "[tid:%i] Executing syscall().\n\n", tid);
 
@@ -926,7 +926,7 @@
     ++(this->thread[tid]->funcExeInst);
 
     // Execute the actual syscall.
-    this->thread[tid]->syscall(fault);
+    this->thread[tid]->syscall();
 
     // Decrease funcExeInst by one as the normal commit will handle
     // incrementing it.
diff --git a/src/cpu/o3/cpu.hh b/src/cpu/o3/cpu.hh
index c3d911b..cc0e2cd 100644
--- a/src/cpu/o3/cpu.hh
+++ b/src/cpu/o3/cpu.hh
@@ -280,7 +280,7 @@
     /** Executes a syscall.
      * @todo: Determine if this needs to be virtual.
      */
-    void syscall(ThreadID tid, Fault *fault);
+    void syscall(ThreadID tid);
 
     /** Starts draining the CPU's pipeline of all instructions in
      * order to stop all memory accesses. */
diff --git a/src/cpu/o3/dyn_inst.hh b/src/cpu/o3/dyn_inst.hh
index d5f142c..5f2a588 100644
--- a/src/cpu/o3/dyn_inst.hh
+++ b/src/cpu/o3/dyn_inst.hh
@@ -249,7 +249,7 @@
     void trap(const Fault &fault);
 
     /** Emulates a syscall. */
-    void syscall(Fault *fault) override;
+    void syscall() override;
 
   public:
 
diff --git a/src/cpu/o3/dyn_inst_impl.hh b/src/cpu/o3/dyn_inst_impl.hh
index 597bd1d..8a6a434 100644
--- a/src/cpu/o3/dyn_inst_impl.hh
+++ b/src/cpu/o3/dyn_inst_impl.hh
@@ -189,13 +189,13 @@
 
 template <class Impl>
 void
-BaseO3DynInst<Impl>::syscall(Fault *fault)
+BaseO3DynInst<Impl>::syscall()
 {
     // HACK: check CPU's nextPC before and after syscall. If it
     // changes, update this instruction's nextPC because the syscall
     // must have changed the nextPC.
     TheISA::PCState curPC = this->cpu->pcState(this->threadNumber);
-    this->cpu->syscall(this->threadNumber, fault);
+    this->cpu->syscall(this->threadNumber);
     TheISA::PCState newPC = this->cpu->pcState(this->threadNumber);
     if (!(curPC == newPC)) {
         this->pcState(newPC);
diff --git a/src/cpu/o3/thread_context.hh b/src/cpu/o3/thread_context.hh
index f710613..e3e11fe 100644
--- a/src/cpu/o3/thread_context.hh
+++ b/src/cpu/o3/thread_context.hh
@@ -421,9 +421,9 @@
 
     /** Executes a syscall in SE mode. */
     void
-    syscall(Fault *fault) override
+    syscall() override
     {
-        return cpu->syscall(thread->threadId(), fault);
+        return cpu->syscall(thread->threadId());
     }
 
     /** Reads the funcExeInst counter. */
diff --git a/src/cpu/o3/thread_state.hh b/src/cpu/o3/thread_state.hh
index 757671a..6420da9 100644
--- a/src/cpu/o3/thread_state.hh
+++ b/src/cpu/o3/thread_state.hh
@@ -127,10 +127,7 @@
     ThreadContext *getTC() { return tc; }
 
     /** Handles the syscall. */
-    void syscall(Fault *fault)
-    {
-        process->syscall(tc, fault);
-    }
+    void syscall() { process->syscall(tc); }
 };
 
 #endif // __CPU_O3_THREAD_STATE_HH__
diff --git a/src/cpu/simple/exec_context.hh b/src/cpu/simple/exec_context.hh
index e7c59c0..5214211 100644
--- a/src/cpu/simple/exec_context.hh
+++ b/src/cpu/simple/exec_context.hh
@@ -494,11 +494,7 @@
     /**
      * Executes a syscall specified by the callnum.
      */
-    void
-    syscall(Fault *fault) override
-    {
-        thread->syscall(fault);
-    }
+    void syscall() override { thread->syscall(); }
 
     /** Returns a pointer to the ThreadContext. */
     ThreadContext *tcBase() const override { return thread->getTC(); }
diff --git a/src/cpu/simple_thread.hh b/src/cpu/simple_thread.hh
index 8a2f227..2c78573 100644
--- a/src/cpu/simple_thread.hh
+++ b/src/cpu/simple_thread.hh
@@ -576,11 +576,7 @@
         return ThreadState::readFuncExeInst();
     }
 
-    void
-    syscall(Fault *fault) override
-    {
-        process->syscall(this, fault);
-    }
+    void syscall() override { process->syscall(this); }
 
     RegVal readIntRegFlat(RegIndex idx) const override { return intRegs[idx]; }
     void
diff --git a/src/cpu/thread_context.hh b/src/cpu/thread_context.hh
index 8ca2c50..6662502 100644
--- a/src/cpu/thread_context.hh
+++ b/src/cpu/thread_context.hh
@@ -293,7 +293,7 @@
     // Same with st cond failures.
     virtual Counter readFuncExeInst() const = 0;
 
-    virtual void syscall(Fault *fault) = 0;
+    virtual void syscall() = 0;
 
     // This function exits the thread context in the CPU and returns
     // 1 if the CPU has no more active threads (meaning it's OK to exit);
diff --git a/src/sim/process.hh b/src/sim/process.hh
index 0add01a..449e0a5 100644
--- a/src/sim/process.hh
+++ b/src/sim/process.hh
@@ -75,7 +75,7 @@
     void initState() override;
     DrainState drain() override;
 
-    virtual void syscall(ThreadContext *tc, Fault *fault) { numSyscalls++; }
+    virtual void syscall(ThreadContext *tc) { numSyscalls++; }
 
     inline uint64_t uid() { return _uid; }
     inline uint64_t euid() { return _euid; }
diff --git a/src/sim/pseudo_inst.cc b/src/sim/pseudo_inst.cc
index 4cbe87c..7335fda 100644
--- a/src/sim/pseudo_inst.cc
+++ b/src/sim/pseudo_inst.cc
@@ -479,8 +479,7 @@
 m5Syscall(ThreadContext *tc)
 {
     DPRINTF(PseudoInst, "PseudoInst::m5Syscall()\n");
-    Fault fault;
-    tc->syscall(&fault);
+    tc->syscall();
 }
 
 void
diff --git a/src/sim/syscall_desc.cc b/src/sim/syscall_desc.cc
index d2e2749..2658717 100644
--- a/src/sim/syscall_desc.cc
+++ b/src/sim/syscall_desc.cc
@@ -35,7 +35,7 @@
 class ThreadContext;
 
 void
-SyscallDesc::doSyscall(ThreadContext *tc, Fault *fault)
+SyscallDesc::doSyscall(ThreadContext *tc)
 {
     DPRINTF_SYSCALL(Base, "Calling %s...\n", dumper(name(), tc));
 
diff --git a/src/sim/syscall_desc.hh b/src/sim/syscall_desc.hh
index 53e3ccd..2fd2434 100644
--- a/src/sim/syscall_desc.hh
+++ b/src/sim/syscall_desc.hh
@@ -71,7 +71,7 @@
      * to add filters for behaviors or apply checks for all system calls.
      * @param tc Handle for owning ThreadContext to pass information
      */
-    void doSyscall(ThreadContext *tc, Fault *fault);
+    void doSyscall(ThreadContext *tc);
 
     std::string name() const { return _name; }
     int num() const { return _num; }