Sync with upstream branch release/2.34/master
Upstream commit: 2fe2af88abd13ae5636881da2e26f461ecb7dfb5 - i386: Remove broken CAN_USE_REGISTER_ASM_EBP (bug 28771) - Update syscall lists for Linux 5.15 - powerpc: Fix unrecognized instruction errors with recent GCC - timezone: test-case for BZ #28707 - timezone: handle truncated timezones from tzcode-2021d and later (BZ #28707) - Fix subscript error with odd TZif file [BZ #28338] - AArch64: Check for SVE in ifuncs [BZ #28744] - intl/plural.y: Avoid conflicting declarations of yyerror and yylex - Linux: Fix 32-bit vDSO for clock_gettime on powerpc32 - linux: Add sparck brk implementation - Update sparc libm-test-ulps - Update hppa libm-test-ulps - riscv: align stack before calling _dl_init [BZ #28703] - riscv: align stack in clone [BZ #28702] - powerpc64[le]: Allocate extra stack frame on syscall.S - elf: Fix tst-cpu-features-cpuinfo for KVM guests on some AMD systems [BZ #28704] - nss: Use "files dns" as the default for the hosts database (bug 28700) - arm: Guard ucontext _rtld_global_ro access by SHARED, not PIC macro - mips: increase stack alignment in clone to match the ABI - mips: align stack in clone [BZ #28223]
This commit is contained in:
parent
479e96c3f6
commit
6c82cf3dec
32
glibc-upstream-2.34-54.patch
Normal file
32
glibc-upstream-2.34-54.patch
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
commit 7af07fe795f43e53d31be1c6f9adba7e05f87b0b
|
||||||
|
Author: Xi Ruoyao <xry111@mengyan1223.wang>
|
||||||
|
Date: Thu Aug 12 20:31:59 2021 +0000
|
||||||
|
|
||||||
|
mips: align stack in clone [BZ #28223]
|
||||||
|
|
||||||
|
The MIPS O32 ABI requires 4 byte aligned stack, and the MIPS N64 and N32
|
||||||
|
ABI require 8 byte aligned stack. Previously if the caller passed an
|
||||||
|
unaligned stack to clone the the child misbehaved.
|
||||||
|
|
||||||
|
Fixes bug 28223.
|
||||||
|
|
||||||
|
(cherry picked from commit 1f51cd9a860ee45eee8a56fb2ba925267a2a7bfe)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/mips/clone.S b/sysdeps/unix/sysv/linux/mips/clone.S
|
||||||
|
index 71d9dba8bd9e8f9e..43a5ad3a400d9504 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/mips/clone.S
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/mips/clone.S
|
||||||
|
@@ -55,6 +55,13 @@ NESTED(__clone,4*SZREG,sp)
|
||||||
|
.set at
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+ /* Align stack to 4/8 bytes per the ABI. */
|
||||||
|
+#if _MIPS_SIM == _ABIO32
|
||||||
|
+ li t0,-4
|
||||||
|
+#else
|
||||||
|
+ li t0,-8
|
||||||
|
+#endif
|
||||||
|
+ and a1,a1,t0
|
||||||
|
|
||||||
|
/* Sanity check arguments. */
|
||||||
|
li v0,EINVAL
|
37
glibc-upstream-2.34-55.patch
Normal file
37
glibc-upstream-2.34-55.patch
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
commit 4db172a54d43f9b7fd17e66fc44a34efb3cab1e1
|
||||||
|
Author: Xi Ruoyao <xry111@mengyan1223.wang>
|
||||||
|
Date: Fri Aug 13 16:01:14 2021 +0000
|
||||||
|
|
||||||
|
mips: increase stack alignment in clone to match the ABI
|
||||||
|
|
||||||
|
In "mips: align stack in clone [BZ #28223]"
|
||||||
|
(commit 1f51cd9a860ee45eee8a56fb2ba925267a2a7bfe) I made a mistake: I
|
||||||
|
misbelieved one "word" was 2-byte and "doubleword" should be 4-byte.
|
||||||
|
But in MIPS ABI one "word" is defined 32-bit (4-byte), so "doubleword" is
|
||||||
|
8-byte [1], and "quadword" is 16-byte [2].
|
||||||
|
|
||||||
|
[1]: "System V Application Binary Interface: MIPS(R) RISC Processor
|
||||||
|
Supplement, 3rd edition", page 3-31
|
||||||
|
[2]: "MIPSpro(TM) 64-Bit Porting and Transition Guide", page 23
|
||||||
|
|
||||||
|
(cherry picked from commit 0f62fe053273ff6c62ac95c59b7687c964737b00)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/mips/clone.S b/sysdeps/unix/sysv/linux/mips/clone.S
|
||||||
|
index 43a5ad3a400d9504..fd71b5ca2eb86089 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/mips/clone.S
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/mips/clone.S
|
||||||
|
@@ -55,11 +55,11 @@ NESTED(__clone,4*SZREG,sp)
|
||||||
|
.set at
|
||||||
|
#endif
|
||||||
|
|
||||||
|
- /* Align stack to 4/8 bytes per the ABI. */
|
||||||
|
+ /* Align stack to 8/16 bytes per the ABI. */
|
||||||
|
#if _MIPS_SIM == _ABIO32
|
||||||
|
- li t0,-4
|
||||||
|
-#else
|
||||||
|
li t0,-8
|
||||||
|
+#else
|
||||||
|
+ li t0,-16
|
||||||
|
#endif
|
||||||
|
and a1,a1,t0
|
||||||
|
|
65
glibc-upstream-2.34-56.patch
Normal file
65
glibc-upstream-2.34-56.patch
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
commit 93aabf891e96e93f100081ee07989c23d7107d17
|
||||||
|
Author: Florian Weimer <fweimer@redhat.com>
|
||||||
|
Date: Fri Dec 17 11:48:41 2021 +0100
|
||||||
|
|
||||||
|
arm: Guard ucontext _rtld_global_ro access by SHARED, not PIC macro
|
||||||
|
|
||||||
|
Due to PIE-by-default, PIC is now defined in more cases. libc.a
|
||||||
|
does not have _rtld_global_ro, and statically linking setcontext
|
||||||
|
fails. SHARED is the right condition to use, so that libc.a
|
||||||
|
references _dl_hwcap instead of _rtld_global_ro.
|
||||||
|
|
||||||
|
For static PIE support, the !SHARED case would still have to be made
|
||||||
|
PIC. This patch does not achieve that.
|
||||||
|
|
||||||
|
Fixes commit 23645707f12f2dd9d80b51effb2d9618a7b65565
|
||||||
|
("Replace --enable-static-pie with --disable-default-pie").
|
||||||
|
|
||||||
|
Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
|
||||||
|
Reviewed-by: Szabolcs Nagy <szabolcs.nagy@arm.com>
|
||||||
|
(cherry picked from commit ce1e5b11229f19820b86f8b19d651f16009552b0)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/arm/getcontext.S b/sysdeps/unix/sysv/linux/arm/getcontext.S
|
||||||
|
index 3aa581c4da6d1166..11bfcbe5f53afc6e 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/arm/getcontext.S
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/arm/getcontext.S
|
||||||
|
@@ -50,7 +50,7 @@ ENTRY(__getcontext)
|
||||||
|
|
||||||
|
/* Store FP regs. Much of the FP code is copied from arm/setjmp.S. */
|
||||||
|
|
||||||
|
-#ifdef PIC
|
||||||
|
+#ifdef SHARED
|
||||||
|
ldr r2, 1f
|
||||||
|
ldr r1, .Lrtld_global_ro
|
||||||
|
0: add r2, pc, r2
|
||||||
|
@@ -102,7 +102,7 @@ ENTRY(__getcontext)
|
||||||
|
|
||||||
|
END(__getcontext)
|
||||||
|
|
||||||
|
-#ifdef PIC
|
||||||
|
+#ifdef SHARED
|
||||||
|
1: .long _GLOBAL_OFFSET_TABLE_ - 0b - PC_OFS
|
||||||
|
.Lrtld_global_ro:
|
||||||
|
.long C_SYMBOL_NAME(_rtld_global_ro)(GOT)
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/arm/setcontext.S b/sysdeps/unix/sysv/linux/arm/setcontext.S
|
||||||
|
index 8be8beefea13883e..4c7c6e550944138c 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/arm/setcontext.S
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/arm/setcontext.S
|
||||||
|
@@ -32,7 +32,7 @@ ENTRY(__setcontext)
|
||||||
|
add r0, r0, #UCONTEXT_REGSPACE
|
||||||
|
|
||||||
|
/* Restore the VFP registers. Copied from arm/__longjmp.S. */
|
||||||
|
-#ifdef PIC
|
||||||
|
+#ifdef SHARED
|
||||||
|
ldr r2, 1f
|
||||||
|
ldr r1, .Lrtld_global_ro
|
||||||
|
0: add r2, pc, r2
|
||||||
|
@@ -101,7 +101,7 @@ ENTRY(__startcontext)
|
||||||
|
.fnend
|
||||||
|
END(__startcontext)
|
||||||
|
|
||||||
|
-#ifdef PIC
|
||||||
|
+#ifdef SHARED
|
||||||
|
1: .long _GLOBAL_OFFSET_TABLE_ - 0b - PC_OFS
|
||||||
|
.Lrtld_global_ro:
|
||||||
|
.long C_SYMBOL_NAME(_rtld_global_ro)(GOT)
|
74
glibc-upstream-2.34-57.patch
Normal file
74
glibc-upstream-2.34-57.patch
Normal file
@ -0,0 +1,74 @@
|
|||||||
|
commit dc9b69d5331dcdca4547c0490cb9fefbd89e40f6
|
||||||
|
Author: Florian Weimer <fweimer@redhat.com>
|
||||||
|
Date: Fri Dec 17 12:01:20 2021 +0100
|
||||||
|
|
||||||
|
nss: Use "files dns" as the default for the hosts database (bug 28700)
|
||||||
|
|
||||||
|
This matches what is currently in nss/nsswitch.conf. The new ordering
|
||||||
|
matches what most distributions use in their installed configuration
|
||||||
|
files.
|
||||||
|
|
||||||
|
It is common to add localhost to /etc/hosts because the name does not
|
||||||
|
exist in the DNS, but is commonly used as a host name.
|
||||||
|
|
||||||
|
With the built-in "dns [!UNAVAIL=return] files" default, dns is
|
||||||
|
searched first and provides an answer for "localhost" (NXDOMAIN).
|
||||||
|
We never look at the files database as a result, so the contents of
|
||||||
|
/etc/hosts is ignored. This means that "getent hosts localhost"
|
||||||
|
fail without a /etc/nsswitch.conf file, even though the host name
|
||||||
|
is listed in /etc/hosts.
|
||||||
|
|
||||||
|
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
|
||||||
|
(cherry picked from commit b99b0f93ee8762fe53ff65802deb6f00700b9924)
|
||||||
|
|
||||||
|
diff --git a/manual/nss.texi b/manual/nss.texi
|
||||||
|
index 3aaa7786f8cf3168..524d22ad1e7f8ca0 100644
|
||||||
|
--- a/manual/nss.texi
|
||||||
|
+++ b/manual/nss.texi
|
||||||
|
@@ -324,9 +324,8 @@ missing.
|
||||||
|
|
||||||
|
@cindex default value, and NSS
|
||||||
|
For the @code{hosts} and @code{networks} databases the default value is
|
||||||
|
-@code{dns [!UNAVAIL=return] files}. I.e., the system is prepared for
|
||||||
|
-the DNS service not to be available but if it is available the answer it
|
||||||
|
-returns is definitive.
|
||||||
|
+@code{files dns}. I.e., local configuration will override the contents
|
||||||
|
+of the domain name system (DNS).
|
||||||
|
|
||||||
|
The @code{passwd}, @code{group}, and @code{shadow} databases was
|
||||||
|
traditionally handled in a special way. The appropriate files in the
|
||||||
|
diff --git a/nss/XXX-lookup.c b/nss/XXX-lookup.c
|
||||||
|
index f1c97f7c8e9d7378..dbc87868dd408d9f 100644
|
||||||
|
--- a/nss/XXX-lookup.c
|
||||||
|
+++ b/nss/XXX-lookup.c
|
||||||
|
@@ -29,7 +29,7 @@
|
||||||
|
|* ALTERNATE_NAME - name of another service which is examined in *|
|
||||||
|
|* case DATABASE_NAME is not found *|
|
||||||
|
|* *|
|
||||||
|
-|* DEFAULT_CONFIG - string for default conf (e.g. "dns files") *|
|
||||||
|
+|* DEFAULT_CONFIG - string for default conf (e.g. "files dns") *|
|
||||||
|
|* *|
|
||||||
|
\*******************************************************************/
|
||||||
|
|
||||||
|
diff --git a/nss/nss_database.c b/nss/nss_database.c
|
||||||
|
index ab121cb371c087e9..54561f03287db2e4 100644
|
||||||
|
--- a/nss/nss_database.c
|
||||||
|
+++ b/nss/nss_database.c
|
||||||
|
@@ -80,7 +80,7 @@ enum nss_database_default
|
||||||
|
{
|
||||||
|
nss_database_default_defconfig = 0, /* "nis [NOTFOUND=return] files". */
|
||||||
|
nss_database_default_compat, /* "compat [NOTFOUND=return] files". */
|
||||||
|
- nss_database_default_dns, /* "dns [!UNAVAIL=return] files". */
|
||||||
|
+ nss_database_default_dns, /* "files dns". */
|
||||||
|
nss_database_default_files, /* "files". */
|
||||||
|
nss_database_default_nis, /* "nis". */
|
||||||
|
nss_database_default_nis_nisplus, /* "nis nisplus". */
|
||||||
|
@@ -133,7 +133,7 @@ nss_database_select_default (struct nss_database_default_cache *cache,
|
||||||
|
#endif
|
||||||
|
|
||||||
|
case nss_database_default_dns:
|
||||||
|
- line = "dns [!UNAVAIL=return] files";
|
||||||
|
+ line = "files dns";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case nss_database_default_files:
|
35
glibc-upstream-2.34-58.patch
Normal file
35
glibc-upstream-2.34-58.patch
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
commit 03de6917bd11c0591867607ce74ef658f76eabb9
|
||||||
|
Author: Aurelien Jarno <aurelien@aurel32.net>
|
||||||
|
Date: Wed Dec 15 23:46:19 2021 +0100
|
||||||
|
|
||||||
|
elf: Fix tst-cpu-features-cpuinfo for KVM guests on some AMD systems [BZ #28704]
|
||||||
|
|
||||||
|
On KVM guests running on some AMD systems, the IBRS feature is reported
|
||||||
|
as a synthetic feature using the Intel feature, while the cpuinfo entry
|
||||||
|
keeps the same. Handle that by first checking the presence of the Intel
|
||||||
|
feature on AMD systems.
|
||||||
|
|
||||||
|
Fixes bug 28704.
|
||||||
|
|
||||||
|
(cherry picked from commit 94058f6cde8b887178885954740ac6c866d25eab)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/x86/tst-cpu-features-cpuinfo.c b/sysdeps/x86/tst-cpu-features-cpuinfo.c
|
||||||
|
index 2d4927f5e52dc260..830aaca2ecae971b 100644
|
||||||
|
--- a/sysdeps/x86/tst-cpu-features-cpuinfo.c
|
||||||
|
+++ b/sysdeps/x86/tst-cpu-features-cpuinfo.c
|
||||||
|
@@ -169,7 +169,14 @@ do_test (int argc, char **argv)
|
||||||
|
else if (cpu_features->basic.kind == arch_kind_amd)
|
||||||
|
{
|
||||||
|
fails += CHECK_PROC (ibpb, AMD_IBPB);
|
||||||
|
- fails += CHECK_PROC (ibrs, AMD_IBRS);
|
||||||
|
+
|
||||||
|
+ /* The IBRS feature on AMD processors is reported using the Intel feature
|
||||||
|
+ * on KVM guests (synthetic bit). In both cases the cpuinfo entry is the
|
||||||
|
+ * same. */
|
||||||
|
+ if (HAS_CPU_FEATURE (IBRS_IBPB))
|
||||||
|
+ fails += CHECK_PROC (ibrs, IBRS_IBPB);
|
||||||
|
+ else
|
||||||
|
+ fails += CHECK_PROC (ibrs, AMD_IBRS);
|
||||||
|
fails += CHECK_PROC (stibp, AMD_STIBP);
|
||||||
|
}
|
||||||
|
fails += CHECK_PROC (ibt, IBT);
|
35
glibc-upstream-2.34-59.patch
Normal file
35
glibc-upstream-2.34-59.patch
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
commit 5daf13b1e637eec0f7a2de05b177cb0d76479aa2
|
||||||
|
Author: Matheus Castanho <msc@linux.ibm.com>
|
||||||
|
Date: Wed Dec 1 11:14:40 2021 -0300
|
||||||
|
|
||||||
|
powerpc64[le]: Allocate extra stack frame on syscall.S
|
||||||
|
|
||||||
|
The syscall function does not allocate the extra stack frame for scv like other
|
||||||
|
assembly syscalls using DO_CALL_SCV. So after commit d120fb9941 changed the
|
||||||
|
offset that is used to save LR, syscall ended up using an invalid offset,
|
||||||
|
causing regressions on powerpc64. So make sure the extra stack frame is
|
||||||
|
allocated in syscall.S as well to make it consistent with other uses of
|
||||||
|
DO_CALL_SCV and avoid similar issues in the future.
|
||||||
|
|
||||||
|
Tested on powerpc, powerpc64, and powerpc64le (with and without scv)
|
||||||
|
|
||||||
|
Reviewed-by: Raphael M Zinsly <rzinsly@linux.ibm.com>
|
||||||
|
|
||||||
|
(cherry picked from commit ae91d3df24a4a1b1f264d101a71a298bff310d14)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/powerpc/syscall.S b/sysdeps/unix/sysv/linux/powerpc/syscall.S
|
||||||
|
index a29652feaf6764cf..a5497c8370982fe3 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/powerpc/syscall.S
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/powerpc/syscall.S
|
||||||
|
@@ -27,7 +27,11 @@ ENTRY (syscall)
|
||||||
|
mr r8,r9
|
||||||
|
#if defined(USE_PPC_SCV) && !IS_IN(rtld) && (defined(__PPC64__) || defined(__powerpc64__))
|
||||||
|
CHECK_SCV_SUPPORT r9 0f
|
||||||
|
+ stdu r1,-SCV_FRAME_SIZE(r1)
|
||||||
|
+ cfi_adjust_cfa_offset(SCV_FRAME_SIZE)
|
||||||
|
DO_CALL_SCV
|
||||||
|
+ addi r1,r1,SCV_FRAME_SIZE
|
||||||
|
+ cfi_adjust_cfa_offset(-SCV_FRAME_SIZE)
|
||||||
|
RET_SCV
|
||||||
|
b 1f
|
||||||
|
#endif
|
32
glibc-upstream-2.34-60.patch
Normal file
32
glibc-upstream-2.34-60.patch
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
commit 9de8011c328021f10588a8acb418daf5121d5f3d
|
||||||
|
Author: Aurelien Jarno <aurelien@aurel32.net>
|
||||||
|
Date: Tue Dec 14 22:44:35 2021 +0100
|
||||||
|
|
||||||
|
riscv: align stack in clone [BZ #28702]
|
||||||
|
|
||||||
|
The RISC-V ABI [1] mandates that "the stack pointer shall be aligned to
|
||||||
|
a 128-bit boundary upon procedure entry". This as not the case in clone.
|
||||||
|
|
||||||
|
This fixes the misc/tst-misalign-clone-internal and
|
||||||
|
misc/tst-misalign-clone tests.
|
||||||
|
|
||||||
|
Fixes bug 28702.
|
||||||
|
|
||||||
|
[1] https://github.com/riscv-non-isa/riscv-elf-psabi-doc
|
||||||
|
|
||||||
|
(cherry picked from commit d2e594d71509faf36cf851a69370db34a4f5fa65)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/riscv/clone.S b/sysdeps/unix/sysv/linux/riscv/clone.S
|
||||||
|
index 12f91a20d3bb34f5..161e83c7e3786b8d 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/riscv/clone.S
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/riscv/clone.S
|
||||||
|
@@ -32,6 +32,9 @@
|
||||||
|
.text
|
||||||
|
LEAF (__clone)
|
||||||
|
|
||||||
|
+ /* Align stack to a 128-bit boundary as per RISC-V ABI. */
|
||||||
|
+ andi a1,a1,ALMASK
|
||||||
|
+
|
||||||
|
/* Sanity check arguments. */
|
||||||
|
beqz a0,L (invalid) /* No NULL function pointers. */
|
||||||
|
beqz a1,L (invalid) /* No NULL stack pointers. */
|
34
glibc-upstream-2.34-61.patch
Normal file
34
glibc-upstream-2.34-61.patch
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
commit aa3a97496c82a8443039248ebee650322c9480f4
|
||||||
|
Author: Aurelien Jarno <aurelien@aurel32.net>
|
||||||
|
Date: Thu Dec 16 00:06:28 2021 +0100
|
||||||
|
|
||||||
|
riscv: align stack before calling _dl_init [BZ #28703]
|
||||||
|
|
||||||
|
Align the stack pointer to 128 bits during the call to _dl_init() as
|
||||||
|
specified by the RISC-V ABI [1]. This fixes the elf/tst-align2 test.
|
||||||
|
|
||||||
|
Fixes bug 28703.
|
||||||
|
|
||||||
|
[1] https://github.com/riscv-non-isa/riscv-elf-psabi-doc
|
||||||
|
|
||||||
|
(cherry picked from commit 225da459cebef1037dcd78b56471edc0721e1c41)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/riscv/dl-machine.h b/sysdeps/riscv/dl-machine.h
|
||||||
|
index aedf69fcdd8aff50..951268923da26a37 100644
|
||||||
|
--- a/sysdeps/riscv/dl-machine.h
|
||||||
|
+++ b/sysdeps/riscv/dl-machine.h
|
||||||
|
@@ -127,8 +127,14 @@ elf_machine_load_address (void)
|
||||||
|
sll a3, a1, " STRINGXP (PTRLOG) "\n\
|
||||||
|
add a3, a3, a2\n\
|
||||||
|
add a3, a3, " STRINGXP (SZREG) "\n\
|
||||||
|
+ # Stash the stack pointer in s1.\n\
|
||||||
|
+ mv s1, sp\n\
|
||||||
|
+ # Align stack to 128 bits for the _dl_init call.\n\
|
||||||
|
+ andi sp, sp,-16\n\
|
||||||
|
# Call the function to run the initializers.\n\
|
||||||
|
jal _dl_init\n\
|
||||||
|
+ # Restore the stack pointer for _start.\n\
|
||||||
|
+ mv sp, s1\n\
|
||||||
|
# Pass our finalizer function to _start.\n\
|
||||||
|
lla a0, _dl_fini\n\
|
||||||
|
# Jump to the user entry point.\n\
|
21
glibc-upstream-2.34-62.patch
Normal file
21
glibc-upstream-2.34-62.patch
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
commit 4029747c592cb2d59805b3a4e7a8963fcdcdbeb1
|
||||||
|
Author: John David Anglin <danglin@gcc.gnu.org>
|
||||||
|
Date: Mon Sep 6 17:37:29 2021 +0000
|
||||||
|
|
||||||
|
Update hppa libm-test-ulps
|
||||||
|
|
||||||
|
(cherry picked from commit d8cf84ac7e504663dfeb2bb45d8d48ae81effe05)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/hppa/fpu/libm-test-ulps b/sysdeps/hppa/fpu/libm-test-ulps
|
||||||
|
index 90e16a72692e9199..3d60fc25a14d053f 100644
|
||||||
|
--- a/sysdeps/hppa/fpu/libm-test-ulps
|
||||||
|
+++ b/sysdeps/hppa/fpu/libm-test-ulps
|
||||||
|
@@ -1104,7 +1104,7 @@ float: 8
|
||||||
|
ldouble: 1
|
||||||
|
|
||||||
|
Function: "tgamma_downward":
|
||||||
|
-double: 8
|
||||||
|
+double: 9
|
||||||
|
float: 7
|
||||||
|
|
||||||
|
Function: "tgamma_towardzero":
|
21
glibc-upstream-2.34-63.patch
Normal file
21
glibc-upstream-2.34-63.patch
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
commit e94544c82f4ac37017589d8d83156d72388fc4af
|
||||||
|
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
|
||||||
|
Date: Wed Aug 4 21:40:32 2021 +0300
|
||||||
|
|
||||||
|
Update sparc libm-test-ulps
|
||||||
|
|
||||||
|
(cherry picked from commit c52eb066bc634a79e4194457362384abe5b43b3a)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/sparc/fpu/libm-test-ulps b/sysdeps/sparc/fpu/libm-test-ulps
|
||||||
|
index c2e4649524aa3a44..f34bbe6c592814d0 100644
|
||||||
|
--- a/sysdeps/sparc/fpu/libm-test-ulps
|
||||||
|
+++ b/sysdeps/sparc/fpu/libm-test-ulps
|
||||||
|
@@ -1346,7 +1346,7 @@ float: 8
|
||||||
|
ldouble: 4
|
||||||
|
|
||||||
|
Function: "tgamma_downward":
|
||||||
|
-double: 8
|
||||||
|
+double: 9
|
||||||
|
float: 7
|
||||||
|
ldouble: 5
|
||||||
|
|
81
glibc-upstream-2.34-64.patch
Normal file
81
glibc-upstream-2.34-64.patch
Normal file
@ -0,0 +1,81 @@
|
|||||||
|
commit 1d9764aba8c00754fbf8299e48afbe222245ee3e
|
||||||
|
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
|
||||||
|
Date: Wed Aug 4 21:34:12 2021 +0300
|
||||||
|
|
||||||
|
linux: Add sparck brk implementation
|
||||||
|
|
||||||
|
It turned that the generic implementation of brk() does not work
|
||||||
|
for sparc, since on failure kernel will just return the previous
|
||||||
|
input value without setting the conditional register.
|
||||||
|
|
||||||
|
This patches adds back a sparc32 and sparc64 implementation removed
|
||||||
|
by 720480934ab9107.
|
||||||
|
|
||||||
|
Checked on sparc64-linux-gnu and sparcv9-linux-gnu.
|
||||||
|
|
||||||
|
(cherry picked from commit 5b86241a032c50462988bdd1439e078384690d34)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/sparc/brk.c b/sysdeps/unix/sysv/linux/sparc/brk.c
|
||||||
|
new file mode 100644
|
||||||
|
index 0000000000000000..aafe9673e3062cf8
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/sparc/brk.c
|
||||||
|
@@ -0,0 +1,58 @@
|
||||||
|
+/* Change data segment. Linux SPARC version.
|
||||||
|
+ Copyright (C) 2021 Free Software Foundation, Inc.
|
||||||
|
+ This file is part of the GNU C Library.
|
||||||
|
+
|
||||||
|
+ The GNU C Library is free software; you can redistribute it and/or
|
||||||
|
+ modify it under the terms of the GNU Lesser General Public
|
||||||
|
+ License as published by the Free Software Foundation; either
|
||||||
|
+ version 2.1 of the License, or (at your option) any later version.
|
||||||
|
+
|
||||||
|
+ The GNU C Library is distributed in the hope that it will be useful,
|
||||||
|
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
+ Lesser General Public License for more details.
|
||||||
|
+
|
||||||
|
+ You should have received a copy of the GNU Lesser General Public
|
||||||
|
+ License along with the GNU C Library. If not, see
|
||||||
|
+ <https://www.gnu.org/licenses/>. */
|
||||||
|
+
|
||||||
|
+#include <errno.h>
|
||||||
|
+#include <unistd.h>
|
||||||
|
+#include <sysdep.h>
|
||||||
|
+
|
||||||
|
+/* This must be initialized data because commons can't have aliases. */
|
||||||
|
+void *__curbrk = 0;
|
||||||
|
+
|
||||||
|
+#if HAVE_INTERNAL_BRK_ADDR_SYMBOL
|
||||||
|
+/* Old braindamage in GCC's crtstuff.c requires this symbol in an attempt
|
||||||
|
+ to work around different old braindamage in the old Linux ELF dynamic
|
||||||
|
+ linker. */
|
||||||
|
+weak_alias (__curbrk, ___brk_addr)
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
+#ifdef __arch64__
|
||||||
|
+# define SYSCALL_NUM "0x6d"
|
||||||
|
+#else
|
||||||
|
+# define SYSCALL_NUM "0x10"
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
+int
|
||||||
|
+__brk (void *addr)
|
||||||
|
+{
|
||||||
|
+ register long int g1 asm ("g1") = __NR_brk;
|
||||||
|
+ register long int o0 asm ("o0") = (long int) addr;
|
||||||
|
+ asm volatile ("ta " SYSCALL_NUM
|
||||||
|
+ : "=r"(o0)
|
||||||
|
+ : "r"(g1), "0"(o0)
|
||||||
|
+ : "cc");
|
||||||
|
+ __curbrk = (void *) o0;
|
||||||
|
+
|
||||||
|
+ if (__curbrk < addr)
|
||||||
|
+ {
|
||||||
|
+ __set_errno (ENOMEM);
|
||||||
|
+ return -1;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ return 0;
|
||||||
|
+}
|
||||||
|
+weak_alias (__brk, brk)
|
33
glibc-upstream-2.34-65.patch
Normal file
33
glibc-upstream-2.34-65.patch
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
commit 8ad6d6d8ed33631bd2ca5d1112e6da2f92731432
|
||||||
|
Author: maminjie <maminjie2@huawei.com>
|
||||||
|
Date: Mon Dec 20 19:36:32 2021 +0800
|
||||||
|
|
||||||
|
Linux: Fix 32-bit vDSO for clock_gettime on powerpc32
|
||||||
|
|
||||||
|
When the clock_id is CLOCK_PROCESS_CPUTIME_ID or CLOCK_THREAD_CPUTIME_ID,
|
||||||
|
on the 5.10 kernel powerpc 32-bit, the 32-bit vDSO is executed successfully (
|
||||||
|
because the __kernel_clock_gettime in arch/powerpc/kernel/vdso32/gettimeofday.S
|
||||||
|
does not support these two IDs, the 32-bit time_t syscall will be used),
|
||||||
|
but tp32.tv_sec is equal to 0, causing the 64-bit time_t syscall to continue to be used,
|
||||||
|
resulting in two system calls.
|
||||||
|
|
||||||
|
Fix commit 72e84d1db22203e01a43268de71ea8669eca2863.
|
||||||
|
|
||||||
|
Signed-off-by: maminjie <maminjie2@huawei.com>
|
||||||
|
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
|
||||||
|
|
||||||
|
(cherry picked from commit e0fc721ce600038dd390e77cfe52440707ef574d)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/clock_gettime.c b/sysdeps/unix/sysv/linux/clock_gettime.c
|
||||||
|
index 91df6b3d967bf945..9c7d9073254843c7 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/clock_gettime.c
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/clock_gettime.c
|
||||||
|
@@ -53,7 +53,7 @@ __clock_gettime64 (clockid_t clock_id, struct __timespec64 *tp)
|
||||||
|
{
|
||||||
|
struct timespec tp32;
|
||||||
|
r = INTERNAL_VSYSCALL_CALL (vdso_time, 2, clock_id, &tp32);
|
||||||
|
- if (r == 0 && tp32.tv_sec > 0)
|
||||||
|
+ if (r == 0 && tp32.tv_sec >= 0)
|
||||||
|
{
|
||||||
|
*tp = valid_timespec_to_timespec64 (tp32);
|
||||||
|
return 0;
|
37
glibc-upstream-2.34-66.patch
Normal file
37
glibc-upstream-2.34-66.patch
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
commit 41fddc064ded5c9a36d8ffaad59a85407a22a535
|
||||||
|
Author: Andrea Monaco <andrea.monaco@autistici.org>
|
||||||
|
Date: Sun Dec 12 10:24:28 2021 +0100
|
||||||
|
|
||||||
|
intl/plural.y: Avoid conflicting declarations of yyerror and yylex
|
||||||
|
|
||||||
|
bison-3.8 includes these lines in the generated intl/plural.c:
|
||||||
|
|
||||||
|
#if !defined __gettexterror && !defined YYERROR_IS_DECLARED
|
||||||
|
void __gettexterror (struct parse_args *arg, const char *msg);
|
||||||
|
#endif
|
||||||
|
#if !defined __gettextlex && !defined YYLEX_IS_DECLARED
|
||||||
|
int __gettextlex (YYSTYPE *yylvalp, struct parse_args *arg);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Those default prototypes provided by bison conflict with the
|
||||||
|
declarations later on in plural.y. This patch solves the issue.
|
||||||
|
|
||||||
|
Reviewed-by: Arjun Shankar <arjun@redhat.com>
|
||||||
|
(cherry picked from commit c6d7d6312c21bbcfb236d48bb7c11cedb234389f)
|
||||||
|
|
||||||
|
diff --git a/intl/plural.y b/intl/plural.y
|
||||||
|
index e02e74541c4574eb..2ee128ba01b5820d 100644
|
||||||
|
--- a/intl/plural.y
|
||||||
|
+++ b/intl/plural.y
|
||||||
|
@@ -40,6 +40,11 @@
|
||||||
|
# define __gettextparse PLURAL_PARSE
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+/* Later we provide those prototypes. Without these macros, bison may
|
||||||
|
+ generate its own prototypes with possible conflicts. */
|
||||||
|
+#define YYLEX_IS_DECLARED
|
||||||
|
+#define YYERROR_IS_DECLARED
|
||||||
|
+
|
||||||
|
%}
|
||||||
|
%parse-param {struct parse_args *arg}
|
||||||
|
%lex-param {struct parse_args *arg}
|
50
glibc-upstream-2.34-67.patch
Normal file
50
glibc-upstream-2.34-67.patch
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
commit 217b84127b3a6590afcc7e198e6c3f665935e8f4
|
||||||
|
Author: Wilco Dijkstra <wdijkstr@arm.com>
|
||||||
|
Date: Thu Jan 6 14:36:28 2022 +0000
|
||||||
|
|
||||||
|
AArch64: Check for SVE in ifuncs [BZ #28744]
|
||||||
|
|
||||||
|
Add a check for SVE in the A64FX ifuncs for memcpy, memset and memmove.
|
||||||
|
This fixes BZ #28744.
|
||||||
|
|
||||||
|
(cherry picked from commit e5fa62b8db546f8792ec9e5c61e6419f4f8e3f4d)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/aarch64/multiarch/memcpy.c b/sysdeps/aarch64/multiarch/memcpy.c
|
||||||
|
index 25e0081eeb51727c..b6703af44b3f1a3d 100644
|
||||||
|
--- a/sysdeps/aarch64/multiarch/memcpy.c
|
||||||
|
+++ b/sysdeps/aarch64/multiarch/memcpy.c
|
||||||
|
@@ -48,7 +48,7 @@ libc_ifunc (__libc_memcpy,
|
||||||
|
|| IS_NEOVERSE_V1 (midr)
|
||||||
|
? __memcpy_simd
|
||||||
|
# if HAVE_AARCH64_SVE_ASM
|
||||||
|
- : (IS_A64FX (midr)
|
||||||
|
+ : (IS_A64FX (midr) && sve
|
||||||
|
? __memcpy_a64fx
|
||||||
|
: __memcpy_generic))))));
|
||||||
|
# else
|
||||||
|
diff --git a/sysdeps/aarch64/multiarch/memmove.c b/sysdeps/aarch64/multiarch/memmove.c
|
||||||
|
index d0adefc547f60030..d2339ff34ff7b3e5 100644
|
||||||
|
--- a/sysdeps/aarch64/multiarch/memmove.c
|
||||||
|
+++ b/sysdeps/aarch64/multiarch/memmove.c
|
||||||
|
@@ -48,7 +48,7 @@ libc_ifunc (__libc_memmove,
|
||||||
|
|| IS_NEOVERSE_V1 (midr)
|
||||||
|
? __memmove_simd
|
||||||
|
# if HAVE_AARCH64_SVE_ASM
|
||||||
|
- : (IS_A64FX (midr)
|
||||||
|
+ : (IS_A64FX (midr) && sve
|
||||||
|
? __memmove_a64fx
|
||||||
|
: __memmove_generic))))));
|
||||||
|
# else
|
||||||
|
diff --git a/sysdeps/aarch64/multiarch/memset.c b/sysdeps/aarch64/multiarch/memset.c
|
||||||
|
index d7d9bbbda095e051..3d839bc02e96380d 100644
|
||||||
|
--- a/sysdeps/aarch64/multiarch/memset.c
|
||||||
|
+++ b/sysdeps/aarch64/multiarch/memset.c
|
||||||
|
@@ -44,7 +44,7 @@ libc_ifunc (__libc_memset,
|
||||||
|
: (IS_EMAG (midr) && zva_size == 64
|
||||||
|
? __memset_emag
|
||||||
|
# if HAVE_AARCH64_SVE_ASM
|
||||||
|
- : (IS_A64FX (midr)
|
||||||
|
+ : (IS_A64FX (midr) && sve
|
||||||
|
? __memset_a64fx
|
||||||
|
: __memset_generic))));
|
||||||
|
# else
|
27
glibc-upstream-2.34-68.patch
Normal file
27
glibc-upstream-2.34-68.patch
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
commit 515a6f53cd984d5e6e374fbee52772f967fc3c73
|
||||||
|
Author: Paul Eggert <eggert@cs.ucla.edu>
|
||||||
|
Date: Mon Sep 13 22:49:45 2021 -0700
|
||||||
|
|
||||||
|
Fix subscript error with odd TZif file [BZ #28338]
|
||||||
|
|
||||||
|
* time/tzfile.c (__tzfile_compute): Fix unlikely off-by-one bug
|
||||||
|
that accessed before start of an array when an oddball-but-valid
|
||||||
|
TZif file was queried with an unusual time_t value.
|
||||||
|
|
||||||
|
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
|
||||||
|
(cherry picked from commit 645277434a42efc547d2cac8bfede4da10b4049f)
|
||||||
|
|
||||||
|
diff --git a/time/tzfile.c b/time/tzfile.c
|
||||||
|
index 4377018a55936389..190a777152b31cee 100644
|
||||||
|
--- a/time/tzfile.c
|
||||||
|
+++ b/time/tzfile.c
|
||||||
|
@@ -765,8 +765,7 @@ __tzfile_compute (__time64_t timer, int use_localtime,
|
||||||
|
*leap_correct = leaps[i].change;
|
||||||
|
|
||||||
|
if (timer == leaps[i].transition /* Exactly at the transition time. */
|
||||||
|
- && ((i == 0 && leaps[i].change > 0)
|
||||||
|
- || leaps[i].change > leaps[i - 1].change))
|
||||||
|
+ && (leaps[i].change > (i == 0 ? 0 : leaps[i - 1].change)))
|
||||||
|
{
|
||||||
|
*leap_hit = 1;
|
||||||
|
while (i > 0
|
52
glibc-upstream-2.34-69.patch
Normal file
52
glibc-upstream-2.34-69.patch
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
commit 85b24f9694e21f1d2f2d8b80d3bf690687723347
|
||||||
|
Author: Hans-Peter Nilsson <hp@axis.com>
|
||||||
|
Date: Fri Dec 17 21:38:00 2021 +0100
|
||||||
|
|
||||||
|
timezone: handle truncated timezones from tzcode-2021d and later (BZ #28707)
|
||||||
|
|
||||||
|
When using a timezone file with a truncated starting time,
|
||||||
|
generated by the zic in IANA tzcode-2021d a.k.a. tzlib-2021d
|
||||||
|
(also in tzlib-2021e; current as of this writing), glibc
|
||||||
|
asserts in __tzfile_read (on e.g. tzset() for this file) and
|
||||||
|
you may find lines matching "tzfile.c:435: __tzfile_read:
|
||||||
|
Assertion `num_types == 1' failed" in your syslog.
|
||||||
|
|
||||||
|
One example of such a file is the tzfile for Asuncion
|
||||||
|
generated by tzlib-2021e as follows, using the tzlib-2021e zic:
|
||||||
|
"zic -d DEST -r @1546300800 -L /dev/null -b slim
|
||||||
|
SOURCE/southamerica". Note that in its type 2 header, it has
|
||||||
|
two entries in its "time-types" array (types), but only one
|
||||||
|
entry in its "transition types" array (type_idxs).
|
||||||
|
|
||||||
|
This is valid and expected already in the published RFC8536, and
|
||||||
|
not even frowned upon: "Local time for timestamps before the
|
||||||
|
first transition is specified by the first time type (time type
|
||||||
|
0)" ... "every nonzero local time type index SHOULD appear at
|
||||||
|
least once in the transition type array". Note the "nonzero ...
|
||||||
|
index". Until the 2021d zic, index 0 has been shared by the
|
||||||
|
first valid transition but with 2021d it's separate, set apart
|
||||||
|
as a placeholder and only "implicitly" indexed. (A draft update
|
||||||
|
of the RFC mandates that the entry at index 0 is a placeholder
|
||||||
|
in this case, hence can no longer be shared.)
|
||||||
|
|
||||||
|
* time/tzfile.c (__tzfile_read): Don't assert when no transitions
|
||||||
|
are found.
|
||||||
|
|
||||||
|
Co-authored-by: Christopher Wong <Christopher.Wong@axis.com>
|
||||||
|
(cherry picked from commit c36f64aa6dff13b12a1e03a185e75a50fa9f6a4c)
|
||||||
|
|
||||||
|
diff --git a/time/tzfile.c b/time/tzfile.c
|
||||||
|
index 190a777152b31cee..8668392ad387af05 100644
|
||||||
|
--- a/time/tzfile.c
|
||||||
|
+++ b/time/tzfile.c
|
||||||
|
@@ -431,8 +431,8 @@ __tzfile_read (const char *file, size_t extra, char **extrap)
|
||||||
|
if (__tzname[0] == NULL)
|
||||||
|
{
|
||||||
|
/* This should only happen if there are no transition rules.
|
||||||
|
- In this case there should be only one single type. */
|
||||||
|
- assert (num_types == 1);
|
||||||
|
+ In this case there's usually only one single type, unless
|
||||||
|
+ e.g. the data file has a truncated time-range. */
|
||||||
|
__tzname[0] = __tzstring (zone_names);
|
||||||
|
}
|
||||||
|
if (__tzname[1] == NULL)
|
130
glibc-upstream-2.34-70.patch
Normal file
130
glibc-upstream-2.34-70.patch
Normal file
@ -0,0 +1,130 @@
|
|||||||
|
commit d5ba02f67dd62a63e29c29eebd6c543722aa6b5b
|
||||||
|
Author: Hans-Peter Nilsson <hp@axis.com>
|
||||||
|
Date: Fri Dec 17 21:45:54 2021 +0100
|
||||||
|
|
||||||
|
timezone: test-case for BZ #28707
|
||||||
|
|
||||||
|
This test-case is the tzfile for Asuncion generated by
|
||||||
|
tzlib-2021e as follows, using the tzlib-2021e zic: "zic -d
|
||||||
|
DEST -r @1546300800 -L /dev/null -b slim
|
||||||
|
SOURCE/southamerica". Note that in its type 2 header, it
|
||||||
|
has two entries in its "time-types" array (types), but only
|
||||||
|
one entry in its "transition types" array (type_idxs).
|
||||||
|
|
||||||
|
* timezone/Makefile, timezone/tst-pr28707.c,
|
||||||
|
timezone/testdata/gen-XT5.sh: New test.
|
||||||
|
|
||||||
|
Co-authored-by: Christopher Wong <Christopher.Wong@axis.com>
|
||||||
|
(cherry picked from commit ebe899af0dc3215159a9c896ac6f35b72a18cb6e)
|
||||||
|
|
||||||
|
diff --git a/timezone/Makefile b/timezone/Makefile
|
||||||
|
index c624a189b322cb5f..f091663b8bbbceda 100644
|
||||||
|
--- a/timezone/Makefile
|
||||||
|
+++ b/timezone/Makefile
|
||||||
|
@@ -23,7 +23,7 @@ subdir := timezone
|
||||||
|
include ../Makeconfig
|
||||||
|
|
||||||
|
others := zdump zic
|
||||||
|
-tests := test-tz tst-timezone tst-tzset
|
||||||
|
+tests := test-tz tst-timezone tst-tzset tst-bz28707
|
||||||
|
|
||||||
|
generated-dirs += testdata
|
||||||
|
|
||||||
|
@@ -85,10 +85,12 @@ $(objpfx)tst-timezone.out: $(addprefix $(testdata)/, \
|
||||||
|
America/Sao_Paulo Asia/Tokyo \
|
||||||
|
Europe/London)
|
||||||
|
$(objpfx)tst-tzset.out: $(addprefix $(testdata)/XT, 1 2 3 4)
|
||||||
|
+$(objpfx)tst-bz28707.out: $(testdata)/XT5
|
||||||
|
|
||||||
|
test-tz-ENV = TZDIR=$(testdata)
|
||||||
|
tst-timezone-ENV = TZDIR=$(testdata)
|
||||||
|
tst-tzset-ENV = TZDIR=$(testdata)
|
||||||
|
+tst-bz28707-ENV = TZDIR=$(testdata)
|
||||||
|
|
||||||
|
# Note this must come second in the deps list for $(built-program-cmd) to work.
|
||||||
|
zic-deps = $(objpfx)zic $(leapseconds) yearistype
|
||||||
|
@@ -122,6 +124,10 @@ $(testdata)/XT%: testdata/XT%
|
||||||
|
$(make-target-directory)
|
||||||
|
cp $< $@
|
||||||
|
|
||||||
|
+$(testdata)/XT%: testdata/gen-XT%.sh
|
||||||
|
+ $(SHELL) $< > $@.tmp
|
||||||
|
+ mv $@.tmp $@
|
||||||
|
+
|
||||||
|
$(objpfx)tzselect: tzselect.ksh $(common-objpfx)config.make
|
||||||
|
sed -e 's|TZDIR=[^}]*|TZDIR=$(zonedir)|' \
|
||||||
|
-e '/TZVERSION=/s|see_Makefile|"$(version)"|' \
|
||||||
|
diff --git a/timezone/testdata/gen-XT5.sh b/timezone/testdata/gen-XT5.sh
|
||||||
|
new file mode 100755
|
||||||
|
index 0000000000000000..3cea0569eb5a6a57
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/timezone/testdata/gen-XT5.sh
|
||||||
|
@@ -0,0 +1,16 @@
|
||||||
|
+#! /bin/sh
|
||||||
|
+
|
||||||
|
+# This test-case is the tzfile for America/Asuncion
|
||||||
|
+# generated by tzlib-2021e as follows, using the tzlib-2021e
|
||||||
|
+# zic: "zic -d DEST -r @1546300800 -L /dev/null -b slim
|
||||||
|
+# SOURCE/southamerica". Note that in its type 2 header, it
|
||||||
|
+# has two entries in its "time-types" array (types), but
|
||||||
|
+# only one entry in its "transition types" array
|
||||||
|
+# (type_idxs).
|
||||||
|
+
|
||||||
|
+printf \
|
||||||
|
+'TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0'\
|
||||||
|
+'\0\0\0\0\0\0\0\1\0\0\0\1\0\0\0\0\0\0\0TZif2\0\0\0\0\0\0\0\0'\
|
||||||
|
+'\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\1\0\0\0\2\0\0\0\b\0'\
|
||||||
|
+'\0\0\0\*\255\200\1\0\0\0\0\0\0\377\377\325\320\1\4-00\0-03\0\n'\
|
||||||
|
+'<-04>4<-03>,M10.1.0/0,M3.4.0/0\n'
|
||||||
|
diff --git a/timezone/tst-bz28707.c b/timezone/tst-bz28707.c
|
||||||
|
new file mode 100644
|
||||||
|
index 0000000000000000..0a9df1e9a094f1e9
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/timezone/tst-bz28707.c
|
||||||
|
@@ -0,0 +1,46 @@
|
||||||
|
+/* Copyright (C) 2021 Free Software Foundation, Inc.
|
||||||
|
+ This file is part of the GNU C Library.
|
||||||
|
+
|
||||||
|
+ The GNU C Library is free software; you can redistribute it and/or
|
||||||
|
+ modify it under the terms of the GNU Lesser General Public
|
||||||
|
+ License as published by the Free Software Foundation; either
|
||||||
|
+ version 2.1 of the License, or (at your option) any later version.
|
||||||
|
+
|
||||||
|
+ The GNU C Library is distributed in the hope that it will be useful,
|
||||||
|
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
+ Lesser General Public License for more details.
|
||||||
|
+
|
||||||
|
+ You should have received a copy of the GNU Lesser General Public
|
||||||
|
+ License along with the GNU C Library; if not, see
|
||||||
|
+ <https://www.gnu.org/licenses/>. */
|
||||||
|
+
|
||||||
|
+#include <time.h>
|
||||||
|
+#include <stdio.h>
|
||||||
|
+#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
+
|
||||||
|
+/* Test that we can use a truncated timezone-file, where the time-type
|
||||||
|
+ at index 0 is not indexed by the transition-types array (and the
|
||||||
|
+ transition-types array does not contain at least both one DST and one
|
||||||
|
+ normal time members). */
|
||||||
|
+
|
||||||
|
+static int
|
||||||
|
+do_test (void)
|
||||||
|
+{
|
||||||
|
+ if (setenv ("TZ", "XT5", 1))
|
||||||
|
+ {
|
||||||
|
+ puts ("setenv failed.");
|
||||||
|
+ return 1;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ tzset ();
|
||||||
|
+
|
||||||
|
+ return
|
||||||
|
+ /* Sanity-check that we got the right timezone-name for DST. For
|
||||||
|
+ normal time, we're likely to get "-00" (the "unspecified" marker),
|
||||||
|
+ even though the POSIX timezone string says "-04". Let's not test
|
||||||
|
+ that. */
|
||||||
|
+ !(strcmp (tzname[1], "-03") == 0);
|
||||||
|
+}
|
||||||
|
+#include <support/test-driver.c>
|
39
glibc-upstream-2.34-71.patch
Normal file
39
glibc-upstream-2.34-71.patch
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
commit e64235ff4266e87b20505101877fe57350ab69ab
|
||||||
|
Author: Paul A. Clarke <pc@us.ibm.com>
|
||||||
|
Date: Tue Sep 14 13:13:33 2021 -0500
|
||||||
|
|
||||||
|
powerpc: Fix unrecognized instruction errors with recent GCC
|
||||||
|
|
||||||
|
Recent binutils commit b25f942e18d6ecd7ec3e2d2e9930eb4f996c258a
|
||||||
|
changes the behavior of `.machine` directives to override, rather
|
||||||
|
than augment, the base CPU. This can result in _reduced_ functionality
|
||||||
|
when, for example, compiling for default machine "power8", but explicitly
|
||||||
|
asking for ".machine power5", which loses Altivec instructions.
|
||||||
|
|
||||||
|
In tst-ucontext-ppc64-vscr.c, while the instructions provoking the new
|
||||||
|
error messages are bracketed by ".machine power5", which is ostensibly
|
||||||
|
Power ISA 2.03 (POWER5), the POWER5 processor did not support the
|
||||||
|
VSX subset, so these instructions are not recognized as "power5".
|
||||||
|
|
||||||
|
Error: unrecognized opcode: `vspltisb'
|
||||||
|
Error: unrecognized opcode: `vpkuwus'
|
||||||
|
Error: unrecognized opcode: `mfvscr'
|
||||||
|
Error: unrecognized opcode: `stvx'
|
||||||
|
|
||||||
|
Manually adding the VSX subset via ".machine altivec" is sufficient.
|
||||||
|
|
||||||
|
Reviewed-by: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
|
||||||
|
(cherry picked from commit 064b475a2e5662b6b3973fabf505eade86e61510)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/powerpc/powerpc64/tst-ucontext-ppc64-vscr.c b/sysdeps/powerpc/powerpc64/tst-ucontext-ppc64-vscr.c
|
||||||
|
index 28c87fcef72bded6..d3fc4ab589f4752a 100644
|
||||||
|
--- a/sysdeps/powerpc/powerpc64/tst-ucontext-ppc64-vscr.c
|
||||||
|
+++ b/sysdeps/powerpc/powerpc64/tst-ucontext-ppc64-vscr.c
|
||||||
|
@@ -50,6 +50,7 @@ do_test (void)
|
||||||
|
/* Set SAT bit in VSCR register. */
|
||||||
|
asm volatile (".machine push;\n"
|
||||||
|
".machine \"power5\";\n"
|
||||||
|
+ ".machine altivec;\n"
|
||||||
|
"vspltisb %0,0;\n"
|
||||||
|
"vspltisb %1,-1;\n"
|
||||||
|
"vpkuwus %0,%0,%1;\n"
|
377
glibc-upstream-2.34-72.patch
Normal file
377
glibc-upstream-2.34-72.patch
Normal file
@ -0,0 +1,377 @@
|
|||||||
|
commit 73558ffe841cf4c60ccb4c71cf6dcebf84f2b736
|
||||||
|
Author: Joseph Myers <joseph@codesourcery.com>
|
||||||
|
Date: Wed Nov 10 15:21:19 2021 +0000
|
||||||
|
|
||||||
|
Update syscall lists for Linux 5.15
|
||||||
|
|
||||||
|
Linux 5.15 has one new syscall, process_mrelease (and also enables the
|
||||||
|
clone3 syscall for RV32). It also has a macro __NR_SYSCALL_MASK for
|
||||||
|
Arm, which is not a syscall but matches the pattern used for syscall
|
||||||
|
macro names.
|
||||||
|
|
||||||
|
Add __NR_SYSCALL_MASK to the names filtered out in the code dealing
|
||||||
|
with syscall lists, update syscall-names.list for the new syscall and
|
||||||
|
regenerate the arch-syscall.h headers with build-many-glibcs.py
|
||||||
|
update-syscalls.
|
||||||
|
|
||||||
|
Tested with build-many-glibcs.py.
|
||||||
|
|
||||||
|
(cherry picked from commit 3387c40a8bbad5faf85b1feb56429cb20feaa640)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/aarch64/arch-syscall.h b/sysdeps/unix/sysv/linux/aarch64/arch-syscall.h
|
||||||
|
index bedab1abbac7f6c1..74a809561a45edc4 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/aarch64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/aarch64/arch-syscall.h
|
||||||
|
@@ -180,6 +180,7 @@
|
||||||
|
#define __NR_preadv2 286
|
||||||
|
#define __NR_prlimit64 261
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 270
|
||||||
|
#define __NR_process_vm_writev 271
|
||||||
|
#define __NR_pselect6 72
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/alpha/arch-syscall.h b/sysdeps/unix/sysv/linux/alpha/arch-syscall.h
|
||||||
|
index 91354ed9e29b8d15..6fc0a23504c3b53d 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/alpha/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/alpha/arch-syscall.h
|
||||||
|
@@ -328,6 +328,7 @@
|
||||||
|
#define __NR_preadv2 520
|
||||||
|
#define __NR_prlimit64 496
|
||||||
|
#define __NR_process_madvise 550
|
||||||
|
+#define __NR_process_mrelease 558
|
||||||
|
#define __NR_process_vm_readv 504
|
||||||
|
#define __NR_process_vm_writev 505
|
||||||
|
#define __NR_pselect6 463
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/arc/arch-syscall.h b/sysdeps/unix/sysv/linux/arc/arch-syscall.h
|
||||||
|
index ff5c7eb36db89494..0c66762bf868a992 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/arc/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/arc/arch-syscall.h
|
||||||
|
@@ -182,6 +182,7 @@
|
||||||
|
#define __NR_preadv2 286
|
||||||
|
#define __NR_prlimit64 261
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 270
|
||||||
|
#define __NR_process_vm_writev 271
|
||||||
|
#define __NR_pselect6_time64 413
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/arm/arch-syscall.h b/sysdeps/unix/sysv/linux/arm/arch-syscall.h
|
||||||
|
index 5772333ceef6ce59..c41a864c6d530eb0 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/arm/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/arm/arch-syscall.h
|
||||||
|
@@ -235,6 +235,7 @@
|
||||||
|
#define __NR_preadv2 392
|
||||||
|
#define __NR_prlimit64 369
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 376
|
||||||
|
#define __NR_process_vm_writev 377
|
||||||
|
#define __NR_pselect6 335
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/csky/arch-syscall.h b/sysdeps/unix/sysv/linux/csky/arch-syscall.h
|
||||||
|
index 4af6d6202f6df7ae..863ffa3e0cd34d3e 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/csky/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/csky/arch-syscall.h
|
||||||
|
@@ -190,6 +190,7 @@
|
||||||
|
#define __NR_preadv2 286
|
||||||
|
#define __NR_prlimit64 261
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 270
|
||||||
|
#define __NR_process_vm_writev 271
|
||||||
|
#define __NR_pselect6 72
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/filter-nr-syscalls.awk b/sysdeps/unix/sysv/linux/filter-nr-syscalls.awk
|
||||||
|
index dddfd517471e5cc9..85b017918ef20736 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/filter-nr-syscalls.awk
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/filter-nr-syscalls.awk
|
||||||
|
@@ -22,7 +22,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
# Skip pseudo-system calls which describe ranges.
|
||||||
|
-/^#define __NR_(syscalls|arch_specific_syscall|(OABI_)?SYSCALL_BASE) / {
|
||||||
|
+/^#define __NR_(syscalls|arch_specific_syscall|(OABI_)?SYSCALL_BASE|SYSCALL_MASK) / {
|
||||||
|
next;
|
||||||
|
}
|
||||||
|
/^#define __NR_(|64_|[NO]32_)Linux(_syscalls)? / {
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/glibcsyscalls.py b/sysdeps/unix/sysv/linux/glibcsyscalls.py
|
||||||
|
index 621a202ed75cd725..fe7896eebe74cdf4 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/glibcsyscalls.py
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/glibcsyscalls.py
|
||||||
|
@@ -41,7 +41,7 @@ RE_PSEUDO_SYSCALL = re.compile(r"""__NR_(
|
||||||
|
(unused|reserved)[0-9]+
|
||||||
|
|
||||||
|
# Pseudo-system call which describes a range.
|
||||||
|
- |(syscalls|arch_specific_syscall|(OABI_)?SYSCALL_BASE)
|
||||||
|
+ |(syscalls|arch_specific_syscall|(OABI_)?SYSCALL_BASE|SYSCALL_MASK)
|
||||||
|
|(|64_|[NO]32_)Linux(_syscalls)?
|
||||||
|
)""", re.X)
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/hppa/arch-syscall.h b/sysdeps/unix/sysv/linux/hppa/arch-syscall.h
|
||||||
|
index b07fc8549de34157..6cf27cd17c1ad0c0 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/hppa/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/hppa/arch-syscall.h
|
||||||
|
@@ -222,6 +222,7 @@
|
||||||
|
#define __NR_preadv2 347
|
||||||
|
#define __NR_prlimit64 321
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 330
|
||||||
|
#define __NR_process_vm_writev 331
|
||||||
|
#define __NR_pselect6 273
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/i386/arch-syscall.h b/sysdeps/unix/sysv/linux/i386/arch-syscall.h
|
||||||
|
index 6e4264698b5ce480..2512508b7daa8ed2 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/i386/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/i386/arch-syscall.h
|
||||||
|
@@ -254,6 +254,7 @@
|
||||||
|
#define __NR_preadv2 378
|
||||||
|
#define __NR_prlimit64 340
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 347
|
||||||
|
#define __NR_process_vm_writev 348
|
||||||
|
#define __NR_prof 44
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/ia64/arch-syscall.h b/sysdeps/unix/sysv/linux/ia64/arch-syscall.h
|
||||||
|
index 1ca706d7216a3902..4a0c737369217367 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/ia64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/ia64/arch-syscall.h
|
||||||
|
@@ -209,6 +209,7 @@
|
||||||
|
#define __NR_preadv2 1348
|
||||||
|
#define __NR_prlimit64 1325
|
||||||
|
#define __NR_process_madvise 1464
|
||||||
|
+#define __NR_process_mrelease 1472
|
||||||
|
#define __NR_process_vm_readv 1332
|
||||||
|
#define __NR_process_vm_writev 1333
|
||||||
|
#define __NR_pselect6 1294
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/m68k/arch-syscall.h b/sysdeps/unix/sysv/linux/m68k/arch-syscall.h
|
||||||
|
index 2f10f71f90d225ff..e310eb5075fb22d8 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/m68k/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/m68k/arch-syscall.h
|
||||||
|
@@ -243,6 +243,7 @@
|
||||||
|
#define __NR_preadv2 377
|
||||||
|
#define __NR_prlimit64 339
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 345
|
||||||
|
#define __NR_process_vm_writev 346
|
||||||
|
#define __NR_pselect6 301
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/microblaze/arch-syscall.h b/sysdeps/unix/sysv/linux/microblaze/arch-syscall.h
|
||||||
|
index 0607a4dfa6adaa23..b4ecad010c2a6abf 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/microblaze/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/microblaze/arch-syscall.h
|
||||||
|
@@ -253,6 +253,7 @@
|
||||||
|
#define __NR_preadv2 393
|
||||||
|
#define __NR_prlimit64 370
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 377
|
||||||
|
#define __NR_process_vm_writev 378
|
||||||
|
#define __NR_prof 44
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/mips/mips32/arch-syscall.h b/sysdeps/unix/sysv/linux/mips/mips32/arch-syscall.h
|
||||||
|
index 0055eec0b169ba96..7e3d138ba969c57b 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/mips/mips32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/mips/mips32/arch-syscall.h
|
||||||
|
@@ -238,6 +238,7 @@
|
||||||
|
#define __NR_preadv2 4361
|
||||||
|
#define __NR_prlimit64 4338
|
||||||
|
#define __NR_process_madvise 4440
|
||||||
|
+#define __NR_process_mrelease 4448
|
||||||
|
#define __NR_process_vm_readv 4345
|
||||||
|
#define __NR_process_vm_writev 4346
|
||||||
|
#define __NR_prof 4044
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n32/arch-syscall.h b/sysdeps/unix/sysv/linux/mips/mips64/n32/arch-syscall.h
|
||||||
|
index 8e8e9f91ccfebfab..7e9e232e5256bc89 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/mips/mips64/n32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n32/arch-syscall.h
|
||||||
|
@@ -221,6 +221,7 @@
|
||||||
|
#define __NR_preadv2 6325
|
||||||
|
#define __NR_prlimit64 6302
|
||||||
|
#define __NR_process_madvise 6440
|
||||||
|
+#define __NR_process_mrelease 6448
|
||||||
|
#define __NR_process_vm_readv 6309
|
||||||
|
#define __NR_process_vm_writev 6310
|
||||||
|
#define __NR_pselect6 6264
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n64/arch-syscall.h b/sysdeps/unix/sysv/linux/mips/mips64/n64/arch-syscall.h
|
||||||
|
index ebd1545f806564bb..f9e7ef72b0aa1749 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/mips/mips64/n64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n64/arch-syscall.h
|
||||||
|
@@ -209,6 +209,7 @@
|
||||||
|
#define __NR_preadv2 5321
|
||||||
|
#define __NR_prlimit64 5297
|
||||||
|
#define __NR_process_madvise 5440
|
||||||
|
+#define __NR_process_mrelease 5448
|
||||||
|
#define __NR_process_vm_readv 5304
|
||||||
|
#define __NR_process_vm_writev 5305
|
||||||
|
#define __NR_pselect6 5260
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/nios2/arch-syscall.h b/sysdeps/unix/sysv/linux/nios2/arch-syscall.h
|
||||||
|
index 2b530b1f88e4c52a..afd73fc1daca1fb4 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/nios2/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/nios2/arch-syscall.h
|
||||||
|
@@ -189,6 +189,7 @@
|
||||||
|
#define __NR_preadv2 286
|
||||||
|
#define __NR_prlimit64 261
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 270
|
||||||
|
#define __NR_process_vm_writev 271
|
||||||
|
#define __NR_pselect6 72
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/arch-syscall.h b/sysdeps/unix/sysv/linux/powerpc/powerpc32/arch-syscall.h
|
||||||
|
index a32984a9c17315ee..0ac2992028eda27e 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/arch-syscall.h
|
||||||
|
@@ -247,6 +247,7 @@
|
||||||
|
#define __NR_preadv2 380
|
||||||
|
#define __NR_prlimit64 325
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 351
|
||||||
|
#define __NR_process_vm_writev 352
|
||||||
|
#define __NR_prof 44
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/arch-syscall.h b/sysdeps/unix/sysv/linux/powerpc/powerpc64/arch-syscall.h
|
||||||
|
index b01e464fb906d632..c890bc644e14fe06 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/arch-syscall.h
|
||||||
|
@@ -231,6 +231,7 @@
|
||||||
|
#define __NR_preadv2 380
|
||||||
|
#define __NR_prlimit64 325
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 351
|
||||||
|
#define __NR_process_vm_writev 352
|
||||||
|
#define __NR_prof 44
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/riscv/rv32/arch-syscall.h b/sysdeps/unix/sysv/linux/riscv/rv32/arch-syscall.h
|
||||||
|
index 24d0a2c455caa630..cd336d755a42598a 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/riscv/rv32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/riscv/rv32/arch-syscall.h
|
||||||
|
@@ -16,6 +16,7 @@
|
||||||
|
#define __NR_clock_nanosleep_time64 407
|
||||||
|
#define __NR_clock_settime64 404
|
||||||
|
#define __NR_clone 220
|
||||||
|
+#define __NR_clone3 435
|
||||||
|
#define __NR_close 57
|
||||||
|
#define __NR_close_range 436
|
||||||
|
#define __NR_connect 203
|
||||||
|
@@ -171,6 +172,7 @@
|
||||||
|
#define __NR_preadv2 286
|
||||||
|
#define __NR_prlimit64 261
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 270
|
||||||
|
#define __NR_process_vm_writev 271
|
||||||
|
#define __NR_pselect6_time64 413
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/riscv/rv64/arch-syscall.h b/sysdeps/unix/sysv/linux/riscv/rv64/arch-syscall.h
|
||||||
|
index e526c89ae7b285cc..8edd21620bb4ef64 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/riscv/rv64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/riscv/rv64/arch-syscall.h
|
||||||
|
@@ -179,6 +179,7 @@
|
||||||
|
#define __NR_preadv2 286
|
||||||
|
#define __NR_prlimit64 261
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 270
|
||||||
|
#define __NR_process_vm_writev 271
|
||||||
|
#define __NR_pselect6 72
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/arch-syscall.h b/sysdeps/unix/sysv/linux/s390/s390-32/arch-syscall.h
|
||||||
|
index d4c7b101b64c010f..1a4873f505765617 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/s390/s390-32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/s390/s390-32/arch-syscall.h
|
||||||
|
@@ -240,6 +240,7 @@
|
||||||
|
#define __NR_preadv2 376
|
||||||
|
#define __NR_prlimit64 334
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 340
|
||||||
|
#define __NR_process_vm_writev 341
|
||||||
|
#define __NR_pselect6 301
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/s390/s390-64/arch-syscall.h b/sysdeps/unix/sysv/linux/s390/s390-64/arch-syscall.h
|
||||||
|
index bd8c78d7059a0f31..2af4607c1d36d173 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/s390/s390-64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/s390/s390-64/arch-syscall.h
|
||||||
|
@@ -211,6 +211,7 @@
|
||||||
|
#define __NR_preadv2 376
|
||||||
|
#define __NR_prlimit64 334
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 340
|
||||||
|
#define __NR_process_vm_writev 341
|
||||||
|
#define __NR_pselect6 301
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/sh/arch-syscall.h b/sysdeps/unix/sysv/linux/sh/arch-syscall.h
|
||||||
|
index 3b6ac3d084d74638..7b422ce268ba14d0 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/sh/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/sh/arch-syscall.h
|
||||||
|
@@ -237,6 +237,7 @@
|
||||||
|
#define __NR_preadv2 381
|
||||||
|
#define __NR_prlimit64 339
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 365
|
||||||
|
#define __NR_process_vm_writev 366
|
||||||
|
#define __NR_pselect6 308
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/arch-syscall.h b/sysdeps/unix/sysv/linux/sparc/sparc32/arch-syscall.h
|
||||||
|
index 35221a707e4d4a7c..77c3cc64f95ea7f3 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/sparc/sparc32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/sparc/sparc32/arch-syscall.h
|
||||||
|
@@ -242,6 +242,7 @@
|
||||||
|
#define __NR_preadv2 358
|
||||||
|
#define __NR_prlimit64 331
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 338
|
||||||
|
#define __NR_process_vm_writev 339
|
||||||
|
#define __NR_pselect6 297
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/arch-syscall.h b/sysdeps/unix/sysv/linux/sparc/sparc64/arch-syscall.h
|
||||||
|
index 5ba2b2050924df1c..7ad50bc4ad6cef04 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/sparc/sparc64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/sparc/sparc64/arch-syscall.h
|
||||||
|
@@ -222,6 +222,7 @@
|
||||||
|
#define __NR_preadv2 358
|
||||||
|
#define __NR_prlimit64 331
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 338
|
||||||
|
#define __NR_process_vm_writev 339
|
||||||
|
#define __NR_pselect6 297
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/syscall-names.list b/sysdeps/unix/sysv/linux/syscall-names.list
|
||||||
|
index fd98893b0e44a606..1a74d090b72f4d61 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/syscall-names.list
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/syscall-names.list
|
||||||
|
@@ -21,8 +21,8 @@
|
||||||
|
# This file can list all potential system calls. The names are only
|
||||||
|
# used if the installed kernel headers also provide them.
|
||||||
|
|
||||||
|
-# The list of system calls is current as of Linux 5.14.
|
||||||
|
-kernel 5.14
|
||||||
|
+# The list of system calls is current as of Linux 5.15.
|
||||||
|
+kernel 5.15
|
||||||
|
|
||||||
|
FAST_atomic_update
|
||||||
|
FAST_cmpxchg
|
||||||
|
@@ -440,6 +440,7 @@ preadv
|
||||||
|
preadv2
|
||||||
|
prlimit64
|
||||||
|
process_madvise
|
||||||
|
+process_mrelease
|
||||||
|
process_vm_readv
|
||||||
|
process_vm_writev
|
||||||
|
prof
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/x86_64/64/arch-syscall.h b/sysdeps/unix/sysv/linux/x86_64/64/arch-syscall.h
|
||||||
|
index 26d6ac68a651ec98..3ce2a1fcfc1c15f2 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/x86_64/64/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/x86_64/64/arch-syscall.h
|
||||||
|
@@ -215,6 +215,7 @@
|
||||||
|
#define __NR_preadv2 327
|
||||||
|
#define __NR_prlimit64 302
|
||||||
|
#define __NR_process_madvise 440
|
||||||
|
+#define __NR_process_mrelease 448
|
||||||
|
#define __NR_process_vm_readv 310
|
||||||
|
#define __NR_process_vm_writev 311
|
||||||
|
#define __NR_pselect6 270
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/x86_64/x32/arch-syscall.h b/sysdeps/unix/sysv/linux/x86_64/x32/arch-syscall.h
|
||||||
|
index 36847783f6b91d5e..9e87e89baccc397c 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/x86_64/x32/arch-syscall.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/x86_64/x32/arch-syscall.h
|
||||||
|
@@ -208,6 +208,7 @@
|
||||||
|
#define __NR_preadv2 1073742370
|
||||||
|
#define __NR_prlimit64 1073742126
|
||||||
|
#define __NR_process_madvise 1073742264
|
||||||
|
+#define __NR_process_mrelease 1073742272
|
||||||
|
#define __NR_process_vm_readv 1073742363
|
||||||
|
#define __NR_process_vm_writev 1073742364
|
||||||
|
#define __NR_pselect6 1073742094
|
442
glibc-upstream-2.34-73.patch
Normal file
442
glibc-upstream-2.34-73.patch
Normal file
@ -0,0 +1,442 @@
|
|||||||
|
commit 2fe2af88abd13ae5636881da2e26f461ecb7dfb5
|
||||||
|
Author: Florian Weimer <fweimer@redhat.com>
|
||||||
|
Date: Thu Jan 13 14:59:29 2022 +0100
|
||||||
|
|
||||||
|
i386: Remove broken CAN_USE_REGISTER_ASM_EBP (bug 28771)
|
||||||
|
|
||||||
|
The configure check for CAN_USE_REGISTER_ASM_EBP tried to compile a
|
||||||
|
simple function that uses %ebp as an inline assembly operand. If
|
||||||
|
compilation failed, CAN_USE_REGISTER_ASM_EBP was set 0, which
|
||||||
|
eventually had these consequences:
|
||||||
|
|
||||||
|
(1) %ebx was avoided as an inline assembly operand, with an
|
||||||
|
assembler macro hack to avoid unnecessary register moves.
|
||||||
|
(2) %ebp was avoided as an inline assembly operand, using an
|
||||||
|
out-of-line syscall function for 6-argument system calls.
|
||||||
|
|
||||||
|
(1) is no longer needed for any GCC version that is supported for
|
||||||
|
building glibc. %ebx can be used directly as a register operand.
|
||||||
|
Therefore, this commit removes the %ebx avoidance completely. This
|
||||||
|
avoids the assembler macro hack, which turns out to be incompatible
|
||||||
|
with the current Systemtap probe macros (which switch to .altmacro
|
||||||
|
unconditionally).
|
||||||
|
|
||||||
|
(2) is still needed in many build configurations. The existing
|
||||||
|
configure check cannot really capture that because the simple function
|
||||||
|
succeeds to compile, while the full glibc build still fails.
|
||||||
|
Therefore, this commit removes the check, the CAN_USE_REGISTER_ASM_EBP
|
||||||
|
macro, and uses the out-of-line syscall function for 6-argument system
|
||||||
|
calls unconditionally.
|
||||||
|
|
||||||
|
Reviewed-by: H.J. Lu <hjl.tools@gmail.com>
|
||||||
|
(cherry picked from commit a78e6a10d0b50d0ca80309775980fc99944b1727)
|
||||||
|
|
||||||
|
diff --git a/config.h.in b/config.h.in
|
||||||
|
index 458342887e4e9380..790038fec60eb049 100644
|
||||||
|
--- a/config.h.in
|
||||||
|
+++ b/config.h.in
|
||||||
|
@@ -286,10 +286,6 @@
|
||||||
|
/* Define if static PIE is enabled. */
|
||||||
|
#define ENABLE_STATIC_PIE 0
|
||||||
|
|
||||||
|
-/* Some compiler options may now allow to use ebp in __asm__ (used mainly
|
||||||
|
- in i386 6 argument syscall issue). */
|
||||||
|
-#define CAN_USE_REGISTER_ASM_EBP 0
|
||||||
|
-
|
||||||
|
/* The default value of x86 CET control. */
|
||||||
|
#define DEFAULT_DL_X86_CET_CONTROL cet_elf_property
|
||||||
|
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/i386/configure b/sysdeps/unix/sysv/linux/i386/configure
|
||||||
|
index 0327590486c80777..f119e62fc31903b3 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/i386/configure
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/i386/configure
|
||||||
|
@@ -1,44 +1,5 @@
|
||||||
|
# This file is generated from configure.ac by Autoconf. DO NOT EDIT!
|
||||||
|
# Local configure fragment for sysdeps/unix/sysv/linux/i386.
|
||||||
|
|
||||||
|
-# Check if CFLAGS allows compiler to use ebp register in inline assembly.
|
||||||
|
-
|
||||||
|
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler flags allows ebp in inline assembly" >&5
|
||||||
|
-$as_echo_n "checking if compiler flags allows ebp in inline assembly... " >&6; }
|
||||||
|
-if ${libc_cv_can_use_register_asm_ebp+:} false; then :
|
||||||
|
- $as_echo_n "(cached) " >&6
|
||||||
|
-else
|
||||||
|
-
|
||||||
|
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||||
|
-/* end confdefs.h. */
|
||||||
|
-
|
||||||
|
- void foo (int i)
|
||||||
|
- {
|
||||||
|
- register int reg asm ("ebp") = i;
|
||||||
|
- asm ("# %0" : : "r" (reg));
|
||||||
|
- }
|
||||||
|
-int
|
||||||
|
-main ()
|
||||||
|
-{
|
||||||
|
-
|
||||||
|
- ;
|
||||||
|
- return 0;
|
||||||
|
-}
|
||||||
|
-_ACEOF
|
||||||
|
-if ac_fn_c_try_compile "$LINENO"; then :
|
||||||
|
- libc_cv_can_use_register_asm_ebp=yes
|
||||||
|
-else
|
||||||
|
- libc_cv_can_use_register_asm_ebp=no
|
||||||
|
-fi
|
||||||
|
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||||
|
-
|
||||||
|
-fi
|
||||||
|
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_can_use_register_asm_ebp" >&5
|
||||||
|
-$as_echo "$libc_cv_can_use_register_asm_ebp" >&6; }
|
||||||
|
-if test $libc_cv_can_use_register_asm_ebp = yes; then
|
||||||
|
- $as_echo "#define CAN_USE_REGISTER_ASM_EBP 1" >>confdefs.h
|
||||||
|
-
|
||||||
|
-fi
|
||||||
|
-
|
||||||
|
libc_cv_gcc_unwind_find_fde=yes
|
||||||
|
ldd_rewrite_script=sysdeps/unix/sysv/linux/ldd-rewrite.sed
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/i386/configure.ac b/sysdeps/unix/sysv/linux/i386/configure.ac
|
||||||
|
index 9e980784bb826463..64ab2cc2c8f9deec 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/i386/configure.ac
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/i386/configure.ac
|
||||||
|
@@ -1,22 +1,5 @@
|
||||||
|
GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
|
||||||
|
# Local configure fragment for sysdeps/unix/sysv/linux/i386.
|
||||||
|
|
||||||
|
-# Check if CFLAGS allows compiler to use ebp register in inline assembly.
|
||||||
|
-AC_CACHE_CHECK([if compiler flags allows ebp in inline assembly],
|
||||||
|
- libc_cv_can_use_register_asm_ebp, [
|
||||||
|
-AC_COMPILE_IFELSE(
|
||||||
|
- [AC_LANG_PROGRAM([
|
||||||
|
- void foo (int i)
|
||||||
|
- {
|
||||||
|
- register int reg asm ("ebp") = i;
|
||||||
|
- asm ("# %0" : : "r" (reg));
|
||||||
|
- }])],
|
||||||
|
- [libc_cv_can_use_register_asm_ebp=yes],
|
||||||
|
- [libc_cv_can_use_register_asm_ebp=no])
|
||||||
|
-])
|
||||||
|
-if test $libc_cv_can_use_register_asm_ebp = yes; then
|
||||||
|
- AC_DEFINE(CAN_USE_REGISTER_ASM_EBP)
|
||||||
|
-fi
|
||||||
|
-
|
||||||
|
libc_cv_gcc_unwind_find_fde=yes
|
||||||
|
ldd_rewrite_script=sysdeps/unix/sysv/linux/ldd-rewrite.sed
|
||||||
|
diff --git a/sysdeps/unix/sysv/linux/i386/sysdep.h b/sysdeps/unix/sysv/linux/i386/sysdep.h
|
||||||
|
index 8a9911b7acd9e692..39d6a3c13427abb5 100644
|
||||||
|
--- a/sysdeps/unix/sysv/linux/i386/sysdep.h
|
||||||
|
+++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
|
||||||
|
@@ -43,15 +43,6 @@
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-/* Since GCC 5 and above can properly spill %ebx with PIC when needed,
|
||||||
|
- we can inline syscalls with 6 arguments if GCC 5 or above is used
|
||||||
|
- to compile glibc. Disable GCC 5 optimization when compiling for
|
||||||
|
- profiling or when -fno-omit-frame-pointer is used since asm ("ebp")
|
||||||
|
- can't be used to put the 6th argument in %ebp for syscall. */
|
||||||
|
-#if !defined PROF && CAN_USE_REGISTER_ASM_EBP
|
||||||
|
-# define OPTIMIZE_FOR_GCC_5
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
#ifdef __ASSEMBLER__
|
||||||
|
|
||||||
|
/* Linux uses a negative return value to indicate syscall errors,
|
||||||
|
@@ -239,36 +230,6 @@
|
||||||
|
extern int __syscall_error (int)
|
||||||
|
attribute_hidden __attribute__ ((__regparm__ (1)));
|
||||||
|
|
||||||
|
-#ifndef OPTIMIZE_FOR_GCC_5
|
||||||
|
-/* We need some help from the assembler to generate optimal code. We
|
||||||
|
- define some macros here which later will be used. */
|
||||||
|
-asm (".L__X'%ebx = 1\n\t"
|
||||||
|
- ".L__X'%ecx = 2\n\t"
|
||||||
|
- ".L__X'%edx = 2\n\t"
|
||||||
|
- ".L__X'%eax = 3\n\t"
|
||||||
|
- ".L__X'%esi = 3\n\t"
|
||||||
|
- ".L__X'%edi = 3\n\t"
|
||||||
|
- ".L__X'%ebp = 3\n\t"
|
||||||
|
- ".L__X'%esp = 3\n\t"
|
||||||
|
- ".macro bpushl name reg\n\t"
|
||||||
|
- ".if 1 - \\name\n\t"
|
||||||
|
- ".if 2 - \\name\n\t"
|
||||||
|
- "error\n\t"
|
||||||
|
- ".else\n\t"
|
||||||
|
- "xchgl \\reg, %ebx\n\t"
|
||||||
|
- ".endif\n\t"
|
||||||
|
- ".endif\n\t"
|
||||||
|
- ".endm\n\t"
|
||||||
|
- ".macro bpopl name reg\n\t"
|
||||||
|
- ".if 1 - \\name\n\t"
|
||||||
|
- ".if 2 - \\name\n\t"
|
||||||
|
- "error\n\t"
|
||||||
|
- ".else\n\t"
|
||||||
|
- "xchgl \\reg, %ebx\n\t"
|
||||||
|
- ".endif\n\t"
|
||||||
|
- ".endif\n\t"
|
||||||
|
- ".endm\n\t");
|
||||||
|
-
|
||||||
|
/* Six-argument syscalls use an out-of-line helper, because an inline
|
||||||
|
asm using all registers apart from %esp cannot work reliably and
|
||||||
|
the assembler does not support describing an asm that saves and
|
||||||
|
@@ -279,7 +240,6 @@ struct libc_do_syscall_args
|
||||||
|
{
|
||||||
|
int ebx, edi, ebp;
|
||||||
|
};
|
||||||
|
-#endif
|
||||||
|
|
||||||
|
# define VDSO_NAME "LINUX_2.6"
|
||||||
|
# define VDSO_HASH 61765110
|
||||||
|
@@ -332,14 +292,8 @@ struct libc_do_syscall_args
|
||||||
|
|
||||||
|
/* Each object using 6-argument inline syscalls must include a
|
||||||
|
definition of __libc_do_syscall. */
|
||||||
|
-#ifdef OPTIMIZE_FOR_GCC_5
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_6(name, args...) \
|
||||||
|
- INTERNAL_SYSCALL_MAIN_INLINE(name, 6, args)
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS_6(name, args...) \
|
||||||
|
- INTERNAL_SYSCALL_MAIN_NCS(name, 6, args)
|
||||||
|
-#else /* GCC 5 */
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_6(name, arg1, arg2, arg3, \
|
||||||
|
- arg4, arg5, arg6) \
|
||||||
|
+#define INTERNAL_SYSCALL_MAIN_6(name, arg1, arg2, arg3, \
|
||||||
|
+ arg4, arg5, arg6) \
|
||||||
|
struct libc_do_syscall_args _xv = \
|
||||||
|
{ \
|
||||||
|
(int) (arg1), \
|
||||||
|
@@ -352,8 +306,8 @@ struct libc_do_syscall_args
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "i" (__NR_##name), "c" (arg2), "d" (arg3), "S" (arg4), "D" (&_xv) \
|
||||||
|
: "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS_6(name, arg1, arg2, arg3, \
|
||||||
|
- arg4, arg5, arg6) \
|
||||||
|
+#define INTERNAL_SYSCALL_MAIN_NCS_6(name, arg1, arg2, arg3, \
|
||||||
|
+ arg4, arg5, arg6) \
|
||||||
|
struct libc_do_syscall_args _xv = \
|
||||||
|
{ \
|
||||||
|
(int) (arg1), \
|
||||||
|
@@ -366,7 +320,6 @@ struct libc_do_syscall_args
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (name), "c" (arg2), "d" (arg3), "S" (arg4), "D" (&_xv) \
|
||||||
|
: "memory", "cc")
|
||||||
|
-#endif /* GCC 5 */
|
||||||
|
|
||||||
|
#define INTERNAL_SYSCALL(name, nr, args...) \
|
||||||
|
({ \
|
||||||
|
@@ -380,193 +333,72 @@ struct libc_do_syscall_args
|
||||||
|
(int) resultvar; })
|
||||||
|
|
||||||
|
#if I386_USE_SYSENTER
|
||||||
|
-# ifdef OPTIMIZE_FOR_GCC_5
|
||||||
|
-# ifdef PIC
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
+# ifdef PIC
|
||||||
|
+# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
LOADREGS_##nr(args) \
|
||||||
|
asm volatile ( \
|
||||||
|
"call *%%gs:%P2" \
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (__NR_##name), "i" (offsetof (tcbhead_t, sysinfo)) \
|
||||||
|
ASMARGS_##nr(args) : "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
+# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
LOADREGS_##nr(args) \
|
||||||
|
asm volatile ( \
|
||||||
|
"call *%%gs:%P2" \
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (name), "i" (offsetof (tcbhead_t, sysinfo)) \
|
||||||
|
ASMARGS_##nr(args) : "memory", "cc")
|
||||||
|
-# else
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
+# else /* I386_USE_SYSENTER && !PIC */
|
||||||
|
+# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
LOADREGS_##nr(args) \
|
||||||
|
asm volatile ( \
|
||||||
|
"call *_dl_sysinfo" \
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (__NR_##name) ASMARGS_##nr(args) : "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
+# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
LOADREGS_##nr(args) \
|
||||||
|
asm volatile ( \
|
||||||
|
"call *_dl_sysinfo" \
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (name) ASMARGS_##nr(args) : "memory", "cc")
|
||||||
|
-# endif
|
||||||
|
-# else /* GCC 5 */
|
||||||
|
-# ifdef PIC
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
- EXTRAVAR_##nr \
|
||||||
|
- asm volatile ( \
|
||||||
|
- LOADARGS_##nr \
|
||||||
|
- "movl %1, %%eax\n\t" \
|
||||||
|
- "call *%%gs:%P2\n\t" \
|
||||||
|
- RESTOREARGS_##nr \
|
||||||
|
- : "=a" (resultvar) \
|
||||||
|
- : "i" (__NR_##name), "i" (offsetof (tcbhead_t, sysinfo)) \
|
||||||
|
- ASMFMT_##nr(args) : "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
- EXTRAVAR_##nr \
|
||||||
|
- asm volatile ( \
|
||||||
|
- LOADARGS_##nr \
|
||||||
|
- "call *%%gs:%P2\n\t" \
|
||||||
|
- RESTOREARGS_##nr \
|
||||||
|
- : "=a" (resultvar) \
|
||||||
|
- : "0" (name), "i" (offsetof (tcbhead_t, sysinfo)) \
|
||||||
|
- ASMFMT_##nr(args) : "memory", "cc")
|
||||||
|
-# else
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
- EXTRAVAR_##nr \
|
||||||
|
- asm volatile ( \
|
||||||
|
- LOADARGS_##nr \
|
||||||
|
- "movl %1, %%eax\n\t" \
|
||||||
|
- "call *_dl_sysinfo\n\t" \
|
||||||
|
- RESTOREARGS_##nr \
|
||||||
|
- : "=a" (resultvar) \
|
||||||
|
- : "i" (__NR_##name) ASMFMT_##nr(args) : "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
- EXTRAVAR_##nr \
|
||||||
|
- asm volatile ( \
|
||||||
|
- LOADARGS_##nr \
|
||||||
|
- "call *_dl_sysinfo\n\t" \
|
||||||
|
- RESTOREARGS_##nr \
|
||||||
|
- : "=a" (resultvar) \
|
||||||
|
- : "0" (name) ASMFMT_##nr(args) : "memory", "cc")
|
||||||
|
-# endif
|
||||||
|
-# endif /* GCC 5 */
|
||||||
|
-#else
|
||||||
|
-# ifdef OPTIMIZE_FOR_GCC_5
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
+# endif /* I386_USE_SYSENTER && !PIC */
|
||||||
|
+#else /* !I386_USE_SYSENTER */
|
||||||
|
+# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
LOADREGS_##nr(args) \
|
||||||
|
asm volatile ( \
|
||||||
|
"int $0x80" \
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (__NR_##name) ASMARGS_##nr(args) : "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
+# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
LOADREGS_##nr(args) \
|
||||||
|
asm volatile ( \
|
||||||
|
"int $0x80" \
|
||||||
|
: "=a" (resultvar) \
|
||||||
|
: "a" (name) ASMARGS_##nr(args) : "memory", "cc")
|
||||||
|
-# else /* GCC 5 */
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_INLINE(name, nr, args...) \
|
||||||
|
- EXTRAVAR_##nr \
|
||||||
|
- asm volatile ( \
|
||||||
|
- LOADARGS_##nr \
|
||||||
|
- "movl %1, %%eax\n\t" \
|
||||||
|
- "int $0x80\n\t" \
|
||||||
|
- RESTOREARGS_##nr \
|
||||||
|
- : "=a" (resultvar) \
|
||||||
|
- : "i" (__NR_##name) ASMFMT_##nr(args) : "memory", "cc")
|
||||||
|
-# define INTERNAL_SYSCALL_MAIN_NCS(name, nr, args...) \
|
||||||
|
- EXTRAVAR_##nr \
|
||||||
|
- asm volatile ( \
|
||||||
|
- LOADARGS_##nr \
|
||||||
|
- "int $0x80\n\t" \
|
||||||
|
- RESTOREARGS_##nr \
|
||||||
|
- : "=a" (resultvar) \
|
||||||
|
- : "0" (name) ASMFMT_##nr(args) : "memory", "cc")
|
||||||
|
-# endif /* GCC 5 */
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
-#define LOADARGS_0
|
||||||
|
-#ifdef __PIC__
|
||||||
|
-# if I386_USE_SYSENTER && defined PIC
|
||||||
|
-# define LOADARGS_1 \
|
||||||
|
- "bpushl .L__X'%k3, %k3\n\t"
|
||||||
|
-# define LOADARGS_5 \
|
||||||
|
- "movl %%ebx, %4\n\t" \
|
||||||
|
- "movl %3, %%ebx\n\t"
|
||||||
|
-# else
|
||||||
|
-# define LOADARGS_1 \
|
||||||
|
- "bpushl .L__X'%k2, %k2\n\t"
|
||||||
|
-# define LOADARGS_5 \
|
||||||
|
- "movl %%ebx, %3\n\t" \
|
||||||
|
- "movl %2, %%ebx\n\t"
|
||||||
|
-# endif
|
||||||
|
-# define LOADARGS_2 LOADARGS_1
|
||||||
|
-# define LOADARGS_3 \
|
||||||
|
- "xchgl %%ebx, %%edi\n\t"
|
||||||
|
-# define LOADARGS_4 LOADARGS_3
|
||||||
|
-#else
|
||||||
|
-# define LOADARGS_1
|
||||||
|
-# define LOADARGS_2
|
||||||
|
-# define LOADARGS_3
|
||||||
|
-# define LOADARGS_4
|
||||||
|
-# define LOADARGS_5
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
-#define RESTOREARGS_0
|
||||||
|
-#ifdef __PIC__
|
||||||
|
-# if I386_USE_SYSENTER && defined PIC
|
||||||
|
-# define RESTOREARGS_1 \
|
||||||
|
- "bpopl .L__X'%k3, %k3\n\t"
|
||||||
|
-# define RESTOREARGS_5 \
|
||||||
|
- "movl %4, %%ebx"
|
||||||
|
-# else
|
||||||
|
-# define RESTOREARGS_1 \
|
||||||
|
- "bpopl .L__X'%k2, %k2\n\t"
|
||||||
|
-# define RESTOREARGS_5 \
|
||||||
|
- "movl %3, %%ebx"
|
||||||
|
-# endif
|
||||||
|
-# define RESTOREARGS_2 RESTOREARGS_1
|
||||||
|
-# define RESTOREARGS_3 \
|
||||||
|
- "xchgl %%edi, %%ebx\n\t"
|
||||||
|
-# define RESTOREARGS_4 RESTOREARGS_3
|
||||||
|
-#else
|
||||||
|
-# define RESTOREARGS_1
|
||||||
|
-# define RESTOREARGS_2
|
||||||
|
-# define RESTOREARGS_3
|
||||||
|
-# define RESTOREARGS_4
|
||||||
|
-# define RESTOREARGS_5
|
||||||
|
-#endif
|
||||||
|
+#endif /* !I386_USE_SYSENTER */
|
||||||
|
|
||||||
|
-#ifdef OPTIMIZE_FOR_GCC_5
|
||||||
|
-# define LOADREGS_0()
|
||||||
|
-# define ASMARGS_0()
|
||||||
|
-# define LOADREGS_1(arg1) \
|
||||||
|
+#define LOADREGS_0()
|
||||||
|
+#define ASMARGS_0()
|
||||||
|
+#define LOADREGS_1(arg1) \
|
||||||
|
LOADREGS_0 ()
|
||||||
|
-# define ASMARGS_1(arg1) \
|
||||||
|
+#define ASMARGS_1(arg1) \
|
||||||
|
ASMARGS_0 (), "b" ((unsigned int) (arg1))
|
||||||
|
-# define LOADREGS_2(arg1, arg2) \
|
||||||
|
+#define LOADREGS_2(arg1, arg2) \
|
||||||
|
LOADREGS_1 (arg1)
|
||||||
|
-# define ASMARGS_2(arg1, arg2) \
|
||||||
|
+#define ASMARGS_2(arg1, arg2) \
|
||||||
|
ASMARGS_1 (arg1), "c" ((unsigned int) (arg2))
|
||||||
|
-# define LOADREGS_3(arg1, arg2, arg3) \
|
||||||
|
+#define LOADREGS_3(arg1, arg2, arg3) \
|
||||||
|
LOADREGS_2 (arg1, arg2)
|
||||||
|
-# define ASMARGS_3(arg1, arg2, arg3) \
|
||||||
|
+#define ASMARGS_3(arg1, arg2, arg3) \
|
||||||
|
ASMARGS_2 (arg1, arg2), "d" ((unsigned int) (arg3))
|
||||||
|
-# define LOADREGS_4(arg1, arg2, arg3, arg4) \
|
||||||
|
+#define LOADREGS_4(arg1, arg2, arg3, arg4) \
|
||||||
|
LOADREGS_3 (arg1, arg2, arg3)
|
||||||
|
-# define ASMARGS_4(arg1, arg2, arg3, arg4) \
|
||||||
|
+#define ASMARGS_4(arg1, arg2, arg3, arg4) \
|
||||||
|
ASMARGS_3 (arg1, arg2, arg3), "S" ((unsigned int) (arg4))
|
||||||
|
-# define LOADREGS_5(arg1, arg2, arg3, arg4, arg5) \
|
||||||
|
+#define LOADREGS_5(arg1, arg2, arg3, arg4, arg5) \
|
||||||
|
LOADREGS_4 (arg1, arg2, arg3, arg4)
|
||||||
|
-# define ASMARGS_5(arg1, arg2, arg3, arg4, arg5) \
|
||||||
|
+#define ASMARGS_5(arg1, arg2, arg3, arg4, arg5) \
|
||||||
|
ASMARGS_4 (arg1, arg2, arg3, arg4), "D" ((unsigned int) (arg5))
|
||||||
|
-# define LOADREGS_6(arg1, arg2, arg3, arg4, arg5, arg6) \
|
||||||
|
- register unsigned int _a6 asm ("ebp") = (unsigned int) (arg6); \
|
||||||
|
- LOADREGS_5 (arg1, arg2, arg3, arg4, arg5)
|
||||||
|
-# define ASMARGS_6(arg1, arg2, arg3, arg4, arg5, arg6) \
|
||||||
|
- ASMARGS_5 (arg1, arg2, arg3, arg4, arg5), "r" (_a6)
|
||||||
|
-#endif /* GCC 5 */
|
||||||
|
|
||||||
|
#define ASMFMT_0()
|
||||||
|
#ifdef __PIC__
|
46
glibc.spec
46
glibc.spec
@ -148,7 +148,7 @@ end \
|
|||||||
Summary: The GNU libc libraries
|
Summary: The GNU libc libraries
|
||||||
Name: glibc
|
Name: glibc
|
||||||
Version: %{glibcversion}
|
Version: %{glibcversion}
|
||||||
Release: 16%{?dist}
|
Release: 17%{?dist}
|
||||||
|
|
||||||
# In general, GPLv2+ is used by programs, LGPLv2+ is used for
|
# In general, GPLv2+ is used by programs, LGPLv2+ is used for
|
||||||
# libraries.
|
# libraries.
|
||||||
@ -287,6 +287,26 @@ Patch87: glibc-upstream-2.34-51.patch
|
|||||||
Patch88: glibc-upstream-2.34-52.patch
|
Patch88: glibc-upstream-2.34-52.patch
|
||||||
Patch89: glibc-upstream-2.34-53.patch
|
Patch89: glibc-upstream-2.34-53.patch
|
||||||
Patch90: glibc-rh1988382.patch
|
Patch90: glibc-rh1988382.patch
|
||||||
|
Patch91: glibc-upstream-2.34-54.patch
|
||||||
|
Patch92: glibc-upstream-2.34-55.patch
|
||||||
|
Patch93: glibc-upstream-2.34-56.patch
|
||||||
|
Patch94: glibc-upstream-2.34-57.patch
|
||||||
|
Patch95: glibc-upstream-2.34-58.patch
|
||||||
|
Patch96: glibc-upstream-2.34-59.patch
|
||||||
|
Patch97: glibc-upstream-2.34-60.patch
|
||||||
|
Patch98: glibc-upstream-2.34-61.patch
|
||||||
|
Patch99: glibc-upstream-2.34-62.patch
|
||||||
|
Patch100: glibc-upstream-2.34-63.patch
|
||||||
|
Patch101: glibc-upstream-2.34-64.patch
|
||||||
|
Patch102: glibc-upstream-2.34-65.patch
|
||||||
|
Patch103: glibc-upstream-2.34-66.patch
|
||||||
|
Patch104: glibc-upstream-2.34-67.patch
|
||||||
|
Patch105: glibc-upstream-2.34-68.patch
|
||||||
|
Patch106: glibc-upstream-2.34-69.patch
|
||||||
|
Patch107: glibc-upstream-2.34-70.patch
|
||||||
|
Patch108: glibc-upstream-2.34-71.patch
|
||||||
|
Patch109: glibc-upstream-2.34-72.patch
|
||||||
|
Patch110: glibc-upstream-2.34-73.patch
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
# Continued list of core "glibc" package information:
|
# Continued list of core "glibc" package information:
|
||||||
@ -2315,6 +2335,30 @@ fi
|
|||||||
%files -f compat-libpthread-nonshared.filelist -n compat-libpthread-nonshared
|
%files -f compat-libpthread-nonshared.filelist -n compat-libpthread-nonshared
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jan 13 2022 Florian Weimer <fweimer@redhat.com> - 2.34-17
|
||||||
|
- Sync with upstream branch release/2.34/master,
|
||||||
|
commit 2fe2af88abd13ae5636881da2e26f461ecb7dfb5
|
||||||
|
- i386: Remove broken CAN_USE_REGISTER_ASM_EBP (bug 28771)
|
||||||
|
- Update syscall lists for Linux 5.15
|
||||||
|
- powerpc: Fix unrecognized instruction errors with recent GCC
|
||||||
|
- timezone: test-case for BZ #28707
|
||||||
|
- timezone: handle truncated timezones from tzcode-2021d and later (BZ #28707)
|
||||||
|
- Fix subscript error with odd TZif file [BZ #28338]
|
||||||
|
- AArch64: Check for SVE in ifuncs [BZ #28744]
|
||||||
|
- intl/plural.y: Avoid conflicting declarations of yyerror and yylex
|
||||||
|
- Linux: Fix 32-bit vDSO for clock_gettime on powerpc32
|
||||||
|
- linux: Add sparck brk implementation
|
||||||
|
- Update sparc libm-test-ulps
|
||||||
|
- Update hppa libm-test-ulps
|
||||||
|
- riscv: align stack before calling _dl_init [BZ #28703]
|
||||||
|
- riscv: align stack in clone [BZ #28702]
|
||||||
|
- powerpc64[le]: Allocate extra stack frame on syscall.S
|
||||||
|
- elf: Fix tst-cpu-features-cpuinfo for KVM guests on some AMD systems [BZ #28704]
|
||||||
|
- nss: Use "files dns" as the default for the hosts database (bug 28700)
|
||||||
|
- arm: Guard ucontext _rtld_global_ro access by SHARED, not PIC macro
|
||||||
|
- mips: increase stack alignment in clone to match the ABI
|
||||||
|
- mips: align stack in clone [BZ #28223]
|
||||||
|
|
||||||
* Tue Dec 14 2021 Siddhesh Poyarekar <siddhesh@redhat.com> - 2.34-16
|
* Tue Dec 14 2021 Siddhesh Poyarekar <siddhesh@redhat.com> - 2.34-16
|
||||||
- Enable PIE by default on all architectures (#1988382)
|
- Enable PIE by default on all architectures (#1988382)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user