Hello,
I am using i.MX8M Mini EVK with Yocto L5.4.47-2.2.0 package and Android 9.0. I want to check the DDR clock frequency at runtime through sysfs or some utility.
I am read the CPU frequecy at runtime using below commands:
cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq
cat /sys/devices/system/cpu/cpu1/cpufreq/cpuinfo_cur_freq
cat /sys/devices/system/cpu/cpu2/cpufreq/cpuinfo_cur_freq
cat /sys/devices/system/cpu/cpu3/cpufreq/cpuinfo_cur_freq
I am looking for something similar for DDR clock.
Please help to suggest the sysfs entry or utility to get the current DDR clock frequency.
Regards,
Naman
Solved! Go to Solution.
Hi @joanxie,
Thank you for suggesting the DDR tool.
This DDR tool requires the device to be in Serial Download mode. I need to check the DDR frequency at runtime while running my application in Android.
For this dump-clocks.sh script can be used from below link:
https://source.codeaurora.org/external/imx/imx-test/tree/test/mxc_clock_test?h=imx_4.14.78_1.0.0_ga
This script will give the dram_core_clk value like below:
dram_core_clk --- 000010a0 1 1 800000000
"dram_core_clk=800" means DRAM Clock=1600 (DDRC PHY PLL multiplies the input frequency by 2 to generate the DDR clock), Data Rate=3200.
Regards,
Naman
you can use Mscale ddr tool to program and test DDR
Hi @joanxie,
Thank you for suggesting the DDR tool.
This DDR tool requires the device to be in Serial Download mode. I need to check the DDR frequency at runtime while running my application in Android.
For this dump-clocks.sh script can be used from below link:
https://source.codeaurora.org/external/imx/imx-test/tree/test/mxc_clock_test?h=imx_4.14.78_1.0.0_ga
This script will give the dram_core_clk value like below:
dram_core_clk --- 000010a0 1 1 800000000
"dram_core_clk=800" means DRAM Clock=1600 (DDRC PHY PLL multiplies the input frequency by 2 to generate the DDR clock), Data Rate=3200.
Regards,
Naman