syzkaller/sys/netbsd/mm_amd64.const
Dmitry Vyukov ecb386fe6f sys: check that target consts are defined
Currently when we get target consts with target.ConstMap["name"]
during target initialization, we just get 0 for missing consts.
This is error-prone as we can mis-type a const, or a const may
be undefined only on some archs (as we have common unix code
shared between several OSes).
Check that all the consts are actually defined.
The check detects several violations, to fix them:
1. move mremap to linux as it's only defined on linux
2. move S_IFMT to openbsd, as it's only defined and used on openbsd
3. define missing MAP_ANONYMOUS for freebsd and netbsd
4. fix extract for netbsd
2018-10-19 19:11:22 +01:00

32 lines
525 B
Plaintext

# AUTOGENERATED FILE
MADV_DONTNEED = 4
MADV_FREE = 6
MADV_NORMAL = 0
MADV_RANDOM = 1
MADV_SEQUENTIAL = 2
MADV_WILLNEED = 3
MAP_ANON = 4096
MAP_ANONYMOUS = 4096
MAP_FILE = 0
MAP_FIXED = 16
MAP_HASSEMAPHORE = 512
MAP_INHERIT = 128
MAP_PRIVATE = 2
MAP_SHARED = 1
MAP_TRYFIXED = 1024
MAP_WIRED = 2048
MCL_CURRENT = 1
MCL_FUTURE = 2
PROT_EXEC = 4
PROT_NONE = 0
PROT_READ = 1
PROT_WRITE = 2
SYS_madvise = 75
SYS_mlock = 203
SYS_mlockall = 242
SYS_mmap = 197
SYS_mprotect = 74
SYS_munlock = 204
SYS_munlockall = 243
SYS_munmap = 73