How to get CPU current frequency in Linux?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to get CPU current frequency in Linux?

231 Views
paullegart
Contributor II

I've got i.MX8 ULP processor and built Yokto Linux image for it. I need to know exact current frequency of each Cortex-A35 core so I tried to use command from chapter 6.2 of IMX_LINUX_USERS_GUIDE but nothing happens. There is no any directory like that:

Spoiler
# cat /sys/devices/system/cpu/*/cpufreq/cpuinfo_cur_freq
cat: '/sys/devices/system/cpu/*/cpufreq/cpuinfo_cur_freq': No such file or directory

It seems I didn't turn something on in the Linux core config.

Any suggestions?

0 Kudos
Reply
1 Reply

205 Views
clay_miller
NXP Employee
NXP Employee

Hi,

I would suggest looking into the AN13814.pdf app note. The i.MX8ULP has a different approach to power management with the uPower module, and it seems it doesn't support cpufreq. The BSP doesn't have the cpufreq driver enabled in the Device tree for the i.MX8ulp.

https://www.nxp.com/docs/en/application-note/AN13914.pdf 

Alternatively, you can view the cpu frequency with the mhz cmd. However, it won't show the individual core frequencies.

Regards,

Clay

0 Kudos
Reply