We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi, ARM experts:
When we porting a secure os in 32bit mode in v8 secure EL1(our EL3 is running in AARCH 64bit mode), we got a strange problem:
When start booting secure os in secure EL1, the bootstrap code which running on PA when mmu off seems ok,
in these code we make some common memory map operation in section mode, for example, 1:1 map for bootstrap, kernel map to a certain address, kernel device i/o map etc.
when we turn mmu on via SCTLR, the 1:1 map boostrap code running seems ok, and we can visit device i/o memory via VA, but when we try to jump to kernel address, the system is abort.
In fact, any operation try to change pc with instruction after mmu on will lead to this kind of problem.
We compare v7 mmu operation with v8 32bit, they looks like compatible in most part, did we miss some important point?
Thank you and waiting for your guidance and suggestion!
Steven
Do you get anything useful out of the fault status registers? They are normally pretty good at pinpointing what the problem is.
In ARMv8-A, when coming out of reset in AArch64, most system registers don't have defined reset values. It could be that your code is relying on an ARMv7 reset value for a bit, which is no longer guaranteed. Could be something like SCTLR.WXN (whether write-able addresses are executable).
For some reasons, our D-Stream can not work in our v8 board yet, so when system abort, we can not get fault status registers now.
We are trying to get this kind of information, thank you for your suggestion, Peter!
Hi, Martin,
The problem is solved, as you say, there are some bit different between ARMv7 and v8 32bit, SCTLR.WXN is one of them, we check again and redefine them, the system seems ok.
Thank you very much!