enh: when CPUID can't be read, built it by ourselves

This commit is contained in:
Stéphane Lesimple 2023-07-30 11:55:12 +02:00
parent 2a5ddc87bf
commit 9c2587bca5

View File

@ -1866,7 +1866,9 @@ parse_cpu_details()
if read_cpuid 0x1 0x0 $EAX 0 0xFFFFFFFF; then
cpu_cpuid="$read_cpuid_value"
else
cpu_cpuid=0
# try to build it by ourselves
_debug "parse_cpu_details: build the CPUID by ourselves"
cpu_cpuid=$(fms2cpuid "$cpu_family" "$cpu_model" "$cpu_stepping")
fi
# under BSD, linprocfs often doesn't export ucode information, so fetch it ourselves the good old way