How do you check if processor.max_cstate is set correctly using terminal/tilix?

I have a ryzen cpu and my cpu has been freezing/crashing a lot over the years and I couldnt' find a solution until recently and I'm told setting the max_cstate should solve my issue.

But how do I check if I set processor.max_cstate correctly from the terminal/tilix?

Current cpu: AMD Ryzen 3 1200 Quad-Core Processor

OS: Ubuntu Desktop 20.04

7

1 Answer

You can check the number of idle states your system currently supports by examination. Example 1 (limitation in place):

~$ grep . /sys/devices/system/cpu/cpu0/cpuidle/state*/name
/sys/devices/system/cpu/cpu0/cpuidle/state0/name:POLL
/sys/devices/system/cpu/cpu0/cpuidle/state1/name:C1

Example 2 (same computer, no limitation):

$ grep . /sys/devices/system/cpu/cpu0/cpuidle/state*/name
/sys/devices/system/cpu/cpu0/cpuidle/state0/name:POLL
/sys/devices/system/cpu/cpu0/cpuidle/state1/name:C1
/sys/devices/system/cpu/cpu0/cpuidle/state2/name:C1E
/sys/devices/system/cpu/cpu0/cpuidle/state3/name:C3
/sys/devices/system/cpu/cpu0/cpuidle/state4/name:C6
/sys/devices/system/cpu/cpu0/cpuidle/state5/name:C7s
/sys/devices/system/cpu/cpu0/cpuidle/state6/name:C8
/sys/devices/system/cpu/cpu0/cpuidle/state7/name:C9
/sys/devices/system/cpu/cpu0/cpuidle/state8/name:C10

Just make the cpu number a wildcard if you want the list for everything (typically the same for each CPU).

1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like