<div dir="ltr"><br><div class="gmail_extra"><br clear="all"><br><div class="gmail_quote">2018-03-09 18:16 GMT+01:00 Ruhollah Majdoddin <span dir="ltr"><<a href="mailto:r.majdodin@gmail.com" target="_blank">r.majdodin@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span>2018-03-06 18:45 GMT+01:00 Rob Landley <span dir="ltr"><<a href="mailto:rob@landley.net" target="_blank">rob@landley.net</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">You could try getting the microblaze target to work? Something's wrong with the<br>
ELF parser, the kernel refuses to launch init. Not quite sure why, I was<br>
planning on drilling down through the kernel's load_elf_binary()<br>
(<a href="https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/fs/binfmt_elf.c#n685" rel="noreferrer" target="_blank">https://git.kernel.org/pub/sc<wbr>m/linux/kernel/git/torvalds/li<wbr>nux.git/tree/fs/binfmt_elf.c#n<wbr>685</a>)<br>
to see if I can figure it out...<br>
<br>
That might be throwing you in the deep end a bit. :)<span class="gmail-m_8848516876070553474m_-3534141818836690615HOEnZb"><font color="#888888"><br></font></span></blockquote><div> </div></span><div>I am working on that. <br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span class="gmail-m_8848516876070553474m_-3534141818836690615HOEnZb"><font color="#888888">Rob<span class="gmail-m_8848516876070553474HOEnZb"><font color="#888888"><br>
</font></span></font></span></blockquote></div><span class="gmail-m_8848516876070553474HOEnZb"><font color="#888888"><br></font></span></div><span class="gmail-m_8848516876070553474HOEnZb"><font color="#888888"><div class="gmail_extra">Ruhollah<br></div></font></span></div>
</blockquote></div><br><p>I have been working on this ever since, and I have problems running linux on Qemu-microblaze. <br></p><p>I have adjusted module/kernel with proper kernel configuration items and other things (attached).<br></p> It does not compile the dts file in linux source tree, because Qemu has already access to the dtb file.<br></div><div class="gmail_extra"></div><div class="gmail_extra">It runs<br></div><div class="gmail_extra"><pre>make ARCH=$KARCH allnoconfig KCONFIG_ALLCONFIG="$OUTPUT/$<wbr>TARGET.miniconf" &&
make KCPPFLAGS="-D__MICROBLAZEEL__" ARCH=$KARCH CROSS_COMPILE="$CROSS_COMPILE" linux.bin</pre><p>to get arch/<span class="gmail-m_8848516876070553474gmail-lia-search-match-lithium">microblaze</span>/boot/linux.<wbr>bin.</p><p>Now if i run<br></p><pre>qemu-system-microblazeel -M petalogix-ml605 -serial mon:stdio -nographic -no-reboot -m 256 -append "panic=1 HOST=<span class="gmail-m_8848516876070553474gmail-lia-search-match-lithium">microblaze</span> console=ttyS0,115200" -kernel linux.bin -d in_asm</pre><p>I get</p><pre>50000000: 01c00094 add r14 r0 r0
50000004: 00c80094 add r6 r8 r0
50000008: ffff0021 s8i
/home/ruhollah/qemu/tcg/tcg-<wbr>op.c:2567: tcg fatal error
Aborted</pre><p>Why?</p><p>My guess is that Qemu requires the kernel in elf format, but linux.bin is not in elf format.</p><p>If I am right, then how can I get the kernel in elf format?</p><p>Ruhollah<br></p><br></div></div>