]> git.ipfire.org Git - thirdparty/glibc.git/commit
aarch64: Add GCS support for setcontext
authorSzabolcs Nagy <szabolcs.nagy@arm.com>
Fri, 24 Feb 2023 16:29:32 +0000 (16:29 +0000)
committerYury Khrustalev <yury.khrustalev@arm.com>
Mon, 20 Jan 2025 09:22:41 +0000 (09:22 +0000)
commit9885d13b669591574829125f13b1078bb12399fc
tree05d3264b76e753b982e494b913ac4527556d15e6
parent1cf59c2603be88e3c97e68b1f219647f20310215
aarch64: Add GCS support for setcontext

Userspace ucontext needs to store GCSPR, it does not have to be
compatible with the kernel ucontext. For now we use the linux
struct gcs_context layout but only use the gcspr field from it.

Similar implementation to the longjmp code, supports switching GCS
if the target GCS is capped, and unwinding a continuous GCS to a
previous state.

Reviewed-by: Wilco Dijkstra <Wilco.Dijkstra@arm.com>
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
sysdeps/unix/sysv/linux/aarch64/getcontext.S
sysdeps/unix/sysv/linux/aarch64/setcontext.S
sysdeps/unix/sysv/linux/aarch64/swapcontext.S
sysdeps/unix/sysv/linux/aarch64/ucontext-internal.h