CPU: Fix incorrect CPU speeds
This commit is contained in:
parent
18cfafa998
commit
dfc64f6b19
2 changed files with 4 additions and 8 deletions
6
neofetch
6
neofetch
|
@ -725,14 +725,12 @@ get_cpu() {
|
|||
"min") speed_type="scaling_min_freq" ;;
|
||||
"max") speed_type="scaling_max_freq" ;;
|
||||
"bios") speed_type="bios_limit" ;;
|
||||
"scaling_current") speed_type="scaling_cur_freq" ;;
|
||||
"scaling_min") speed_type="scaling_min_freq" ;;
|
||||
"scaling_max") speed_type="scaling_max_freq" ;;
|
||||
esac
|
||||
|
||||
# Fallback to cpuinfo_max_freq if $speed_type fails
|
||||
speed="$(< "${speed_dir}/${speed_type}")" || \
|
||||
speed="$(< "${speed_dir}/cpuinfo_max_freq")"
|
||||
speed="$(< "${speed_dir}/bios_limit")" || \
|
||||
speed="$(< "${speed_dir}/scaling_max_freq")"
|
||||
|
||||
speed="$((speed / 100000))"
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue