arch-arm: Do not check MustBeOne flag for TLB requests from the prefetcher
[gem5.git] / src / sim / syscall_desc.hh
index 37aaad14d05afc9f81439d0e48b6c7e70e22f190..451db084bb15a45b6996b18d85a996ad78c2193b 100644 (file)
 
 #include <string>
 
+#include "base/types.hh"
+
 class Process;
+class SyscallDesc;
 class SyscallReturn;
 class ThreadContext;
 
+SyscallReturn unimplementedFunc(SyscallDesc *desc, int num,
+    Process *p, ThreadContext *tc);
+
 /**
  * This class provides the wrapper interface for the system call
  * implementations which are defined in the sim/syscall_emul files and
@@ -64,7 +70,8 @@ class SyscallDesc {
     typedef SyscallReturn (*SyscallExecutor)(SyscallDesc*, int num,
                                              Process*, ThreadContext*);
 
-    SyscallDesc(const char *name, SyscallExecutor sys_exec, int flags = 0)
+    SyscallDesc(const char *name,
+                SyscallExecutor sys_exec=unimplementedFunc, int flags=0)
         : _name(name), executor(sys_exec), _flags(flags), _warned(false)
     {
     }
@@ -91,7 +98,8 @@ class SyscallDesc {
      * @param proc Handle for the owning Process to pass information
      * @param tc Handle for owning ThreadContext to pass information
      */
-    void doSyscall(int callnum, Process *proc, ThreadContext *tc);
+    void doSyscall(int callnum, Process *proc, ThreadContext *tc,
+                   Fault *fault);
 
     /**
      * Return false if WarnOnce is set and a warning has already been issued.
@@ -104,6 +112,10 @@ class SyscallDesc {
 
     std::string name() { return _name; }
 
+    int getFlags() const { return _flags; }
+
+    void setFlags(int flags) { _flags = flags; }
+
   private:
     /** System call name (e.g., open, mmap, clone, socket, etc.) */
     std::string _name;