glibc/sysdeps/unix/sysv/linux/x86
H.J. Lu 743113d42e x86: Set FSGSBASE to active if enabled by kernel
Linux kernel uses AT_HWCAP2 to indicate if FSGSBASE instructions are
enabled.  If the HWCAP2_FSGSBASE bit in AT_HWCAP2 is set, FSGSBASE
instructions can be used in user space.  Define dl_check_hwcap2 to set
the FSGSBASE feature to active on Linux when the HWCAP2_FSGSBASE bit is
set.

Add a test to verify that FSGSBASE is active on current kernels.
NB: This test will fail if the kernel doesn't set the HWCAP2_FSGSBASE
bit in AT_HWCAP2 while fsgsbase shows up in /proc/cpuinfo.
Reviewed-by: Florian Weimer <fweimer@redhat.com>
2023-04-03 11:36:48 -07:00
..
bits
include
sys
Implies
Makefile
arch-pkey.h
cpu-features.c
dl-cet.h
dl-hwcap2.h x86: Set FSGSBASE to active if enabled by kernel 2023-04-03 11:36:48 -07:00
dl-minsigstacksize.h
dl-sysdep.c
elf-read-prop.h
elision-conf.c
elision-conf.h
elision-lock.c
elision-timed.c
elision-trylock.c
elision-unlock.c
gettimeofday.c
hle.h
jmp_buf-ssp.sym
longjmp.c
pkey_get.c
pkey_set.c
readelflib.c
setjmpP.h
sysconf.c
time.c
tst-cet-property-1.c
tst-cet-property-2.c
tst-cet-property-dep-2.S
tst-cet-setcontext-1.c
tst-cet-vfork-1.c
tst-saved_mask-1.c
xstatver.h