MLK-22425 TMU: iMX8MN: Enable loading TASR and TCALIV from fuse
authorYe Li <ye.li@nxp.com>
Mon, 12 Aug 2019 03:42:27 +0000 (20:42 -0700)
committerYe Li <ye.li@nxp.com>
Mon, 12 Aug 2019 05:37:31 +0000 (22:37 -0700)
Like iMX8MM, iMX8MN also needs SW to load TMU TASR and TCALIV registers
value from fuse before enabling TMU calibration. Otherwise the calibration
is not exact.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit 9fb7f904ff6a03e2951a770daba12a522373c8ae)

arch/arm/mach-imx/imx8m/soc.c

index 6f2efe5..7bf8aac 100644 (file)
@@ -884,7 +884,7 @@ int imx8m_usb_power(int usb_id, bool on)
 
 void nxp_tmu_arch_init(void *reg_base)
 {
-       if (is_imx8mm()) {
+       if (is_imx8mm() || is_imx8mn()) {
                /* Load TCALIV and TASR from fuses */
                struct ocotp_regs *ocotp = (struct ocotp_regs *)OCOTP_BASE_ADDR;
                struct fuse_bank *bank = &ocotp->bank[3];