Hi experts,
i am trying wakeup the secondary CPU core in bootloader, i am able to do this through a trusted firmware. The problem comes after wakeup!
Once the cpu is up it will be in EL-2 mode and it executes a predefined function, in which i will load the stack pointer(SP) with a valid address and transfer the control to a function written in c-code. once the controls is transferred it is not executing the any of further functions. Are there any additional settings which need to be done before we pass the control to actual function?
below is the code which is executed by the secondary cpu.
.global reset_handler_smp reset_handler_smp: ldr x3, =( svc_secondary_stack ) /* stack base ptr */ mrs x1, mpidr_el1 /* read mpidr reg */ and x0, x1, #0xf /* cpuid =mpidr[3:0] */ mov x2, #STACK_SIZE /* stack size */ mul x0, x0, x2 add x3, x3, x0 /* x3 - per cpu stack */ bic sp, x3, #7 /* 8bit aligned stack */ bl _secondary_cpu_entry looop: b looop
can some one please help me