|
From: | Alexander Graf |
Subject: | Re: [Qemu-arm] [Qemu-devel] [PATCH] target/arm: Allow to switch from MON->HYP on AArch32 |
Date: | Wed, 9 Jan 2019 18:14:10 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 |
On 01/09/2019 05:59 PM, Peter Maydell wrote:
On Wed, 9 Jan 2019 at 16:52, Peter Maydell <address@hidden> wrote:On Wed, 9 Jan 2019 at 15:26, Alexander Graf <address@hidden> wrote:In U-boot, we switch from S-SVC -> MON -> HYP when we want to enter HYP mode. This dance seems to work ok (hence it's there in the code base), but breaks with current QEMU.PS: it would be helpful if the commit message said how u-boot is trying to go from Mon to Hyp -- some ways to try to do this are OK, and some are not, so whether it's supposed to work or not depends on what u-boot is actually doing...
I don't fully understand all of it to be honest :). But the code is here: http://git.denx.de/?p=u-boot.git;a=blob;f=arch/arm/cpu/armv7/nonsec_virt.SWhat I managed to understand so far is that it goes to MON using the smc #0 call and then changes SPSR so that on return (movs pc) the mode will be different.
But please double check whether this is supposed to work - I don't find mode switching on ARM terribly intuitive ;).
Alex
[Prev in Thread] | Current Thread | [Next in Thread] |