Commit c45a08e5 authored by Albert Strasheim's avatar Albert Strasheim Committed by Russ Cox

syscall: Add DT_* and MADV_* constants on Linux.

R=rsc, agl1
CC=golang-dev
https://golang.org/cl/4370041
parent cf56f06a
......@@ -119,7 +119,7 @@ done
$2 ~ /^E[A-Z0-9_]+$/ ||
$2 ~ /^SIG[^_]/ ||
$2 ~ /^IN_/ ||
$2 ~ /^(AF|SOCK|SO|SOL|IPPROTO|IP|IPV6|TCP|EVFILT|EV|SHUT|PROT|MAP|PACKET|MSG|SCM|MCL)_/ ||
$2 ~ /^(AF|SOCK|SO|SOL|IPPROTO|IP|IPV6|TCP|EVFILT|EV|SHUT|PROT|MAP|PACKET|MSG|SCM|MCL|DT|MADV)_/ ||
$2 == "SOMAXCONN" ||
$2 == "NAME_MAX" ||
$2 == "IFNAMSIZ" ||
......
......@@ -48,6 +48,15 @@ const (
AF_UNSPEC = 0
AF_WANPIPE = 0x19
AF_X25 = 0x9
DT_BLK = 0x6
DT_CHR = 0x2
DT_DIR = 0x4
DT_FIFO = 0x1
DT_LNK = 0xa
DT_REG = 0x8
DT_SOCK = 0xc
DT_UNKNOWN = 0
DT_WHT = 0xe
E2BIG = 0x7
EACCES = 0xd
EADDRINUSE = 0x62
......@@ -418,6 +427,17 @@ const (
LINUX_REBOOT_CMD_SW_SUSPEND = 0xd000fce2
LINUX_REBOOT_MAGIC1 = 0xfee1dead
LINUX_REBOOT_MAGIC2 = 0x28121969
MADV_DOFORK = 0xb
MADV_DONTFORK = 0xa
MADV_DONTNEED = 0x4
MADV_HWPOISON = 0x64
MADV_MERGEABLE = 0xc
MADV_NORMAL = 0
MADV_RANDOM = 0x1
MADV_REMOVE = 0x9
MADV_SEQUENTIAL = 0x2
MADV_UNMERGEABLE = 0xd
MADV_WILLNEED = 0x3
MAP_32BIT = 0x40
MAP_ANON = 0x20
MAP_ANONYMOUS = 0x20
......
......@@ -48,6 +48,15 @@ const (
AF_UNSPEC = 0
AF_WANPIPE = 0x19
AF_X25 = 0x9
DT_BLK = 0x6
DT_CHR = 0x2
DT_DIR = 0x4
DT_FIFO = 0x1
DT_LNK = 0xa
DT_REG = 0x8
DT_SOCK = 0xc
DT_UNKNOWN = 0
DT_WHT = 0xe
E2BIG = 0x7
EACCES = 0xd
EADDRINUSE = 0x62
......@@ -418,6 +427,17 @@ const (
LINUX_REBOOT_CMD_SW_SUSPEND = 0xd000fce2
LINUX_REBOOT_MAGIC1 = 0xfee1dead
LINUX_REBOOT_MAGIC2 = 0x28121969
MADV_DOFORK = 0xb
MADV_DONTFORK = 0xa
MADV_DONTNEED = 0x4
MADV_HWPOISON = 0x64
MADV_MERGEABLE = 0xc
MADV_NORMAL = 0
MADV_RANDOM = 0x1
MADV_REMOVE = 0x9
MADV_SEQUENTIAL = 0x2
MADV_UNMERGEABLE = 0xd
MADV_WILLNEED = 0x3
MAP_32BIT = 0x40
MAP_ANON = 0x20
MAP_ANONYMOUS = 0x20
......
// mksysnum_linux.sh /usr/include/asm/unistd_32.h
// mksysnum_linux.pl /usr/include/asm/unistd_32.h
// MACHINE GENERATED BY THE ABOVE COMMAND; DO NOT EDIT
package syscall
......
// mksysnum_linux.sh /usr/include/asm/unistd_64.h
// mksysnum_linux.pl /usr/include/asm/unistd_64.h
// MACHINE GENERATED BY THE ABOVE COMMAND; DO NOT EDIT
package syscall
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment