getting error while booting cpu cpu0: failed to get the regulator, imx7d-cpufreq: probe of imx7d-cpufreq failed with error -2?

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

getting error while booting cpu cpu0: failed to get the regulator, imx7d-cpufreq: probe of imx7d-cpufreq failed with error -2?

2,542 Views
jagdishgediya
Contributor I

Hi All,

I am getting below error while booting imx7 based custom board.

cpu cpu0: failed to get the regulator

imx7d-cpufreq: probe of imx7d-cpufreq failed with error -2

What can be the reason for it?

Am i missing anything in device tree? @

Labels (3)
Tags (2)
0 Kudos
4 Replies

1,656 Views
jacobpostman
Contributor II

Hi Jagdish,

I am guessing you are not using the PF3000 PMIC?

I had a similar issue which was caused by line 194 in drivers/cpufreq/imx7-cpufreq.c:

arm_reg = devm_regulator_get(cpu_dev, "arm");

which is looking for the regulator "arm-supply" under the cpu parent of the device tree.

If, as in my case, it is not convenient to place the supply under the cpu parent, you can try making the following change to line 194:

-      arm_reg = devm_regulator_get(cpu_dev, "arm");

+      arm_reg = devm_regulator_get(&pdev->dev, "arm");

linux-2.6-imx.git - Freescale i.MX Linux Tree

Jacob

0 Kudos

1,656 Views
igorpadykov
NXP Employee
NXP Employee

Hi jagdish

one can check presence &cpu0 { arm-supply = <&sw1a_reg>

as in imx7d-sdb.dts example

linux-2.6-imx.git - Freescale i.MX Linux Tree

One can try to debug it more using attached Linux Manual

Chapter 23 CPU Frequency Scaling (CPUFREQ) Driver

Best regards

igor

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1,656 Views
jagdishgediya
Contributor I

Hi Igorpadycov,

Thanks for your reply.

&cpu0 { arm-supply = <&sw1a_reg> is already available in device tree by default. but still i am getting this error. i have gone through respective section of the document you have attached, but it didn't help me to resolve this issue.

Is it anything related to PMIC?

"sw1a_reg" is available in PMIC phandle in device tree. Currently i am facing some issue with PMIC? Can it be the reason?

0 Kudos

1,656 Views
igorpadykov
NXP Employee
NXP Employee

one can try to debug it more adding printfs in probe function.

~igor

0 Kudos