mirror of
https://github.com/immortalwrt/immortalwrt.git
synced 2025-08-07 22:06:25 +08:00
autocore: cpuinfo: add support for AMD Zen CPU temperature sensor
This commit is contained in:
@ -41,7 +41,7 @@ case "$DISTRIB_TARGET" in
|
||||
elif grep -q "GenuineIntel" "/proc/cpuinfo"; then
|
||||
cpu_temp="$(sensors "coretemp-*" 2>"/dev/null" | grep -E "(Package id |Core )" | grep -Eo "\+[0-9.]*°C" | head -n1 | tr -d "+")"
|
||||
elif grep -q "AuthenticAMD" "/proc/cpuinfo"; then
|
||||
cpu_temp="$(sensors "k*temp-*" 2>"/dev/null" | awk '/Tdie/ {print $2}' | head -n1 | tr -d "+")"
|
||||
cpu_temp="$(sensors "k10temp-*" 2>"/dev/null" | awk '/Tctl|Tdie/ {print $2}' | head -n1 | tr -d "+")"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
|
Reference in New Issue
Block a user