* [PATCH 1/2] runqemu: Automatically add a TFTP directory for slirp boot
@ 2017-03-24 16:12 Alistair Francis
2017-03-24 16:12 ` [PATCH 2/2] runqemu: Add a background command option Alistair Francis
2017-03-24 19:02 ` ✗ patchtest: failure for "runqemu: Automatically add a T..." and 1 more Patchwork
0 siblings, 2 replies; 3+ messages in thread
From: Alistair Francis @ 2017-03-24 16:12 UTC (permalink / raw)
To: openembedded-core, liezhi.yang, ross.burton
When booting QEMU with slirp networking we want to use QEMUs TFTP server
to make the images in deploy accessible to the guest.
Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
---
scripts/runqemu | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/runqemu b/scripts/runqemu
index 23c9efb..f76d976 100755
--- a/scripts/runqemu
+++ b/scripts/runqemu
@@ -832,7 +832,7 @@ class BaseConfig(object):
self.kernel_cmdline_script += ' ip=dhcp'
# Port mapping
hostfwd = ",hostfwd=tcp::2222-:22,hostfwd=tcp::2323-:23"
- qb_slirp_opt_default = "-netdev user,id=net0%s" % hostfwd
+ qb_slirp_opt_default = "-netdev user,id=net0%s,tftp=%s" % (hostfwd, self.get('DEPLOY_DIR_IMAGE'))
qb_slirp_opt = self.get('QB_SLIRP_OPT') or qb_slirp_opt_default
# Figure out the port
ports = re.findall('hostfwd=[^-]*:([0-9]+)-[^,-]*', qb_slirp_opt)
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] runqemu: Add a background command option
2017-03-24 16:12 [PATCH 1/2] runqemu: Automatically add a TFTP directory for slirp boot Alistair Francis
@ 2017-03-24 16:12 ` Alistair Francis
2017-03-24 19:02 ` ✗ patchtest: failure for "runqemu: Automatically add a T..." and 1 more Patchwork
1 sibling, 0 replies; 3+ messages in thread
From: Alistair Francis @ 2017-03-24 16:12 UTC (permalink / raw)
To: openembedded-core, liezhi.yang, ross.burton
This allows callers to specify commands that should be run in the background
while running QEMU. This can be specified by assigning the commands to the
'QB_BACKGROUND_COMMAND' varialbe in the machine conf.
This is useful for starting automated debugging instances, automated
testing instances (using QMP) or other servers/clients that QEMU can
connect to.
Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
---
documentation/ref-manual/migration.xml | 2 ++
scripts/runqemu | 7 +++++++
2 files changed, 9 insertions(+)
diff --git a/documentation/ref-manual/migration.xml b/documentation/ref-manual/migration.xml
index 2bdb542..15db364 100644
--- a/documentation/ref-manual/migration.xml
+++ b/documentation/ref-manual/migration.xml
@@ -3581,6 +3581,8 @@ $ runqemu qemux86-64 tmp/deploy/images/qemux86-64/core-image-minimal-qemux86-64.
QB_TCPSERIAL_OPT: tcp serial port option (e.g.
" -device virtio-serial-device -chardev socket,id=virtcon,port=@PORT@,host=127.0.0.1 -device virtconsole,chardev=virtcon"
runqemu will replace "@PORT@" with the port number which is used.
+ QB_BACKGROUND_COMMAND: If specified this command is run in the background while
+ running QEMU.
</literallayout>
</para>
diff --git a/scripts/runqemu b/scripts/runqemu
index f76d976..b5cc56a 100755
--- a/scripts/runqemu
+++ b/scripts/runqemu
@@ -1118,6 +1118,13 @@ class BaseConfig(object):
kernel_opts += " -dtb %s" % self.dtb
else:
kernel_opts = ""
+ background_cmd = self.get('QB_BACKGROUND_COMMAND')
+
+ if background_cmd:
+ logger.info('Running in the background %s' % background_cmd)
+ if subprocess.call(background_cmd + ' &', shell=True) != 0:
+ raise Exception('Failed to run %s' % cmd)
+
cmd = "%s %s" % (self.qemu_opt, kernel_opts)
logger.info('Running %s' % cmd)
if subprocess.call(cmd, shell=True) != 0:
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* ✗ patchtest: failure for "runqemu: Automatically add a T..." and 1 more
2017-03-24 16:12 [PATCH 1/2] runqemu: Automatically add a TFTP directory for slirp boot Alistair Francis
2017-03-24 16:12 ` [PATCH 2/2] runqemu: Add a background command option Alistair Francis
@ 2017-03-24 19:02 ` Patchwork
1 sibling, 0 replies; 3+ messages in thread
From: Patchwork @ 2017-03-24 19:02 UTC (permalink / raw)
To: Alistair Francis; +Cc: openembedded-core
== Series Details ==
Series: "runqemu: Automatically add a T..." and 1 more
Revision: 1
URL : https://patchwork.openembedded.org/series/5965/
State : failure
== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:
* Issue Series does not apply on top of target branch [test_series_merge_on_head]
Suggested fix Rebase your series on top of targeted branch
Targeted branch master (currently at 3b5ac72bdf)
If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).
---
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-03-24 19:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-24 16:12 [PATCH 1/2] runqemu: Automatically add a TFTP directory for slirp boot Alistair Francis
2017-03-24 16:12 ` [PATCH 2/2] runqemu: Add a background command option Alistair Francis
2017-03-24 19:02 ` ✗ patchtest: failure for "runqemu: Automatically add a T..." and 1 more Patchwork
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox