Alec Roelke has submitted this change and it was merged. ( https://gem5-review.googlesource.com/5501 )

Change subject: sim-se: Add default to SyscallDesc constructor
......................................................................

sim-se: Add default to SyscallDesc constructor

This patch adds a default value of unimplementedFunc to SyscallDesc's
constructor's second argument, which makes adding system call
placeholders to SE mode cleaner.

Change-Id: I3e7efb3a887cc52d16d2095d3dd2e2a96fb882fb
Reviewed-on: https://gem5-review.googlesource.com/5501
Reviewed-by: Gabe Black <gabebl...@google.com>
Maintainer: Brandon Potter <brandon.pot...@amd.com>
---
M src/sim/syscall_desc.hh
1 file changed, 6 insertions(+), 1 deletion(-)

Approvals:
  Gabe Black: Looks good to me, approved
  Brandon Potter: Looks good to me, approved



diff --git a/src/sim/syscall_desc.hh b/src/sim/syscall_desc.hh
index d72803e..451db08 100644
--- a/src/sim/syscall_desc.hh
+++ b/src/sim/syscall_desc.hh
@@ -51,9 +51,13 @@
 #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
@@ -66,7 +70,8 @@
     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)
     {
     }

--
To view, visit https://gem5-review.googlesource.com/5501
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I3e7efb3a887cc52d16d2095d3dd2e2a96fb882fb
Gerrit-Change-Number: 5501
Gerrit-PatchSet: 2
Gerrit-Owner: Alec Roelke <ar...@virginia.edu>
Gerrit-Reviewer: Alec Roelke <ar...@virginia.edu>
Gerrit-Reviewer: Brandon Potter <brandon.pot...@amd.com>
Gerrit-Reviewer: Gabe Black <gabebl...@google.com>
_______________________________________________
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to