From: Joseph Myers <joseph@codesourcery.com>
To: <libc-alpha@sourceware.org>
Subject: Add SHM_HUGETLB, SHM_NORESERVE to bits/shm.h
Date: Thu, 16 Nov 2017 21:14:00 -0000 [thread overview]
Message-ID: <alpine.DEB.2.20.1711162113380.14274@digraph.polyomino.org.uk> (raw)
Linux 4.14 adds SHM_HUGETLB and SHM_NORESERVE to
include/uapi/linux/shm.h. (These macros previously existed in the
kernel, but in the non-UAPI header.) This patch adds them to
bits/shm.h accordingly.
Tested for x86_64, and with build-many-glibcs.py.
2017-11-16 Joseph Myers <joseph@codesourcery.com>
* sysdeps/unix/sysv/linux/bits/shm.h (SHM_HUGETLB): New macro.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/alpha/bits/shm.h (SHM_HUGETLB):
Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/arm/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/generic/bits/shm.h (SHM_HUGETLB):
Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/hppa/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/ia64/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/mips/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/powerpc/bits/shm.h (SHM_HUGETLB):
Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/s390/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/sh/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/shm.h (SHM_HUGETLB):
Likewise.
(SHM_NORESERVE): Likewise.
* sysdeps/unix/sysv/linux/x86/bits/shm.h (SHM_HUGETLB): Likewise.
(SHM_NORESERVE): Likewise.
diff --git a/sysdeps/unix/sysv/linux/alpha/bits/shm.h b/sysdeps/unix/sysv/linux/alpha/bits/shm.h
index d628dcf..4c9dd05 100644
--- a/sysdeps/unix/sysv/linux/alpha/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/alpha/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/arm/bits/shm.h b/sysdeps/unix/sysv/linux/arm/bits/shm.h
index 2448ffd..c2ffbc4 100644
--- a/sysdeps/unix/sysv/linux/arm/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/arm/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/bits/shm.h b/sysdeps/unix/sysv/linux/bits/shm.h
index f8f593c..c73f090 100644
--- a/sysdeps/unix/sysv/linux/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/generic/bits/shm.h b/sysdeps/unix/sysv/linux/generic/bits/shm.h
index 057b85c..2e160ad 100644
--- a/sysdeps/unix/sysv/linux/generic/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/generic/bits/shm.h
@@ -23,9 +23,11 @@
#include <bits/types.h>
#include <bits/wordsize.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/hppa/bits/shm.h b/sysdeps/unix/sysv/linux/hppa/bits/shm.h
index 495dae8..9f07f3a 100644
--- a/sysdeps/unix/sysv/linux/hppa/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/hppa/bits/shm.h
@@ -22,9 +22,11 @@
#include <bits/types.h>
#include <bits/wordsize.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/ia64/bits/shm.h b/sysdeps/unix/sysv/linux/ia64/bits/shm.h
index add8a60..ec44a48 100644
--- a/sysdeps/unix/sysv/linux/ia64/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/ia64/bits/shm.h
@@ -21,9 +21,11 @@
#include <sys/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/mips/bits/shm.h b/sysdeps/unix/sysv/linux/mips/bits/shm.h
index 20a02ce..d09d093 100644
--- a/sysdeps/unix/sysv/linux/mips/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/mips/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/powerpc/bits/shm.h b/sysdeps/unix/sysv/linux/powerpc/bits/shm.h
index 3812e73..a7bcacd 100644
--- a/sysdeps/unix/sysv/linux/powerpc/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/powerpc/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/s390/bits/shm.h b/sysdeps/unix/sysv/linux/s390/bits/shm.h
index 768b169..0c24d76 100644
--- a/sysdeps/unix/sysv/linux/s390/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/s390/bits/shm.h
@@ -22,9 +22,11 @@
#include <bits/types.h>
#include <bits/wordsize.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/sh/bits/shm.h b/sysdeps/unix/sysv/linux/sh/bits/shm.h
index d1f47ec..02750f4 100644
--- a/sysdeps/unix/sysv/linux/sh/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/sh/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/sparc/bits/shm.h b/sysdeps/unix/sysv/linux/sparc/bits/shm.h
index c7857cc..d995661 100644
--- a/sysdeps/unix/sysv/linux/sparc/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/sparc/bits/shm.h
@@ -22,9 +22,11 @@
#include <bits/types.h>
#include <bits/wordsize.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
diff --git a/sysdeps/unix/sysv/linux/x86/bits/shm.h b/sysdeps/unix/sysv/linux/x86/bits/shm.h
index 5f8e2e1..78a427b 100644
--- a/sysdeps/unix/sysv/linux/x86/bits/shm.h
+++ b/sysdeps/unix/sysv/linux/x86/bits/shm.h
@@ -21,9 +21,11 @@
#include <bits/types.h>
-/* Permission flag for shmget. */
+/* Flags for shmget. */
#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+#define SHM_HUGETLB 04000 /* Segment will use huge TLB pages. */
+#define SHM_NORESERVE 010000 /* Don't check for reservations. */
/* Flags for `shmat'. */
#define SHM_RDONLY 010000 /* attach read-only else read-write */
--
Joseph S. Myers
joseph@codesourcery.com
next reply other threads:[~2017-11-16 21:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-16 21:14 Joseph Myers [this message]
2017-11-16 21:32 ` Dmitry V. Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.DEB.2.20.1711162113380.14274@digraph.polyomino.org.uk \
--to=joseph@codesourcery.com \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).