diff options
| author | Kees Cook <[email protected]> | 2020-06-09 03:15:09 +0000 |
|---|---|---|
| committer | Thomas Gleixner <[email protected]> | 2020-06-18 09:41:32 +0000 |
| commit | a13b9d0b97211579ea63b96c606de79b963c0f47 (patch) | |
| tree | 6cc00b548d67524d637c808aeb2d74fea61d8f4c /scripts/gcc-plugins/sancov_plugin.c | |
| parent | x86/resctrl: Fix a NULL vs IS_ERR() static checker warning in rdt_cdp_peer_get() (diff) | |
| download | kernel-a13b9d0b97211579ea63b96c606de79b963c0f47.tar.gz kernel-a13b9d0b97211579ea63b96c606de79b963c0f47.zip | |
x86/cpu: Use pinning mask for CR4 bits needing to be 0
The X86_CR4_FSGSBASE bit of CR4 should not change after boot[1]. Older
kernels should enforce this bit to zero, and newer kernels need to
enforce it depending on boot-time configuration (e.g. "nofsgsbase").
To support a pinned bit being either 1 or 0, use an explicit mask in
combination with the expected pinned bit values.
[1] https://lore.kernel.org/lkml/[email protected]
Signed-off-by: Kees Cook <[email protected]>
Signed-off-by: Thomas Gleixner <[email protected]>
Cc: [email protected]
Link: https://lkml.kernel.org/r/202006082013.71E29A42@keescook
Diffstat (limited to 'scripts/gcc-plugins/sancov_plugin.c')
0 files changed, 0 insertions, 0 deletions
