Update spectre-meltdown-checker.sh
Check after checking ibrs_enabled
This commit is contained in:
parent
9063a7fd20
commit
7ae2dfe35a
|
@ -2121,10 +2121,6 @@ check_variant2_linux()
|
||||||
if [ "$ibpb_enabled" = 2 ]; then
|
if [ "$ibpb_enabled" = 2 ]; then
|
||||||
# if ibpb=2, ibrs is forcefully=0
|
# if ibpb=2, ibrs is forcefully=0
|
||||||
pstatus blue NO "IBPB used instead of IBRS in all kernel entrypoints"
|
pstatus blue NO "IBPB used instead of IBRS in all kernel entrypoints"
|
||||||
else
|
|
||||||
if [ ! "$cpuid_ibrs" = 'SPEC_CTRL' ] && [ ! "cpuid_ibrs" = 'IBRS_SUPPORT' ] && [ ! "cpuid_spec_ctrl" = -1 ]; then
|
|
||||||
pstatus yellow NO;
|
|
||||||
_debug "ibrs: known cpu not supporting SPEC-CTRL or IBRS";
|
|
||||||
else
|
else
|
||||||
# 0 means disabled
|
# 0 means disabled
|
||||||
# 1 is enabled only for kernel space
|
# 1 is enabled only for kernel space
|
||||||
|
@ -2141,10 +2137,12 @@ check_variant2_linux()
|
||||||
1) if [ "$ibrs_fw_enabled" = 1 ]; then pstatus green YES "for kernel space and firmware code"; else pstatus green YES "for kernel space"; fi;;
|
1) if [ "$ibrs_fw_enabled" = 1 ]; then pstatus green YES "for kernel space and firmware code"; else pstatus green YES "for kernel space"; fi;;
|
||||||
2) if [ "$ibrs_fw_enabled" = 1 ]; then pstatus green YES "for kernel, user space, and firmware code" ; else pstatus green YES "for both kernel and user space"; fi;;
|
2) if [ "$ibrs_fw_enabled" = 1 ]; then pstatus green YES "for kernel, user space, and firmware code" ; else pstatus green YES "for both kernel and user space"; fi;;
|
||||||
3) if [ "$ibrs_fw_enabled" = 1 ]; then pstatus green YES "for kernel and firmware code"; else pstatus green YES; fi;;
|
3) if [ "$ibrs_fw_enabled" = 1 ]; then pstatus green YES "for kernel and firmware code"; else pstatus green YES; fi;;
|
||||||
*) pstatus yellow UNKNOWN;;
|
*) if [ ! "$cpuid_ibrs" = 'SPEC_CTRL' ] && [ ! "cpuid_ibrs" = 'IBRS_SUPPORT' ] && [ ! "cpuid_spec_ctrl" = -1 ];
|
||||||
|
then pstatus yellow NO; _debug "ibrs: known cpu not supporting SPEC-CTRL or IBRS";
|
||||||
|
else
|
||||||
|
pstatus yellow UNKNOWN; fi;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
pstatus blue N/A "not testable in offline mode"
|
pstatus blue N/A "not testable in offline mode"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue