1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-28 00:21:52 +03:00

x86: Move CET control to _dl_x86_feature_control [BZ #25887]

1. Include <dl-procruntime.c> to get architecture specific initializer in
rtld_global.
2. Change _dl_x86_feature_1[2] to _dl_x86_feature_1.
3. Add _dl_x86_feature_control after _dl_x86_feature_1, which is a
struct of 2 bitfields for IBT and SHSTK control

This fixes [BZ #25887].
This commit is contained in:
H.J. Lu
2020-04-28 10:05:25 -07:00
parent cbfc16122e
commit 674ea88294
9 changed files with 81 additions and 68 deletions

View File

@ -34,7 +34,7 @@ static inline void
x86_setup_tls (void)
{
__libc_setup_tls ();
THREAD_SETMEM (THREAD_SELF, header.feature_1, GL(dl_x86_feature_1)[0]);
THREAD_SETMEM (THREAD_SELF, header.feature_1, GL(dl_x86_feature_1));
}
# define ARCH_SETUP_TLS() x86_setup_tls ()