arm: cosmetic fix for name and handle aarch64

This commit is contained in:
Stéphane Lesimple 2018-01-15 23:45:25 +01:00
parent 72ef94ab3d
commit 193e0d8d08

View File

@ -189,8 +189,10 @@ is_cpu_vulnerable()
# reference: https://developer.arm.com/support/security-update # reference: https://developer.arm.com/support/security-update
cpupart=$(awk '/CPU part/ {print $4;exit}' /proc/cpuinfo) cpupart=$(awk '/CPU part/ {print $4;exit}' /proc/cpuinfo)
cpuarch=$(awk '/CPU architecture/ {print $3;exit}' /proc/cpuinfo) cpuarch=$(awk '/CPU architecture/ {print $3;exit}' /proc/cpuinfo)
# some kernels report AArch64 instead of 8
[ "$cpuarch" = "AArch64" ] && cpuarch=8
if [ -n "$cpupart" -a -n "$cpuarch" ]; then if [ -n "$cpupart" -a -n "$cpuarch" ]; then
cpu_friendly_name="ARM v$cpuarch Part Number $cpupart" cpu_friendly_name="ARM v$cpuarch model $cpupart"
# Cortex-R7 and Cortex-R8 are real-time and only used in medical devices or such # Cortex-R7 and Cortex-R8 are real-time and only used in medical devices or such
# I can't find their CPU part number, but it's probably not that useful anyway # I can't find their CPU part number, but it's probably not that useful anyway
# model R7 R8 A9 A15 A17 A57 A72 A73 A75 # model R7 R8 A9 A15 A17 A57 A72 A73 A75