CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
python3: updated to 3.9.10
[ports/core-arm.git] / glibc / glibc-2.32-2.patch
CommitLineData
31dbf41c
VM
1diff --git a/NEWS b/NEWS
2index 485b8ddffa..3030735839 100644
3--- a/NEWS
4+++ b/NEWS
5@@ -5,6 +5,17 @@ See the end for copying conditions.
6 Please send GNU C library bug reports via <https://sourceware.org/bugzilla/>
7 using `glibc' in the "product" field.
8 \f
9+The following bugs are resolved with this release:
10+
11+ [26534] libm.so 2.32 SIGILL in pow() due to FMA4 instruction on non-FMA4
12+ system
13+ [26555] string: strerrorname_np does not return the documented value
14+ [26636] libc: 32-bit shmctl(IPC_INFO) crashes when shminfo struct is
15+ at the end of a memory mapping
16+ [26637] libc: semctl SEM_STAT_ANY fails to pass the buffer specified
17+ by the caller to the kernel
18+ [26639] libc: msgctl IPC_INFO and MSG_INFO return garbage
19+
20 Version 2.32
21
22 Major new features:
23diff --git a/iconv/Versions b/iconv/Versions
24index 8a5f4cf780..d51af52fa3 100644
25--- a/iconv/Versions
26+++ b/iconv/Versions
27@@ -6,7 +6,9 @@ libc {
28 GLIBC_PRIVATE {
29 # functions shared with iconv program
30 __gconv_get_alias_db; __gconv_get_cache; __gconv_get_modules_db;
31- __gconv_open; __gconv_create_spec;
32+
33+ # functions used elsewhere in glibc
34+ __gconv_open; __gconv_create_spec; __gconv_destroy_spec;
35
36 # function used by the gconv modules
37 __gconv_transliterate;
38diff --git a/iconv/gconv_charset.c b/iconv/gconv_charset.c
39index 6ccd0773cc..4ba0aa99f5 100644
40--- a/iconv/gconv_charset.c
41+++ b/iconv/gconv_charset.c
42@@ -216,3 +216,13 @@ out:
43 return ret;
44 }
45 libc_hidden_def (__gconv_create_spec)
46+
47+
48+void
49+__gconv_destroy_spec (struct gconv_spec *conv_spec)
50+{
51+ free (conv_spec->fromcode);
52+ free (conv_spec->tocode);
53+ return;
54+}
55+libc_hidden_def (__gconv_destroy_spec)
56diff --git a/iconv/gconv_charset.h b/iconv/gconv_charset.h
57index b39b09aea1..e9c122cf7e 100644
58--- a/iconv/gconv_charset.h
59+++ b/iconv/gconv_charset.h
60@@ -48,33 +48,6 @@
61 #define GCONV_IGNORE_ERRORS_SUFFIX "IGNORE"
62
63
64-/* This function accepts the charset names of the source and destination of the
65- conversion and populates *conv_spec with an equivalent conversion
66- specification that may later be used by __gconv_open. The charset names
67- might contain options in the form of suffixes that alter the conversion,
68- e.g. "ISO-10646/UTF-8/TRANSLIT". It processes the charset names, ignoring
69- and truncating any suffix options in fromcode, and processing and truncating
70- any suffix options in tocode. Supported suffix options ("TRANSLIT" or
71- "IGNORE") when found in tocode lead to the corresponding flag in *conv_spec
72- to be set to true. Unrecognized suffix options are silently discarded. If
73- the function succeeds, it returns conv_spec back to the caller. It returns
74- NULL upon failure. */
75-struct gconv_spec *
76-__gconv_create_spec (struct gconv_spec *conv_spec, const char *fromcode,
77- const char *tocode);
78-libc_hidden_proto (__gconv_create_spec)
79-
80-
81-/* This function frees all heap memory allocated by __gconv_create_spec. */
82-static void __attribute__ ((unused))
83-gconv_destroy_spec (struct gconv_spec *conv_spec)
84-{
85- free (conv_spec->fromcode);
86- free (conv_spec->tocode);
87- return;
88-}
89-
90-
91 /* This function copies in-order, characters from the source 's' that are
92 either alpha-numeric or one in one of these: "_-.,:/" - into the destination
93 'wp' while dropping all other characters. In the process, it converts all
94diff --git a/iconv/gconv_int.h b/iconv/gconv_int.h
95index e86938dae7..f721ce30ff 100644
96--- a/iconv/gconv_int.h
97+++ b/iconv/gconv_int.h
98@@ -152,6 +152,27 @@ extern int __gconv_open (struct gconv_spec *conv_spec,
99 __gconv_t *handle, int flags);
100 libc_hidden_proto (__gconv_open)
101
102+/* This function accepts the charset names of the source and destination of the
103+ conversion and populates *conv_spec with an equivalent conversion
104+ specification that may later be used by __gconv_open. The charset names
105+ might contain options in the form of suffixes that alter the conversion,
106+ e.g. "ISO-10646/UTF-8/TRANSLIT". It processes the charset names, ignoring
107+ and truncating any suffix options in fromcode, and processing and truncating
108+ any suffix options in tocode. Supported suffix options ("TRANSLIT" or
109+ "IGNORE") when found in tocode lead to the corresponding flag in *conv_spec
110+ to be set to true. Unrecognized suffix options are silently discarded. If
111+ the function succeeds, it returns conv_spec back to the caller. It returns
112+ NULL upon failure. */
113+extern struct gconv_spec *
114+__gconv_create_spec (struct gconv_spec *conv_spec, const char *fromcode,
115+ const char *tocode);
116+libc_hidden_proto (__gconv_create_spec)
117+
118+/* This function frees all heap memory allocated by __gconv_create_spec. */
119+extern void
120+__gconv_destroy_spec (struct gconv_spec *conv_spec);
121+libc_hidden_proto (__gconv_destroy_spec)
122+
123 /* Free resources associated with transformation descriptor CD. */
124 extern int __gconv_close (__gconv_t cd)
125 attribute_hidden;
126diff --git a/iconv/iconv_open.c b/iconv/iconv_open.c
127index dd54bc12e0..5b30055c04 100644
128--- a/iconv/iconv_open.c
129+++ b/iconv/iconv_open.c
130@@ -39,7 +39,7 @@ iconv_open (const char *tocode, const char *fromcode)
131
132 int res = __gconv_open (&conv_spec, &cd, 0);
133
134- gconv_destroy_spec (&conv_spec);
135+ __gconv_destroy_spec (&conv_spec);
136
137 if (__builtin_expect (res, __GCONV_OK) != __GCONV_OK)
138 {
139diff --git a/iconv/iconv_prog.c b/iconv/iconv_prog.c
140index b4334faa57..d59979759c 100644
141--- a/iconv/iconv_prog.c
142+++ b/iconv/iconv_prog.c
143@@ -184,7 +184,7 @@ main (int argc, char *argv[])
144 /* Let's see whether we have these coded character sets. */
145 res = __gconv_open (&conv_spec, &cd, 0);
146
147- gconv_destroy_spec (&conv_spec);
148+ __gconv_destroy_spec (&conv_spec);
149
150 if (res != __GCONV_OK)
151 {
152diff --git a/intl/dcigettext.c b/intl/dcigettext.c
153index 2e7c662bc7..bd332e71da 100644
154--- a/intl/dcigettext.c
155+++ b/intl/dcigettext.c
156@@ -1120,15 +1120,18 @@ _nl_find_msg (struct loaded_l10nfile *domain_file,
157
158 # ifdef _LIBC
159
160- struct gconv_spec conv_spec
161- = { .fromcode = norm_add_slashes (charset, ""),
162- .tocode = norm_add_slashes (outcharset, ""),
163- /* We always want to use transliteration. */
164- .translit = true,
165- .ignore = false
166- };
167+ struct gconv_spec conv_spec;
168+
169+ __gconv_create_spec (&conv_spec, charset, outcharset);
170+
171+ /* We always want to use transliteration. */
172+ conv_spec.translit = true;
173+
174 int r = __gconv_open (&conv_spec, &convd->conv,
175 GCONV_AVOID_NOCONV);
176+
177+ __gconv_destroy_spec (&conv_spec);
178+
179 if (__builtin_expect (r != __GCONV_OK, 0))
180 {
181 /* If the output encoding is the same there is
182diff --git a/intl/tst-codeset.c b/intl/tst-codeset.c
183index fd70432eca..e9f6e5e09f 100644
184--- a/intl/tst-codeset.c
185+++ b/intl/tst-codeset.c
186@@ -22,13 +22,11 @@
187 #include <stdio.h>
188 #include <stdlib.h>
189 #include <string.h>
190+#include <support/check.h>
191
192 static int
193 do_test (void)
194 {
195- char *s;
196- int result = 0;
197-
198 unsetenv ("LANGUAGE");
199 unsetenv ("OUTPUT_CHARSET");
200 setlocale (LC_ALL, "de_DE.ISO-8859-1");
201@@ -36,25 +34,21 @@ do_test (void)
202 bindtextdomain ("codeset", OBJPFX "domaindir");
203
204 /* Here we expect output in ISO-8859-1. */
205- s = gettext ("cheese");
206- if (strcmp (s, "K\344se"))
207- {
208- printf ("call 1 returned: %s\n", s);
209- result = 1;
210- }
211+ TEST_COMPARE_STRING (gettext ("cheese"), "K\344se");
212
213+ /* Here we expect output in UTF-8. */
214 bind_textdomain_codeset ("codeset", "UTF-8");
215+ TEST_COMPARE_STRING (gettext ("cheese"), "K\303\244se");
216
217- /* Here we expect output in UTF-8. */
218- s = gettext ("cheese");
219- if (strcmp (s, "K\303\244se"))
220- {
221- printf ("call 2 returned: %s\n", s);
222- result = 1;
223- }
224-
225- return result;
226+ /* `a with umlaut' is transliterated to `ae'. */
227+ bind_textdomain_codeset ("codeset", "ASCII//TRANSLIT");
228+ TEST_COMPARE_STRING (gettext ("cheese"), "Kaese");
229+
230+ /* Transliteration also works by default even if not set. */
231+ bind_textdomain_codeset ("codeset", "ASCII");
232+ TEST_COMPARE_STRING (gettext ("cheese"), "Kaese");
233+
234+ return 0;
235 }
236
237-#define TEST_FUNCTION do_test ()
238-#include "../test-skeleton.c"
239+#include <support/test-driver.c>
240diff --git a/stdio-common/Makefile b/stdio-common/Makefile
241index 8475fd1f09..eff0c98d82 100644
242--- a/stdio-common/Makefile
243+++ b/stdio-common/Makefile
244@@ -69,7 +69,8 @@ tests := tstscanf test_rdwr test-popen tstgetln test-fseek \
245 tst-printf-bz25691 \
246 tst-vfprintf-width-prec-alloc \
247 tst-printf-fp-free \
248- tst-printf-fp-leak
249+ tst-printf-fp-leak \
250+ test-strerr
251
252
253 test-srcs = tst-unbputc tst-printf tst-printfsz-islongdouble
254diff --git a/stdio-common/errlist.c b/stdio-common/errlist.c
255index d15f13a22a..2ecf121674 100644
256--- a/stdio-common/errlist.c
257+++ b/stdio-common/errlist.c
258@@ -20,9 +20,13 @@
259 #include <libintl.h>
260 #include <array_length.h>
261
262+#ifndef ERR_MAP
263+# define ERR_MAP(n) n
264+#endif
265+
266 const char *const _sys_errlist_internal[] =
267 {
268-#define _S(n, str) [n] = str,
269+#define _S(n, str) [ERR_MAP(n)] = str,
270 #include <errlist.h>
271 #undef _S
272 };
273@@ -41,20 +45,21 @@ static const union sys_errname_t
274 {
275 #define MSGSTRFIELD1(line) str##line
276 #define MSGSTRFIELD(line) MSGSTRFIELD1(line)
277-#define _S(n, str) char MSGSTRFIELD(__LINE__)[sizeof(str)];
278+#define _S(n, str) char MSGSTRFIELD(__LINE__)[sizeof(#n)];
279 #include <errlist.h>
280 #undef _S
281 };
282 char str[0];
283 } _sys_errname = { {
284-#define _S(n, s) s,
285+#define _S(n, s) #n,
286 #include <errlist.h>
287 #undef _S
288 } };
289
290 static const unsigned short _sys_errnameidx[] =
291 {
292-#define _S(n, s) [n] = offsetof(union sys_errname_t, MSGSTRFIELD(__LINE__)),
293+#define _S(n, s) \
294+ [ERR_MAP(n)] = offsetof(union sys_errname_t, MSGSTRFIELD(__LINE__)),
295 #include <errlist.h>
296 #undef _S
297 };
298diff --git a/stdio-common/test-strerr.c b/stdio-common/test-strerr.c
299index fded208118..d77b81d507 100644
300--- a/stdio-common/test-strerr.c
301+++ b/stdio-common/test-strerr.c
302@@ -18,46 +18,672 @@
303
304 #include <string.h>
305 #include <errno.h>
306-#include <array_length.h>
307
308 #include <support/support.h>
309 #include <support/check.h>
310
311-#define N_(name) name
312-
313-static const char *const errlist[] =
314- {
315-/* This file is auto-generated from errlist.def. */
316-#include <errlist.h>
317- };
318-
319-#define MSGSTR_T errname_t
320-#define MSGSTR errname
321-#define MSGIDX errnameidx
322-#include <errlist-name.h>
323-#undef MSGSTR
324-#undef MSGIDX
325-
326 static int
327 do_test (void)
328 {
329- TEST_VERIFY (strerrordesc_np (-1) == NULL);
330- TEST_VERIFY (strerrordesc_np (array_length (errlist)) == NULL);
331- for (size_t i = 0; i < array_length (errlist); i++)
332- {
333- if (errlist[i] == NULL)
334- continue;
335- TEST_COMPARE_STRING (strerrordesc_np (i), errlist[i]);
336- }
337+ TEST_COMPARE_STRING (strerrordesc_np (0), "Success");
338+ TEST_COMPARE_STRING (strerrorname_np (0), "0");
339
340- TEST_VERIFY (strerrorname_np (-1) == NULL);
341- TEST_VERIFY (strerrorname_np (array_length (errlist)) == NULL);
342- for (size_t i = 0; i < array_length (errlist); i++)
343- {
344- if (errlist[i] == NULL)
345- continue;
346- TEST_COMPARE_STRING (strerrorname_np (i), errname.str + errnameidx[i]);
347- }
348+#ifdef EPERM
349+ TEST_COMPARE_STRING (strerrordesc_np (EPERM), "Operation not permitted");
350+ TEST_COMPARE_STRING (strerrorname_np (EPERM), "EPERM");
351+#endif
352+#ifdef ENOENT
353+ TEST_COMPARE_STRING (strerrordesc_np (ENOENT),
354+ "No such file or directory");
355+ TEST_COMPARE_STRING (strerrorname_np (ENOENT), "ENOENT");
356+#endif
357+#ifdef ESRCH
358+ TEST_COMPARE_STRING (strerrordesc_np (ESRCH), "No such process");
359+ TEST_COMPARE_STRING (strerrorname_np (ESRCH), "ESRCH");
360+#endif
361+#ifdef EINTR
362+ TEST_COMPARE_STRING (strerrordesc_np (EINTR), "Interrupted system call");
363+ TEST_COMPARE_STRING (strerrorname_np (EINTR), "EINTR");
364+#endif
365+#ifdef EIO
366+ TEST_COMPARE_STRING (strerrordesc_np (EIO), "Input/output error");
367+ TEST_COMPARE_STRING (strerrorname_np (EIO), "EIO");
368+#endif
369+#ifdef ENXIO
370+ TEST_COMPARE_STRING (strerrordesc_np (ENXIO), "No such device or address");
371+ TEST_COMPARE_STRING (strerrorname_np (ENXIO), "ENXIO");
372+#endif
373+#ifdef E2BIG
374+ TEST_COMPARE_STRING (strerrordesc_np (E2BIG), "Argument list too long");
375+ TEST_COMPARE_STRING (strerrorname_np (E2BIG), "E2BIG");
376+#endif
377+#ifdef ENOEXEC
378+ TEST_COMPARE_STRING (strerrordesc_np (ENOEXEC), "Exec format error");
379+ TEST_COMPARE_STRING (strerrorname_np (ENOEXEC), "ENOEXEC");
380+#endif
381+#ifdef EBADF
382+ TEST_COMPARE_STRING (strerrordesc_np (EBADF), "Bad file descriptor");
383+ TEST_COMPARE_STRING (strerrorname_np (EBADF), "EBADF");
384+#endif
385+#ifdef ECHILD
386+ TEST_COMPARE_STRING (strerrordesc_np (ECHILD), "No child processes");
387+ TEST_COMPARE_STRING (strerrorname_np (ECHILD), "ECHILD");
388+#endif
389+#ifdef EDEADLK
390+ TEST_COMPARE_STRING (strerrordesc_np (EDEADLK),
391+ "Resource deadlock avoided");
392+ TEST_COMPARE_STRING (strerrorname_np (EDEADLK), "EDEADLK");
393+#endif
394+#ifdef ENOMEM
395+ TEST_COMPARE_STRING (strerrordesc_np (ENOMEM), "Cannot allocate memory");
396+ TEST_COMPARE_STRING (strerrorname_np (ENOMEM), "ENOMEM");
397+#endif
398+#ifdef EACCES
399+ TEST_COMPARE_STRING (strerrordesc_np (EACCES), "Permission denied");
400+ TEST_COMPARE_STRING (strerrorname_np (EACCES), "EACCES");
401+#endif
402+#ifdef EFAULT
403+ TEST_COMPARE_STRING (strerrordesc_np (EFAULT), "Bad address");
404+ TEST_COMPARE_STRING (strerrorname_np (EFAULT), "EFAULT");
405+#endif
406+#ifdef ENOTBLK
407+ TEST_COMPARE_STRING (strerrordesc_np (ENOTBLK), "Block device required");
408+ TEST_COMPARE_STRING (strerrorname_np (ENOTBLK), "ENOTBLK");
409+#endif
410+#ifdef EBUSY
411+ TEST_COMPARE_STRING (strerrordesc_np (EBUSY), "Device or resource busy");
412+ TEST_COMPARE_STRING (strerrorname_np (EBUSY), "EBUSY");
413+#endif
414+#ifdef EEXIST
415+ TEST_COMPARE_STRING (strerrordesc_np (EEXIST), "File exists");
416+ TEST_COMPARE_STRING (strerrorname_np (EEXIST), "EEXIST");
417+#endif
418+#ifdef EXDEV
419+ TEST_COMPARE_STRING (strerrordesc_np (EXDEV), "Invalid cross-device link");
420+ TEST_COMPARE_STRING (strerrorname_np (EXDEV), "EXDEV");
421+#endif
422+#ifdef ENODEV
423+ TEST_COMPARE_STRING (strerrordesc_np (ENODEV), "No such device");
424+ TEST_COMPARE_STRING (strerrorname_np (ENODEV), "ENODEV");
425+#endif
426+#ifdef ENOTDIR
427+ TEST_COMPARE_STRING (strerrordesc_np (ENOTDIR), "Not a directory");
428+ TEST_COMPARE_STRING (strerrorname_np (ENOTDIR), "ENOTDIR");
429+#endif
430+#ifdef EISDIR
431+ TEST_COMPARE_STRING (strerrordesc_np (EISDIR), "Is a directory");
432+ TEST_COMPARE_STRING (strerrorname_np (EISDIR), "EISDIR");
433+#endif
434+#ifdef EINVAL
435+ TEST_COMPARE_STRING (strerrordesc_np (EINVAL), "Invalid argument");
436+ TEST_COMPARE_STRING (strerrorname_np (EINVAL), "EINVAL");
437+#endif
438+#ifdef EMFILE
439+ TEST_COMPARE_STRING (strerrordesc_np (EMFILE), "Too many open files");
440+ TEST_COMPARE_STRING (strerrorname_np (EMFILE), "EMFILE");
441+#endif
442+#ifdef ENFILE
443+ TEST_COMPARE_STRING (strerrordesc_np (ENFILE),
444+ "Too many open files in system");
445+ TEST_COMPARE_STRING (strerrorname_np (ENFILE), "ENFILE");
446+#endif
447+#ifdef ENOTTY
448+ TEST_COMPARE_STRING (strerrordesc_np (ENOTTY),
449+ "Inappropriate ioctl for device");
450+ TEST_COMPARE_STRING (strerrorname_np (ENOTTY), "ENOTTY");
451+#endif
452+#ifdef ETXTBSY
453+ TEST_COMPARE_STRING (strerrordesc_np (ETXTBSY), "Text file busy");
454+ TEST_COMPARE_STRING (strerrorname_np (ETXTBSY), "ETXTBSY");
455+#endif
456+#ifdef EFBIG
457+ TEST_COMPARE_STRING (strerrordesc_np (EFBIG), "File too large");
458+ TEST_COMPARE_STRING (strerrorname_np (EFBIG), "EFBIG");
459+#endif
460+#ifdef ENOSPC
461+ TEST_COMPARE_STRING (strerrordesc_np (ENOSPC), "No space left on device");
462+ TEST_COMPARE_STRING (strerrorname_np (ENOSPC), "ENOSPC");
463+#endif
464+#ifdef ESPIPE
465+ TEST_COMPARE_STRING (strerrordesc_np (ESPIPE), "Illegal seek");
466+ TEST_COMPARE_STRING (strerrorname_np (ESPIPE), "ESPIPE");
467+#endif
468+#ifdef EROFS
469+ TEST_COMPARE_STRING (strerrordesc_np (EROFS), "Read-only file system");
470+ TEST_COMPARE_STRING (strerrorname_np (EROFS), "EROFS");
471+#endif
472+#ifdef EMLINK
473+ TEST_COMPARE_STRING (strerrordesc_np (EMLINK), "Too many links");
474+ TEST_COMPARE_STRING (strerrorname_np (EMLINK), "EMLINK");
475+#endif
476+#ifdef EPIPE
477+ TEST_COMPARE_STRING (strerrordesc_np (EPIPE), "Broken pipe");
478+ TEST_COMPARE_STRING (strerrorname_np (EPIPE), "EPIPE");
479+#endif
480+#ifdef EDOM
481+ TEST_COMPARE_STRING (strerrordesc_np (EDOM),
482+ "Numerical argument out of domain");
483+ TEST_COMPARE_STRING (strerrorname_np (EDOM), "EDOM");
484+#endif
485+#ifdef ERANGE
486+ TEST_COMPARE_STRING (strerrordesc_np (ERANGE),
487+ "Numerical result out of range");
488+ TEST_COMPARE_STRING (strerrorname_np (ERANGE), "ERANGE");
489+#endif
490+#ifdef EAGAIN
491+ TEST_COMPARE_STRING (strerrordesc_np (EAGAIN),
492+ "Resource temporarily unavailable");
493+ TEST_COMPARE_STRING (strerrorname_np (EAGAIN), "EAGAIN");
494+#endif
495+#ifdef EINPROGRESS
496+ TEST_COMPARE_STRING (strerrordesc_np (EINPROGRESS),
497+ "Operation now in progress");
498+ TEST_COMPARE_STRING (strerrorname_np (EINPROGRESS), "EINPROGRESS");
499+#endif
500+#ifdef EALREADY
501+ TEST_COMPARE_STRING (strerrordesc_np (EALREADY),
502+ "Operation already in progress");
503+ TEST_COMPARE_STRING (strerrorname_np (EALREADY), "EALREADY");
504+#endif
505+#ifdef ENOTSOCK
506+ TEST_COMPARE_STRING (strerrordesc_np (ENOTSOCK),
507+ "Socket operation on non-socket");
508+ TEST_COMPARE_STRING (strerrorname_np (ENOTSOCK), "ENOTSOCK");
509+#endif
510+#ifdef EMSGSIZE
511+ TEST_COMPARE_STRING (strerrordesc_np (EMSGSIZE), "Message too long");
512+ TEST_COMPARE_STRING (strerrorname_np (EMSGSIZE), "EMSGSIZE");
513+#endif
514+#ifdef EPROTOTYPE
515+ TEST_COMPARE_STRING (strerrordesc_np (EPROTOTYPE),
516+ "Protocol wrong type for socket");
517+ TEST_COMPARE_STRING (strerrorname_np (EPROTOTYPE), "EPROTOTYPE");
518+#endif
519+#ifdef ENOPROTOOPT
520+ TEST_COMPARE_STRING (strerrordesc_np (ENOPROTOOPT),
521+ "Protocol not available");
522+ TEST_COMPARE_STRING (strerrorname_np (ENOPROTOOPT), "ENOPROTOOPT");
523+#endif
524+#ifdef EPROTONOSUPPORT
525+ TEST_COMPARE_STRING (strerrordesc_np (EPROTONOSUPPORT),
526+ "Protocol not supported");
527+ TEST_COMPARE_STRING (strerrorname_np (EPROTONOSUPPORT), "EPROTONOSUPPORT");
528+#endif
529+#ifdef ESOCKTNOSUPPORT
530+ TEST_COMPARE_STRING (strerrordesc_np (ESOCKTNOSUPPORT),
531+ "Socket type not supported");
532+ TEST_COMPARE_STRING (strerrorname_np (ESOCKTNOSUPPORT), "ESOCKTNOSUPPORT");
533+#endif
534+#ifdef EOPNOTSUPP
535+ TEST_COMPARE_STRING (strerrordesc_np (EOPNOTSUPP),
536+ "Operation not supported");
537+ TEST_COMPARE_STRING (strerrorname_np (EOPNOTSUPP), "EOPNOTSUPP");
538+#endif
539+#ifdef EPFNOSUPPORT
540+ TEST_COMPARE_STRING (strerrordesc_np (EPFNOSUPPORT),
541+ "Protocol family not supported");
542+ TEST_COMPARE_STRING (strerrorname_np (EPFNOSUPPORT), "EPFNOSUPPORT");
543+#endif
544+#ifdef EAFNOSUPPORT
545+ TEST_COMPARE_STRING (strerrordesc_np (EAFNOSUPPORT),
546+ "Address family not supported by protocol");
547+ TEST_COMPARE_STRING (strerrorname_np (EAFNOSUPPORT), "EAFNOSUPPORT");
548+#endif
549+#ifdef EADDRINUSE
550+ TEST_COMPARE_STRING (strerrordesc_np (EADDRINUSE),
551+ "Address already in use");
552+ TEST_COMPARE_STRING (strerrorname_np (EADDRINUSE), "EADDRINUSE");
553+#endif
554+#ifdef EADDRNOTAVAIL
555+ TEST_COMPARE_STRING (strerrordesc_np (EADDRNOTAVAIL),
556+ "Cannot assign requested address");
557+ TEST_COMPARE_STRING (strerrorname_np (EADDRNOTAVAIL), "EADDRNOTAVAIL");
558+#endif
559+#ifdef ENETDOWN
560+ TEST_COMPARE_STRING (strerrordesc_np (ENETDOWN), "Network is down");
561+ TEST_COMPARE_STRING (strerrorname_np (ENETDOWN), "ENETDOWN");
562+#endif
563+#ifdef ENETUNREACH
564+ TEST_COMPARE_STRING (strerrordesc_np (ENETUNREACH),
565+ "Network is unreachable");
566+ TEST_COMPARE_STRING (strerrorname_np (ENETUNREACH), "ENETUNREACH");
567+#endif
568+#ifdef ENETRESET
569+ TEST_COMPARE_STRING (strerrordesc_np (ENETRESET),
570+ "Network dropped connection on reset");
571+ TEST_COMPARE_STRING (strerrorname_np (ENETRESET), "ENETRESET");
572+#endif
573+#ifdef ECONNABORTED
574+ TEST_COMPARE_STRING (strerrordesc_np (ECONNABORTED),
575+ "Software caused connection abort");
576+ TEST_COMPARE_STRING (strerrorname_np (ECONNABORTED), "ECONNABORTED");
577+#endif
578+#ifdef ECONNRESET
579+ TEST_COMPARE_STRING (strerrordesc_np (ECONNRESET),
580+ "Connection reset by peer");
581+ TEST_COMPARE_STRING (strerrorname_np (ECONNRESET), "ECONNRESET");
582+#endif
583+#ifdef ENOBUFS
584+ TEST_COMPARE_STRING (strerrordesc_np (ENOBUFS),
585+ "No buffer space available");
586+ TEST_COMPARE_STRING (strerrorname_np (ENOBUFS), "ENOBUFS");
587+#endif
588+#ifdef EISCONN
589+ TEST_COMPARE_STRING (strerrordesc_np (EISCONN),
590+ "Transport endpoint is already connected");
591+ TEST_COMPARE_STRING (strerrorname_np (EISCONN), "EISCONN");
592+#endif
593+#ifdef ENOTCONN
594+ TEST_COMPARE_STRING (strerrordesc_np (ENOTCONN),
595+ "Transport endpoint is not connected");
596+ TEST_COMPARE_STRING (strerrorname_np (ENOTCONN), "ENOTCONN");
597+#endif
598+#ifdef EDESTADDRREQ
599+ TEST_COMPARE_STRING (strerrordesc_np (EDESTADDRREQ),
600+ "Destination address required");
601+ TEST_COMPARE_STRING (strerrorname_np (EDESTADDRREQ), "EDESTADDRREQ");
602+#endif
603+#ifdef ESHUTDOWN
604+ TEST_COMPARE_STRING (strerrordesc_np (ESHUTDOWN),
605+ "Cannot send after transport endpoint shutdown");
606+ TEST_COMPARE_STRING (strerrorname_np (ESHUTDOWN), "ESHUTDOWN");
607+#endif
608+#ifdef ETOOMANYREFS
609+ TEST_COMPARE_STRING (strerrordesc_np (ETOOMANYREFS),
610+ "Too many references: cannot splice");
611+ TEST_COMPARE_STRING (strerrorname_np (ETOOMANYREFS), "ETOOMANYREFS");
612+#endif
613+#ifdef ETIMEDOUT
614+ TEST_COMPARE_STRING (strerrordesc_np (ETIMEDOUT), "Connection timed out");
615+ TEST_COMPARE_STRING (strerrorname_np (ETIMEDOUT), "ETIMEDOUT");
616+#endif
617+#ifdef ECONNREFUSED
618+ TEST_COMPARE_STRING (strerrordesc_np (ECONNREFUSED), "Connection refused");
619+ TEST_COMPARE_STRING (strerrorname_np (ECONNREFUSED), "ECONNREFUSED");
620+#endif
621+#ifdef ELOOP
622+ TEST_COMPARE_STRING (strerrordesc_np (ELOOP),
623+ "Too many levels of symbolic links");
624+ TEST_COMPARE_STRING (strerrorname_np (ELOOP), "ELOOP");
625+#endif
626+#ifdef ENAMETOOLONG
627+ TEST_COMPARE_STRING (strerrordesc_np (ENAMETOOLONG), "File name too long");
628+ TEST_COMPARE_STRING (strerrorname_np (ENAMETOOLONG), "ENAMETOOLONG");
629+#endif
630+#ifdef EHOSTDOWN
631+ TEST_COMPARE_STRING (strerrordesc_np (EHOSTDOWN), "Host is down");
632+ TEST_COMPARE_STRING (strerrorname_np (EHOSTDOWN), "EHOSTDOWN");
633+#endif
634+#ifdef EHOSTUNREACH
635+ TEST_COMPARE_STRING (strerrordesc_np (EHOSTUNREACH), "No route to host");
636+ TEST_COMPARE_STRING (strerrorname_np (EHOSTUNREACH), "EHOSTUNREACH");
637+#endif
638+#ifdef ENOTEMPTY
639+ TEST_COMPARE_STRING (strerrordesc_np (ENOTEMPTY), "Directory not empty");
640+ TEST_COMPARE_STRING (strerrorname_np (ENOTEMPTY), "ENOTEMPTY");
641+#endif
642+#ifdef EUSERS
643+ TEST_COMPARE_STRING (strerrordesc_np (EUSERS), "Too many users");
644+ TEST_COMPARE_STRING (strerrorname_np (EUSERS), "EUSERS");
645+#endif
646+#ifdef EDQUOT
647+ TEST_COMPARE_STRING (strerrordesc_np (EDQUOT), "Disk quota exceeded");
648+ TEST_COMPARE_STRING (strerrorname_np (EDQUOT), "EDQUOT");
649+#endif
650+#ifdef ESTALE
651+ TEST_COMPARE_STRING (strerrordesc_np (ESTALE), "Stale file handle");
652+ TEST_COMPARE_STRING (strerrorname_np (ESTALE), "ESTALE");
653+#endif
654+#ifdef EREMOTE
655+ TEST_COMPARE_STRING (strerrordesc_np (EREMOTE), "Object is remote");
656+ TEST_COMPARE_STRING (strerrorname_np (EREMOTE), "EREMOTE");
657+#endif
658+#ifdef ENOLCK
659+ TEST_COMPARE_STRING (strerrordesc_np (ENOLCK), "No locks available");
660+ TEST_COMPARE_STRING (strerrorname_np (ENOLCK), "ENOLCK");
661+#endif
662+#ifdef ENOSYS
663+ TEST_COMPARE_STRING (strerrordesc_np (ENOSYS), "Function not implemented");
664+ TEST_COMPARE_STRING (strerrorname_np (ENOSYS), "ENOSYS");
665+#endif
666+#ifdef EILSEQ
667+ TEST_COMPARE_STRING (strerrordesc_np (EILSEQ),
668+ "Invalid or incomplete multibyte or wide character");
669+ TEST_COMPARE_STRING (strerrorname_np (EILSEQ), "EILSEQ");
670+#endif
671+#ifdef EBADMSG
672+ TEST_COMPARE_STRING (strerrordesc_np (EBADMSG), "Bad message");
673+ TEST_COMPARE_STRING (strerrorname_np (EBADMSG), "EBADMSG");
674+#endif
675+#ifdef EIDRM
676+ TEST_COMPARE_STRING (strerrordesc_np (EIDRM), "Identifier removed");
677+ TEST_COMPARE_STRING (strerrorname_np (EIDRM), "EIDRM");
678+#endif
679+#ifdef EMULTIHOP
680+ TEST_COMPARE_STRING (strerrordesc_np (EMULTIHOP), "Multihop attempted");
681+ TEST_COMPARE_STRING (strerrorname_np (EMULTIHOP), "EMULTIHOP");
682+#endif
683+#ifdef ENODATA
684+ TEST_COMPARE_STRING (strerrordesc_np (ENODATA), "No data available");
685+ TEST_COMPARE_STRING (strerrorname_np (ENODATA), "ENODATA");
686+#endif
687+#ifdef ENOLINK
688+ TEST_COMPARE_STRING (strerrordesc_np (ENOLINK), "Link has been severed");
689+ TEST_COMPARE_STRING (strerrorname_np (ENOLINK), "ENOLINK");
690+#endif
691+#ifdef ENOMSG
692+ TEST_COMPARE_STRING (strerrordesc_np (ENOMSG),
693+ "No message of desired type");
694+ TEST_COMPARE_STRING (strerrorname_np (ENOMSG), "ENOMSG");
695+#endif
696+#ifdef ENOSR
697+ TEST_COMPARE_STRING (strerrordesc_np (ENOSR), "Out of streams resources");
698+ TEST_COMPARE_STRING (strerrorname_np (ENOSR), "ENOSR");
699+#endif
700+#ifdef ENOSTR
701+ TEST_COMPARE_STRING (strerrordesc_np (ENOSTR), "Device not a stream");
702+ TEST_COMPARE_STRING (strerrorname_np (ENOSTR), "ENOSTR");
703+#endif
704+#ifdef EOVERFLOW
705+ TEST_COMPARE_STRING (strerrordesc_np (EOVERFLOW),
706+ "Value too large for defined data type");
707+ TEST_COMPARE_STRING (strerrorname_np (EOVERFLOW), "EOVERFLOW");
708+#endif
709+#ifdef EPROTO
710+ TEST_COMPARE_STRING (strerrordesc_np (EPROTO), "Protocol error");
711+ TEST_COMPARE_STRING (strerrorname_np (EPROTO), "EPROTO");
712+#endif
713+#ifdef ETIME
714+ TEST_COMPARE_STRING (strerrordesc_np (ETIME), "Timer expired");
715+ TEST_COMPARE_STRING (strerrorname_np (ETIME), "ETIME");
716+#endif
717+#ifdef ECANCELED
718+ TEST_COMPARE_STRING (strerrordesc_np (ECANCELED), "Operation canceled");
719+ TEST_COMPARE_STRING (strerrorname_np (ECANCELED), "ECANCELED");
720+#endif
721+#ifdef EOWNERDEAD
722+ TEST_COMPARE_STRING (strerrordesc_np (EOWNERDEAD), "Owner died");
723+ TEST_COMPARE_STRING (strerrorname_np (EOWNERDEAD), "EOWNERDEAD");
724+#endif
725+#ifdef ENOTRECOVERABLE
726+ TEST_COMPARE_STRING (strerrordesc_np (ENOTRECOVERABLE),
727+ "State not recoverable");
728+ TEST_COMPARE_STRING (strerrorname_np (ENOTRECOVERABLE), "ENOTRECOVERABLE");
729+#endif
730+#ifdef ERESTART
731+ TEST_COMPARE_STRING (strerrordesc_np (ERESTART),
732+ "Interrupted system call should be restarted");
733+ TEST_COMPARE_STRING (strerrorname_np (ERESTART), "ERESTART");
734+#endif
735+#ifdef ECHRNG
736+ TEST_COMPARE_STRING (strerrordesc_np (ECHRNG),
737+ "Channel number out of range");
738+ TEST_COMPARE_STRING (strerrorname_np (ECHRNG), "ECHRNG");
739+#endif
740+#ifdef EL2NSYNC
741+ TEST_COMPARE_STRING (strerrordesc_np (EL2NSYNC),
742+ "Level 2 not synchronized");
743+ TEST_COMPARE_STRING (strerrorname_np (EL2NSYNC), "EL2NSYNC");
744+#endif
745+#ifdef EL3HLT
746+ TEST_COMPARE_STRING (strerrordesc_np (EL3HLT), "Level 3 halted");
747+ TEST_COMPARE_STRING (strerrorname_np (EL3HLT), "EL3HLT");
748+#endif
749+#ifdef EL3RST
750+ TEST_COMPARE_STRING (strerrordesc_np (EL3RST), "Level 3 reset");
751+ TEST_COMPARE_STRING (strerrorname_np (EL3RST), "EL3RST");
752+#endif
753+#ifdef ELNRNG
754+ TEST_COMPARE_STRING (strerrordesc_np (ELNRNG), "Link number out of range");
755+ TEST_COMPARE_STRING (strerrorname_np (ELNRNG), "ELNRNG");
756+#endif
757+#ifdef EUNATCH
758+ TEST_COMPARE_STRING (strerrordesc_np (EUNATCH),
759+ "Protocol driver not attached");
760+ TEST_COMPARE_STRING (strerrorname_np (EUNATCH), "EUNATCH");
761+#endif
762+#ifdef ENOCSI
763+ TEST_COMPARE_STRING (strerrordesc_np (ENOCSI),
764+ "No CSI structure available");
765+ TEST_COMPARE_STRING (strerrorname_np (ENOCSI), "ENOCSI");
766+#endif
767+#ifdef EL2HLT
768+ TEST_COMPARE_STRING (strerrordesc_np (EL2HLT), "Level 2 halted");
769+ TEST_COMPARE_STRING (strerrorname_np (EL2HLT), "EL2HLT");
770+#endif
771+#ifdef EBADE
772+ TEST_COMPARE_STRING (strerrordesc_np (EBADE), "Invalid exchange");
773+ TEST_COMPARE_STRING (strerrorname_np (EBADE), "EBADE");
774+#endif
775+#ifdef EBADR
776+ TEST_COMPARE_STRING (strerrordesc_np (EBADR),
777+ "Invalid request descriptor");
778+ TEST_COMPARE_STRING (strerrorname_np (EBADR), "EBADR");
779+#endif
780+#ifdef EXFULL
781+ TEST_COMPARE_STRING (strerrordesc_np (EXFULL), "Exchange full");
782+ TEST_COMPARE_STRING (strerrorname_np (EXFULL), "EXFULL");
783+#endif
784+#ifdef ENOANO
785+ TEST_COMPARE_STRING (strerrordesc_np (ENOANO), "No anode");
786+ TEST_COMPARE_STRING (strerrorname_np (ENOANO), "ENOANO");
787+#endif
788+#ifdef EBADRQC
789+ TEST_COMPARE_STRING (strerrordesc_np (EBADRQC), "Invalid request code");
790+ TEST_COMPARE_STRING (strerrorname_np (EBADRQC), "EBADRQC");
791+#endif
792+#ifdef EBADSLT
793+ TEST_COMPARE_STRING (strerrordesc_np (EBADSLT), "Invalid slot");
794+ TEST_COMPARE_STRING (strerrorname_np (EBADSLT), "EBADSLT");
795+#endif
796+#ifdef EBFONT
797+ TEST_COMPARE_STRING (strerrordesc_np (EBFONT), "Bad font file format");
798+ TEST_COMPARE_STRING (strerrorname_np (EBFONT), "EBFONT");
799+#endif
800+#ifdef ENONET
801+ TEST_COMPARE_STRING (strerrordesc_np (ENONET),
802+ "Machine is not on the network");
803+ TEST_COMPARE_STRING (strerrorname_np (ENONET), "ENONET");
804+#endif
805+#ifdef ENOPKG
806+ TEST_COMPARE_STRING (strerrordesc_np (ENOPKG), "Package not installed");
807+ TEST_COMPARE_STRING (strerrorname_np (ENOPKG), "ENOPKG");
808+#endif
809+#ifdef EADV
810+ TEST_COMPARE_STRING (strerrordesc_np (EADV), "Advertise error");
811+ TEST_COMPARE_STRING (strerrorname_np (EADV), "EADV");
812+#endif
813+#ifdef ESRMNT
814+ TEST_COMPARE_STRING (strerrordesc_np (ESRMNT), "Srmount error");
815+ TEST_COMPARE_STRING (strerrorname_np (ESRMNT), "ESRMNT");
816+#endif
817+#ifdef ECOMM
818+ TEST_COMPARE_STRING (strerrordesc_np (ECOMM),
819+ "Communication error on send");
820+ TEST_COMPARE_STRING (strerrorname_np (ECOMM), "ECOMM");
821+#endif
822+#ifdef EDOTDOT
823+ TEST_COMPARE_STRING (strerrordesc_np (EDOTDOT), "RFS specific error");
824+ TEST_COMPARE_STRING (strerrorname_np (EDOTDOT), "EDOTDOT");
825+#endif
826+#ifdef ENOTUNIQ
827+ TEST_COMPARE_STRING (strerrordesc_np (ENOTUNIQ),
828+ "Name not unique on network");
829+ TEST_COMPARE_STRING (strerrorname_np (ENOTUNIQ), "ENOTUNIQ");
830+#endif
831+#ifdef EBADFD
832+ TEST_COMPARE_STRING (strerrordesc_np (EBADFD),
833+ "File descriptor in bad state");
834+ TEST_COMPARE_STRING (strerrorname_np (EBADFD), "EBADFD");
835+#endif
836+#ifdef EREMCHG
837+ TEST_COMPARE_STRING (strerrordesc_np (EREMCHG), "Remote address changed");
838+ TEST_COMPARE_STRING (strerrorname_np (EREMCHG), "EREMCHG");
839+#endif
840+#ifdef ELIBACC
841+ TEST_COMPARE_STRING (strerrordesc_np (ELIBACC),
842+ "Can not access a needed shared library");
843+ TEST_COMPARE_STRING (strerrorname_np (ELIBACC), "ELIBACC");
844+#endif
845+#ifdef ELIBBAD
846+ TEST_COMPARE_STRING (strerrordesc_np (ELIBBAD),
847+ "Accessing a corrupted shared library");
848+ TEST_COMPARE_STRING (strerrorname_np (ELIBBAD), "ELIBBAD");
849+#endif
850+#ifdef ELIBSCN
851+ TEST_COMPARE_STRING (strerrordesc_np (ELIBSCN),
852+ ".lib section in a.out corrupted");
853+ TEST_COMPARE_STRING (strerrorname_np (ELIBSCN), "ELIBSCN");
854+#endif
855+#ifdef ELIBMAX
856+ TEST_COMPARE_STRING (strerrordesc_np (ELIBMAX),
857+ "Attempting to link in too many shared libraries");
858+ TEST_COMPARE_STRING (strerrorname_np (ELIBMAX), "ELIBMAX");
859+#endif
860+#ifdef ELIBEXEC
861+ TEST_COMPARE_STRING (strerrordesc_np (ELIBEXEC),
862+ "Cannot exec a shared library directly");
863+ TEST_COMPARE_STRING (strerrorname_np (ELIBEXEC), "ELIBEXEC");
864+#endif
865+#ifdef ESTRPIPE
866+ TEST_COMPARE_STRING (strerrordesc_np (ESTRPIPE), "Streams pipe error");
867+ TEST_COMPARE_STRING (strerrorname_np (ESTRPIPE), "ESTRPIPE");
868+#endif
869+#ifdef EUCLEAN
870+ TEST_COMPARE_STRING (strerrordesc_np (EUCLEAN),
871+ "Structure needs cleaning");
872+ TEST_COMPARE_STRING (strerrorname_np (EUCLEAN), "EUCLEAN");
873+#endif
874+#ifdef ENOTNAM
875+ TEST_COMPARE_STRING (strerrordesc_np (ENOTNAM),
876+ "Not a XENIX named type file");
877+ TEST_COMPARE_STRING (strerrorname_np (ENOTNAM), "ENOTNAM");
878+#endif
879+#ifdef ENAVAIL
880+ TEST_COMPARE_STRING (strerrordesc_np (ENAVAIL),
881+ "No XENIX semaphores available");
882+ TEST_COMPARE_STRING (strerrorname_np (ENAVAIL), "ENAVAIL");
883+#endif
884+#ifdef EISNAM
885+ TEST_COMPARE_STRING (strerrordesc_np (EISNAM), "Is a named type file");
886+ TEST_COMPARE_STRING (strerrorname_np (EISNAM), "EISNAM");
887+#endif
888+#ifdef EREMOTEIO
889+ TEST_COMPARE_STRING (strerrordesc_np (EREMOTEIO), "Remote I/O error");
890+ TEST_COMPARE_STRING (strerrorname_np (EREMOTEIO), "EREMOTEIO");
891+#endif
892+#ifdef ENOMEDIUM
893+ TEST_COMPARE_STRING (strerrordesc_np (ENOMEDIUM), "No medium found");
894+ TEST_COMPARE_STRING (strerrorname_np (ENOMEDIUM), "ENOMEDIUM");
895+#endif
896+#ifdef EMEDIUMTYPE
897+ TEST_COMPARE_STRING (strerrordesc_np (EMEDIUMTYPE), "Wrong medium type");
898+ TEST_COMPARE_STRING (strerrorname_np (EMEDIUMTYPE), "EMEDIUMTYPE");
899+#endif
900+#ifdef ENOKEY
901+ TEST_COMPARE_STRING (strerrordesc_np (ENOKEY),
902+ "Required key not available");
903+ TEST_COMPARE_STRING (strerrorname_np (ENOKEY), "ENOKEY");
904+#endif
905+#ifdef EKEYEXPIRED
906+ TEST_COMPARE_STRING (strerrordesc_np (EKEYEXPIRED), "Key has expired");
907+ TEST_COMPARE_STRING (strerrorname_np (EKEYEXPIRED), "EKEYEXPIRED");
908+#endif
909+#ifdef EKEYREVOKED
910+ TEST_COMPARE_STRING (strerrordesc_np (EKEYREVOKED),
911+ "Key has been revoked");
912+ TEST_COMPARE_STRING (strerrorname_np (EKEYREVOKED), "EKEYREVOKED");
913+#endif
914+#ifdef EKEYREJECTED
915+ TEST_COMPARE_STRING (strerrordesc_np (EKEYREJECTED),
916+ "Key was rejected by service");
917+ TEST_COMPARE_STRING (strerrorname_np (EKEYREJECTED), "EKEYREJECTED");
918+#endif
919+#ifdef ERFKILL
920+ TEST_COMPARE_STRING (strerrordesc_np (ERFKILL),
921+ "Operation not possible due to RF-kill");
922+ TEST_COMPARE_STRING (strerrorname_np (ERFKILL), "ERFKILL");
923+#endif
924+#ifdef EHWPOISON
925+ TEST_COMPARE_STRING (strerrordesc_np (EHWPOISON),
926+ "Memory page has hardware error");
927+ TEST_COMPARE_STRING (strerrorname_np (EHWPOISON), "EHWPOISON");
928+#endif
929+#ifdef EBADRPC
930+ TEST_COMPARE_STRING (strerrordesc_np (EBADRPC), "RPC struct is bad");
931+ TEST_COMPARE_STRING (strerrorname_np (EBADRPC), "EBADRPC");
932+#endif
933+#ifdef EFTYPE
934+ TEST_COMPARE_STRING (strerrordesc_np (EFTYPE),
935+ "Inappropriate file type or format");
936+ TEST_COMPARE_STRING (strerrorname_np (EFTYPE), "EFTYPE");
937+#endif
938+#ifdef EPROCUNAVAIL
939+ TEST_COMPARE_STRING (strerrordesc_np (EPROCUNAVAIL),
940+ "RPC bad procedure for program");
941+ TEST_COMPARE_STRING (strerrorname_np (EPROCUNAVAIL), "EPROCUNAVAIL");
942+#endif
943+#ifdef EAUTH
944+ TEST_COMPARE_STRING (strerrordesc_np (EAUTH), "Authentication error");
945+ TEST_COMPARE_STRING (strerrorname_np (EAUTH), "EAUTH");
946+#endif
947+#ifdef EDIED
948+ TEST_COMPARE_STRING (strerrordesc_np (EDIED), "Translator died");
949+ TEST_COMPARE_STRING (strerrorname_np (EDIED), "EDIED");
950+#endif
951+#ifdef ERPCMISMATCH
952+ TEST_COMPARE_STRING (strerrordesc_np (ERPCMISMATCH), "RPC version wrong");
953+ TEST_COMPARE_STRING (strerrorname_np (ERPCMISMATCH), "ERPCMISMATCH");
954+#endif
955+#ifdef EGREGIOUS
956+ TEST_COMPARE_STRING (strerrordesc_np (EGREGIOUS),
957+ "You really blew it this time");
958+ TEST_COMPARE_STRING (strerrorname_np (EGREGIOUS), "EGREGIOUS");
959+#endif
960+#ifdef EPROCLIM
961+ TEST_COMPARE_STRING (strerrordesc_np (EPROCLIM), "Too many processes");
962+ TEST_COMPARE_STRING (strerrorname_np (EPROCLIM), "EPROCLIM");
963+#endif
964+#ifdef EGRATUITOUS
965+ TEST_COMPARE_STRING (strerrordesc_np (EGRATUITOUS), "Gratuitous error");
966+ TEST_COMPARE_STRING (strerrorname_np (EGRATUITOUS), "EGRATUITOUS");
967+#endif
968+#if defined (ENOTSUP) && ENOTSUP != EOPNOTSUPP
969+ TEST_COMPARE_STRING (strerrordesc_np (ENOTSUP), "Not supported");
970+ TEST_COMPARE_STRING (strerrorname_np (ENOTSUP), "ENOTSUP");
971+#endif
972+#ifdef EPROGMISMATCH
973+ TEST_COMPARE_STRING (strerrordesc_np (EPROGMISMATCH),
974+ "RPC program version wrong");
975+ TEST_COMPARE_STRING (strerrorname_np (EPROGMISMATCH), "EPROGMISMATCH");
976+#endif
977+#ifdef EBACKGROUND
978+ TEST_COMPARE_STRING (strerrordesc_np (EBACKGROUND),
979+ "Inappropriate operation for background process");
980+ TEST_COMPARE_STRING (strerrorname_np (EBACKGROUND), "EBACKGROUND");
981+#endif
982+#ifdef EIEIO
983+ TEST_COMPARE_STRING (strerrordesc_np (EIEIO), "Computer bought the farm");
984+ TEST_COMPARE_STRING (strerrorname_np (EIEIO), "EIEIO");
985+#endif
986+#if defined (EWOULDBLOCK) && EWOULDBLOCK != EAGAIN
987+ TEST_COMPARE_STRING (strerrordesc_np (EWOULDBLOCK),
988+ "Operation would block");
989+ TEST_COMPARE_STRING (strerrorname_np (EWOULDBLOCK), "EWOULDBLOCK");
990+#endif
991+#ifdef ENEEDAUTH
992+ TEST_COMPARE_STRING (strerrordesc_np (ENEEDAUTH), "Need authenticator");
993+ TEST_COMPARE_STRING (strerrorname_np (ENEEDAUTH), "ENEEDAUTH");
994+#endif
995+#ifdef ED
996+ TEST_COMPARE_STRING (strerrordesc_np (ED), "?");
997+ TEST_COMPARE_STRING (strerrorname_np (ED), "ED");
998+#endif
999+#ifdef EPROGUNAVAIL
1000+ TEST_COMPARE_STRING (strerrordesc_np (EPROGUNAVAIL),
1001+ "RPC program not available");
1002+ TEST_COMPARE_STRING (strerrorname_np (EPROGUNAVAIL), "EPROGUNAVAIL");
1003+#endif
1004
1005 return 0;
1006 }
1007diff --git a/sysdeps/aarch64/multiarch/memcpy.c b/sysdeps/aarch64/multiarch/memcpy.c
1008index 7cf5f033e8..799d60c98c 100644
1009--- a/sysdeps/aarch64/multiarch/memcpy.c
1010+++ b/sysdeps/aarch64/multiarch/memcpy.c
1011@@ -41,7 +41,8 @@ libc_ifunc (__libc_memcpy,
1012 ? __memcpy_falkor
1013 : (IS_THUNDERX2 (midr) || IS_THUNDERX2PA (midr)
1014 ? __memcpy_thunderx2
1015- : (IS_NEOVERSE_N1 (midr)
1016+ : (IS_NEOVERSE_N1 (midr) || IS_NEOVERSE_N2 (midr)
1017+ || IS_NEOVERSE_V1 (midr)
1018 ? __memcpy_simd
1019 : __memcpy_generic)))));
1020
1021diff --git a/sysdeps/aarch64/multiarch/memcpy_advsimd.S b/sysdeps/aarch64/multiarch/memcpy_advsimd.S
1022index d4ba747777..48bb6d7ca4 100644
1023--- a/sysdeps/aarch64/multiarch/memcpy_advsimd.S
1024+++ b/sysdeps/aarch64/multiarch/memcpy_advsimd.S
1025@@ -223,12 +223,13 @@ L(copy_long_backwards):
1026 b.ls L(copy64_from_start)
1027
1028 L(loop64_backwards):
1029- stp A_q, B_q, [dstend, -32]
1030+ str B_q, [dstend, -16]
1031+ str A_q, [dstend, -32]
1032 ldp A_q, B_q, [srcend, -96]
1033- stp C_q, D_q, [dstend, -64]
1034+ str D_q, [dstend, -48]
1035+ str C_q, [dstend, -64]!
1036 ldp C_q, D_q, [srcend, -128]
1037 sub srcend, srcend, 64
1038- sub dstend, dstend, 64
1039 subs count, count, 64
1040 b.hi L(loop64_backwards)
1041
1042diff --git a/sysdeps/aarch64/multiarch/memmove.c b/sysdeps/aarch64/multiarch/memmove.c
1043index ad10aa8ac6..46a4cb3a54 100644
1044--- a/sysdeps/aarch64/multiarch/memmove.c
1045+++ b/sysdeps/aarch64/multiarch/memmove.c
1046@@ -41,7 +41,8 @@ libc_ifunc (__libc_memmove,
1047 ? __memmove_falkor
1048 : (IS_THUNDERX2 (midr) || IS_THUNDERX2PA (midr)
1049 ? __memmove_thunderx2
1050- : (IS_NEOVERSE_N1 (midr)
1051+ : (IS_NEOVERSE_N1 (midr) || IS_NEOVERSE_N2 (midr)
1052+ || IS_NEOVERSE_V1 (midr)
1053 ? __memmove_simd
1054 : __memmove_generic)))));
1055
1056diff --git a/sysdeps/gnu/errlist.h b/sysdeps/gnu/errlist.h
1057index 5d11ed723d..6329e5f393 100644
1058--- a/sysdeps/gnu/errlist.h
1059+++ b/sysdeps/gnu/errlist.h
1060@@ -1,24 +1,21 @@
1061-#ifndef ERR_MAP
1062-#define ERR_MAP(value) value
1063-#endif
1064-_S(ERR_MAP(0), N_("Success"))
1065+_S(0, N_("Success"))
1066 #ifdef EPERM
1067 /*
1068 TRANS Only the owner of the file (or other resource)
1069 TRANS or processes with special privileges can perform the operation. */
1070-_S(ERR_MAP(EPERM), N_("Operation not permitted"))
1071+_S(EPERM, N_("Operation not permitted"))
1072 #endif
1073 #ifdef ENOENT
1074 /*
1075 TRANS This is a ``file doesn't exist'' error
1076 TRANS for ordinary files that are referenced in contexts where they are
1077 TRANS expected to already exist. */
1078-_S(ERR_MAP(ENOENT), N_("No such file or directory"))
1079+_S(ENOENT, N_("No such file or directory"))
1080 #endif
1081 #ifdef ESRCH
1082 /*
1083 TRANS No process matches the specified process ID. */
1084-_S(ERR_MAP(ESRCH), N_("No such process"))
1085+_S(ESRCH, N_("No such process"))
1086 #endif
1087 #ifdef EINTR
1088 /*
1089@@ -29,12 +26,12 @@ TRANS
1090 TRANS You can choose to have functions resume after a signal that is handled,
1091 TRANS rather than failing with @code{EINTR}; see @ref{Interrupted
1092 TRANS Primitives}. */
1093-_S(ERR_MAP(EINTR), N_("Interrupted system call"))
1094+_S(EINTR, N_("Interrupted system call"))
1095 #endif
1096 #ifdef EIO
1097 /*
1098 TRANS Usually used for physical read or write errors. */
1099-_S(ERR_MAP(EIO), N_("Input/output error"))
1100+_S(EIO, N_("Input/output error"))
1101 #endif
1102 #ifdef ENXIO
1103 /*
1104@@ -43,7 +40,7 @@ TRANS represented by a file you specified, and it couldn't find the device.
1105 TRANS This can mean that the device file was installed incorrectly, or that
1106 TRANS the physical device is missing or not correctly attached to the
1107 TRANS computer. */
1108-_S(ERR_MAP(ENXIO), N_("No such device or address"))
1109+_S(ENXIO, N_("No such device or address"))
1110 #endif
1111 #ifdef E2BIG
1112 /*
1113@@ -51,27 +48,27 @@ TRANS Used when the arguments passed to a new program
1114 TRANS being executed with one of the @code{exec} functions (@pxref{Executing a
1115 TRANS File}) occupy too much memory space. This condition never arises on
1116 TRANS @gnuhurdsystems{}. */
1117-_S(ERR_MAP(E2BIG), N_("Argument list too long"))
1118+_S(E2BIG, N_("Argument list too long"))
1119 #endif
1120 #ifdef ENOEXEC
1121 /*
1122 TRANS Invalid executable file format. This condition is detected by the
1123 TRANS @code{exec} functions; see @ref{Executing a File}. */
1124-_S(ERR_MAP(ENOEXEC), N_("Exec format error"))
1125+_S(ENOEXEC, N_("Exec format error"))
1126 #endif
1127 #ifdef EBADF
1128 /*
1129 TRANS For example, I/O on a descriptor that has been
1130 TRANS closed or reading from a descriptor open only for writing (or vice
1131 TRANS versa). */
1132-_S(ERR_MAP(EBADF), N_("Bad file descriptor"))
1133+_S(EBADF, N_("Bad file descriptor"))
1134 #endif
1135 #ifdef ECHILD
1136 /*
1137 TRANS This error happens on operations that are
1138 TRANS supposed to manipulate child processes, when there aren't any processes
1139 TRANS to manipulate. */
1140-_S(ERR_MAP(ECHILD), N_("No child processes"))
1141+_S(ECHILD, N_("No child processes"))
1142 #endif
1143 #ifdef EDEADLK
1144 /*
1145@@ -79,74 +76,74 @@ TRANS Allocating a system resource would have resulted in a
1146 TRANS deadlock situation. The system does not guarantee that it will notice
1147 TRANS all such situations. This error means you got lucky and the system
1148 TRANS noticed; it might just hang. @xref{File Locks}, for an example. */
1149-_S(ERR_MAP(EDEADLK), N_("Resource deadlock avoided"))
1150+_S(EDEADLK, N_("Resource deadlock avoided"))
1151 #endif
1152 #ifdef ENOMEM
1153 /*
1154 TRANS The system cannot allocate more virtual memory
1155 TRANS because its capacity is full. */
1156-_S(ERR_MAP(ENOMEM), N_("Cannot allocate memory"))
1157+_S(ENOMEM, N_("Cannot allocate memory"))
1158 #endif
1159 #ifdef EACCES
1160 /*
1161 TRANS The file permissions do not allow the attempted operation. */
1162-_S(ERR_MAP(EACCES), N_("Permission denied"))
1163+_S(EACCES, N_("Permission denied"))
1164 #endif
1165 #ifdef EFAULT
1166 /*
1167 TRANS An invalid pointer was detected.
1168 TRANS On @gnuhurdsystems{}, this error never happens; you get a signal instead. */
1169-_S(ERR_MAP(EFAULT), N_("Bad address"))
1170+_S(EFAULT, N_("Bad address"))
1171 #endif
1172 #ifdef ENOTBLK
1173 /*
1174 TRANS A file that isn't a block special file was given in a situation that
1175 TRANS requires one. For example, trying to mount an ordinary file as a file
1176 TRANS system in Unix gives this error. */
1177-_S(ERR_MAP(ENOTBLK), N_("Block device required"))
1178+_S(ENOTBLK, N_("Block device required"))
1179 #endif
1180 #ifdef EBUSY
1181 /*
1182 TRANS A system resource that can't be shared is already in use.
1183 TRANS For example, if you try to delete a file that is the root of a currently
1184 TRANS mounted filesystem, you get this error. */
1185-_S(ERR_MAP(EBUSY), N_("Device or resource busy"))
1186+_S(EBUSY, N_("Device or resource busy"))
1187 #endif
1188 #ifdef EEXIST
1189 /*
1190 TRANS An existing file was specified in a context where it only
1191 TRANS makes sense to specify a new file. */
1192-_S(ERR_MAP(EEXIST), N_("File exists"))
1193+_S(EEXIST, N_("File exists"))
1194 #endif
1195 #ifdef EXDEV
1196 /*
1197 TRANS An attempt to make an improper link across file systems was detected.
1198 TRANS This happens not only when you use @code{link} (@pxref{Hard Links}) but
1199 TRANS also when you rename a file with @code{rename} (@pxref{Renaming Files}). */
1200-_S(ERR_MAP(EXDEV), N_("Invalid cross-device link"))
1201+_S(EXDEV, N_("Invalid cross-device link"))
1202 #endif
1203 #ifdef ENODEV
1204 /*
1205 TRANS The wrong type of device was given to a function that expects a
1206 TRANS particular sort of device. */
1207-_S(ERR_MAP(ENODEV), N_("No such device"))
1208+_S(ENODEV, N_("No such device"))
1209 #endif
1210 #ifdef ENOTDIR
1211 /*
1212 TRANS A file that isn't a directory was specified when a directory is required. */
1213-_S(ERR_MAP(ENOTDIR), N_("Not a directory"))
1214+_S(ENOTDIR, N_("Not a directory"))
1215 #endif
1216 #ifdef EISDIR
1217 /*
1218 TRANS You cannot open a directory for writing,
1219 TRANS or create or remove hard links to it. */
1220-_S(ERR_MAP(EISDIR), N_("Is a directory"))
1221+_S(EISDIR, N_("Is a directory"))
1222 #endif
1223 #ifdef EINVAL
1224 /*
1225 TRANS This is used to indicate various kinds of problems
1226 TRANS with passing the wrong argument to a library function. */
1227-_S(ERR_MAP(EINVAL), N_("Invalid argument"))
1228+_S(EINVAL, N_("Invalid argument"))
1229 #endif
1230 #ifdef EMFILE
1231 /*
1232@@ -157,20 +154,20 @@ TRANS In BSD and GNU, the number of open files is controlled by a resource
1233 TRANS limit that can usually be increased. If you get this error, you might
1234 TRANS want to increase the @code{RLIMIT_NOFILE} limit or make it unlimited;
1235 TRANS @pxref{Limits on Resources}. */
1236-_S(ERR_MAP(EMFILE), N_("Too many open files"))
1237+_S(EMFILE, N_("Too many open files"))
1238 #endif
1239 #ifdef ENFILE
1240 /*
1241 TRANS There are too many distinct file openings in the entire system. Note
1242 TRANS that any number of linked channels count as just one file opening; see
1243 TRANS @ref{Linked Channels}. This error never occurs on @gnuhurdsystems{}. */
1244-_S(ERR_MAP(ENFILE), N_("Too many open files in system"))
1245+_S(ENFILE, N_("Too many open files in system"))
1246 #endif
1247 #ifdef ENOTTY
1248 /*
1249 TRANS Inappropriate I/O control operation, such as trying to set terminal
1250 TRANS modes on an ordinary file. */
1251-_S(ERR_MAP(ENOTTY), N_("Inappropriate ioctl for device"))
1252+_S(ENOTTY, N_("Inappropriate ioctl for device"))
1253 #endif
1254 #ifdef ETXTBSY
1255 /*
1256@@ -179,35 +176,35 @@ TRANS write to a file that is currently being executed. Often using a
1257 TRANS debugger to run a program is considered having it open for writing and
1258 TRANS will cause this error. (The name stands for ``text file busy''.) This
1259 TRANS is not an error on @gnuhurdsystems{}; the text is copied as necessary. */
1260-_S(ERR_MAP(ETXTBSY), N_("Text file busy"))
1261+_S(ETXTBSY, N_("Text file busy"))
1262 #endif
1263 #ifdef EFBIG
1264 /*
1265 TRANS The size of a file would be larger than allowed by the system. */
1266-_S(ERR_MAP(EFBIG), N_("File too large"))
1267+_S(EFBIG, N_("File too large"))
1268 #endif
1269 #ifdef ENOSPC
1270 /*
1271 TRANS Write operation on a file failed because the
1272 TRANS disk is full. */
1273-_S(ERR_MAP(ENOSPC), N_("No space left on device"))
1274+_S(ENOSPC, N_("No space left on device"))
1275 #endif
1276 #ifdef ESPIPE
1277 /*
1278 TRANS Invalid seek operation (such as on a pipe). */
1279-_S(ERR_MAP(ESPIPE), N_("Illegal seek"))
1280+_S(ESPIPE, N_("Illegal seek"))
1281 #endif
1282 #ifdef EROFS
1283 /*
1284 TRANS An attempt was made to modify something on a read-only file system. */
1285-_S(ERR_MAP(EROFS), N_("Read-only file system"))
1286+_S(EROFS, N_("Read-only file system"))
1287 #endif
1288 #ifdef EMLINK
1289 /*
1290 TRANS The link count of a single file would become too large.
1291 TRANS @code{rename} can cause this error if the file being renamed already has
1292 TRANS as many links as it can take (@pxref{Renaming Files}). */
1293-_S(ERR_MAP(EMLINK), N_("Too many links"))
1294+_S(EMLINK, N_("Too many links"))
1295 #endif
1296 #ifdef EPIPE
1297 /*
1298@@ -216,19 +213,19 @@ TRANS Every library function that returns this error code also generates a
1299 TRANS @code{SIGPIPE} signal; this signal terminates the program if not handled
1300 TRANS or blocked. Thus, your program will never actually see @code{EPIPE}
1301 TRANS unless it has handled or blocked @code{SIGPIPE}. */
1302-_S(ERR_MAP(EPIPE), N_("Broken pipe"))
1303+_S(EPIPE, N_("Broken pipe"))
1304 #endif
1305 #ifdef EDOM
1306 /*
1307 TRANS Used by mathematical functions when an argument value does
1308 TRANS not fall into the domain over which the function is defined. */
1309-_S(ERR_MAP(EDOM), N_("Numerical argument out of domain"))
1310+_S(EDOM, N_("Numerical argument out of domain"))
1311 #endif
1312 #ifdef ERANGE
1313 /*
1314 TRANS Used by mathematical functions when the result value is
1315 TRANS not representable because of overflow or underflow. */
1316-_S(ERR_MAP(ERANGE), N_("Numerical result out of range"))
1317+_S(ERANGE, N_("Numerical result out of range"))
1318 #endif
1319 #ifdef EAGAIN
1320 /*
1321@@ -261,7 +258,7 @@ TRANS Such shortages are usually fairly serious and affect the whole system,
1322 TRANS so usually an interactive program should report the error to the user
1323 TRANS and return to its command loop.
1324 TRANS @end itemize */
1325-_S(ERR_MAP(EAGAIN), N_("Resource temporarily unavailable"))
1326+_S(EAGAIN, N_("Resource temporarily unavailable"))
1327 #endif
1328 #ifdef EINPROGRESS
1329 /*
1330@@ -273,47 +270,47 @@ TRANS the operation has begun and will take some time. Attempts to manipulate
1331 TRANS the object before the call completes return @code{EALREADY}. You can
1332 TRANS use the @code{select} function to find out when the pending operation
1333 TRANS has completed; @pxref{Waiting for I/O}. */
1334-_S(ERR_MAP(EINPROGRESS), N_("Operation now in progress"))
1335+_S(EINPROGRESS, N_("Operation now in progress"))
1336 #endif
1337 #ifdef EALREADY
1338 /*
1339 TRANS An operation is already in progress on an object that has non-blocking
1340 TRANS mode selected. */
1341-_S(ERR_MAP(EALREADY), N_("Operation already in progress"))
1342+_S(EALREADY, N_("Operation already in progress"))
1343 #endif
1344 #ifdef ENOTSOCK
1345 /*
1346 TRANS A file that isn't a socket was specified when a socket is required. */
1347-_S(ERR_MAP(ENOTSOCK), N_("Socket operation on non-socket"))
1348+_S(ENOTSOCK, N_("Socket operation on non-socket"))
1349 #endif
1350 #ifdef EMSGSIZE
1351 /*
1352 TRANS The size of a message sent on a socket was larger than the supported
1353 TRANS maximum size. */
1354-_S(ERR_MAP(EMSGSIZE), N_("Message too long"))
1355+_S(EMSGSIZE, N_("Message too long"))
1356 #endif
1357 #ifdef EPROTOTYPE
1358 /*
1359 TRANS The socket type does not support the requested communications protocol. */
1360-_S(ERR_MAP(EPROTOTYPE), N_("Protocol wrong type for socket"))
1361+_S(EPROTOTYPE, N_("Protocol wrong type for socket"))
1362 #endif
1363 #ifdef ENOPROTOOPT
1364 /*
1365 TRANS You specified a socket option that doesn't make sense for the
1366 TRANS particular protocol being used by the socket. @xref{Socket Options}. */
1367-_S(ERR_MAP(ENOPROTOOPT), N_("Protocol not available"))
1368+_S(ENOPROTOOPT, N_("Protocol not available"))
1369 #endif
1370 #ifdef EPROTONOSUPPORT
1371 /*
1372 TRANS The socket domain does not support the requested communications protocol
1373 TRANS (perhaps because the requested protocol is completely invalid).
1374 TRANS @xref{Creating a Socket}. */
1375-_S(ERR_MAP(EPROTONOSUPPORT), N_("Protocol not supported"))
1376+_S(EPROTONOSUPPORT, N_("Protocol not supported"))
1377 #endif
1378 #ifdef ESOCKTNOSUPPORT
1379 /*
1380 TRANS The socket type is not supported. */
1381-_S(ERR_MAP(ESOCKTNOSUPPORT), N_("Socket type not supported"))
1382+_S(ESOCKTNOSUPPORT, N_("Socket type not supported"))
1383 #endif
1384 #ifdef EOPNOTSUPP
1385 /*
1386@@ -323,71 +320,71 @@ TRANS implemented for all communications protocols. On @gnuhurdsystems{}, this
1387 TRANS error can happen for many calls when the object does not support the
1388 TRANS particular operation; it is a generic indication that the server knows
1389 TRANS nothing to do for that call. */
1390-_S(ERR_MAP(EOPNOTSUPP), N_("Operation not supported"))
1391+_S(EOPNOTSUPP, N_("Operation not supported"))
1392 #endif
1393 #ifdef EPFNOSUPPORT
1394 /*
1395 TRANS The socket communications protocol family you requested is not supported. */
1396-_S(ERR_MAP(EPFNOSUPPORT), N_("Protocol family not supported"))
1397+_S(EPFNOSUPPORT, N_("Protocol family not supported"))
1398 #endif
1399 #ifdef EAFNOSUPPORT
1400 /*
1401 TRANS The address family specified for a socket is not supported; it is
1402 TRANS inconsistent with the protocol being used on the socket. @xref{Sockets}. */
1403-_S(ERR_MAP(EAFNOSUPPORT), N_("Address family not supported by protocol"))
1404+_S(EAFNOSUPPORT, N_("Address family not supported by protocol"))
1405 #endif
1406 #ifdef EADDRINUSE
1407 /*
1408 TRANS The requested socket address is already in use. @xref{Socket Addresses}. */
1409-_S(ERR_MAP(EADDRINUSE), N_("Address already in use"))
1410+_S(EADDRINUSE, N_("Address already in use"))
1411 #endif
1412 #ifdef EADDRNOTAVAIL
1413 /*
1414 TRANS The requested socket address is not available; for example, you tried
1415 TRANS to give a socket a name that doesn't match the local host name.
1416 TRANS @xref{Socket Addresses}. */
1417-_S(ERR_MAP(EADDRNOTAVAIL), N_("Cannot assign requested address"))
1418+_S(EADDRNOTAVAIL, N_("Cannot assign requested address"))
1419 #endif
1420 #ifdef ENETDOWN
1421 /*
1422 TRANS A socket operation failed because the network was down. */
1423-_S(ERR_MAP(ENETDOWN), N_("Network is down"))
1424+_S(ENETDOWN, N_("Network is down"))
1425 #endif
1426 #ifdef ENETUNREACH
1427 /*
1428 TRANS A socket operation failed because the subnet containing the remote host
1429 TRANS was unreachable. */
1430-_S(ERR_MAP(ENETUNREACH), N_("Network is unreachable"))
1431+_S(ENETUNREACH, N_("Network is unreachable"))
1432 #endif
1433 #ifdef ENETRESET
1434 /*
1435 TRANS A network connection was reset because the remote host crashed. */
1436-_S(ERR_MAP(ENETRESET), N_("Network dropped connection on reset"))
1437+_S(ENETRESET, N_("Network dropped connection on reset"))
1438 #endif
1439 #ifdef ECONNABORTED
1440 /*
1441 TRANS A network connection was aborted locally. */
1442-_S(ERR_MAP(ECONNABORTED), N_("Software caused connection abort"))
1443+_S(ECONNABORTED, N_("Software caused connection abort"))
1444 #endif
1445 #ifdef ECONNRESET
1446 /*
1447 TRANS A network connection was closed for reasons outside the control of the
1448 TRANS local host, such as by the remote machine rebooting or an unrecoverable
1449 TRANS protocol violation. */
1450-_S(ERR_MAP(ECONNRESET), N_("Connection reset by peer"))
1451+_S(ECONNRESET, N_("Connection reset by peer"))
1452 #endif
1453 #ifdef ENOBUFS
1454 /*
1455 TRANS The kernel's buffers for I/O operations are all in use. In GNU, this
1456 TRANS error is always synonymous with @code{ENOMEM}; you may get one or the
1457 TRANS other from network operations. */
1458-_S(ERR_MAP(ENOBUFS), N_("No buffer space available"))
1459+_S(ENOBUFS, N_("No buffer space available"))
1460 #endif
1461 #ifdef EISCONN
1462 /*
1463 TRANS You tried to connect a socket that is already connected.
1464 TRANS @xref{Connecting}. */
1465-_S(ERR_MAP(EISCONN), N_("Transport endpoint is already connected"))
1466+_S(EISCONN, N_("Transport endpoint is already connected"))
1467 #endif
1468 #ifdef ENOTCONN
1469 /*
1470@@ -395,74 +392,74 @@ TRANS The socket is not connected to anything. You get this error when you
1471 TRANS try to transmit data over a socket, without first specifying a
1472 TRANS destination for the data. For a connectionless socket (for datagram
1473 TRANS protocols, such as UDP), you get @code{EDESTADDRREQ} instead. */
1474-_S(ERR_MAP(ENOTCONN), N_("Transport endpoint is not connected"))
1475+_S(ENOTCONN, N_("Transport endpoint is not connected"))
1476 #endif
1477 #ifdef EDESTADDRREQ
1478 /*
1479 TRANS No default destination address was set for the socket. You get this
1480 TRANS error when you try to transmit data over a connectionless socket,
1481 TRANS without first specifying a destination for the data with @code{connect}. */
1482-_S(ERR_MAP(EDESTADDRREQ), N_("Destination address required"))
1483+_S(EDESTADDRREQ, N_("Destination address required"))
1484 #endif
1485 #ifdef ESHUTDOWN
1486 /*
1487 TRANS The socket has already been shut down. */
1488-_S(ERR_MAP(ESHUTDOWN), N_("Cannot send after transport endpoint shutdown"))
1489+_S(ESHUTDOWN, N_("Cannot send after transport endpoint shutdown"))
1490 #endif
1491 #ifdef ETOOMANYREFS
1492-_S(ERR_MAP(ETOOMANYREFS), N_("Too many references: cannot splice"))
1493+_S(ETOOMANYREFS, N_("Too many references: cannot splice"))
1494 #endif
1495 #ifdef ETIMEDOUT
1496 /*
1497 TRANS A socket operation with a specified timeout received no response during
1498 TRANS the timeout period. */
1499-_S(ERR_MAP(ETIMEDOUT), N_("Connection timed out"))
1500+_S(ETIMEDOUT, N_("Connection timed out"))
1501 #endif
1502 #ifdef ECONNREFUSED
1503 /*
1504 TRANS A remote host refused to allow the network connection (typically because
1505 TRANS it is not running the requested service). */
1506-_S(ERR_MAP(ECONNREFUSED), N_("Connection refused"))
1507+_S(ECONNREFUSED, N_("Connection refused"))
1508 #endif
1509 #ifdef ELOOP
1510 /*
1511 TRANS Too many levels of symbolic links were encountered in looking up a file name.
1512 TRANS This often indicates a cycle of symbolic links. */
1513-_S(ERR_MAP(ELOOP), N_("Too many levels of symbolic links"))
1514+_S(ELOOP, N_("Too many levels of symbolic links"))
1515 #endif
1516 #ifdef ENAMETOOLONG
1517 /*
1518 TRANS Filename too long (longer than @code{PATH_MAX}; @pxref{Limits for
1519 TRANS Files}) or host name too long (in @code{gethostname} or
1520 TRANS @code{sethostname}; @pxref{Host Identification}). */
1521-_S(ERR_MAP(ENAMETOOLONG), N_("File name too long"))
1522+_S(ENAMETOOLONG, N_("File name too long"))
1523 #endif
1524 #ifdef EHOSTDOWN
1525 /*
1526 TRANS The remote host for a requested network connection is down. */
1527-_S(ERR_MAP(EHOSTDOWN), N_("Host is down"))
1528+_S(EHOSTDOWN, N_("Host is down"))
1529 #endif
1530 /*
1531 TRANS The remote host for a requested network connection is not reachable. */
1532 #ifdef EHOSTUNREACH
1533-_S(ERR_MAP(EHOSTUNREACH), N_("No route to host"))
1534+_S(EHOSTUNREACH, N_("No route to host"))
1535 #endif
1536 #ifdef ENOTEMPTY
1537 /*
1538 TRANS Directory not empty, where an empty directory was expected. Typically,
1539 TRANS this error occurs when you are trying to delete a directory. */
1540-_S(ERR_MAP(ENOTEMPTY), N_("Directory not empty"))
1541+_S(ENOTEMPTY, N_("Directory not empty"))
1542 #endif
1543 #ifdef EUSERS
1544 /*
1545 TRANS The file quota system is confused because there are too many users.
1546 TRANS @c This can probably happen in a GNU system when using NFS. */
1547-_S(ERR_MAP(EUSERS), N_("Too many users"))
1548+_S(EUSERS, N_("Too many users"))
1549 #endif
1550 #ifdef EDQUOT
1551 /*
1552 TRANS The user's disk quota was exceeded. */
1553-_S(ERR_MAP(EDQUOT), N_("Disk quota exceeded"))
1554+_S(EDQUOT, N_("Disk quota exceeded"))
1555 #endif
1556 #ifdef ESTALE
1557 /*
1558@@ -471,7 +468,7 @@ TRANS file system which is due to file system rearrangements on the server host
1559 TRANS for NFS file systems or corruption in other file systems.
1560 TRANS Repairing this condition usually requires unmounting, possibly repairing
1561 TRANS and remounting the file system. */
1562-_S(ERR_MAP(ESTALE), N_("Stale file handle"))
1563+_S(ESTALE, N_("Stale file handle"))
1564 #endif
1565 #ifdef EREMOTE
1566 /*
1567@@ -479,7 +476,7 @@ TRANS An attempt was made to NFS-mount a remote file system with a file name tha
1568 TRANS already specifies an NFS-mounted file.
1569 TRANS (This is an error on some operating systems, but we expect it to work
1570 TRANS properly on @gnuhurdsystems{}, making this error code impossible.) */
1571-_S(ERR_MAP(EREMOTE), N_("Object is remote"))
1572+_S(EREMOTE, N_("Object is remote"))
1573 #endif
1574 #ifdef ENOLCK
1575 /*
1576@@ -487,7 +484,7 @@ TRANS This is used by the file locking facilities; see
1577 TRANS @ref{File Locks}. This error is never generated by @gnuhurdsystems{}, but
1578 TRANS it can result from an operation to an NFS server running another
1579 TRANS operating system. */
1580-_S(ERR_MAP(ENOLCK), N_("No locks available"))
1581+_S(ENOLCK, N_("No locks available"))
1582 #endif
1583 #ifdef ENOSYS
1584 /*
1585@@ -496,46 +493,46 @@ TRANS not implemented at all, either in the C library itself or in the
1586 TRANS operating system. When you get this error, you can be sure that this
1587 TRANS particular function will always fail with @code{ENOSYS} unless you
1588 TRANS install a new version of the C library or the operating system. */
1589-_S(ERR_MAP(ENOSYS), N_("Function not implemented"))
1590+_S(ENOSYS, N_("Function not implemented"))
1591 #endif
1592 #ifdef EILSEQ
1593 /*
1594 TRANS While decoding a multibyte character the function came along an invalid
1595 TRANS or an incomplete sequence of bytes or the given wide character is invalid. */
1596-_S(ERR_MAP(EILSEQ), N_("Invalid or incomplete multibyte or wide character"))
1597+_S(EILSEQ, N_("Invalid or incomplete multibyte or wide character"))
1598 #endif
1599 #ifdef EBADMSG
1600-_S(ERR_MAP(EBADMSG), N_("Bad message"))
1601+_S(EBADMSG, N_("Bad message"))
1602 #endif
1603 #ifdef EIDRM
1604-_S(ERR_MAP(EIDRM), N_("Identifier removed"))
1605+_S(EIDRM, N_("Identifier removed"))
1606 #endif
1607 #ifdef EMULTIHOP
1608-_S(ERR_MAP(EMULTIHOP), N_("Multihop attempted"))
1609+_S(EMULTIHOP, N_("Multihop attempted"))
1610 #endif
1611 #ifdef ENODATA
1612-_S(ERR_MAP(ENODATA), N_("No data available"))
1613+_S(ENODATA, N_("No data available"))
1614 #endif
1615 #ifdef ENOLINK
1616-_S(ERR_MAP(ENOLINK), N_("Link has been severed"))
1617+_S(ENOLINK, N_("Link has been severed"))
1618 #endif
1619 #ifdef ENOMSG
1620-_S(ERR_MAP(ENOMSG), N_("No message of desired type"))
1621+_S(ENOMSG, N_("No message of desired type"))
1622 #endif
1623 #ifdef ENOSR
1624-_S(ERR_MAP(ENOSR), N_("Out of streams resources"))
1625+_S(ENOSR, N_("Out of streams resources"))
1626 #endif
1627 #ifdef ENOSTR
1628-_S(ERR_MAP(ENOSTR), N_("Device not a stream"))
1629+_S(ENOSTR, N_("Device not a stream"))
1630 #endif
1631 #ifdef EOVERFLOW
1632-_S(ERR_MAP(EOVERFLOW), N_("Value too large for defined data type"))
1633+_S(EOVERFLOW, N_("Value too large for defined data type"))
1634 #endif
1635 #ifdef EPROTO
1636-_S(ERR_MAP(EPROTO), N_("Protocol error"))
1637+_S(EPROTO, N_("Protocol error"))
1638 #endif
1639 #ifdef ETIME
1640-_S(ERR_MAP(ETIME), N_("Timer expired"))
1641+_S(ETIME, N_("Timer expired"))
1642 #endif
1643 #ifdef ECANCELED
1644 /*
1645@@ -543,148 +540,148 @@ TRANS An asynchronous operation was canceled before it
1646 TRANS completed. @xref{Asynchronous I/O}. When you call @code{aio_cancel},
1647 TRANS the normal result is for the operations affected to complete with this
1648 TRANS error; @pxref{Cancel AIO Operations}. */
1649-_S(ERR_MAP(ECANCELED), N_("Operation canceled"))
1650+_S(ECANCELED, N_("Operation canceled"))
1651 #endif
1652 #ifdef EOWNERDEAD
1653-_S(ERR_MAP(EOWNERDEAD), N_("Owner died"))
1654+_S(EOWNERDEAD, N_("Owner died"))
1655 #endif
1656 #ifdef ENOTRECOVERABLE
1657-_S(ERR_MAP(ENOTRECOVERABLE), N_("State not recoverable"))
1658+_S(ENOTRECOVERABLE, N_("State not recoverable"))
1659 #endif
1660 #ifdef ERESTART
1661-_S(ERR_MAP(ERESTART), N_("Interrupted system call should be restarted"))
1662+_S(ERESTART, N_("Interrupted system call should be restarted"))
1663 #endif
1664 #ifdef ECHRNG
1665-_S(ERR_MAP(ECHRNG), N_("Channel number out of range"))
1666+_S(ECHRNG, N_("Channel number out of range"))
1667 #endif
1668 #ifdef EL2NSYNC
1669-_S(ERR_MAP(EL2NSYNC), N_("Level 2 not synchronized"))
1670+_S(EL2NSYNC, N_("Level 2 not synchronized"))
1671 #endif
1672 #ifdef EL3HLT
1673-_S(ERR_MAP(EL3HLT), N_("Level 3 halted"))
1674+_S(EL3HLT, N_("Level 3 halted"))
1675 #endif
1676 #ifdef EL3RST
1677-_S(ERR_MAP(EL3RST), N_("Level 3 reset"))
1678+_S(EL3RST, N_("Level 3 reset"))
1679 #endif
1680 #ifdef ELNRNG
1681-_S(ERR_MAP(ELNRNG), N_("Link number out of range"))
1682+_S(ELNRNG, N_("Link number out of range"))
1683 #endif
1684 #ifdef EUNATCH
1685-_S(ERR_MAP(EUNATCH), N_("Protocol driver not attached"))
1686+_S(EUNATCH, N_("Protocol driver not attached"))
1687 #endif
1688 #ifdef ENOCSI
1689-_S(ERR_MAP(ENOCSI), N_("No CSI structure available"))
1690+_S(ENOCSI, N_("No CSI structure available"))
1691 #endif
1692 #ifdef EL2HLT
1693-_S(ERR_MAP(EL2HLT), N_("Level 2 halted"))
1694+_S(EL2HLT, N_("Level 2 halted"))
1695 #endif
1696 #ifdef EBADE
1697-_S(ERR_MAP(EBADE), N_("Invalid exchange"))
1698+_S(EBADE, N_("Invalid exchange"))
1699 #endif
1700 #ifdef EBADR
1701-_S(ERR_MAP(EBADR), N_("Invalid request descriptor"))
1702+_S(EBADR, N_("Invalid request descriptor"))
1703 #endif
1704 #ifdef EXFULL
1705-_S(ERR_MAP(EXFULL), N_("Exchange full"))
1706+_S(EXFULL, N_("Exchange full"))
1707 #endif
1708 #ifdef ENOANO
1709-_S(ERR_MAP(ENOANO), N_("No anode"))
1710+_S(ENOANO, N_("No anode"))
1711 #endif
1712 #ifdef EBADRQC
1713-_S(ERR_MAP(EBADRQC), N_("Invalid request code"))
1714+_S(EBADRQC, N_("Invalid request code"))
1715 #endif
1716 #ifdef EBADSLT
1717-_S(ERR_MAP(EBADSLT), N_("Invalid slot"))
1718+_S(EBADSLT, N_("Invalid slot"))
1719 #endif
1720 #ifdef EBFONT
1721-_S(ERR_MAP(EBFONT), N_("Bad font file format"))
1722+_S(EBFONT, N_("Bad font file format"))
1723 #endif
1724 #ifdef ENONET
1725-_S(ERR_MAP(ENONET), N_("Machine is not on the network"))
1726+_S(ENONET, N_("Machine is not on the network"))
1727 #endif
1728 #ifdef ENOPKG
1729-_S(ERR_MAP(ENOPKG), N_("Package not installed"))
1730+_S(ENOPKG, N_("Package not installed"))
1731 #endif
1732 #ifdef EADV
1733-_S(ERR_MAP(EADV), N_("Advertise error"))
1734+_S(EADV, N_("Advertise error"))
1735 #endif
1736 #ifdef ESRMNT
1737-_S(ERR_MAP(ESRMNT), N_("Srmount error"))
1738+_S(ESRMNT, N_("Srmount error"))
1739 #endif
1740 #ifdef ECOMM
1741-_S(ERR_MAP(ECOMM), N_("Communication error on send"))
1742+_S(ECOMM, N_("Communication error on send"))
1743 #endif
1744 #ifdef EDOTDOT
1745-_S(ERR_MAP(EDOTDOT), N_("RFS specific error"))
1746+_S(EDOTDOT, N_("RFS specific error"))
1747 #endif
1748 #ifdef ENOTUNIQ
1749-_S(ERR_MAP(ENOTUNIQ), N_("Name not unique on network"))
1750+_S(ENOTUNIQ, N_("Name not unique on network"))
1751 #endif
1752 #ifdef EBADFD
1753-_S(ERR_MAP(EBADFD), N_("File descriptor in bad state"))
1754+_S(EBADFD, N_("File descriptor in bad state"))
1755 #endif
1756 #ifdef EREMCHG
1757-_S(ERR_MAP(EREMCHG), N_("Remote address changed"))
1758+_S(EREMCHG, N_("Remote address changed"))
1759 #endif
1760 #ifdef ELIBACC
1761-_S(ERR_MAP(ELIBACC), N_("Can not access a needed shared library"))
1762+_S(ELIBACC, N_("Can not access a needed shared library"))
1763 #endif
1764 #ifdef ELIBBAD
1765-_S(ERR_MAP(ELIBBAD), N_("Accessing a corrupted shared library"))
1766+_S(ELIBBAD, N_("Accessing a corrupted shared library"))
1767 #endif
1768 #ifdef ELIBSCN
1769-_S(ERR_MAP(ELIBSCN), N_(".lib section in a.out corrupted"))
1770+_S(ELIBSCN, N_(".lib section in a.out corrupted"))
1771 #endif
1772 #ifdef ELIBMAX
1773-_S(ERR_MAP(ELIBMAX), N_("Attempting to link in too many shared libraries"))
1774+_S(ELIBMAX, N_("Attempting to link in too many shared libraries"))
1775 #endif
1776 #ifdef ELIBEXEC
1777-_S(ERR_MAP(ELIBEXEC), N_("Cannot exec a shared library directly"))
1778+_S(ELIBEXEC, N_("Cannot exec a shared library directly"))
1779 #endif
1780 #ifdef ESTRPIPE
1781-_S(ERR_MAP(ESTRPIPE), N_("Streams pipe error"))
1782+_S(ESTRPIPE, N_("Streams pipe error"))
1783 #endif
1784 #ifdef EUCLEAN
1785-_S(ERR_MAP(EUCLEAN), N_("Structure needs cleaning"))
1786+_S(EUCLEAN, N_("Structure needs cleaning"))
1787 #endif
1788 #ifdef ENOTNAM
1789-_S(ERR_MAP(ENOTNAM), N_("Not a XENIX named type file"))
1790+_S(ENOTNAM, N_("Not a XENIX named type file"))
1791 #endif
1792 #ifdef ENAVAIL
1793-_S(ERR_MAP(ENAVAIL), N_("No XENIX semaphores available"))
1794+_S(ENAVAIL, N_("No XENIX semaphores available"))
1795 #endif
1796 #ifdef EISNAM
1797-_S(ERR_MAP(EISNAM), N_("Is a named type file"))
1798+_S(EISNAM, N_("Is a named type file"))
1799 #endif
1800 #ifdef EREMOTEIO
1801-_S(ERR_MAP(EREMOTEIO), N_("Remote I/O error"))
1802+_S(EREMOTEIO, N_("Remote I/O error"))
1803 #endif
1804 #ifdef ENOMEDIUM
1805-_S(ERR_MAP(ENOMEDIUM), N_("No medium found"))
1806+_S(ENOMEDIUM, N_("No medium found"))
1807 #endif
1808 #ifdef EMEDIUMTYPE
1809-_S(ERR_MAP(EMEDIUMTYPE), N_("Wrong medium type"))
1810+_S(EMEDIUMTYPE, N_("Wrong medium type"))
1811 #endif
1812 #ifdef ENOKEY
1813-_S(ERR_MAP(ENOKEY), N_("Required key not available"))
1814+_S(ENOKEY, N_("Required key not available"))
1815 #endif
1816 #ifdef EKEYEXPIRED
1817-_S(ERR_MAP(EKEYEXPIRED), N_("Key has expired"))
1818+_S(EKEYEXPIRED, N_("Key has expired"))
1819 #endif
1820 #ifdef EKEYREVOKED
1821-_S(ERR_MAP(EKEYREVOKED), N_("Key has been revoked"))
1822+_S(EKEYREVOKED, N_("Key has been revoked"))
1823 #endif
1824 #ifdef EKEYREJECTED
1825-_S(ERR_MAP(EKEYREJECTED), N_("Key was rejected by service"))
1826+_S(EKEYREJECTED, N_("Key was rejected by service"))
1827 #endif
1828 #ifdef ERFKILL
1829-_S(ERR_MAP(ERFKILL), N_("Operation not possible due to RF-kill"))
1830+_S(ERFKILL, N_("Operation not possible due to RF-kill"))
1831 #endif
1832 #ifdef EHWPOISON
1833-_S(ERR_MAP(EHWPOISON), N_("Memory page has hardware error"))
1834+_S(EHWPOISON, N_("Memory page has hardware error"))
1835 #endif
1836 #ifdef EBADRPC
1837-_S(ERR_MAP(EBADRPC), N_("RPC struct is bad"))
1838+_S(EBADRPC, N_("RPC struct is bad"))
1839 #endif
1840 #ifdef EFTYPE
1841 /*
1842@@ -693,40 +690,40 @@ TRANS operation, or a data file had the wrong format.
1843 TRANS
1844 TRANS On some systems @code{chmod} returns this error if you try to set the
1845 TRANS sticky bit on a non-directory file; @pxref{Setting Permissions}. */
1846-_S(ERR_MAP(EFTYPE), N_("Inappropriate file type or format"))
1847+_S(EFTYPE, N_("Inappropriate file type or format"))
1848 #endif
1849 #ifdef EPROCUNAVAIL
1850-_S(ERR_MAP(EPROCUNAVAIL), N_("RPC bad procedure for program"))
1851+_S(EPROCUNAVAIL, N_("RPC bad procedure for program"))
1852 #endif
1853 #ifdef EAUTH
1854-_S(ERR_MAP(EAUTH), N_("Authentication error"))
1855+_S(EAUTH, N_("Authentication error"))
1856 #endif
1857 #ifdef EDIED
1858 /*
1859 TRANS On @gnuhurdsystems{}, opening a file returns this error when the file is
1860 TRANS translated by a program and the translator program dies while starting
1861 TRANS up, before it has connected to the file. */
1862-_S(ERR_MAP(EDIED), N_("Translator died"))
1863+_S(EDIED, N_("Translator died"))
1864 #endif
1865 #ifdef ERPCMISMATCH
1866-_S(ERR_MAP(ERPCMISMATCH), N_("RPC version wrong"))
1867+_S(ERPCMISMATCH, N_("RPC version wrong"))
1868 #endif
1869 #ifdef EGREGIOUS
1870 /*
1871 TRANS You did @strong{what}? */
1872-_S(ERR_MAP(EGREGIOUS), N_("You really blew it this time"))
1873+_S(EGREGIOUS, N_("You really blew it this time"))
1874 #endif
1875 #ifdef EPROCLIM
1876 /*
1877 TRANS This means that the per-user limit on new process would be exceeded by
1878 TRANS an attempted @code{fork}. @xref{Limits on Resources}, for details on
1879 TRANS the @code{RLIMIT_NPROC} limit. */
1880-_S(ERR_MAP(EPROCLIM), N_("Too many processes"))
1881+_S(EPROCLIM, N_("Too many processes"))
1882 #endif
1883 #ifdef EGRATUITOUS
1884 /*
1885 TRANS This error code has no purpose. */
1886-_S(ERR_MAP(EGRATUITOUS), N_("Gratuitous error"))
1887+_S(EGRATUITOUS, N_("Gratuitous error"))
1888 #endif
1889 #if defined (ENOTSUP) && ENOTSUP != EOPNOTSUPP
1890 /*
1891@@ -742,10 +739,10 @@ TRANS values.
1892 TRANS
1893 TRANS If the entire function is not available at all in the implementation,
1894 TRANS it returns @code{ENOSYS} instead. */
1895-_S(ERR_MAP(ENOTSUP), N_("Not supported"))
1896+_S(ENOTSUP, N_("Not supported"))
1897 #endif
1898 #ifdef EPROGMISMATCH
1899-_S(ERR_MAP(EPROGMISMATCH), N_("RPC program version wrong"))
1900+_S(EPROGMISMATCH, N_("RPC program version wrong"))
1901 #endif
1902 #ifdef EBACKGROUND
1903 /*
1904@@ -755,7 +752,7 @@ TRANS foreground process group of the terminal. Users do not usually see this
1905 TRANS error because functions such as @code{read} and @code{write} translate
1906 TRANS it into a @code{SIGTTIN} or @code{SIGTTOU} signal. @xref{Job Control},
1907 TRANS for information on process groups and these signals. */
1908-_S(ERR_MAP(EBACKGROUND), N_("Inappropriate operation for background process"))
1909+_S(EBACKGROUND, N_("Inappropriate operation for background process"))
1910 #endif
1911 #ifdef EIEIO
1912 /*
1913@@ -773,7 +770,7 @@ TRANS @c "bought the farm" means "died". -jtobey
1914 TRANS @c
1915 TRANS @c Translators, please do not translate this litteraly, translate it into
1916 TRANS @c an idiomatic funny way of saying that the computer died. */
1917-_S(ERR_MAP(EIEIO), N_("Computer bought the farm"))
1918+_S(EIEIO, N_("Computer bought the farm"))
1919 #endif
1920 #if defined (EWOULDBLOCK) && EWOULDBLOCK != EAGAIN
1921 /*
1922@@ -782,18 +779,18 @@ TRANS The values are always the same, on every operating system.
1923 TRANS
1924 TRANS C libraries in many older Unix systems have @code{EWOULDBLOCK} as a
1925 TRANS separate error code. */
1926-_S(ERR_MAP(EWOULDBLOCK), N_("Operation would block"))
1927+_S(EWOULDBLOCK, N_("Operation would block"))
1928 #endif
1929 #ifdef ENEEDAUTH
1930-_S(ERR_MAP(ENEEDAUTH), N_("Need authenticator"))
1931+_S(ENEEDAUTH, N_("Need authenticator"))
1932 #endif
1933 #ifdef ED
1934 /*
1935 TRANS The experienced user will know what is wrong.
1936 TRANS @c This error code is a joke. Its perror text is part of the joke.
1937 TRANS @c Don't change it. */
1938-_S(ERR_MAP(ED), N_("?"))
1939+_S(ED, N_("?"))
1940 #endif
1941 #ifdef EPROGUNAVAIL
1942-_S(ERR_MAP(EPROGUNAVAIL), N_("RPC program not available"))
1943+_S(EPROGUNAVAIL, N_("RPC program not available"))
1944 #endif
1945diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile
1946index 9b2a253032..34748ffcd1 100644
1947--- a/sysdeps/unix/sysv/linux/Makefile
1948+++ b/sysdeps/unix/sysv/linux/Makefile
1949@@ -100,7 +100,7 @@ tests += tst-clone tst-clone2 tst-clone3 tst-fanotify tst-personality \
1950 tst-quota tst-sync_file_range tst-sysconf-iov_max tst-ttyname \
1951 test-errno-linux tst-memfd_create tst-mlock2 tst-pkey \
1952 tst-rlimit-infinity tst-ofdlocks tst-gettid tst-gettid-kill \
1953- tst-tgkill
1954+ tst-tgkill tst-sysvsem-linux tst-sysvmsg-linux tst-sysvshm-linux
1955 tests-internal += tst-ofdlocks-compat tst-sigcontext-get_pc
1956
1957 CFLAGS-tst-sigcontext-get_pc.c = -fasynchronous-unwind-tables
1958diff --git a/sysdeps/unix/sysv/linux/aarch64/configure b/sysdeps/unix/sysv/linux/aarch64/configure
1959index 27d50e1d3c..290670a67a 100644
1960--- a/sysdeps/unix/sysv/linux/aarch64/configure
1961+++ b/sysdeps/unix/sysv/linux/aarch64/configure
1962@@ -6,10 +6,10 @@ arch_minimum_kernel=3.7.0
1963 test -n "$libc_cv_slibdir" ||
1964 case "$prefix" in
1965 /usr | /usr/)
1966- libc_cv_slibdir='/lib64'
1967+ libc_cv_slibdir='/lib'
1968 libc_cv_rtlddir='/lib'
1969 if test "$libdir" = '${exec_prefix}/lib'; then
1970- libdir='${exec_prefix}/lib64';
1971+ libdir='${exec_prefix}/lib';
1972 # Locale data can be shared between 32-bit and 64-bit libraries.
1973 libc_cv_complocaledir='${exec_prefix}/lib/locale'
1974 fi
1975diff --git a/sysdeps/unix/sysv/linux/aarch64/cpu-features.h b/sysdeps/unix/sysv/linux/aarch64/cpu-features.h
1976index fc688450ee..00a4d0c8e7 100644
1977--- a/sysdeps/unix/sysv/linux/aarch64/cpu-features.h
1978+++ b/sysdeps/unix/sysv/linux/aarch64/cpu-features.h
1979@@ -54,6 +54,10 @@
1980 && MIDR_PARTNUM(midr) == 0x000)
1981 #define IS_NEOVERSE_N1(midr) (MIDR_IMPLEMENTOR(midr) == 'A' \
1982 && MIDR_PARTNUM(midr) == 0xd0c)
1983+#define IS_NEOVERSE_N2(midr) (MIDR_IMPLEMENTOR(midr) == 'A' \
1984+ && MIDR_PARTNUM(midr) == 0xd49)
1985+#define IS_NEOVERSE_V1(midr) (MIDR_IMPLEMENTOR(midr) == 'A' \
1986+ && MIDR_PARTNUM(midr) == 0xd40)
1987
1988 #define IS_EMAG(midr) (MIDR_IMPLEMENTOR(midr) == 'P' \
1989 && MIDR_PARTNUM(midr) == 0x000)
1990diff --git a/sysdeps/unix/sysv/linux/msgctl.c b/sysdeps/unix/sysv/linux/msgctl.c
1991index 0776472d5e..a1f24ab242 100644
1992--- a/sysdeps/unix/sysv/linux/msgctl.c
1993+++ b/sysdeps/unix/sysv/linux/msgctl.c
1994@@ -90,8 +90,15 @@ __msgctl64 (int msqid, int cmd, struct __msqid64_ds *buf)
1995 struct kernel_msqid64_ds ksemid, *arg = NULL;
1996 if (buf != NULL)
1997 {
1998- msqid64_to_kmsqid64 (buf, &ksemid);
1999- arg = &ksemid;
2000+ /* This is a Linux extension where kernel returns a 'struct msginfo'
2001+ instead. */
2002+ if (cmd == IPC_INFO || cmd == MSG_INFO)
2003+ arg = (struct kernel_msqid64_ds *) buf;
2004+ else
2005+ {
2006+ msqid64_to_kmsqid64 (buf, &ksemid);
2007+ arg = &ksemid;
2008+ }
2009 }
2010 # ifdef __ASSUME_SYSVIPC_BROKEN_MODE_T
2011 if (cmd == IPC_SET)
2012@@ -169,8 +176,15 @@ __msgctl (int msqid, int cmd, struct msqid_ds *buf)
2013 struct __msqid64_ds msqid64, *buf64 = NULL;
2014 if (buf != NULL)
2015 {
2016- msqid_to_msqid64 (&msqid64, buf);
2017- buf64 = &msqid64;
2018+ /* This is a Linux extension where kernel returns a 'struct msginfo'
2019+ instead. */
2020+ if (cmd == IPC_INFO || cmd == MSG_INFO)
2021+ buf64 = (struct __msqid64_ds *) buf;
2022+ else
2023+ {
2024+ msqid_to_msqid64 (&msqid64, buf);
2025+ buf64 = &msqid64;
2026+ }
2027 }
2028
2029 int ret = __msgctl64 (msqid, cmd, buf64);
2030diff --git a/sysdeps/unix/sysv/linux/semctl.c b/sysdeps/unix/sysv/linux/semctl.c
2031index f131a26fc7..1cdabde8f2 100644
2032--- a/sysdeps/unix/sysv/linux/semctl.c
2033+++ b/sysdeps/unix/sysv/linux/semctl.c
2034@@ -102,6 +102,7 @@ semun64_to_ksemun64 (int cmd, union semun64 semun64,
2035 r.array = semun64.array;
2036 break;
2037 case SEM_STAT:
2038+ case SEM_STAT_ANY:
2039 case IPC_STAT:
2040 case IPC_SET:
2041 r.buf = buf;
2042@@ -150,6 +151,7 @@ __semctl64 (int semid, int semnum, int cmd, ...)
2043 case IPC_STAT: /* arg.buf */
2044 case IPC_SET:
2045 case SEM_STAT:
2046+ case SEM_STAT_ANY:
2047 case IPC_INFO: /* arg.__buf */
2048 case SEM_INFO:
2049 va_start (ap, cmd);
2050@@ -238,6 +240,7 @@ semun_to_semun64 (int cmd, union semun semun, struct __semid64_ds *semid64)
2051 r.array = semun.array;
2052 break;
2053 case SEM_STAT:
2054+ case SEM_STAT_ANY:
2055 case IPC_STAT:
2056 case IPC_SET:
2057 r.buf = semid64;
2058@@ -267,6 +270,7 @@ __semctl (int semid, int semnum, int cmd, ...)
2059 case IPC_STAT: /* arg.buf */
2060 case IPC_SET:
2061 case SEM_STAT:
2062+ case SEM_STAT_ANY:
2063 case IPC_INFO: /* arg.__buf */
2064 case SEM_INFO:
2065 va_start (ap, cmd);
2066@@ -321,6 +325,7 @@ __semctl_mode16 (int semid, int semnum, int cmd, ...)
2067 case IPC_STAT: /* arg.buf */
2068 case IPC_SET:
2069 case SEM_STAT:
2070+ case SEM_STAT_ANY:
2071 case IPC_INFO: /* arg.__buf */
2072 case SEM_INFO:
2073 va_start (ap, cmd);
2074@@ -354,6 +359,7 @@ __old_semctl (int semid, int semnum, int cmd, ...)
2075 case IPC_STAT: /* arg.buf */
2076 case IPC_SET:
2077 case SEM_STAT:
2078+ case SEM_STAT_ANY:
2079 case IPC_INFO: /* arg.__buf */
2080 case SEM_INFO:
2081 va_start (ap, cmd);
2082diff --git a/sysdeps/unix/sysv/linux/shmctl.c b/sysdeps/unix/sysv/linux/shmctl.c
2083index 76d88441f1..1d19a798b1 100644
2084--- a/sysdeps/unix/sysv/linux/shmctl.c
2085+++ b/sysdeps/unix/sysv/linux/shmctl.c
2086@@ -90,8 +90,15 @@ __shmctl64 (int shmid, int cmd, struct __shmid64_ds *buf)
2087 struct kernel_shmid64_ds kshmid, *arg = NULL;
2088 if (buf != NULL)
2089 {
2090- shmid64_to_kshmid64 (buf, &kshmid);
2091- arg = &kshmid;
2092+ /* This is a Linux extension where kernel expects either a
2093+ 'struct shminfo' (IPC_INFO) or 'struct shm_info' (SHM_INFO). */
2094+ if (cmd == IPC_INFO || cmd == SHM_INFO)
2095+ arg = (struct kernel_shmid64_ds *) buf;
2096+ else
2097+ {
2098+ shmid64_to_kshmid64 (buf, &kshmid);
2099+ arg = &kshmid;
2100+ }
2101 }
2102 # ifdef __ASSUME_SYSVIPC_BROKEN_MODE_T
2103 if (cmd == IPC_SET)
2104@@ -107,7 +114,6 @@ __shmctl64 (int shmid, int cmd, struct __shmid64_ds *buf)
2105
2106 switch (cmd)
2107 {
2108- case IPC_INFO:
2109 case IPC_STAT:
2110 case SHM_STAT:
2111 case SHM_STAT_ANY:
2112@@ -168,8 +174,15 @@ __shmctl (int shmid, int cmd, struct shmid_ds *buf)
2113 struct __shmid64_ds shmid64, *buf64 = NULL;
2114 if (buf != NULL)
2115 {
2116- shmid_to_shmid64 (&shmid64, buf);
2117- buf64 = &shmid64;
2118+ /* This is a Linux extension where kernel expects either a
2119+ 'struct shminfo' (IPC_INFO) or 'struct shm_info' (SHM_INFO). */
2120+ if (cmd == IPC_INFO || cmd == SHM_INFO)
2121+ buf64 = (struct __shmid64_ds *) buf;
2122+ else
2123+ {
2124+ shmid_to_shmid64 (&shmid64, buf);
2125+ buf64 = &shmid64;
2126+ }
2127 }
2128
2129 int ret = __shmctl64 (shmid, cmd, buf64);
2130@@ -178,7 +191,6 @@ __shmctl (int shmid, int cmd, struct shmid_ds *buf)
2131
2132 switch (cmd)
2133 {
2134- case IPC_INFO:
2135 case IPC_STAT:
2136 case SHM_STAT:
2137 case SHM_STAT_ANY:
2138diff --git a/sysdeps/unix/sysv/linux/tst-sysvmsg-linux.c b/sysdeps/unix/sysv/linux/tst-sysvmsg-linux.c
2139new file mode 100644
2140index 0000000000..630f4f792c
2141--- /dev/null
2142+++ b/sysdeps/unix/sysv/linux/tst-sysvmsg-linux.c
2143@@ -0,0 +1,177 @@
2144+/* Basic tests for Linux SYSV message queue extensions.
2145+ Copyright (C) 2020 Free Software Foundation, Inc.
2146+ This file is part of the GNU C Library.
2147+
2148+ The GNU C Library is free software; you can redistribute it and/or
2149+ modify it under the terms of the GNU Lesser General Public
2150+ License as published by the Free Software Foundation; either
2151+ version 2.1 of the License, or (at your option) any later version.
2152+
2153+ The GNU C Library is distributed in the hope that it will be useful,
2154+ but WITHOUT ANY WARRANTY; without even the implied warranty of
2155+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2156+ Lesser General Public License for more details.
2157+
2158+ You should have received a copy of the GNU Lesser General Public
2159+ License along with the GNU C Library; if not, see
2160+ <https://www.gnu.org/licenses/>. */
2161+
2162+#include <sys/ipc.h>
2163+#include <sys/msg.h>
2164+#include <errno.h>
2165+#include <stdlib.h>
2166+#include <stdbool.h>
2167+#include <stdio.h>
2168+
2169+#include <support/check.h>
2170+#include <support/temp_file.h>
2171+
2172+#define MSGQ_MODE 0644
2173+
2174+/* These are for the temporary file we generate. */
2175+static char *name;
2176+static int msqid;
2177+
2178+static void
2179+remove_msq (void)
2180+{
2181+ /* Enforce message queue removal in case of early test failure.
2182+ Ignore error since the msg may already have being removed. */
2183+ msgctl (msqid, IPC_RMID, NULL);
2184+}
2185+
2186+static void
2187+do_prepare (int argc, char *argv[])
2188+{
2189+ TEST_VERIFY_EXIT (create_temp_file ("tst-sysvmsg.", &name) != -1);
2190+}
2191+
2192+#define PREPARE do_prepare
2193+
2194+struct test_msginfo
2195+{
2196+ int msgmax;
2197+ int msgmnb;
2198+ int msgmni;
2199+};
2200+
2201+/* It tries to obtain some system-wide SysV messsage queue information from
2202+ /proc to check against IPC_INFO/MSG_INFO. The /proc only returns the
2203+ tunables value of MSGMAX, MSGMNB, and MSGMNI.
2204+
2205+ The kernel also returns constant value for MSGSSZ, MSGSEG and also MSGMAP,
2206+ MSGPOOL, and MSGTQL (for IPC_INFO). The issue to check them is they might
2207+ change over kernel releases. */
2208+
2209+static int
2210+read_proc_file (const char *file)
2211+{
2212+ FILE *f = fopen (file, "r");
2213+ if (f == NULL)
2214+ FAIL_UNSUPPORTED ("/proc is not mounted or %s is not available", file);
2215+
2216+ int v;
2217+ int r = fscanf (f, "%d", & v);
2218+ TEST_VERIFY_EXIT (r == 1);
2219+
2220+ fclose (f);
2221+ return v;
2222+}
2223+
2224+
2225+/* Check if the message queue with IDX (index into the kernel's internal
2226+ array) matches the one with KEY. The CMD is either MSG_STAT or
2227+ MSG_STAT_ANY. */
2228+
2229+static bool
2230+check_msginfo (int idx, key_t key, int cmd)
2231+{
2232+ struct msqid_ds msginfo;
2233+ int mid = msgctl (idx, cmd, &msginfo);
2234+ /* Ignore unused array slot returned by the kernel or information from
2235+ unknown message queue. */
2236+ if ((mid == -1 && errno == EINVAL) || mid != msqid)
2237+ return false;
2238+
2239+ if (mid == -1)
2240+ FAIL_EXIT1 ("msgctl with %s failed: %m",
2241+ cmd == MSG_STAT ? "MSG_STAT" : "MSG_STAT_ANY");
2242+
2243+ TEST_COMPARE (msginfo.msg_perm.__key, key);
2244+ TEST_COMPARE (msginfo.msg_perm.mode, MSGQ_MODE);
2245+ TEST_COMPARE (msginfo.msg_qnum, 0);
2246+
2247+ return true;
2248+}
2249+
2250+static int
2251+do_test (void)
2252+{
2253+ atexit (remove_msq);
2254+
2255+ key_t key = ftok (name, 'G');
2256+ if (key == -1)
2257+ FAIL_EXIT1 ("ftok failed: %m");
2258+
2259+ msqid = msgget (key, MSGQ_MODE | IPC_CREAT);
2260+ if (msqid == -1)
2261+ FAIL_EXIT1 ("msgget failed: %m");
2262+
2263+ struct test_msginfo tipcinfo;
2264+ tipcinfo.msgmax = read_proc_file ("/proc/sys/kernel/msgmax");
2265+ tipcinfo.msgmnb = read_proc_file ("/proc/sys/kernel/msgmnb");
2266+ tipcinfo.msgmni = read_proc_file ("/proc/sys/kernel/msgmni");
2267+
2268+ int msqidx;
2269+
2270+ {
2271+ struct msginfo ipcinfo;
2272+ msqidx = msgctl (msqid, IPC_INFO, (struct msqid_ds *) &ipcinfo);
2273+ if (msqidx == -1)
2274+ FAIL_EXIT1 ("msgctl with IPC_INFO failed: %m");
2275+
2276+ TEST_COMPARE (ipcinfo.msgmax, tipcinfo.msgmax);
2277+ TEST_COMPARE (ipcinfo.msgmnb, tipcinfo.msgmnb);
2278+ TEST_COMPARE (ipcinfo.msgmni, tipcinfo.msgmni);
2279+ }
2280+
2281+ /* Same as before but with MSG_INFO. */
2282+ {
2283+ struct msginfo ipcinfo;
2284+ msqidx = msgctl (msqid, MSG_INFO, (struct msqid_ds *) &ipcinfo);
2285+ if (msqidx == -1)
2286+ FAIL_EXIT1 ("msgctl with IPC_INFO failed: %m");
2287+
2288+ TEST_COMPARE (ipcinfo.msgmax, tipcinfo.msgmax);
2289+ TEST_COMPARE (ipcinfo.msgmnb, tipcinfo.msgmnb);
2290+ TEST_COMPARE (ipcinfo.msgmni, tipcinfo.msgmni);
2291+ }
2292+
2293+ /* We check if the created message queue shows in global list. */
2294+ bool found = false;
2295+ for (int i = 0; i <= msqidx; i++)
2296+ {
2297+ /* We can't tell apart if MSG_STAT_ANY is not supported (kernel older
2298+ than 4.17) or if the index used is invalid. So it just check if the
2299+ value returned from a valid call matches the created message
2300+ queue. */
2301+ check_msginfo (i, key, MSG_STAT_ANY);
2302+
2303+ if (check_msginfo (i, key, MSG_STAT))
2304+ {
2305+ found = true;
2306+ break;
2307+ }
2308+ }
2309+
2310+ if (!found)
2311+ FAIL_EXIT1 ("msgctl with MSG_STAT/MSG_STAT_ANY could not find the "
2312+ "created message queue");
2313+
2314+ if (msgctl (msqid, IPC_RMID, NULL) == -1)
2315+ FAIL_EXIT1 ("msgctl failed");
2316+
2317+ return 0;
2318+}
2319+
2320+#include <support/test-driver.c>
2321diff --git a/sysdeps/unix/sysv/linux/tst-sysvsem-linux.c b/sysdeps/unix/sysv/linux/tst-sysvsem-linux.c
2322new file mode 100644
2323index 0000000000..45f19e2d37
2324--- /dev/null
2325+++ b/sysdeps/unix/sysv/linux/tst-sysvsem-linux.c
2326@@ -0,0 +1,184 @@
2327+/* Basic tests for Linux SYSV semaphore extensions.
2328+ Copyright (C) 2020 Free Software Foundation, Inc.
2329+ This file is part of the GNU C Library.
2330+
2331+ The GNU C Library is free software; you can redistribute it and/or
2332+ modify it under the terms of the GNU Lesser General Public
2333+ License as published by the Free Software Foundation; either
2334+ version 2.1 of the License, or (at your option) any later version.
2335+
2336+ The GNU C Library is distributed in the hope that it will be useful,
2337+ but WITHOUT ANY WARRANTY; without even the implied warranty of
2338+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2339+ Lesser General Public License for more details.
2340+
2341+ You should have received a copy of the GNU Lesser General Public
2342+ License along with the GNU C Library; if not, see
2343+ <https://www.gnu.org/licenses/>. */
2344+
2345+#include <sys/ipc.h>
2346+#include <sys/sem.h>
2347+#include <errno.h>
2348+#include <stdlib.h>
2349+#include <stdbool.h>
2350+#include <stdio.h>
2351+
2352+#include <support/check.h>
2353+#include <support/temp_file.h>
2354+
2355+/* These are for the temporary file we generate. */
2356+static char *name;
2357+static int semid;
2358+
2359+static void
2360+remove_sem (void)
2361+{
2362+ /* Enforce message queue removal in case of early test failure.
2363+ Ignore error since the sem may already have being removed. */
2364+ semctl (semid, 0, IPC_RMID, 0);
2365+}
2366+
2367+static void
2368+do_prepare (int argc, char *argv[])
2369+{
2370+ TEST_VERIFY_EXIT (create_temp_file ("tst-sysvsem.", &name) != -1);
2371+}
2372+
2373+#define PREPARE do_prepare
2374+
2375+#define SEM_MODE 0644
2376+
2377+union semun
2378+{
2379+ int val;
2380+ struct semid_ds *buf;
2381+ unsigned short *array;
2382+ struct seminfo *__buf;
2383+};
2384+
2385+struct test_seminfo
2386+{
2387+ int semmsl;
2388+ int semmns;
2389+ int semopm;
2390+ int semmni;
2391+};
2392+
2393+/* It tries to obtain some system-wide SysV semaphore information from /proc
2394+ to check against IPC_INFO/SEM_INFO. The /proc only returns the tunables
2395+ value of SEMMSL, SEMMNS, SEMOPM, and SEMMNI.
2396+
2397+ The kernel also returns constant value for SEMVMX, SEMMNU, SEMMAP, SEMUME,
2398+ and also SEMUSZ and SEMAEM (for IPC_INFO). The issue to check them is they
2399+ might change over kernel releases. */
2400+
2401+static void
2402+read_sem_stat (struct test_seminfo *tseminfo)
2403+{
2404+ FILE *f = fopen ("/proc/sys/kernel/sem", "r");
2405+ if (f == NULL)
2406+ FAIL_UNSUPPORTED ("/proc is not mounted or /proc/sys/kernel/sem is not "
2407+ "available");
2408+
2409+ int r = fscanf (f, "%d %d %d %d",
2410+ &tseminfo->semmsl, &tseminfo->semmns, &tseminfo->semopm,
2411+ &tseminfo->semmni);
2412+ TEST_VERIFY_EXIT (r == 4);
2413+
2414+ fclose (f);
2415+}
2416+
2417+
2418+/* Check if the semaphore with IDX (index into the kernel's internal array)
2419+ matches the one with KEY. The CMD is either SEM_STAT or SEM_STAT_ANY. */
2420+
2421+static bool
2422+check_seminfo (int idx, key_t key, int cmd)
2423+{
2424+ struct semid_ds seminfo;
2425+ int sid = semctl (idx, 0, cmd, (union semun) { .buf = &seminfo });
2426+ /* Ignore unused array slot returned by the kernel or information from
2427+ unknown semaphores. */
2428+ if ((sid == -1 && errno == EINVAL) || sid != semid)
2429+ return false;
2430+
2431+ if (sid == -1)
2432+ FAIL_EXIT1 ("semctl with SEM_STAT failed (errno=%d)", errno);
2433+
2434+ TEST_COMPARE (seminfo.sem_perm.__key, key);
2435+ TEST_COMPARE (seminfo.sem_perm.mode, SEM_MODE);
2436+ TEST_COMPARE (seminfo.sem_nsems, 1);
2437+
2438+ return true;
2439+}
2440+
2441+static int
2442+do_test (void)
2443+{
2444+ atexit (remove_sem);
2445+
2446+ key_t key = ftok (name, 'G');
2447+ if (key == -1)
2448+ FAIL_EXIT1 ("ftok failed: %m");
2449+
2450+ semid = semget (key, 1, IPC_CREAT | IPC_EXCL | SEM_MODE);
2451+ if (semid == -1)
2452+ FAIL_EXIT1 ("semget failed: %m");
2453+
2454+ struct test_seminfo tipcinfo;
2455+ read_sem_stat (&tipcinfo);
2456+
2457+ int semidx;
2458+
2459+ {
2460+ struct seminfo ipcinfo;
2461+ semidx = semctl (semid, 0, IPC_INFO, (union semun) { .__buf = &ipcinfo });
2462+ if (semidx == -1)
2463+ FAIL_EXIT1 ("semctl with IPC_INFO failed: %m");
2464+
2465+ TEST_COMPARE (ipcinfo.semmsl, tipcinfo.semmsl);
2466+ TEST_COMPARE (ipcinfo.semmns, tipcinfo.semmns);
2467+ TEST_COMPARE (ipcinfo.semopm, tipcinfo.semopm);
2468+ TEST_COMPARE (ipcinfo.semmni, tipcinfo.semmni);
2469+ }
2470+
2471+ /* Same as before but with SEM_INFO. */
2472+ {
2473+ struct seminfo ipcinfo;
2474+ semidx = semctl (semid, 0, SEM_INFO, (union semun) { .__buf = &ipcinfo });
2475+ if (semidx == -1)
2476+ FAIL_EXIT1 ("semctl with IPC_INFO failed: %m");
2477+
2478+ TEST_COMPARE (ipcinfo.semmsl, tipcinfo.semmsl);
2479+ TEST_COMPARE (ipcinfo.semmns, tipcinfo.semmns);
2480+ TEST_COMPARE (ipcinfo.semopm, tipcinfo.semopm);
2481+ TEST_COMPARE (ipcinfo.semmni, tipcinfo.semmni);
2482+ }
2483+
2484+ /* We check if the created semaphore shows in the system-wide status. */
2485+ bool found = false;
2486+ for (int i = 0; i <= semidx; i++)
2487+ {
2488+ /* We can't tell apart if SEM_STAT_ANY is not supported (kernel older
2489+ than 4.17) or if the index used is invalid. So it just check if
2490+ value returned from a valid call matches the created semaphore. */
2491+ check_seminfo (i, key, SEM_STAT_ANY);
2492+
2493+ if (check_seminfo (i, key, SEM_STAT))
2494+ {
2495+ found = true;
2496+ break;
2497+ }
2498+ }
2499+
2500+ if (!found)
2501+ FAIL_EXIT1 ("semctl with SEM_STAT/SEM_STAT_ANY could not find the "
2502+ "created semaphore");
2503+
2504+ if (semctl (semid, 0, IPC_RMID, 0) == -1)
2505+ FAIL_EXIT1 ("semctl failed: %m");
2506+
2507+ return 0;
2508+}
2509+
2510+#include <support/test-driver.c>
2511diff --git a/sysdeps/unix/sysv/linux/tst-sysvshm-linux.c b/sysdeps/unix/sysv/linux/tst-sysvshm-linux.c
2512new file mode 100644
2513index 0000000000..7128ae2e14
2514--- /dev/null
2515+++ b/sysdeps/unix/sysv/linux/tst-sysvshm-linux.c
2516@@ -0,0 +1,185 @@
2517+/* Basic tests for Linux SYSV shared memory extensions.
2518+ Copyright (C) 2020 Free Software Foundation, Inc.
2519+ This file is part of the GNU C Library.
2520+
2521+ The GNU C Library is free software; you can redistribute it and/or
2522+ modify it under the terms of the GNU Lesser General Public
2523+ License as published by the Free Software Foundation; either
2524+ version 2.1 of the License, or (at your option) any later version.
2525+
2526+ The GNU C Library is distributed in the hope that it will be useful,
2527+ but WITHOUT ANY WARRANTY; without even the implied warranty of
2528+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2529+ Lesser General Public License for more details.
2530+
2531+ You should have received a copy of the GNU Lesser General Public
2532+ License along with the GNU C Library; if not, see
2533+ <https://www.gnu.org/licenses/>. */
2534+
2535+#include <sys/ipc.h>
2536+#include <sys/shm.h>
2537+#include <errno.h>
2538+#include <stdlib.h>
2539+#include <stdbool.h>
2540+#include <stdio.h>
2541+#include <unistd.h>
2542+#include <inttypes.h>
2543+#include <limits.h>
2544+
2545+#include <support/check.h>
2546+#include <support/temp_file.h>
2547+
2548+#define SHM_MODE 0644
2549+
2550+/* These are for the temporary file we generate. */
2551+static char *name;
2552+static int shmid;
2553+static long int pgsz;
2554+
2555+static void
2556+remove_shm (void)
2557+{
2558+ /* Enforce message queue removal in case of early test failure.
2559+ Ignore error since the shm may already have being removed. */
2560+ shmctl (shmid, IPC_RMID, NULL);
2561+}
2562+
2563+static void
2564+do_prepare (int argc, char *argv[])
2565+{
2566+ TEST_VERIFY_EXIT (create_temp_file ("tst-sysvshm.", &name) != -1);
2567+}
2568+
2569+#define PREPARE do_prepare
2570+
2571+struct test_shminfo
2572+{
2573+ unsigned long int shmall;
2574+ unsigned long int shmmax;
2575+ unsigned long int shmmni;
2576+};
2577+
2578+/* It tries to obtain some system-wide SysV shared memory information from
2579+ /proc to check against IPC_INFO/SHM_INFO. The /proc only returns the
2580+ tunables value of SHMALL, SHMMAX, and SHMMNI. */
2581+
2582+static uint64_t
2583+read_proc_file (const char *file)
2584+{
2585+ FILE *f = fopen (file, "r");
2586+ if (f == NULL)
2587+ FAIL_UNSUPPORTED ("/proc is not mounted or %s is not available", file);
2588+
2589+ /* Handle 32-bit binaries running on 64-bit kernels. */
2590+ uint64_t v;
2591+ int r = fscanf (f, "%" SCNu64, &v);
2592+ TEST_VERIFY_EXIT (r == 1);
2593+
2594+ fclose (f);
2595+ return v;
2596+}
2597+
2598+
2599+/* Check if the message queue with IDX (index into the kernel's internal
2600+ array) matches the one with KEY. The CMD is either SHM_STAT or
2601+ SHM_STAT_ANY. */
2602+
2603+static bool
2604+check_shminfo (int idx, key_t key, int cmd)
2605+{
2606+ struct shmid_ds shminfo;
2607+ int sid = shmctl (idx, cmd, &shminfo);
2608+ /* Ignore unused array slot returned by the kernel or information from
2609+ unknown message queue. */
2610+ if ((sid == -1 && errno == EINVAL) || sid != shmid)
2611+ return false;
2612+
2613+ if (sid == -1)
2614+ FAIL_EXIT1 ("shmctl with %s failed: %m",
2615+ cmd == SHM_STAT ? "SHM_STAT" : "SHM_STAT_ANY");
2616+
2617+ TEST_COMPARE (shminfo.shm_perm.__key, key);
2618+ TEST_COMPARE (shminfo.shm_perm.mode, SHM_MODE);
2619+ TEST_COMPARE (shminfo.shm_segsz, pgsz);
2620+
2621+ return true;
2622+}
2623+
2624+static int
2625+do_test (void)
2626+{
2627+ atexit (remove_shm);
2628+
2629+ pgsz = sysconf (_SC_PAGESIZE);
2630+ if (pgsz == -1)
2631+ FAIL_EXIT1 ("sysconf (_SC_PAGESIZE) failed: %m");
2632+
2633+ key_t key = ftok (name, 'G');
2634+ if (key == -1)
2635+ FAIL_EXIT1 ("ftok failed: %m");
2636+
2637+ shmid = shmget (key, pgsz, IPC_CREAT | IPC_EXCL | SHM_MODE);
2638+ if (shmid == -1)
2639+ FAIL_EXIT1 ("shmget failed: %m");
2640+
2641+ struct test_shminfo tipcinfo;
2642+ {
2643+ uint64_t v = read_proc_file ("/proc/sys/kernel/shmmax");
2644+#if LONG_MAX == INT_MAX
2645+ /* Kernel explicit clamp the value for shmmax on compat symbol (32-bit
2646+ binaries running on 64-bit kernels). */
2647+ if (v > INT_MAX)
2648+ v = INT_MAX;
2649+#endif
2650+ tipcinfo.shmmax = v;
2651+ }
2652+ tipcinfo.shmall = read_proc_file ("/proc/sys/kernel/shmall");
2653+ tipcinfo.shmmni = read_proc_file ("/proc/sys/kernel/shmmni");
2654+
2655+ int shmidx;
2656+
2657+ /* Note: SHM_INFO does not return a shminfo, but rather a 'struct shm_info'.
2658+ It is tricky to verify its values since the syscall returns system wide
2659+ resources consumed by shared memory. The shmctl implementation handles
2660+ SHM_INFO as IPC_INFO, so the IPC_INFO test should validate SHM_INFO as
2661+ well. */
2662+
2663+ {
2664+ struct shminfo ipcinfo;
2665+ shmidx = shmctl (shmid, IPC_INFO, (struct shmid_ds *) &ipcinfo);
2666+ if (shmidx == -1)
2667+ FAIL_EXIT1 ("shmctl with IPC_INFO failed: %m");
2668+
2669+ TEST_COMPARE (ipcinfo.shmall, tipcinfo.shmall);
2670+ TEST_COMPARE (ipcinfo.shmmax, tipcinfo.shmmax);
2671+ TEST_COMPARE (ipcinfo.shmmni, tipcinfo.shmmni);
2672+ }
2673+
2674+ /* We check if the created shared memory shows in the global list. */
2675+ bool found = false;
2676+ for (int i = 0; i <= shmidx; i++)
2677+ {
2678+ /* We can't tell apart if SHM_STAT_ANY is not supported (kernel older
2679+ than 4.17) or if the index used is invalid. So it just check if
2680+ value returned from a valid call matches the created message
2681+ queue. */
2682+ check_shminfo (i, key, SHM_STAT_ANY);
2683+
2684+ if (check_shminfo (i, key, SHM_STAT))
2685+ {
2686+ found = true;
2687+ break;
2688+ }
2689+ }
2690+
2691+ if (!found)
2692+ FAIL_EXIT1 ("shmctl with SHM_STAT/SHM_STAT_ANY could not find the "
2693+ "created shared memory");
2694+
2695+ if (shmctl (shmid, IPC_RMID, NULL) == -1)
2696+ FAIL_EXIT1 ("shmctl failed");
2697+
2698+ return 0;
2699+}
2700+
2701+#include <support/test-driver.c>
2702diff --git a/sysdeps/unix/sysv/linux/x86_64/64/configure b/sysdeps/unix/sysv/linux/x86_64/64/configure
2703index 9d298faba7..cef1ec842c 100644
2704--- a/sysdeps/unix/sysv/linux/x86_64/64/configure
2705+++ b/sysdeps/unix/sysv/linux/x86_64/64/configure
2706@@ -4,10 +4,10 @@
2707 test -n "$libc_cv_slibdir" ||
2708 case "$prefix" in
2709 /usr | /usr/)
2710- libc_cv_slibdir='/lib64'
2711- libc_cv_rtlddir='/lib64'
2712+ libc_cv_slibdir='/lib'
2713+ libc_cv_rtlddir='/lib'
2714 if test "$libdir" = '${exec_prefix}/lib'; then
2715- libdir='${exec_prefix}/lib64';
2716+ libdir='${exec_prefix}/lib';
2717 # Locale data can be shared between 32-bit and 64-bit libraries.
2718 libc_cv_complocaledir='${exec_prefix}/lib/locale'
2719 fi
2720diff --git a/sysdeps/unix/sysv/linux/x86_64/ldconfig.h b/sysdeps/unix/sysv/linux/x86_64/ldconfig.h
2721index 062c04689d..7783757726 100644
2722--- a/sysdeps/unix/sysv/linux/x86_64/ldconfig.h
2723+++ b/sysdeps/unix/sysv/linux/x86_64/ldconfig.h
2724@@ -18,9 +18,9 @@
2725 #include <sysdeps/generic/ldconfig.h>
2726
2727 #define SYSDEP_KNOWN_INTERPRETER_NAMES \
2728- { "/lib/ld-linux.so.2", FLAG_ELF_LIBC6 }, \
2729+ { "/lib32/ld-linux.so.2", FLAG_ELF_LIBC6 }, \
2730 { "/libx32/ld-linux-x32.so.2", FLAG_ELF_LIBC6 }, \
2731- { "/lib64/ld-linux-x86-64.so.2", FLAG_ELF_LIBC6 },
2732+ { "/lib/ld-linux-x86-64.so.2", FLAG_ELF_LIBC6 },
2733 #define SYSDEP_KNOWN_LIBRARY_NAMES \
2734 { "libc.so.6", FLAG_ELF_LIBC6 }, \
2735 { "libm.so.6", FLAG_ELF_LIBC6 },
2736diff --git a/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed b/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed
2737index 44d76e8aa1..7d6cb1e20b 100644
2738--- a/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed
2739+++ b/sysdeps/unix/sysv/linux/x86_64/ldd-rewrite.sed
2740@@ -1,3 +1,3 @@
2741 /LD_TRACE_LOADED_OBJECTS=1/a\
2742 add_env="$add_env LD_LIBRARY_VERSION=\\$verify_out"
2743-s_^\(RTLDLIST=\)\(.*lib\)\(\|64\|x32\)\(/[^/]*\)\(-x86-64\|-x32\)\(\.so\.[0-9.]*\)[ ]*$_\1"\2\4\6 \264\4-x86-64\6 \2x32\4-x32\6"_
2744+s_^\(RTLDLIST=\)\(.*lib\)\(\|64\|x32\)\(/[^/]*\)\(-x86-64\|-x32\)\(\.so\.[0-9.]*\)[ ]*$_\1"\232\4\6 \2\4-x86-64\6 \2x32\4-x32\6"_
2745diff --git a/sysdeps/x86_64/fpu/multiarch/ifunc-fma4.h b/sysdeps/x86_64/fpu/multiarch/ifunc-fma4.h
2746index 7659758972..e5fd5ac9cb 100644
2747--- a/sysdeps/x86_64/fpu/multiarch/ifunc-fma4.h
2748+++ b/sysdeps/x86_64/fpu/multiarch/ifunc-fma4.h
2749@@ -32,7 +32,7 @@ IFUNC_SELECTOR (void)
2750 && CPU_FEATURE_USABLE_P (cpu_features, AVX2))
2751 return OPTIMIZE (fma);
2752
2753- if (CPU_FEATURE_USABLE_P (cpu_features, FMA))
2754+ if (CPU_FEATURE_USABLE_P (cpu_features, FMA4))
2755 return OPTIMIZE (fma4);
2756
2757 return OPTIMIZE (sse2);
2758diff --git a/sysvipc/test-sysvsem.c b/sysvipc/test-sysvsem.c
2759index 01dbff343a..b7284e0b48 100644
2760--- a/sysvipc/test-sysvsem.c
2761+++ b/sysvipc/test-sysvsem.c
2762@@ -20,6 +20,7 @@
2763 #include <stdlib.h>
2764 #include <errno.h>
2765 #include <string.h>
2766+#include <stdbool.h>
2767 #include <sys/types.h>
2768 #include <sys/ipc.h>
2769 #include <sys/sem.h>
2770diff --git a/version.h b/version.h
2771index 83cd196798..e6ca7a8857 100644
2772--- a/version.h
2773+++ b/version.h
2774@@ -1,4 +1,4 @@
2775 /* This file just defines the current version number of libc. */
2776
2777-#define RELEASE "release"
2778+#define RELEASE "stable"
2779 #define VERSION "2.32"