03-01-2017 06:44 AM
I'm working on a project wherein I boot OP-TEE in the secure world, and then handoff the bring up to Linux. OP-TEE is booting fine as well as properly doing the handoff. However, Linux failis to boot.
I've honed in to the specific call chain and instruction the causes the fault:
Call chaing: zynq_irq_init() -> zynq_early_slcr_init()-> regmap_update_bits()->regmap_mmio_read()->regmap_mmio_read32le().
If I boot Linux as primary, I have no problems booting.
I have attached two images: terminal01.jpg and terminal03.jpg. The first shows the boot trace (with msgs that I added) when zynq_early_slcr_init() is executed, the second when it is not (i.e. the failure happens in zynq_clock_init())
My suspicion is that OP-TEE is locking down access to a number of the MM registers, including the SLCR, to secure world access only. When Linux, running in the normal world tries to read or write from/to these registers, bad things happen. However, at this point, I haven't confirmed that.
I am wondering a few things;:
- Has anybody done a similar implementation before and encountered the same kinds of issues? If so, how were they addressed?
- Are there any petalinux configuration parameters that I have somehow missed that make this kind of boot config work properly?
This issue is pretty much my last thing to take care of before I have everything working. Any help would be extremely appreciated.
03-01-2017 10:11 AM
Another bit of information. The specific register access that is failing is the one performed by regmap_update_bits(zynq_slcr_regmap, SLCR_L2C_RAM, 0x70707, 0x20202), in response to AR#54190 design advisory. This is part of L2 cache setup. If I remove this step, the L2 cache appears to be setup fine...but I get a similar error on another register access downstream.
07-02-2017 07:50 PM
I am also trying to boot OP-TEE and Linux (provided in xilinx github). Now, I have boot OP-TEE, but can not switch to normal world boot. The log shows OP_TEE have initialized and switched to normal world, but no output from Linux.
DEBUG: [0x0] TEE-CORE:init_primary_helper:585: Primary CPU switching to normal world boot
I find you have boot linux successfully, but occurs some problems during booting. I have tried a lot, but it also failed.
Can you tell me the method that using OP-TEE to boot linux?
Else, I use U-Boot to boot OP-TEE.
Can you give me some help.