]> git.baikalelectronics.ru Git - uboot.git/commit
cpu: imx8: use intended cpu-thermal device when getting temp value
authorAnatolij Gustschin <agust@denx.de>
Tue, 19 May 2020 23:31:44 +0000 (01:31 +0200)
committerAnatolij Gustschin <agust@denx.de>
Fri, 22 May 2020 11:27:46 +0000 (13:27 +0200)
commit62639ec368a3a0e34a10d4481bd30e6d82dd6be9
tree3ed22b51f4ab6a7cbb069859d24506959ec4d39e
parente19e7b1af1789ea03beaf33270d7fff630c8ad58
cpu: imx8: use intended cpu-thermal device when getting temp value

This fixes getting DT alert and critical pdata values in imx_scu_thermal
driver. On i.MX8QXP using not initialized alert pdata value resulted in
boot hang and endless loop outputting:
CPU Temperature (47200C) has beyond alert (0C), close to critical (0C) waiting...

While at it, preset CPU type values once to avoid multiple calls
of device_is_compatible() for same property.

Fixes: 32045931c14d ("cpu: imx_cpu: Print the CPU temperature for iMX8QM A72")
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
drivers/cpu/imx8_cpu.c