imx53 trustzone boot problem

Ofer Hasson hassonof at ...310...
Tue Mar 10 11:19:22 CET 2015


Hello,

I'm trying to boot genode on the secure world and linux on normal world of
the iMX53-QSB board (freescale).

The problem I'm encountering is:
[init -> tz_vmm] Start virtual machine ...
and then various errors, either it hangs, or
undefined instruction, or
Pagefault in core thread (pager_activation): ip=70055228 fault=20ef8904
failed to communicate thread event


My steps leading to this:

Downloaded http://genode.org/files/images/imx53_qsb/initrd.gz
and cloned https://github.com/skalk/linux.git
git checkout imx53-tz

Kernel compile:
using
http://www.codesourcery.com/sgpp/lite/arm/portal/package4573/public/arm-none-linux-gnueabi/arm-2009q1-203-arm-none-linux-gnueabi.bin
make CROSS_COMPILE=/opt/codesourcery/bin/arm-none-linux-gnueabi- ARCH=arm
imx5_android_tz_defconfig
make CROSS_COMPILE=/opt/codesourcery/bin/arm-none-linux-gnueabi- ARCH=arm
uImage
copied the initrd and uImage into the micro sd card, changed the name of
uImage into linux

I cloned https://github.com/genodelabs/genode.git
working on the master branch, current commit hash: 54ef87c

Created build directory:
tool/create_builddir hw_imx53_qsb_tz BUILD_DIR=hw_imx53_qsb_tz
I added "SPECS += trustzone" to etc/specs.conf in the build directory

Compiled:
make run/tz_vmm

Created u-boot image:
/opt/gcc-linaro-arm-none-eabi-4.9-2014.09_linux/bin/arm-none-eabi-objcopy
-O binary var/run/tz_vmm/image.elf var/run/tz_vmm/image.bin
mkimage -A arm -O linux -T kernel -C none -a 0x70010000 -e 0x70010000 -d
var/run/tz_vmm/image.bin var/run/tz_vmm/uImage

Next, i copy the image to the micro sd card.

On the u-boot shell:
ext2load mmc 0:1 0x71000000 uImage
bootm 0x71000000

OUTPUT:
## Booting kernel from Legacy Image at 71000000 ...
   Image Name:
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    9355264 Bytes = 8.9 MiB
   Load Address: 70010000
   Entry Point:  70010000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK

Starting kernel ...

kernel initialized
Genode 15.02 <local changes>
int main(): --- create local services ---
int main(): --- start init ---
In Rom_connection():
/home/hassonof/arm-tz/devel/boards/iMX53/genode-original/repos/base/include/rom_session/con7
filename = init, label = <NULL>
int main(): transferred 246 MB to init
int main(): --- init created, waiting for exit condition ---
[init] Could not open file "ld.lib.so"
[init] In Rom_connection():
/home/hassonof/arm-tz/devel/boards/iMX53/genode-original/repos/base/include/rom_sess7
[init] filename = config, label = <NULL>
[init] parent provides
[init]   service "ROM"
[init]   service "RAM"
[init]   service "IRQ"
[init]   service "IO_MEM"
[init]   service "CAP"
[init]   service "PD"
[init]   service "RM"
[init]   service "CPU"
[init]   service "LOG"
[init]   service "SIGNAL"
[init]   service "VM"
[init] In Rom_connection():
/home/hassonof/arm-tz/devel/boards/iMX53/genode-original/repos/base/include/rom_sess7
[init] filename = tz_vmm, label = tz_vmm
[init] child "tz_vmm"
[init]   RAM quota:  3932160
[init]   ELF binary: tz_vmm
[init]   priority:   0
[init -> tz_vmm] Start virtual machine ...


and then errors described at the beginning.
I was looking in the code and dumping some output to find the problem,
at repos/os/src/server/tz_vmm/include/vm_base.h:
_load_kernel() function, at lines #52-53 the memcpy crashes.
the arguments being passed to him are: destination: 80008000  source:
f0001000, size: 3203072

what am i doing wrong ?

Thanks
Ofer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.genode.org/pipermail/users/attachments/20150310/37b99afe/attachment.html>


More information about the users mailing list