<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/scripts/runqemu, branch 2.7_M2</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=2.7_M2</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=2.7_M2'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2018-12-15T11:55:38+00:00</updated>
<entry>
<title>runqemu: clean up subprocess usage</title>
<updated>2018-12-15T11:55:38+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross.burton@intel.com</email>
</author>
<published>2018-09-21T15:11:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=a785fdbe62595af092e050c19e291596e84fb930'/>
<id>urn:sha1:a785fdbe62595af092e050c19e291596e84fb930</id>
<content type='text'>
Where possible pass lists instead of strings, don't use a subshell, and call
check*() instead of using Popen directly.

(From OE-Core rev: d2374623444752af1ad748ed36b68ea58f629bf6)

Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/runqemu: Improve lockfile handling for python with close_fd=True</title>
<updated>2018-12-01T11:38:36+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2018-11-28T17:31:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=407138c7e59d1fe871cc563d57311e1223edd5c2'/>
<id>urn:sha1:407138c7e59d1fe871cc563d57311e1223edd5c2</id>
<content type='text'>
On python versions with close_fds=True (python 3.2 onwards), the tap
device lockfile isn't passed to the child process.

Since this guards against use of an active interface, we really want this
here, so pass it in pass_fds. This means if the parent exits early, the child
still holds the lock, avoiding messages like:

runqemu - ERROR - Failed to run qemu: qemu-system-x86_64: could not configure /dev/net/tun (tap0): Device or resource busy

(From OE-Core rev: 17a0a067d597c445c5892ff9914e91a2187f7e09)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/runqemu: Tidy up lock handling code</title>
<updated>2018-12-01T11:38:36+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2018-11-28T17:30:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=2d0b794b03a391cd2d7873c0c35bcd360616dfc9'/>
<id>urn:sha1:2d0b794b03a391cd2d7873c0c35bcd360616dfc9</id>
<content type='text'>
Various tweaks:
- Balance up the aquire/release functions
- Use debug messge for both acquiring and release message for consistency in logs
- Use None instead of an empty string
- Reset the value of the field if we don't have the lock any more

(From OE-Core rev: 58e48211f7cb44d959b571d449a94291c27535a5)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/runqemu: Fix logic error causing failures with MACHINE from the environment</title>
<updated>2018-12-01T11:38:36+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2018-11-28T16:09:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=1eaf3631a63dab882ef3aee28d97ff216d981db3'/>
<id>urn:sha1:1eaf3631a63dab882ef3aee28d97ff216d981db3</id>
<content type='text'>
MACHINE=qemux86-64 oe-selftest -r runqemu.RunqemuTests.test_boot_machine_slirp_qcow2

fails yet

oe-selftest -r runqemu.RunqemuTests.test_boot_machine_slirp_qcow2

with MACHINE in local.conf would work.

It turns out that:

runqemu slirp wic.qcow2 qemux86-64

works but:

MACHINE=qemux86-64 runqemu slirp wic.qcow2 qemux86-64

does not.

The reason are the misplaced return statements in runqemu, its skipping a block
of logic when MACHINE is set in the environment when it shouldn't. Fix this.

(From OE-Core rev: 98d113ae52cbbc88773a81a17b0933412a8e463b)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/runqemu: Replace subprocess.run() for compatibilty</title>
<updated>2018-11-14T11:14:39+00:00</updated>
<author>
<name>Michael Halstead</name>
<email>mhalstead@linuxfoundation.org</email>
</author>
<published>2018-11-08T20:58:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=aba0686c72ebf15ef0f08b7b33844a03891df9fa'/>
<id>urn:sha1:aba0686c72ebf15ef0f08b7b33844a03891df9fa</id>
<content type='text'>
subprocess.run() was introduced in Python 3.5. We currently support down to
Python 3.4 so I've replaced it with subprocess.check_call() which is available
in that version.

(From OE-Core rev: 3a09cee5994ce65079dab1042e47e5eed4540bb9)

Signed-off-by: Michael Halstead &lt;mhalstead@linuxfoundation.org&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/runqemu: Add serialstdio mode</title>
<updated>2018-11-14T11:14:39+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2018-11-08T20:58:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=e69ac0cab6828041e76504205bddb5014e20eaff'/>
<id>urn:sha1:e69ac0cab6828041e76504205bddb5014e20eaff</id>
<content type='text'>
Its currently not possible to have a console available whilst using qemu in graphics
mode. This is causing some issues for testing autobuilder bringup so all a "serialstdio"
mode to runqemu to accomodate this.

The existing serialstdio internal variable is renamed to allow the new user visible option.

(From OE-Core rev: 101b70d3c6a0a5a022d96dfdd21500b757c8fada)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>runqemu: fix handling of SIGTERM and the problem of line wrapping</title>
<updated>2018-09-25T22:15:49+00:00</updated>
<author>
<name>Chen Qi</name>
<email>Qi.Chen@windriver.com</email>
</author>
<published>2018-09-25T07:08:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=0e10a37618c089dc472896a0354aec10ee332913'/>
<id>urn:sha1:0e10a37618c089dc472896a0354aec10ee332913</id>
<content type='text'>
The current handling of SIGTERM is incorrect as the process pid returned
by Popen call with shell setting to True is actualy the shell instead of
the qemu process. So use shlex to split cmd so that we can avoid using
shell=True. This ensures the child process is the actual qemu process.

Also, as we install a SIGTERM handler, we need handle the situation of
qemu terminated by SIGTERM, otherwise we will get ERROR message in such
case.

Besides, we have a problem that after running qemu, the terminal's behavior
is incorrect regarding long lines or long commands. Long commands or long
outputs should appear in multiple lines, but they appear in the same line,
overriding previous output. Use `tput smam' to fix this problem.

(From OE-Core rev: e8acef383767cfd1ef0c3d3c45d9d6eb1c83b3e7)

Signed-off-by: Chen Qi &lt;Qi.Chen@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>runqemu: exit gracefully with an error message if qemu system is not evaluated</title>
<updated>2018-08-15T08:44:33+00:00</updated>
<author>
<name>Jagadeesh Krishnanjanappa</name>
<email>jkrishnanjanappa@mvista.com</email>
</author>
<published>2018-08-14T14:35:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=138637e2b81bf2e2f0a797fedbb34cdc134c7a2b'/>
<id>urn:sha1:138637e2b81bf2e2f0a797fedbb34cdc134c7a2b</id>
<content type='text'>
It solves below error:
-- snip --
return 'qemu-system-%s' % qbsys
UnboundLocalError: local variable 'qbsys' referenced before assignment
-- snip --

[YOCTO #12846]

(From OE-Core rev: 519273f54c0b8a6fff36afeb7646d8e37717be22)

Signed-off-by: Jagadeesh Krishnanjanappa &lt;jkrishnanjanappa@mvista.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>logging: use warning instead warn</title>
<updated>2018-07-26T12:16:40+00:00</updated>
<author>
<name>Chen Qi</name>
<email>Qi.Chen@windriver.com</email>
</author>
<published>2018-07-19T05:47:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=869e501544960f638edfe17c9d7500b54d05837e'/>
<id>urn:sha1:869e501544960f638edfe17c9d7500b54d05837e</id>
<content type='text'>
The warn method is deprecated. We should use the documented warning instead.

Quoting from the python's official doc:
"""
Note: There is an obsolete method warn which is functionally identical to warning.
      As warn is deprecated, please do not use it - use warning instead.
"""

(From OE-Core rev: f467fd277eb77336097cfc0f5f329bdc8d0f70cb)

Signed-off-by: Chen Qi &lt;Qi.Chen@windriver.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>scripts/runqemu: fix qemumips qemumips64 memory detection kernel panic</title>
<updated>2018-07-10T16:33:00+00:00</updated>
<author>
<name>He Zhe</name>
<email>zhe.he@windriver.com</email>
</author>
<published>2018-07-09T03:14:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=c68e4c6e3eb612bb7afd9d7f1e9a6dc295d44346'/>
<id>urn:sha1:c68e4c6e3eb612bb7afd9d7f1e9a6dc295d44346</id>
<content type='text'>
$ runqemu qemumips64 core-image-minimal nographic qemuparams="-m 512"
...
[    0.000000] Call Trace:
[    0.000000] [&lt;ffffffff801268c0&gt;] clear_page+0x0/0x128
[    0.000000] [&lt;ffffffff80238158&gt;] get_page_from_freelist+0xab8/0xc00
[    0.000000] [&lt;ffffffff80238964&gt;] __alloc_pages_nodemask+0xdc/0xf68
[    0.000000] [&lt;ffffffff80239808&gt;] __get_free_pages+0x18/0x70
[    0.000000] [&lt;ffffffff80122a4c&gt;] setup_zero_pages+0x1c/0xb8
[    0.000000] [&lt;ffffffff80c7c998&gt;] mem_init+0x54/0xa0
[    0.000000] [&lt;ffffffff80c74904&gt;] start_kernel+0x204/0x4d8
[    0.000000] [&lt;ffffffff8091dfb0&gt;] kernel_entry+0x0/0x40
[    0.000000] Code: 02002025  1000f8d9  8e634d7c &lt;34860f80&gt; cc9e0000
cc9e0020  cc9e0040  cc9e0060  cc9e0080
[    0.000000]
[    0.000000] ---[ end trace 0000000000000000 ]---
[    0.000000] Kernel panic - not syncing: Attempted to kill the idle task!
[    0.000000] ---[ end Kernel panic - not syncing: Attempted to kill the idle task!
...

OE uses qemumips to simulate a Malta board by default.

As upstream qemu introduced:
https://git.qemu.org/?p=qemu.git;a=commit;h=94c2b6aff43cdfcfdfb552773a6b6b973a72ef0b

The Malta board can support up to 2GiB of RAM which should
be able to boot a Linux kernel built with CONFIG_HIGHMEM
enabled and passing "-m 2048" to QEMU and appending the
following kernel parameters:
...
mem=256M@0x0 mem=256M@0x90000000 mem=1536M@0x20000000
...

But the following commit in kernel broke above mem=X@Y setting
which added the memory as reserved memory area.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=73fbc1eba7ffa3bf0ad12486232a8a1edb4e4411
...
commit 73fbc1eba7ffa3bf0ad12486232a8a1edb4e4411
Author: Marcin Nowakowski &lt;marcin.nowakowski@imgtec.com&gt;
Date:   Wed Nov 23 14:43:49 2016 +0100

    MIPS: fix mem=X@Y commandline processing
...

So remove `mem=*' to disable user-defined physical RAM map
which let kernel itself caculates memory ranges.

Author: Hongxu Jia &lt;hongxu.jia@windriver.com&gt;
[ Merge the two fixes for qemumips32 and qemumips64 into one patch,
  and make it support all mips cases ]
(From OE-Core rev: 0220cb34a91658ecc3782ec1a4700dcb5ece37d8)

Signed-off-by: He Zhe &lt;zhe.he@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
