glibc/sysdeps
Szabolcs Nagy 3ac237fb71 aarch64: Add GCS support for makecontext
Changed the makecontext logic: previously the first setcontext jumped
straight to the user callback function and the return address is set
to __startcontext. This does not work when GCS is enabled as the
integrity of the return address is protected, so instead the context
is setup such that setcontext jumps to __startcontext which calls the
user callback (passed in x20).

The map_shadow_stack syscall is used to allocate a suitably sized GCS
(which includes some reserved area to account for altstack signal
handlers and otherwise supports maximum number of 16 byte aligned
stack frames on the given stack) however the GCS is never freed as
the lifetime of ucontext and related stack is user managed.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2025-01-20 09:22:41 +00:00
..
aarch64 aarch64: Mark swapcontext with indirect_return 2025-01-20 09:22:41 +00:00
alpha math: update alpha ulps 2025-01-05 20:02:53 +01:00
arc arc: Update libm test ulps 2025-01-15 11:41:30 +00:00
arm math: update arm ulps 2025-01-17 19:36:22 +00:00
csky Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
generic Add generic 'extra TLS' 2025-01-10 20:19:28 +00:00
gnu Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
hppa Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
htl htl: move pthread_mutexattr_setprioceiling, pthread_mutexattr_getprioceiling into libc. 2025-01-02 01:20:21 +01:00
hurd Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
i386 nptl: Introduce <rseq-access.h> for RSEQ_* accessors 2025-01-10 20:20:17 +00:00
ieee754 math: Fix acosf when building with gcc <= 11 2025-01-09 12:53:58 -03:00
loongarch Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
m68k Add missing include guards to <dl-tls.h> 2025-01-10 19:02:47 +01:00
mach hurd: Fix EINVAL error on linking to a slash-trailing path [BZ #32569] 2025-01-19 15:11:44 +01:00
microblaze Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
mips Add missing include guards to <dl-tls.h> 2025-01-10 19:02:47 +01:00
nptl nptl: Remove g_refs from condition variables 2025-01-17 14:56:58 -05:00
or1k Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
posix Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
powerpc Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
pthread Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
riscv Add missing include guards to <dl-tls.h> 2025-01-10 19:02:47 +01:00
s390 Add missing include guards to <dl-tls.h> 2025-01-10 19:02:47 +01:00
sh elf: Introduce generic <dl-tls.h> 2025-01-02 13:45:27 +01:00
sparc Move <thread_pointer.h> to kernel-independent sysdeps directories 2025-01-09 19:30:16 +01:00
unix aarch64: Add GCS support for makecontext 2025-01-20 09:22:41 +00:00
wordsize-32 Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
wordsize-64 Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
x86 x86: Add missing #include <features.h> to <thread_pointer.h> 2025-01-09 19:30:41 +01:00
x86_64 x86-64: Cast __rseq_offset to long long int [BZ #32543] 2025-01-12 07:08:27 +08:00