Loading RTEMS-application with U-boot on Raspberry Pi or MicroZed
Sebastian Huber
sebastian.huber at embedded-brains.de
Tue Apr 12 06:07:35 UTC 2016
On 11/04/16 15:43, Jan Sommer wrote:
> I just tried the same setup with the Xilinx MicroZed board at work.
> There, the same behaviour appears.
> If I compile a simple bare metal application I can load the binary to
> the correct address and run it or load the elf-file somewhere into the
> memory and use the bootelf-command to start the application.
> If I try to do the same with a compiled RTEMS-application, it won't
> work. The same RTEMS-application runs if I put it directly into the
> bootimage (without using u-boot).
>
> How does it work on other ARM-boards? The BeagleBone uses u-boot to
> load all its binaries, doesn't it?
You have to specify the correct entry and load addresses for the
mkimage. For example:
readelf -l ticker.exe
Elf file type is EXEC (Executable file)
Entry point 0x400145
There are 5 program headers, starting at offset 52
Program Headers:
Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align
EXIDX 0x00ec70 0x0040eb70 0x0040eb70 0x00008 0x00008 R 0x4
LOAD 0x000100 0x00400000 0x00400000 0x0ebc4 0x0ebc4 RWE 0x40
LOAD 0x00ecc8 0x20401148 0x0040ebc4 0x006a4 0x006a4 RW 0x8
LOAD 0x00f380 0x20400000 0x20400000 0x00000 0x5f000 RW 0x20
LOAD 0x00f36c 0x2045f000 0x2045f000 0x00000 0x01000 RW 0x1
Section to Segment mapping:
Segment Sections...
00 .ARM.exidx
01 .start .text .init .fini .rodata .ARM.exidx .eh_frame
.init_array .fini_array .jcr .rtemsroset
02 .data
03 .vector .bss .work
04 .xbarrier .robarrier .rwbarrier .stack .nocachenoload
Then use:
mkimage -a 0x00400000 -e 0x400145
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber at embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
More information about the users
mailing list