Re: [U-Boot] [PATCH v5 3/8] ARM: add assembly routine to switch to non-secure state

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 






On Fri, Sep 20, 2013 at 4:05 AM, Peter Maydell <peter.maydell@xxxxxxxxxx> wrote:
On 20 September 2013 06:55, Mj Embd <mj.embd@xxxxxxxxx> wrote:
> Hello Andre,
> I need a bit clarification here, if you read the next line after the line
> you have quoted. It clearly says that you can use a MCR to change from
> Secure to NS in Monitor Mode

No, it's not saying that, because Monitor mode is always Secure:
this is exactly why an MCR to change SCR.NS is OK only in
Monitor mode -- it doesn't change from Secure to Non-Secure.
Only when you do an exception-return to leave Monitor mode
will you drop into the NonSecure world.

> "Use an MCR instruction that writes SCR.NS to change from Secure to
> Non-secure state. This means ARM recommends that software does not alter
> SCR.NS in any mode except Monitor mode. ARM deprecates changing SCR.NS in
> any other mode."

The text says "don't change from Secure to NonSecure by flipping
SCR.NS". It then lays out the corollary: the only time you then can
change SCR.NS is when it won't switch from Secure to NonSecure,
which is when you're in Monitor mode.

[MJ] Ok got your point. Then what would be the steps to return from Monitor to Hyp mode? 
 
-- PMM



--
-mj
_______________________________________________
kvmarm mailing list
kvmarm@xxxxxxxxxxxxxxxxxxxxx
https://lists.cs.columbia.edu/cucslists/listinfo/kvmarm

[Index of Archives]     [Linux KVM]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux