#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
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)
{
}
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;