<div style="color:#000; font-size: 14px;font-family: arial;"><div>This elf file is position-independent and can be loaded to any location. We can add a simple script to handle it.<br><br>1. Convert vmlinux to binary by objcopy, the binary file name is flat_file<br><br>2. Write a simple assembly file (tmp.S), convert binary to object, the file name is obj_file<br>```<br>.section .text<br>.globl _start<br>_start:<br>.incbin "flat_file"<br>```<br>command: as tmp.S -o obj_file<br><br>3. Relink. Linker script like this(tmp.ld):<br>```<br>ENTRY(_start)<br><br>SECTIONS {<br>  . = target_address;<br>  .text : { *(.text) }<br>}<br>```<br>command: ld -T tmp.ld obj_file<br></div><div><br></div><div><br></div><div><br></div></div><!-- jy5ContentSuffix --><div>在2018年09月25 20时51分, "Philipp Hug"<philipp@hug.cx>写道:</div><blockquote id="isReplyContent" style="padding-left:1ex; margin: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"><br><div dir="ltr"><div dir="ltr"><div dir="ltr"><div class="gmail_quote"><div dir="ltr">Am Di., 25. Sep. 2018 um 13:50 Uhr schrieb Jonathan Neuschäfer <<a href="mailto:j.neuschaefer@gmx.net">j.neuschaefer@gmx.net</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Would FIT support require discussion/cooperation with other projects<br>like Linux or u-boot?<br><br></blockquote><div>What seems to be missing is the kernel image format to be used within the FIT. e.g. look at arm64:</div><div><a href="https://github.com/torvalds/linux/blob/master/arch/arm64/kernel/head.S#L73">https://github.com/torvalds/linux/blob/master/arch/arm64/kernel/head.S#L73</a></div><div><a href="https://github.com/coreboot/coreboot/blob/master/src/arch/arm64/fit_payload.c#L29">https://github.com/coreboot/coreboot/blob/master/src/arch/arm64/fit_payload.c#L29</a> </div><div><br></div><div>Philipp</div><div><br></div><div> </div></div></div></div></div></blockquote><br><br><span title="neteasefooter"><p> </p></span>