<div dir="ltr">Hi Robert,<div><br></div><div>So close!  qemuarm64 is breaking on the AB:<div><br></div><div><a href="https://autobuilder.yoctoproject.org/main/builders/nightly-arm64/builds/536/steps/Running%20Sanity%20Tests/logs/stdio">https://autobuilder.yoctoproject.org/main/builders/nightly-arm64/builds/536/steps/Running%20Sanity%20Tests/logs/stdio</a><br></div><div><br></div><div>I suspect we&#39;re passing some options to runqemu that you didn&#39;t cover in your testing.</div><div><br></div><div>Ross</div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 25 August 2016 at 15:40, Robert Yang <span dir="ltr">&lt;<a href="mailto:liezhi.yang@windriver.com" target="_blank">liezhi.yang@windriver.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">* V5<br>
  - Fix race issues when building multi image recipes at the same time, they<br>
    might write qemuboo.py at the same time in the past. Now each image has<br>
    a unique ${IMAGE_LINK_NAME}.runqemu.<wbr>conf.<br>
<br>
  - qemuboot.py -&gt; ${IMAGE_LINK_NAME}.runqemu.<wbr>conf, I used &quot;import qemuboot.py&quot;,<br>
    but now we can&#39;t &quot;import ${IMAGE_LINK_NAME}.runqemu.py&quot; since<br>
    IMAGE_LINK_NAME contains dash &quot;-&quot;, so rename it to .conf and use configparser<br>
    to read/write it.<br>
<span class=""><br>
* V4<br>
  - Now the conf files can use @TAP@, @ROOTFS@ and @PORT@ when set vars<br>
    for runqemu, so all the arch info are gone. And also update comments<br>
    in qemuboot.bbclass.<br>
  - Add var QB_SLIRP_OPT for slirp mode as Nathan suggested, also add<br>
    QB_TAP_OPT whichi is for tap mode.<br>
  - Print &quot;Try &#39;runqemu help&#39; on how to use it&quot; when failed to parse args<br>
    as Nathan suggested.<br>
  - Fix device locking problems.<br>
  - Fix nativesdk-qemu-helper.<br>
  - Fix comments for <a href="http://qemurunner.py/qemutinyrunner.py" rel="noreferrer" target="_blank">qemurunner.py/qemutinyrunner.<wbr>py</a><br>
<br>
</span><span class="">* V3<br>
  - Move the qemu boot settings out of tune files (e.g., arch-x86.inc)<br>
    to avoid mixing BSP settings with the tunings as Mark suggested. and<br>
    put them to &lt;machine&gt;.conf or &lt;qemuboot&gt;.inc file.<br>
<br>
* V2<br>
  - Fixes for RP&#39;s comments<br>
    a) Remove a kvm commit message since qemu-kvm can only run target when<br>
       its arch is the same as the host arch:<br>
       The kvm support is not limited on x86 or x86_64<br>
<br>
    b) Fix a typo in commit message: qemu-boot.bbclass -&gt; qemuboot.bbclass,<br>
       You may wonder why I use qemuboot.bbclass but not qemu-boot.bbclass,<br>
</span>       this is because the bbclass will save vars into qemuboot.conf, the<br>
       qemuboot.conf can&#39;t be qemu-boot.py here, otherwise,<br>
<span class="">       &quot;import qemu-boot.py&quot; doesn&#39;t work since &quot;-&quot; is not a validate<br>
       identifier, so use &quot;qemuboot&quot; to make them unify.<br>
<br>
    c) Reorder the patches to make sure they don&#39;t break the bisect build.<br>
<br>
  - Update commit message:<br>
    &quot;Fix SLIRP mode&quot; -&gt; &quot;Fix SLIRP mode, add help message, avoid mixing<br>
  with tap&quot;<br>
<br>
* V1<br>
  Previously, runqemu had hard coded machine knowledge, which limited its<br>
  usage, for example, qemu can boot genericx86, but runqemu can&#39;t, we need<br>
  edit runqemu/runqemu-internal a lot if we want to boot genericx86.<br>
<br>
  Now bsp conf files can set vars to make it can be boot by runqemu, and<br>
</span>  qemuboot.bbclass will save these info to DEPLOY_DIR_IMAGE/qemuboot.<wbr>conf.<br>
<span class="">  Please see qemuboot.bbclass&#39; comments on how to set the vars.<br>
<br>
  - Re-write it in python3, which can reduce lines from 1239 to about 750<br>
    lines<br>
  - All the machine knowledges are gone<br>
  - All of the TUN_ARCH knowledge are gone (FIXED in V4)<br>
  - All the previous options are preserved, and there is a new way to run<br>
    runqemu: (it doesn&#39;t need run &quot;bitake -e&quot; in such a case)<br>
    $ runqemu tmp/deploy/images/qemux86<br>
    or:<br>
    $ runqemu tmp/deploy/images/qemuarm/&lt;<wbr>image&gt;.ext4<br>
    or:<br>
</span>    $ runqemu tmp/deploy/images/qemuarm/<wbr>qemuboot.conf<br>
<span class="">  - Fixed audio support, not limited on x86 or x86_64<br>
  - The kvm support is not limited on x86 or x86_64 (REMOVED by V2)<br>
  - Fix SLIRP mode (FIXED by V2)<br>
  - Fix NFS boot, it will extract &lt;image&gt;.tar.bz2 or tar.gz to<br>
    DEPLOY_DIR_IMAGE/&lt;image&gt;-<wbr>nfsroot when no NFS_DIR, and remove it after<br>
    stop.<br>
  - More bsps can be boot, such as genericx86 and genericx86-64.<br>
  - The patch for qemuzynq, qemuzynqmp, qemumicroblaze has been sent to<br>
    meta-xilinx&#39; mailing list.<br>
  - I can&#39;t find any qemush4 bsp or how to build it, so it is not<br>
    considered atm.<br>
<br>
  - Tested the following machines, all of them work well.<br>
    genericx86 genericx86-64<br>
    qemuarm qemuarm64<br>
    qemumips qemumips64 qemuppc<br>
    qemux86 qemux86-64<br>
    qemuzynq qemuzynqmp<br>
<br>
    Tested ext4, nfs, slirp, vmdk, iso and cpio.gz when they are available.<br>
<br>
  And also test &quot;bitbake core-image-sato -ctestimage&quot; which uses runqemu,<br>
  it works, well.<br>
<br>
// Robert<br>
<br>
</span>The following changes since commit a7f1435c4c26237cdb55066c9f5408<wbr>b4fdf016aa:<br>
<br>
  combo-layer: python3: fix UnicodeDecodeError (2016-08-24 13:58:24 +0100)<br>
<span class=""><br>
are available in the git repository at:<br>
<br>
  git://<a href="http://git.openembedded.org/openembedded-core-contrib" rel="noreferrer" target="_blank">git.openembedded.org/<wbr>openembedded-core-contrib</a> rbt/runqemu<br>
  <a href="http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=rbt/runqemu" rel="noreferrer" target="_blank">http://cgit.openembedded.org/<wbr>cgit.cgi/openembedded-core-<wbr>contrib/log/?h=rbt/runqemu</a><br>
<br>
</span>Robert Yang (10):<br>
<span class="">  qemuboot.bbclass: add it for runqemu<br>
  qemuarm.conf: set vars for runqemu<br>
  qemuarm64.conf: set vars for runqemu<br>
  qemux86.conf/qemux86-64.conf: set vars for runqemu<br>
  qemumips/qemumips64.conf: set vars for runqemu<br>
  qemuppc.conf: set vars for runqemu<br>
  qemu.inc: inherit qemuboot.bbclass<br>
  runqemu: refactor it and remove machine knowledge<br>
</span><span class="">  nativesdk-qemu-helper: fix for new runqemu<br>
  <a href="http://qemurunner.py/qemutinyrunner.py" rel="noreferrer" target="_blank">qemurunner.py/qemutinyrunner.<wbr>py</a>: remove runqemu-internal<br>
<br>
</span> meta/classes/qemuboot.bbclass                      |   75 ++<br>
<span class=""> meta/conf/machine/include/<wbr>qemu.inc                 |    2 +<br>
 meta/conf/machine/include/<wbr>qemuboot-mips.inc        |    7 +<br>
 meta/conf/machine/include/<wbr>qemuboot-x86.inc         |   14 +<br>
 meta/conf/machine/qemuarm.conf                     |    5 +<br>
 meta/conf/machine/qemuarm64.<wbr>conf                   |   13 +<br>
 meta/conf/machine/qemumips.<wbr>conf                    |    1 +<br>
 meta/conf/machine/qemumips64.<wbr>conf                  |    1 +<br>
 meta/conf/machine/qemuppc.conf                     |    7 +<br>
 meta/conf/machine/qemux86-64.<wbr>conf                  |    1 +<br>
 meta/conf/machine/qemux86.conf                     |    1 +<br>
 meta/lib/oeqa/utils/<wbr>qemurunner.py                  |    2 +-<br>
 meta/lib/oeqa/utils/<wbr>qemutinyrunner.py              |    2 +-<br>
</span> .../qemu/<a href="http://nativesdk-qemu-helper_1.0.bb" rel="noreferrer" target="_blank">nativesdk-qemu-<wbr>helper_1.0.bb</a>              |    9 +-<br>
 scripts/runqemu                                    | 1332 ++++++++++++--------<br>
 scripts/runqemu-internal                           |  739 -----------<br>
 16 files changed, 941 insertions(+), 1270 deletions(-)<br>
<span class=""> create mode 100644 meta/classes/qemuboot.bbclass<br>
 create mode 100644 meta/conf/machine/include/<wbr>qemuboot-mips.inc<br>
 create mode 100644 meta/conf/machine/include/<wbr>qemuboot-x86.inc<br>
 delete mode 100755 scripts/runqemu-internal<br>
<br>
--<br>
</span>2.9.0<br>
<div class="HOEnZb"><div class="h5"><br>
--<br>
______________________________<wbr>_________________<br>
Openembedded-core mailing list<br>
<a href="mailto:Openembedded-core@lists.openembedded.org">Openembedded-core@lists.<wbr>openembedded.org</a><br>
<a href="http://lists.openembedded.org/mailman/listinfo/openembedded-core" rel="noreferrer" target="_blank">http://lists.openembedded.org/<wbr>mailman/listinfo/openembedded-<wbr>core</a><br>
</div></div></blockquote></div><br></div>