Fix report CPU_TYPE in hardware.sh for RPIs
Changes: * For CPU_TYPE in hardware.sh, report something if /proc/cpuinfo does not contain processor model information
This commit is contained in:
parent
17d6163514
commit
847f4ab742
5 changed files with 19 additions and 5 deletions
|
@ -17,6 +17,7 @@ if [ "$KERNEL" = "Linux" ] ; then
|
|||
CPU_TYPE=$(awk -F: '/model name/ {print $2; exit}' /proc/cpuinfo 2>>"$TEE_DEST")
|
||||
CPU_CACHE=$(awk -F: '/cache size/ {print $2; exit}' /proc/cpuinfo 2>>"$TEE_DEST")
|
||||
CPU_COUNT=$(grep -c processor /proc/cpuinfo 2>>"$TEE_DEST")
|
||||
[ -z "$CPU_TYPE" ] && [ -r /proc/device-tree/compatible ] && CPU_TYPE=$(cat /proc/device-tree/compatible | tr '\0' ',')
|
||||
# HDs
|
||||
# shellcheck disable=SC2010
|
||||
for deviceBasename in $(ls /sys/block | grep -E -v '^(dm|md|ram|sr|loop)')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue