]> granicus.if.org Git - strace/commitdiff
xlat: cleanup mmap_flags.in
authorEugene Syromyatnikov <evgsyr@gmail.com>
Thu, 8 Mar 2018 16:55:01 +0000 (17:55 +0100)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 27 Mar 2018 22:22:23 +0000 (22:22 +0000)
* xlat/mmap_flags.in (_MAP_NEW): Remove SunOS-specific comment, add
a comment that this is a SPARC-specific constant (from
arch/sparc/include/uapi/asm/mman.h).
(MAP_GROWSUP): IA-64-specific constant (from
arch/ia64/include/uapi/asm/mman.h).
(MAP_INHERIT): Add a comment that this is a SPARC-specific constant
(from arch/sparc/include/uapi/asm/mman.h).
(_MAP_INHERIT): Add a comment that this is an Alpha-specific constant
(from arch/alpha/include/uapi/asm/mman.h).
(MAP_ANON): Remove, FreeBSD-specific constant.
(MAP_HASSEMAPHORE): Rename to...
(_MAP_HASSEMAPHORE): ...this, add a comment that this is an
Alpha-specific constant (from arch/alpha/include/uapi/asm/mman.h).
(MAP_NOSYNC, MAP_NOCORE): Remove.
(MAP_AUTOGROW, MAP_AUTORSRV, MAP_LOCAL): Add a comment that this is
an architecture-specific constant (from
arch/mips/include/uapi/asm/mman.h, arch/xtensa/include/uapi/asm/mman.h).
(_MAP_UNALIGNED): Add a comment that this is an Alpha-specific constant
(from arch/alpha/include/uapi/asm/mman.h).

xlat/mmap_flags.in

index ff284e28c1b32485123c08fd663fc732d30e5225..5b05e611132d1b4ff9af029f6a7e29cefbd14bbd 100644 (file)
@@ -8,50 +8,23 @@ MAP_RENAME
 MAP_NORESERVE
 MAP_POPULATE
 MAP_NONBLOCK
-/*
- * XXX - this was introduced in SunOS 4.x to distinguish between
- * the old pre-4.x "mmap()", which:
- *
- *     only let you map devices with an "mmap" routine (e.g.,
- *     frame buffers) in;
- *
- *     required you to specify the mapping address;
- *
- *     returned 0 on success and -1 on failure;
- *
- * memory and which, and the 4.x "mmap()" which:
- *
- *     can map plain files;
- *
- *     can be asked to pick where to map the file;
- *
- *     returns the address where it mapped the file on success
- *     and -1 on failure.
- *
- * It's not actually used in source code that calls "mmap()"; the
- * "mmap()" routine adds it for you.
- *
- * It'd be nice to come up with some way of eliminating it from
- * the flags, e.g. reporting calls *without* it as "old_mmap()"
- * and calls with it as "mmap()".
- */
-_MAP_NEW
+_MAP_NEW /* sparc */
 MAP_GROWSDOWN
+MAP_GROWSUP /* ia64 */
 MAP_DENYWRITE
 MAP_EXECUTABLE
-MAP_INHERIT
+MAP_INHERIT /* sparc */
+_MAP_INHERIT /* alpha */
 MAP_FILE
 MAP_LOCKED
-/* FreeBSD ones */
-#if defined(MAP_ANON) && (!defined(MAP_ANONYMOUS) || MAP_ANON != MAP_ANONYMOUS)
-MAP_ANON
-#endif
-MAP_HASSEMAPHORE
+_MAP_HASSEMAPHORE /* alpha */
 MAP_STACK
 MAP_HUGETLB
 MAP_SYNC
 #if defined MAP_UNINITIALIZED && MAP_UNINITIALIZED > 0
 MAP_UNINITIALIZED
 #endif
-MAP_NOSYNC
-MAP_NOCORE
+MAP_AUTOGROW /* MIPS, xtensa */
+MAP_AUTORSRV /* MIPS, xtensa */
+MAP_LOCAL /* MIPS, xtensa */
+_MAP_UNALIGNED /* alpha */