From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marc Zyngier Date: Tue, 03 Jun 2014 10:46:06 +0100 Subject: [U-Boot] smp_kick_all_cpus() function's role In-Reply-To: (TigerLiu@via-alliance.com's message of "Tue, 3 Jun 2014 10:41:51 +0100") References: Message-ID: <87lhtez5pd.fsf@approximate.cambridge.arm.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Tue, Jun 03 2014 at 10:41:51 am BST, "TigerLiu at via-alliance.com" wrote: > Hi, Marc: >>My understanding is that if you're using the Trusted Firmware, then you >>have an implementation of PSCI, and that's what you must use to bring >>the CPUs into u-boot. U-Boot will be running non-secure anyway, so it >>requires the firmware to perform S to NS transition on its behalf. > Do you mean : > Waking up Non-BSP cores through PSCI interface, and then let them switch > to Non-Secure state through smp_kick_all_cpus()? No. You don't need smp_kick_all_cpus at all. Just call the PSCI firmware to wake up the secondary CPUs, and they will be directly placed in non-secure mode. > And another question: > 1. how to determine successfully transitioning to Non-Secure? > Is there any register to indicate current state is Non-Secure state? > And after transitioning to non-secure state, I tried to access SCR > register,but it caused system hang. No, there is no architectural way. But if you go from EL3 to EL2, looking at the mode in PSTATE is pretty easy. M. -- Jazz is not dead. It just smells funny.