Andrea Mondelli has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/18668

Change subject: sim-se: correct statfs inclusion on !linux host
......................................................................

sim-se: correct statfs inclusion on !linux host

Added missing header
Fixed typo on __linux__ macro conditional

Change-Id: I83b69856e5ec8b23b707642c0e14216cf62db31e
---
M src/sim/syscall_emul.cc
M src/sim/syscall_emul.hh
2 files changed, 4 insertions(+), 1 deletion(-)



diff --git a/src/sim/syscall_emul.cc b/src/sim/syscall_emul.cc
index 98fbe96..1e11950 100644
--- a/src/sim/syscall_emul.cc
+++ b/src/sim/syscall_emul.cc
@@ -1039,7 +1039,7 @@
 SyscallReturn
fallocateFunc(SyscallDesc *desc, int callnum, Process *p, ThreadContext *tc)
 {
-#if __linux__
+#ifdef __linux__
     int index = 0;
     int tgt_fd = p->getSyscallArg(tc, index);
     int mode = p->getSyscallArg(tc, index);
diff --git a/src/sim/syscall_emul.hh b/src/sim/syscall_emul.hh
index 91db9ae..97cc144 100644
--- a/src/sim/syscall_emul.hh
+++ b/src/sim/syscall_emul.hh
@@ -63,6 +63,9 @@
 #include <sys/eventfd.h>
 #include <sys/statfs.h>

+#else
+#include <sys/mount.h>
+
 #endif

 #ifdef __CYGWIN32__

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

Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-Change-Id: I83b69856e5ec8b23b707642c0e14216cf62db31e
Gerrit-Change-Number: 18668
Gerrit-PatchSet: 1
Gerrit-Owner: Andrea Mondelli <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to