changeset cfad34a15729 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=cfad34a15729
description:
syscall_emul: remove mmapFlagTable
After all this it turns out we don't even use it.
diffstat:
src/arch/alpha/linux/linux.hh | 3 --
src/arch/arm/linux/linux.hh | 3 --
src/arch/mips/linux/linux.hh | 3 --
src/arch/power/linux/linux.hh | 3 --
src/arch/sparc/linux/linux.hh | 3 --
src/arch/x86/linux/linux.hh | 3 --
src/kern/linux/flag_tables.hh | 46 +------------------------------------------
7 files changed, 1 insertions(+), 63 deletions(-)
diffs (138 lines):
diff -r 3d47d83a48eb -r cfad34a15729 src/arch/alpha/linux/linux.hh
--- a/src/arch/alpha/linux/linux.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/arch/alpha/linux/linux.hh Fri Apr 01 16:38:16 2016 -0700
@@ -103,9 +103,6 @@
static const int TGT_O_PATH = 040000000; //!< O_PATH
//@}
- /// For mmap().
- static SyscallFlagTransTable mmapFlagTable[];
-
static const unsigned TGT_MAP_SHARED = 0x000001;
static const unsigned TGT_MAP_PRIVATE = 0x000002;
static const unsigned TGT_MAP_ANON = 0x000010;
diff -r 3d47d83a48eb -r cfad34a15729 src/arch/arm/linux/linux.hh
--- a/src/arch/arm/linux/linux.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/arch/arm/linux/linux.hh Fri Apr 01 16:38:16 2016 -0700
@@ -124,9 +124,6 @@
static const int TGT_O_PATH = 010000000; //!< O_PATH
//@}
- /// For mmap().
- static SyscallFlagTransTable mmapFlagTable[];
-
static const unsigned TGT_MAP_SHARED = 0x00001;
static const unsigned TGT_MAP_PRIVATE = 0x00002;
static const unsigned TGT_MAP_ANON = 0x00020;
diff -r 3d47d83a48eb -r cfad34a15729 src/arch/mips/linux/linux.hh
--- a/src/arch/mips/linux/linux.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/arch/mips/linux/linux.hh Fri Apr 01 16:38:16 2016 -0700
@@ -102,9 +102,6 @@
static const int TGT_O_PATH = 0x00200000; //!< O_PATH
//@}
- /// For mmap().
- static SyscallFlagTransTable mmapFlagTable[];
-
static const unsigned TGT_MAP_SHARED = 0x00001;
static const unsigned TGT_MAP_PRIVATE = 0x00002;
static const unsigned TGT_MAP_ANON = 0x00800;
diff -r 3d47d83a48eb -r cfad34a15729 src/arch/power/linux/linux.hh
--- a/src/arch/power/linux/linux.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/arch/power/linux/linux.hh Fri Apr 01 16:38:16 2016 -0700
@@ -163,9 +163,6 @@
static const int TGT_O_PATH = 010000000; //!< O_PATH
//@}
- /// For mmap().
- static SyscallFlagTransTable mmapFlagTable[];
-
static const unsigned TGT_MAP_SHARED = 0x00001;
static const unsigned TGT_MAP_PRIVATE = 0x00002;
static const unsigned TGT_MAP_ANON = 0x00020;
diff -r 3d47d83a48eb -r cfad34a15729 src/arch/sparc/linux/linux.hh
--- a/src/arch/sparc/linux/linux.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/arch/sparc/linux/linux.hh Fri Apr 01 16:38:16 2016 -0700
@@ -119,9 +119,6 @@
static const int NUM_OPEN_FLAGS;
- /// For mmap().
- static SyscallFlagTransTable mmapFlagTable[];
-
static const unsigned TGT_MAP_SHARED = 0x00001;
static const unsigned TGT_MAP_PRIVATE = 0x00002;
static const unsigned TGT_MAP_ANON = 0x00020;
diff -r 3d47d83a48eb -r cfad34a15729 src/arch/x86/linux/linux.hh
--- a/src/arch/x86/linux/linux.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/arch/x86/linux/linux.hh Fri Apr 01 16:38:16 2016 -0700
@@ -126,9 +126,6 @@
static const int NUM_OPEN_FLAGS;
- /// For mmap().
- static SyscallFlagTransTable mmapFlagTable[];
-
static const unsigned TGT_MAP_SHARED = 0x00001;
static const unsigned TGT_MAP_PRIVATE = 0x00002;
static const unsigned TGT_MAP_32BIT = 0x00040;
diff -r 3d47d83a48eb -r cfad34a15729 src/kern/linux/flag_tables.hh
--- a/src/kern/linux/flag_tables.hh Fri Apr 01 16:38:15 2016 -0700
+++ b/src/kern/linux/flag_tables.hh Fri Apr 01 16:38:16 2016 -0700
@@ -46,7 +46,7 @@
* @file flag_tables.hh
*
* This file contains definitions of flag translation tables for the
- * open() and mmap() system calls. Since the tables are nearly identical
+ * open() system call. Since the tables are nearly identical
* across target platforms (other than the values of the target flags),
* we use a single copy of the tables but include it separately for
* each target platform. The TARGET macro must be #defined before including
@@ -110,47 +110,3 @@
const int TARGET::NUM_OPEN_FLAGS =
sizeof(TARGET::openFlagTable) / sizeof(TARGET::openFlagTable[0]);
-
-// mmap(2) flags translation table
-SyscallFlagTransTable TARGET::mmapFlagTable[] = {
- { TARGET::TGT_MAP_SHARED, MAP_SHARED },
- { TARGET::TGT_MAP_PRIVATE, MAP_PRIVATE },
- { TARGET::TGT_MAP_FIXED, MAP_FIXED },
- { TARGET::TGT_MAP_ANONYMOUS, MAP_ANONYMOUS },
- { TARGET::TGT_MAP_ANON, MAP_ANON },
- { TARGET::TGT_MAP_FILE, MAP_FILE },
-#if defined(MAP_32BIT) && defined(TARGET_HAS_MAP_32BIT)
- { TARGET::TGT_MAP_32BIT, MAP_32BIT },
-#endif
-#ifdef MAP_DENYWRITE
- { TARGET::TGT_MAP_DENYWRITE, MAP_DENYWRITE },
-#endif
-#ifdef MAP_EXECUTABLE
- { TARGET::TGT_MAP_EXECUTABLE, MAP_EXECUTABLE },
-#endif
-#ifdef MAP_GROWSDOWN
- { TARGET::TGT_MAP_GROWSDOWN, MAP_GROWSDOWN },
-#endif
-#ifdef MAP_HUGETLB
- { TARGET::TGT_MAP_HUGETLB, MAP_HUGETLB },
-#endif
-#ifdef MAP_LOCKED
- { TARGET::TGT_MAP_LOCKED, MAP_LOCKED },
-#endif
-#ifdef MAP_NONBLOCK
- { TARGET::TGT_MAP_NONBLOCK, MAP_NONBLOCK },
-#endif
-#ifdef MAP_NORESERVE
- { TARGET::TGT_MAP_NORESERVE, MAP_NORESERVE },
-#endif
-#ifdef MAP_POPULATE
- { TARGET::TGT_MAP_POPULATE, MAP_POPULATE },
-#endif
-#ifdef MAP_STACK
- { TARGET::TGT_MAP_STACK, MAP_STACK },
-#endif
-};
-
-const unsigned TARGET::NUM_MMAP_FLAGS =
- sizeof(TARGET::mmapFlagTable) / sizeof(TARGET::mmapFlagTable[0]);
-
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev