Apalis IMX6Q CPU temperature read failure

Hi,
I was trying to make a script to monitor CPU and baseboard temperature, but I was unable to read the first one. It looks like a device driver problem, because thermal’s sys paths do not exist:

root@apalis-imx6q:~# cat /sys/devices/virtual/thermal/thermal_zone0/temp
cat: /sys/devices/virtual/thermal/thermal_zone0/temp: No existe el fichero o el directorio
root@apalis-imx6q:~# cd /sys/class/thermal/
root@apalis-imx6q:/sys/class/thermal# ls -lthr
total 0
root@apalis-imx6q:/sys/class/thermal# 

I have checked kernel log files and I did not find errors. I am using a custom kernel image built from 3.14.52 source, without any changes on drivers.

Thanks for your help and advices.
Regards.

Hi

The path exists on my unaltered V2.6.1 image.
Can you check if you accidental deleted a kernel option from the .config or the device tree you used?

Max

Hi Max, thanks for your response.

Yes, I have checked before posting. Thermal options in my custom .config file are below:

CONFIG_THERMAL=y
CONFIG_THERMAL_HWMON=y
CONFIG_THERMAL_OF=y
CONFIG_THERMAL_DEFAULT_GOV_STEP_WISE=y
# CONFIG_THERMAL_DEFAULT_GOV_FAIR_SHARE is not set
# CONFIG_THERMAL_DEFAULT_GOV_USER_SPACE is not set
# CONFIG_THERMAL_GOV_FAIR_SHARE is not set
CONFIG_THERMAL_GOV_STEP_WISE=y
# CONFIG_THERMAL_GOV_USER_SPACE is not set
# CONFIG_THERMAL_EMULATION is not set
CONFIG_DEVICE_THERMAL=y

Are there any other configuration vars that need to be set?

Most possibly you are just missing CONFIG_CPU_THERMAL and/or CONFIG_IMX_THERMAL.

Thanks very much for the response.

It is a bit strange, those config options does not appear in my config file. I am shure that I did not delete them. I will add them and recompile. Moreover, I couldn’t find them using menuconfig.

Later, I have done “make apalis_imx6_defconfig” to built the default .config file, added some custom kernel options and save it. That was deleting those config options

Regards.