MLK-18822 imx: Fix bootaux issue when running on ARM64
authorYe Li <ye.li@nxp.com>
Wed, 11 Jul 2018 08:41:24 +0000 (01:41 -0700)
committerYe Li <ye.li@nxp.com>
Wed, 28 Apr 2021 20:41:04 +0000 (13:41 -0700)
The bootaux from community uses ulong to read private data and write to M4 TCM,
this cause problem on ARM64 platform where the ulong is 8bytes.
Fix it by using u32 to replace ulong.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
(cherry picked from commit f3d936c84759fcd47a2489cf31fe46cd84ba1f47)
(cherry picked from commit 2795cbf333997f2b723dff7d7585ece0257a0b3f)
(cherry picked from commit f22ccd7e79d7372f6c961bc876f16938e983291d)

arch/arm/mach-imx/imx_bootaux.c

index 4c7b37a..c352c1d 100644 (file)
@@ -16,7 +16,7 @@
 
 int arch_auxiliary_core_up(u32 core_id, ulong addr)
 {
-       ulong stack, pc;
+       u32 stack, pc;
 
        if (!addr)
                return -EINVAL;
@@ -45,7 +45,7 @@ int arch_auxiliary_core_up(u32 core_id, ulong addr)
                pc = *(u32 *)(addr + 4);
        }
 #endif
-       printf("## Starting auxiliary core stack = 0x%08lX, pc = 0x%08lX...\n",
+       printf("## Starting auxiliary core stack = 0x%08X, pc = 0x%08X...\n",
               stack, pc);
 
        /* Set the stack and pc to MCU bootROM */