Fix broken cpu speed on NetBSD

This commit is contained in:
Dylan 2016-04-04 22:20:15 +10:00
parent b07d18d6d0
commit 8d67097a32

View file

@ -977,11 +977,7 @@ getcpu () {
speed=$((speed / 100000))
else
speed=$(awk -F ': |\\.' '/cpu MHz/ {printf $2; exit}' /proc/cpuinfo)
case "$distro" in
"NetBSD"*) speed=$((speed / 10000)) ;;
*) speed=$((speed / 100)) ;;
esac
speed=$((speed / 100))
fi
cores=$(awk -F ': ' '/siblings/ {printf $2; exit}' /proc/cpuinfo)