mirror of
https://github.com/speed47/spectre-meltdown-checker
synced 2024-11-07 14:43:40 +01:00
commit
3568293570
@ -732,8 +732,12 @@ mount_debugfs()
|
|||||||
load_msr()
|
load_msr()
|
||||||
{
|
{
|
||||||
if [ "$os" = Linux ]; then
|
if [ "$os" = Linux ]; then
|
||||||
|
if ! grep -e msr /proc/modules 2>/dev/null; then
|
||||||
modprobe msr 2>/dev/null && insmod_msr=1
|
modprobe msr 2>/dev/null && insmod_msr=1
|
||||||
_debug "attempted to load module msr, insmod_msr=$insmod_msr"
|
_debug "attempted to load module msr, insmod_msr=$insmod_msr"
|
||||||
|
else
|
||||||
|
_debug "msr module already loaded"
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
if ! kldstat -q -m cpuctl; then
|
if ! kldstat -q -m cpuctl; then
|
||||||
kldload cpuctl 2>/dev/null && kldload_cpuctl=1
|
kldload cpuctl 2>/dev/null && kldload_cpuctl=1
|
||||||
@ -747,8 +751,12 @@ load_msr()
|
|||||||
load_cpuid()
|
load_cpuid()
|
||||||
{
|
{
|
||||||
if [ "$os" = Linux ]; then
|
if [ "$os" = Linux ]; then
|
||||||
|
if ! grep -e cpuid /proc/modules 2>/dev/null; then
|
||||||
modprobe cpuid 2>/dev/null && insmod_cpuid=1
|
modprobe cpuid 2>/dev/null && insmod_cpuid=1
|
||||||
_debug "attempted to load module cpuid, insmod_cpuid=$insmod_cpuid"
|
_debug "attempted to load module cpuid, insmod_cpuid=$insmod_cpuid"
|
||||||
|
else
|
||||||
|
_debug "cpuid module already loaded"
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
if ! kldstat -q -m cpuctl; then
|
if ! kldstat -q -m cpuctl; then
|
||||||
kldload cpuctl 2>/dev/null && kldload_cpuctl=1
|
kldload cpuctl 2>/dev/null && kldload_cpuctl=1
|
||||||
|
Loading…
Reference in New Issue
Block a user