1
0
mirror of https://github.com/speed47/spectre-meltdown-checker synced 2024-12-22 20:33:56 +01:00

Merge pull request #11 from sebastianw/kaiser-cpu-flag

Recognize 'kaiser' flag in /proc/cpuinfo
This commit is contained in:
Stéphane Lesimple 2018-01-08 14:45:40 +01:00 committed by GitHub
commit 88df48f4a7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -290,6 +290,10 @@ if grep ^flags /proc/cpuinfo | grep -qw pti; then
# vanilla PTI patch sets the 'pti' flag in cpuinfo
pstatus green YES
kpti_enabled=1
elif grep ^flags /proc/cpuinfo | grep -qw kaiser; then
# kernel line 4.9 sets the 'kaiser' flag in cpuinfo
pstatus green YES
kpti_enabled=1
elif [ -e /sys/kernel/debug/x86/pti_enabled ]; then
# RedHat Backport creates a dedicated file, see https://access.redhat.com/articles/3311301
kpti_enabled=$(cat /sys/kernel/debug/x86/pti_enabled 2>/dev/null)